1424 列表上增加最后一条通知时间,并且可以看到最后一条通知内容。
Showing
1 changed file
with
13 additions
and
6 deletions
@@ -186,19 +186,19 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl | @@ -186,19 +186,19 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl | ||
186 | cols: [[{ | 186 | cols: [[{ |
187 | type: 'checkbox' | 187 | type: 'checkbox' |
188 | }, { | 188 | }, { |
189 | - field: 'name', title: '名称', align: 'center', width: '15%', | 189 | + field: 'name', title: '名称', align: 'center', minWidth: '100', |
190 | templet: | 190 | templet: |
191 | '<div>' + | 191 | '<div>' + |
192 | ' <span data-id="{{d.id}}" class="link link-noticeTimely-edit">{{d.name}}</span>' + | 192 | ' <span data-id="{{d.id}}" class="link link-noticeTimely-edit">{{d.name}}</span>' + |
193 | '</div>' | 193 | '</div>' |
194 | }, { | 194 | }, { |
195 | - field: 'details', title: '内容', align: 'left', width: '25%', | 195 | + field: 'details', title: '内容', align: 'left', width: '15%', |
196 | templet: function (d) { | 196 | templet: function (d) { |
197 | // return '<input type="text" class="layui-input" style= "background-color:transparent;border:0;padding-bottom: 10px" readonly="readonly" name="details" value="' + d.details + '">' | 197 | // return '<input type="text" class="layui-input" style= "background-color:transparent;border:0;padding-bottom: 10px" readonly="readonly" name="details" value="' + d.details + '">' |
198 | return '<code>' + d.details + '</code>' | 198 | return '<code>' + d.details + '</code>' |
199 | } | 199 | } |
200 | }, { | 200 | }, { |
201 | - field: 'frequency', title: '频率', align: 'center', minWidth: '130' | 201 | + field: 'frequency', title: '频率', align: 'center', minWidth: '120' |
202 | }, { | 202 | }, { |
203 | field: 'noticeNicknames', title: '用户', align: 'center', minWidth: '180' | 203 | field: 'noticeNicknames', title: '用户', align: 'center', minWidth: '180' |
204 | }, { | 204 | }, { |
@@ -209,17 +209,24 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl | @@ -209,17 +209,24 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl | ||
209 | return ''; | 209 | return ''; |
210 | } | 210 | } |
211 | },{ | 211 | },{ |
212 | - field: 'state', title: '是否启用', align: 'center', minWidth: '100', | 212 | + field: 'lastSendContent', title: '最后发送内容', align: 'center', minWidth: '200',templet: function (d) { |
213 | + if(d.noticeStateNew && d.noticeStateNew.sendContent){ | ||
214 | + return d.noticeStateNew.sendContent; | ||
215 | + } | ||
216 | + return ''; | ||
217 | + } | ||
218 | + },{ | ||
219 | + field: 'state', title: '是否启用', align: 'center', minWidth: '60', | ||
213 | templet: function (d) { | 220 | templet: function (d) { |
214 | var checked = d.state == 2 ? 'checked' : ''; | 221 | var checked = d.state == 2 ? 'checked' : ''; |
215 | return '<div><input type="checkbox" data-id="' + d.id + '" lay-filter="switch_noticeTimely_checkbox_state" name="state" lay-skin="switch" lay-text="启用|禁用" ' + checked + ' ></div>' | 222 | return '<div><input type="checkbox" data-id="' + d.id + '" lay-filter="switch_noticeTimely_checkbox_state" name="state" lay-skin="switch" lay-text="启用|禁用" ' + checked + ' ></div>' |
216 | } | 223 | } |
217 | }, { | 224 | }, { |
218 | - title: '操作', align: 'center', minWidth: '120', fixed: 'right', | 225 | + title: '操作', align: 'center', minWidth: '80', fixed: 'right', |
219 | templet: | 226 | templet: |
220 | '<div>' + | 227 | '<div>' + |
221 | ' <button data-id="{{d.id}}" class="layui-btn layui-btn-xs layui-btn-normal link-noticeTimely-delete" lay-tips="删除"><i class="layui-icon"></i></button>' + | 228 | ' <button data-id="{{d.id}}" class="layui-btn layui-btn-xs layui-btn-normal link-noticeTimely-delete" lay-tips="删除"><i class="layui-icon"></i></button>' + |
222 | - ' <button data-id="{{d.id}}" class="layui-btn layui-btn-xs layui-btn-normal link-noticeTimely-history" lay-tips="历史记录"><i class="layui-icon"></i></button>' + | 229 | + ' <button data-id="{{d.id}}" class="layui-btn layui-btn-xs layui-btn-normal link-noticeTimely-history" lay-tips="历史记录"><i class="layui-icon"></i></button>' + |
223 | '</div>' | 230 | '</div>' |
224 | }]], | 231 | }]], |
225 | done: function (res) { | 232 | done: function (res) { |
-
Please register or login to post a comment