|
@@ -71,11 +71,17 @@ layui.use(['element','mylayer','newtable','laydate','myform','page'], function (
|
|
toolbarExtraData:setting.userId,
|
|
toolbarExtraData:setting.userId,
|
|
cols:[[
|
|
cols:[[
|
|
{type: 'numbers', title: '序号', width: '60',fixed: 'left'},
|
|
{type: 'numbers', title: '序号', width: '60',fixed: 'left'},
|
|
- {field: 'customNum', title: '自编号', width:120,fixed: 'left',templet:function(d){
|
|
|
|
- return d.discardIf==1?("<font color='red'>"+d.customNum+"</font>"):d.customNum;
|
|
|
|
|
|
+ {field: 'customNum', title: '自编号', width:100,align:'center',fixed: 'left',templet:function(d){
|
|
|
|
+ let cls=d.discardIf==1?'discard-car':'';
|
|
|
|
+ if("是"==d.customTag){
|
|
|
|
+ cls=cls+" outside-car";
|
|
|
|
+ }
|
|
|
|
+ return "<div class=\""+cls+"\">"+d.customNum+"</div>";
|
|
}},
|
|
}},
|
|
{field: 'carNum', title: '牌照号', width:120,fixed: 'left'},
|
|
{field: 'carNum', title: '牌照号', width:120,fixed: 'left'},
|
|
{field: 'belongOrgName', title: '所属单位', width:180,align:'center'},
|
|
{field: 'belongOrgName', title: '所属单位', width:180,align:'center'},
|
|
|
|
+ {field: 'customTag', title: '是否托管', width:120,align:'center'},
|
|
|
|
+
|
|
{field: 'deviceName', title: '设备名称', width:220,sort:true},
|
|
{field: 'deviceName', title: '设备名称', width:220,sort:true},
|
|
{field: 'deviceModel', title: '规格型号', width:260,sort:true},
|
|
{field: 'deviceModel', title: '规格型号', width:260,sort:true},
|
|
{field: 'quotaPower', title: '额定功率(kw)', width:160},
|
|
{field: 'quotaPower', title: '额定功率(kw)', width:160},
|
|
@@ -85,7 +91,7 @@ layui.use(['element','mylayer','newtable','laydate','myform','page'], function (
|
|
{field: 'oilType', title: '燃油类型', width:110,align:'center'},
|
|
{field: 'oilType', title: '燃油类型', width:110,align:'center'},
|
|
|
|
|
|
{field: 'coilCarTypeName', title: '柴油车辆类型', width:140,align:'center'},
|
|
{field: 'coilCarTypeName', title: '柴油车辆类型', width:140,align:'center'},
|
|
- {field: 'op', title: '操作', width:260,align:'center',toolbar:'#toolbar'}
|
|
|
|
|
|
+ {field: 'op', title: '操作', width:300,align:'center',toolbar:'#toolbar'}
|
|
|
|
|
|
]]
|
|
]]
|
|
});
|
|
});
|
|
@@ -240,6 +246,22 @@ layui.use(['element','mylayer','newtable','laydate','myform','page'], function (
|
|
maxmin :true
|
|
maxmin :true
|
|
});
|
|
});
|
|
}
|
|
}
|
|
|
|
+ else if(layEvent === 'insideTag'||layEvent === 'outsideTag'){
|
|
|
|
+ page.ajax({
|
|
|
|
+ url:"car/setTag.do",
|
|
|
|
+ data:{carId:data.carId,tag:(layEvent === 'outsideTag'?'是':'否')}
|
|
|
|
+ },function(resp){
|
|
|
|
+ if(!resp.success){
|
|
|
|
+ layer.msg(resp.exception);
|
|
|
|
+ }
|
|
|
|
+ else{
|
|
|
|
+ layer.msg("操作成功");
|
|
|
|
+ table.refresh("LAY-tab-car");
|
|
|
|
+ }
|
|
|
|
+ },function(){
|
|
|
|
+ layer.msg("网络请求出现错误");
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
|
|
});
|
|
});
|
|
|
|
|