12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485 |
- {extend name="common/common2" /}
- {block name="main"}
- <div class="ibox">
- <div class="ibox-content">
- <div class="jqGrid_wrapper">
- <table id="table" style="border-collapse: collapse"></table>
- <div id="pager"></div>
- </div>
- </div>
- </div>
- {/block}
- {block name="script"}
- <script src="/static/layDate-v5.0.9/laydate.js"></script>
- <script>
- $(function () {
- laydate.render({
- elem: '#start',
- trigger: 'click' ,
- theme: '#284a94'
- });
- laydate.render({
- elem: '#end',
- trigger: 'click' ,
- theme: '#284a94'
- });
- $(window).bind("resize",function(){
- var width=$(".jqGrid_wrapper").width();
- $("#table").setGridWidth(width);
- });
- $.jgrid.defaults.styleUI="Bootstrap";
- $("#table").jqGrid({
- url:"{:url('bhTodoList',[],'')}",
- datatype: "json",
- colModel:[
- {label:'运送类型',name:'type_name',index:'type_name',width:60,editable: false,sortable: false},
- {label:'描述',name:'content',index:'content',width:50,sortable: true},
- {label:'始发',name:'start_name',index:'start_name',width:40,sortable: true},
- {label:'到达',name:'end_name',index:'end_name',width:60,sortable: true},
- {label:'运送员',name:'real_names',index:'real_names',width:60,sortable: true},
- {label:'需求',name:'xtime',index:'xtime',width:60,sortable: true},
- {label:'派工',name:'stime',index:'stime',width:60,sortable: true},
- {label:'接受',name:'ctime',index:'ctime',width:60,sortable: true},
- {label:'优先级',name:'priorityName',index:'priorityName',width:60,sortable: true},
- {label:'运送设备',name:'device_name',index:'device_name',width:60,sortable: true},
- {label:'创建人',name:'real_name',index:'real_name',width:60,sortable: true},
- {label:'延迟原因',name:'delay_reason',index:'delay_reason',width:60,sortable: true},
- {label:'延迟时间',name:'delay_diff',index:'delay_diff',width:60,sortable: true},
- {label:'剩余时间',name:'last_time',index:'last_time',width:60,sortable: true},
- {label:'操作',width:100,sortable: false,formatter: function (a, b, c) {
- var send_url = "{:url('Todo/send',[],'')}/id/"+c.id+'/mode/'+c.work_type_mode;
- var cancel_url = "{:url('Todo/disCancel',[],'')}/id/"+c.id;
- var btn = '';
- btn += '<a url="'+send_url+'" href="javascript:;" data-title="重新派单" onclick="layer_open(this,1)"><span class="label label-primary" title="重新派单">重新派单</span></a> ';
- btn += '<a url="'+cancel_url+'" href="javascript:;" data-title="取消" onclick="layer_open(this,1)"><span class="label label-danger" title="取消">取消</span></a>';
- return btn;
- }},
- ],
- rowNum:10,
- rowList:[10,20,30,50,100],
- pager: '#pager',
- sortname: 'id',
- viewrecords: true,
- autowidth:true,
- mtype: 'post',
- height: 'auto',
- emptyrecords: "暂无数据",
- sortorder: "desc",
- caption:"驳回工单列表",
- loadComplete: function (xhr) {
- if(xhr.code==0){
- layer.msg(xhr.msg);
- return false;
- }
- },
- });
- });
- </script>
- {/block}
|