diff --git a/js/car_basic/child/driver_re_detail.js b/js/car_basic/child/driver_re_detail.js
new file mode 100644
index 0000000..0d27506
--- /dev/null
+++ b/js/car_basic/child/driver_re_detail.js
@@ -0,0 +1,248 @@
+let objParam;
+let form, table, tableIns, layer, element;
+let pageNum = 1;
+
+function setParams(params) {
+ objParam = JSON.parse(params);
+ layui.use(["form", "table", 'layer', 'element'], function () {
+ form = layui.form;
+ table = layui.table;
+ element = layui.element;
+ layer = layui.layer;
+ initTable();
+ });
+}
+
+// 查询/重置
+function queryTable(type) {
+ if (type === 1) {
+ let code = $('#code').val();
+ let flag = checkValue(code);
+ if (flag) {
+ $('#code').val('');
+ return layer.msg('需求计划编号查询包含特殊字符,请重新输入', { icon: 2 });
+ }
+ reloadTable(1);
+ } else if (type === 2) {
+ $('#code').val('');
+ $('#status').val('');
+ layui.form.render();
+ reloadTable(1);
+ }
+}
+
+// 刷新页面数据
+function reloadData() {
+ reloadTable(pageNum);
+}
+
+// 重载表格
+function reloadTable(pageNum) {
+ table.reload("currentTableId", {
+ page: {
+ curr: pageNum ? pageNum : 1,
+ },
+ where: {
+ encryptedData: JSON.stringify({
+ 'code': $('#code').val(),
+ 'status': $('#status').val(),
+ 'proId': objParam.proId
+ }),
+ },
+ },
+ );
+}
+
+// 初始化表格
+function initTable() {
+ tableIns = table.render({
+ elem: "#currentTableId",
+ id: 'currentTableId',
+ headers: {
+ authorization: sessionStorage.getItem("gz-token"),
+ },
+ height: "full-250",
+ url: dataUrl + "backstage/carDriver/getRePlan",
+ where: {
+ encryptedData: JSON.stringify({
+ 'id': objParam.id
+ }),
+ },
+ request: {
+ pageName: 'pageNum',
+ limitName: 'pageSize'
+ },
+ parseData: function (res) { // res 即为原始返回的数据
+ if (res.code === 401) {
+ closeWindowOpen();
+ }
+ return {
+ "code": 0, // 解析接口状态
+ "msg": '获取成功', // 解析提示文本
+ "count": res.total, // 解析数据长度
+ "data": res.list // 解析数据列表
+ };
+ },
+ cols: [
+ [
+ {
+ width: '5%',
+ title: "序号",
+ align: "center",
+ templet: function (d) {
+ return d.LAY_NUM;
+ },
+ },
+ {
+ field: "typeName",
+ width: '19%',
+ title: "计划类型",
+ unresize: true,
+ align: "center",
+ sort:true,
+ },
+ {
+ field: "code",
+ width: '19%',
+ title: "需求计划
编号",
+ unresize: true,
+ align: "center",
+ sort:true,
+ templet: function (d) {
+ return "" + d.code + "";
+ },
+ },
+ {
+ field: "userName",
+ width: '19%',
+ title: "申请人",
+ unresize: true,
+ align: "center",
+ sort:true,
+ },
+ {
+ field: "appLyTime",
+ title: "申请时间",
+ width: '19%',
+ unresize: true,
+ align: "center",
+ sort:true,
+ },
+ {
+ field: "remark",
+ title: "备注",
+ width: '19%',
+ unresize: true,
+ align: "center",
+ sort:true,
+ templet: function (d) {
+ if (d.remark) {
+ if (d.remark.length > 60) {
+ return '' + d.remark.substring(0, 60) + '...'
+ } else {
+ return '' + d.remark + ''
+ }
+ } else {
+ return '';
+ }
+ },
+ },
+ ],
+ ],
+ limits: [10, 15, 20, 25, 50, 100],
+ limit: 10,
+ page: true,
+ done: function (res, curr, count) {
+ pageNum = tableIns.config.page.curr;
+ table.resize("currentTableId");
+ },
+ });
+}
+
+
+// 导出
+function exportExcel() {
+ let params = {
+ 'planCode': $('#planCode').val(),
+ 'status': $('#status').val(),
+ 'proId': objParam.proId
+ }
+ let url = dataUrl + "backstage/purchase/exportDetails";
+ exportExcelUtil(url, '需求计划详情', JSON.stringify(params));
+}
+
+// 详情
+function dispatchCarDetail(obj, type) {
+ let flag = isExistData(type, obj);
+ if (!flag && type === 1) {
+ return layer.msg('暂无派车批次数据', { icon: 7 });
+ } else if (!flag && type === 2) {
+ return layer.msg('暂无待审核批次数据', { icon: 7 });
+ }
+ let title = '详情';
+ if (type === 2) {
+ title = '审核';
+ }
+ obj.type = type;
+ openIframeByParamObj2("dispatchCarDetail", title, "../car_demand_plan/child/dispatch_car_detail.html", "92%", "95%", obj, 2);
+}
+
+// 修改记录
+function editRecord(obj) {
+ let flag = isExistData(3, obj);
+ if (!flag) {
+ return layer.msg('暂无派车批次数据', { icon: 7 });
+ }
+ openIframeByParamObj2("editRecord", "修改记录", "../car_demand_plan/child/dispatch_car_edit_record_list.html", "92%", "95%", obj);
+}
+
+// 派车分配
+function dispatchCarAllocation(obj) {
+ openIframeByParamObj("dispatchCarAllocation", "派车分配", "./dispatch_car_allocation_form.html", "92%", "95%", obj);
+}
+
+// 刷新页面数据
+function refreshAllData() {
+ getProStatisticsDetails();
+ reloadData();
+}
+
+// 需求计划详情
+function viewPlanDetail(obj) {
+ openIframeByParamObj2("viewPlanDetail", "需求计划详情", "../car_demand_plan/child/apply_plan_detail.html", "92%", "95%", obj);
+}
+
+// 分配错误修改
+function allocationError() {
+ openIframeByParamObj("allocationError", "分配错误修改", "./allocation_error_form.html", "50%", "65%", objParam);
+}
+
+// 校验是否存在派车批次数据、待审核批次数据
+function isExistData(type, obj) {
+ let flag = true;
+ let params = {
+ encryptedData: JSON.stringify({
+ 'planId': obj.id,
+ })
+ };
+ let url = ''
+ if (type === 1 || type === 3) {
+ url = dataUrl + 'backstage/supDispatchCar/getAllOutList'; // 详情-派车批次
+ } else if (type === 2) { // 审核-待审核批次
+ url = dataUrl + 'backstage/dispatchCar/getAuditListNew';
+ }
+ ajaxRequest(url, "POST", params, false, function () {
+ }, function (result) {
+ if (result.code === 200) {
+ if (result.data.length === 0 && (type === 1 || type === 3)) {
+ flag = false;
+ } else if (result.data.length === 0 && type === 2) {
+ flag = false;
+ }
+ } else {
+ }
+ }, function (xhr, status, error) {
+ errorFn(xhr, status, error)
+ }, null);
+ return flag;
+}
\ No newline at end of file
diff --git a/js/car_basic/driver_white_list.js b/js/car_basic/driver_white_list.js
index da6334d..6958927 100644
--- a/js/car_basic/driver_white_list.js
+++ b/js/car_basic/driver_white_list.js
@@ -95,7 +95,7 @@ function initTable() {
},
{
field: "name",
- width: '12%',
+ width: '10%',
title: "姓名",
unresize: true,
align: "center",
@@ -103,7 +103,7 @@ function initTable() {
},
{
field: "phone",
- width: '12%',
+ width: '10%',
title: "联系方式",
unresize: true,
align: "center",
@@ -111,7 +111,7 @@ function initTable() {
},
{
field: "sfzNum",
- width: '12%',
+ width: '10%',
title: "身份证",
unresize: true,
align: "center",
@@ -122,7 +122,7 @@ function initTable() {
},
{
field: "jszNum",
- width: '12%',
+ width: '10%',
title: "驾驶证",
unresize: true,
align: "center",
@@ -133,7 +133,7 @@ function initTable() {
},
{
field: "otherNum",
- width: '12%',
+ width: '10%',
title: "其他操作证",
unresize: true,
align: "center",
@@ -150,6 +150,19 @@ function initTable() {
align: "center",
sort:true,
},
+ {
+ field: "num",
+ width: '10%',
+ title: "关联计划",
+ unresize: true,
+ align: "center",
+ sort:true,
+ templet: function (d) {
+ let html = "";
+ html += ""+d.num+"";
+ return html;
+ },
+ },
{
title: "操作",
width: '13%',
@@ -175,6 +188,11 @@ function initTable() {
});
}
+// 关联详情
+function reDetail(obj) {
+ openIframeByParamObj("reDetail", "关联详情", "./child/driver_re_detail.html", "92%", "95%", obj, 1);
+}
+
// 导出
function exportExcel() {
let params = {
diff --git a/js/car_demand_plan/child/dispatch_car_pro_detail.js b/js/car_demand_plan/child/dispatch_car_pro_detail.js
index 5707ca3..1d9370f 100644
--- a/js/car_demand_plan/child/dispatch_car_pro_detail.js
+++ b/js/car_demand_plan/child/dispatch_car_pro_detail.js
@@ -260,7 +260,9 @@ function initTable() {
html += "