diff --git a/js/car_basic/car_list.js b/js/car_basic/car_list.js index 4f2fa0d..fd7326f 100644 --- a/js/car_basic/car_list.js +++ b/js/car_basic/car_list.js @@ -86,7 +86,7 @@ function initTable() { cols: [ [ { - width: '6.9%', + width: '5%', title: "序号", align: "center", templet: function (d) { @@ -95,7 +95,7 @@ function initTable() { }, { field: "carNum", - width: '9%', + width: '7%', title: "车牌号", unresize: true, align: "center", @@ -119,7 +119,7 @@ function initTable() { }, { field: "ton", - width: '11%', + width: '10%', title: "车辆吨位(T)", unresize: true, align: "center", @@ -130,7 +130,7 @@ function initTable() { }, { field: "xyNum", - width: '8%', + width: '7%', title: "挂靠协议", unresize: true, align: "center", @@ -141,7 +141,7 @@ function initTable() { }, { field: "bxNum", - width: '8%', + width: '7%', title: "车辆保险", unresize: true, sort:true, @@ -152,7 +152,7 @@ function initTable() { }, { field: "xszNum", - width: '8%', + width: '7%', title: "行驶证", unresize: true, sort:true, @@ -163,7 +163,7 @@ function initTable() { }, { field: "bxDay", - width: '12%', + width: '11%', title: "车辆保险到期日期", unresize: true, align: "center", @@ -177,6 +177,17 @@ function initTable() { align: "center", sort:true, }, + { + field: "isWhiteList", + width: '9%', + title: "是否为白名单", + unresize: true, + align: "center", + sort:true, + templet: function (d) { + return (d.isWhiteList===1 ? "是" : "否"); + }, + }, { title: "操作", width: '10%', diff --git a/js/car_basic/child/car_detail.js b/js/car_basic/child/car_detail.js index 182f432..c2fdfe2 100644 --- a/js/car_basic/child/car_detail.js +++ b/js/car_basic/child/car_detail.js @@ -38,6 +38,11 @@ function getCarCarDetails() { $('#ton').html(obj.ton + ' 吨 '); $('#bxDay').html(obj.bxDay); $('#supName').html(obj.supName); + if (obj.isWhiteList===1){ + $('#isWhiteList').html("是"); + } else { + $('#isWhiteList').html("否") + } setFileTable(obj.fileList); } } diff --git a/js/car_basic/child/car_edit_form.js b/js/car_basic/child/car_edit_form.js index 39f09bc..01b0e5d 100644 --- a/js/car_basic/child/car_edit_form.js +++ b/js/car_basic/child/car_edit_form.js @@ -1,5 +1,6 @@ let form, layer, laydate, fileList = new Array(), imgListUp = new Array(), delImgIdList = [], delImgTypeList = []; let objParam; // 是否保存并继续 +let isWhiteList=0; function setParams(obj) { objParam = JSON.parse(obj); layui.use(['form', 'layer', 'laydate', 'upload'], function () { @@ -31,6 +32,11 @@ function setParams(obj) { } } }); + // 监听radio选择变化 + form.on('radio(isWhiteList)', function (data) { + isWhiteList=data.value; + console.log(isWhiteList); + }); form.on('submit(formData)', function (data) { submitApply(data); }); @@ -198,6 +204,7 @@ function getCarCarDetails() { // 表单赋值 function setFormData(obj) { + isWhiteList=obj.isWhiteList; form.val('formInfo', obj); let fileList = obj.fileList, html = '', cent = ''; for (let i = 0; i < fileList.length; i++) { diff --git a/js/car_basic/child/car_form.js b/js/car_basic/child/car_form.js index d8c07de..1682c5a 100644 --- a/js/car_basic/child/car_form.js +++ b/js/car_basic/child/car_form.js @@ -1,5 +1,6 @@ let form, layer, laydate, fileList = new Array(), imgListUp = new Array();; let objParam; // 是否保存并继续 +let isWhiteList=0; function setParams(obj) { objParam = JSON.parse(obj); layui.use(['form', 'layer', 'laydate', 'upload'], function () { @@ -31,6 +32,11 @@ function setParams(obj) { } } }); + // 监听radio选择变化 + form.on('radio(isWhiteList)', function (data) { + isWhiteList=data.value; + console.log(isWhiteList); + }); form.on('submit(formData)', function (data) { submitApply(data); }); diff --git a/js/car_basic/child/driver_detail.js b/js/car_basic/child/driver_detail.js index 314a91c..bf6f705 100644 --- a/js/car_basic/child/driver_detail.js +++ b/js/car_basic/child/driver_detail.js @@ -35,6 +35,11 @@ function getDriverDetails() { $('#name').html(obj.name); $('#phone').html(obj.phone); $('#supName').html(obj.supName); + if (obj.isWhiteList===1){ + $('#isWhiteList').html("是"); + } else { + $('#isWhiteList').html("否") + } setFileTable(obj.fileList); } } diff --git a/js/car_basic/child/driver_edit_form.js b/js/car_basic/child/driver_edit_form.js index 933e33b..267b3b7 100644 --- a/js/car_basic/child/driver_edit_form.js +++ b/js/car_basic/child/driver_edit_form.js @@ -1,5 +1,6 @@ let form, layer, laydate, fileList = new Array(), imgListUp = new Array(), delImgIdList = [], delImgTypeList = []; let objParam; // 是否保存并继续 +let isWhiteList=0; function setParams(obj) { objParam = JSON.parse(obj); layui.use(['form', 'layer', 'laydate', 'upload'], function () { @@ -17,6 +18,11 @@ function setParams(obj) { } }, }); + // 监听radio选择变化 + form.on('radio(isWhiteList)', function (data) { + isWhiteList=data.value; + console.log(isWhiteList); + }); form.on('submit(formData)', function (data) { submitApply(data); }); @@ -180,6 +186,7 @@ function getCarCarDetails() { // 表单赋值 function setFormData(obj) { + isWhiteList=obj.isWhiteList; form.val('formInfo', obj); let fileList = obj.fileList, html = '', cent = ''; for (let i = 0; i < fileList.length; i++) { diff --git a/js/car_basic/child/driver_form.js b/js/car_basic/child/driver_form.js index ac157bd..d51cced 100644 --- a/js/car_basic/child/driver_form.js +++ b/js/car_basic/child/driver_form.js @@ -1,5 +1,6 @@ let form, layer, laydate, fileList = new Array(), imgListUp = new Array();; let objParam; // 是否保存并继续 +let isWhiteList=0; function setParams(obj) { objParam = JSON.parse(obj); layui.use(['form', 'layer', 'laydate', 'upload'], function () { @@ -17,6 +18,11 @@ function setParams(obj) { } }, }); + // 监听radio选择变化 + form.on('radio(isWhiteList)', function (data) { + isWhiteList=data.value; + console.log(isWhiteList); + }); form.on('submit(formData)', function (data) { submitApply(data); }); diff --git a/js/car_basic/driver_list.js b/js/car_basic/driver_list.js index f14c423..25e036c 100644 --- a/js/car_basic/driver_list.js +++ b/js/car_basic/driver_list.js @@ -95,7 +95,7 @@ function initTable() { }, { field: "name", - width: '15%', + width: '10%', title: "姓名", unresize: true, align: "center", @@ -103,7 +103,7 @@ function initTable() { }, { field: "phone", - width: '15%', + width: '10%', title: "联系方式", unresize: true, align: "center", @@ -150,6 +150,17 @@ function initTable() { align: "center", sort:true, }, + { + field: "isWhiteList", + width: '10%', + title: "是否为白名单", + unresize: true, + align: "center", + sort:true, + templet: function (d) { + return (d.isWhiteList===1 ? "是" : "否"); + }, + }, { title: "操作", width: '13%', diff --git a/js/welcome/data_datail_pro_list.js b/js/welcome/data_datail_pro_list.js index d99bac1..dbe4491 100644 --- a/js/welcome/data_datail_pro_list.js +++ b/js/welcome/data_datail_pro_list.js @@ -217,6 +217,9 @@ function setStatusColor(value) { } else if (value === '3') { color = "#19be6b"; name = '全部派车' + } else if (value === '4') { + color = "#f56c6c"; + name ='待分配' } return ' ● '+name+''; } diff --git a/js/welcome/data_detail_common.js b/js/welcome/data_detail_common.js index 4b7b77e..244eda3 100644 --- a/js/welcome/data_detail_common.js +++ b/js/welcome/data_detail_common.js @@ -23,7 +23,7 @@ function loadCompanyData() { // 派车状态 function loadDispatchStatusData(type) { - let list = [{ id: 'dispatch-0', labelName: '全部' }, { id: 'dispatch-1', labelName: '部分派车' }, { id: 'dispatch-2', labelName: '待派车' }, { id: 'dispatch-3', labelName: '全部派车' }]; + let list = [{ id: 'dispatch-0', labelName: '全部' }, { id: 'dispatch-1', labelName: '部分派车' }, { id: 'dispatch-2', labelName: '待派车' }, { id: 'dispatch-3', labelName: '全部派车' }, { id: 'dispatch-4', labelName: '待分配' }]; if(type){ list = [{ id: 'dispatch-0', labelName: '全部' }, { id: 'dispatch-1', labelName: '待派车' }, { id: 'dispatch-2', labelName: '已派车' }]; } diff --git a/page/car_basic/child/car_detail.html b/page/car_basic/child/car_detail.html index 09a9851..1bbcadb 100644 --- a/page/car_basic/child/car_detail.html +++ b/page/car_basic/child/car_detail.html @@ -40,13 +40,13 @@