wupengfei %!s(int64=2) %!d(string=hai) anos
pai
achega
f2a2cc8475

+ 23 - 0
application/admin/view/official/index-mall-notice.html

@@ -0,0 +1,23 @@
+<form onsubmit="return false;" data-auto="true" action="{:url('save')}" method="post" class='layui-form layui-card' autocomplete="off">
+
+    <div class="layui-card-body padding-40">
+        <label class="layui-form-item block relative">
+            <span class="color-green margin-right-10">公告标题</span><span class="nowrap color-desc">MallNoticeTitle</span>
+            <input name="mall_notice_title"   required placeholder="请输入公告标题" value="{:sysconf('mall_notice_title')}" class="layui-input">
+        </label>
+
+        <label class="layui-form-item margin-top-20 block relative">
+            <span class="color-green margin-right-10">公告内容</span><span class="nowrap color-desc">MallNoticeContent</span>
+            <textarea name="mall_notice_content">{:sysconf('mall_notice_content')}</textarea>
+        </label>
+        <div class="layui-form-item text-center margin-top-20">
+            <button class="layui-btn" type="submit">保存配置</button>
+        </div>
+    </div>
+    <script>
+        window.form.render();
+        require(['ckeditor', 'angular'], function () {
+            window.createEditor('[name="mall_notice_content"]', {height: 500});
+        })
+    </script>
+</form>

+ 3 - 1
application/admin/view/official/index.html

@@ -6,12 +6,14 @@
     <ul class="layui-tab-title notselect">
         <li data-type="store-config-type-sms1">配置信息</li>
         <li data-type="store-config-type-sms2">使用协议</li>
-        <li data-type="store-config-type-sms2">店铺公告</li>
+        <li data-type="store-config-type-sms2">首页公告</li>
+        <li data-type="store-config-type-sms2">商城公告</li>
     </ul>
     <div class="layui-tab-content">
         <div class="layui-tab-item">{include file='official/platform-set'}</div>
         <div class="layui-tab-item">{include file='official/index-agreement'}</div>
         <div class="layui-tab-item">{include file='official/index-notice'}</div>
+        <div class="layui-tab-item">{include file='official/index-mall-notice'}</div>
 
     </div>
 </div>

+ 5 - 3
application/api/controller/Expedite.php

@@ -146,12 +146,14 @@ class Expedite extends Base
      * @method GET
      * @param name:search_name type:string default:-- desc:根据下面名称查(不传查全部的)
      * @return name:agreement type:string default:-- desc:用户协议【使用协议】富文本
-     * @return name:notice_title type:string default:-- desc:公告标题【字符串】
-     * @return name:notice_content type:string default:-- desc:公告内容【富文本】
+     * @return name:notice_title type:string default:-- desc:首页公告标题【字符串】
+     * @return name:notice_content type:string default:-- desc:首页公告内容【富文本】
+     * @return name:mall_notice_title type:string default:-- desc:商城公告内容【字符串】
+     * @return name:mall_notice_content type:string default:-- desc:商城公告内容【富文本】
      */
     public function getSysConfig(){
         $search_name = input('get.search_name');
-        $con_name = $search_name? [$search_name] : ['agreement','notice_title','notice_content'];
+        $con_name = $search_name? [$search_name] : ['agreement','notice_title','notice_content','mall_notice_title','mall_notice_content'];
         $set = Db::name('system_config')->where('name','in',$con_name)->select();
         $ret = [];
         foreach ($set as $value) {