From 8d508b9c84ea08ea4ea71ab8431a74587933215b Mon Sep 17 00:00:00 2001
From: jsasg <735273025@qq.com>
Date: Mon, 21 Apr 2025 17:30:50 +0800
Subject: [PATCH] =?UTF-8?q?feat:=20=E8=81=94=E7=B3=BB=E6=88=91=E4=BB=AC=20?=
=?UTF-8?q?-=20=E5=AE=A2=E6=88=B7=E6=9C=8D=E5=8A=A1?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app/index/common.php | 13 +++
app/index/controller/ContactUs.php | 31 +++++++
app/index/lang/en-us.php | 3 +
app/index/lang/zh-cn.php | 3 +
app/index/view/contact_us/index.html | 56 ++++++++++++
public/static/index/css/contactus_index.css | 96 +++++++++++++++++++++
6 files changed, 202 insertions(+)
create mode 100644 public/static/index/css/contactus_index.css
diff --git a/app/index/common.php b/app/index/common.php
index 12436156..724ba086 100644
--- a/app/index/common.php
+++ b/app/index/common.php
@@ -1,2 +1,15 @@
function($query) {
+ $query->withoutField(['status', 'created_at', 'updated_at', 'deleted_at'])
+ ->where('status', '=', 1)
+ ->order(['sort' => 'asc', 'id' => 'desc']);
+ }])
+ ->uniqueLabel(['BANNER_6805e3d32dcc2', 'BANNER_6806090c1838f'])
+ ->language($this->lang_id)
+ ->enabled(true)
+ ->select();
+ if (!$banner->isEmpty()) {
+ $banner_map = [];
+ foreach ($banner as $v) {
+ $banner_map[$v->unique_label] = $v;
+ }
+ $focus_image = data_get($banner_map, 'BANNER_6805e3d32dcc2')?->items->first()?->toArray();
+ $info_datas = data_get($banner_map, 'BANNER_6806090c1838f')?->items->each(function($item) {
+ if (Str::contains($item->title, '
')) {
+ $title = explode('
', $item->title);
+ $item->title = $title[0];
+ $item->title_short = $title[1];
+ }
+ return $item;
+ })->chunk(4)->toArray();
+ }
+ View::assign('focus_image', $focus_image);
+ View::assign('info_datas', $info_datas);
+
return View::fetch('index');
}
diff --git a/app/index/lang/en-us.php b/app/index/lang/en-us.php
index b154880f..b1e2042a 100644
--- a/app/index/lang/en-us.php
+++ b/app/index/lang/en-us.php
@@ -46,6 +46,9 @@ return [
'events' => 'Brand Events',
'development' => 'Tech Development',
],
+ 'contact_index' => [
+ 'title' => 'contact us',
+ ],
'contact_message' => [
'title' => 'contact us',
'our_information' => 'Our Information',
diff --git a/app/index/lang/zh-cn.php b/app/index/lang/zh-cn.php
index fd6c195e..54d68a19 100644
--- a/app/index/lang/zh-cn.php
+++ b/app/index/lang/zh-cn.php
@@ -46,6 +46,9 @@ return [
'events' => '品牌里程',
'development' => '品牌活动',
],
+ 'contact_index' => [
+ 'title' => '客户服务',
+ ],
'contact_message' => [
'title' => '联系我们',
'our_information' => '我们的信息',
diff --git a/app/index/view/contact_us/index.html b/app/index/view/contact_us/index.html
index e69de29b..728fb1b7 100644
--- a/app/index/view/contact_us/index.html
+++ b/app/index/view/contact_us/index.html
@@ -0,0 +1,56 @@
+{extend name="public/base" /}
+{block name="title"}
+