wupengfei 2 年之前
父节点
当前提交
ece24e0eca

+ 2 - 2
application/nutrition/controller/Channel.php

@@ -18,7 +18,7 @@ class Channel extends Controller
     protected $table = 'NewsChannel';
 
     /**
-     * 资讯素材
+     * 资讯栏目
      * @auth true
      * @menu true
      * @throws \think\Exception
@@ -29,7 +29,7 @@ class Channel extends Controller
      */
     public function index()
     {
-        $this->title = '资讯';
+        $this->title = '资讯栏目';
         $query = $this->_query($this->table)->where('is_deleted',0);
         $query->like('title');
         $query->order(' sort desc , id desc')->page();

+ 1 - 1
application/nutrition/view/channel/index.html

@@ -9,7 +9,7 @@
     <table class="layui-table margin-top-20" lay-skin="line">
         <thead>
         <tr>
-            <th class='text-left nowrap' style="width: 50%">标题</th>
+            <th class='text-left nowrap' style="width: 30%">标题</th>
             <th class='text-left nowrap'>描述</th>
             <th class='text-left nowrap'>状态</th>
             <th class="text-left nowrap" >操作</th>

+ 17 - 0
application/nutrition/view/news_manage/form.html

@@ -11,6 +11,23 @@
                 </div>
             </div>
 
+
+            <div class="layui-form-item">
+                <label class="layui-form-label label-required">资讯栏目</label>
+                <div class="layui-input-inline">
+                    <select name="first_classify" lay-filter ="first_classify">
+                        <option value="0">请选择</option>
+                        {foreach $news_channel as $nk=>$nv}
+                            {if  isset($vo.channel_id) && $vo.channel_id == $nk }
+                                <option selected value="{$nk}">{$nv}</option>
+                            {else}
+                                <option value="{$nk}">{$nv}</option>
+                            {/if}
+                        {/foreach}
+                    </select>
+                </div>
+            </div>
+
             <div class="layui-form-item">
                 <label class="layui-form-label label-required">分类</label>
                 <div class="layui-input-inline">