From 0620759090646bf58a7e786c55cfe07ce1984e45 Mon Sep 17 00:00:00 2001 From: Administrator <hbal> Date: 星期五, 31 三月 2023 10:11:23 +0800 Subject: [PATCH] 分单随行人员 --- WebContent/basic/js/formSplit.js | 43 +++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 41 insertions(+), 2 deletions(-) diff --git a/WebContent/basic/js/formSplit.js b/WebContent/basic/js/formSplit.js index 729ee8f..526293d 100644 --- a/WebContent/basic/js/formSplit.js +++ b/WebContent/basic/js/formSplit.js @@ -14,7 +14,9 @@ // var data_doDel = Mock.mock('/transport/yscompany/del.htm', {code: 0, errmsg: 'errmsg'}) // var data_doSave = Mock.mock('/transport/yscompany/save.htm', {code: 0, errmsg: 'errmsg'}) //test data end - +/* + * 閰嶈溅鎴愬姛 ---- 闇�瑕佹坊鍔犻殢琛屼汉鍛� ---- 鏄惁绔嬪嵆娣诲姞 闅忚浜哄憳 ----- 纭畾 --- 璺宠浆鍒版坊鍔犻〉闈紙缁戝畾杞﹁締銆佷笟鍔″崟銆佷汉鍛樺叧绯伙級 ---杞﹁締浠诲姟椤甸潰涔熷彲浠ユ坊鍔犳垨淇敼锛堢粦瀹氳溅杈嗐�佷笟鍔″崟銆佷汉鍛樺叧绯伙級 +*/ var SORT = [ {key: '鎵规鍙�', value: 'tdmx_fdcph', visible: ko.observable(true)}, {key: '瑙勬牸鍨嬪彿', value: 'tdmx_ggxh', visible: ko.observable(true)}, @@ -48,7 +50,9 @@ modal: $('#modal'), clearSortBtn: $('#clearSortBtn'), ssortBtn:$('#searchSortBtn'), - sxBtn:$('#sxBtn') + sxBtn:$('#sxBtn'), + personModal:$("#personModal"), + addPerson: $("#addPerson") } var Obj = { @@ -170,6 +174,13 @@ vm.o(ko.mapping.fromJS(Obj)); I.tempVehicleModal.modal('show'); }); + // I.addPerson.click(function (e) { + // e.preventDefault(); + // // vm.o(ko.mapping.fromJS(Obj)); + // // I.personModal.modal('show'); + // var item = {businessNo:'XS202203060079',vehicleId: '娌狤J3876'} + // addPersonTab(item); + // }); I.tempVehicleModal.on('hidden.bs.modal', function (e) { clearError(); }); @@ -484,7 +495,10 @@ // } // }); // }); + // 閰嶈溅 updateNum(); + var item = {businessNo: data.item.businessNo, vehicleId: vehicle.vehicleId} + confirmAddCarPersonTab(item); getVehicleList(); return; } @@ -492,6 +506,31 @@ "json" ); } +function confirmAddCarPersonTab(item) { + swal({ + title: "鏄惁闇�瑕佹坊鍔犻殢杞︿汉鍛橈紵", text: "濡傛灉涓嶆坊鍔犳垨闇�瑕佷慨鏀癸紝璇峰埌杞﹁締浠诲姟璇︽儏澶勬搷浣溿��", type: "warning", + showCancelButton: true, + confirmButtonColor: "#1c84c6", + confirmButtonText: "纭畾", + cancelButtonText: "鍙栨秷", + closeOnConfirm: true, + closeOnCancel: true, + }, function (isConfirm) { + if (isConfirm) { + addPersonTab(item) + } + }); +} +function addPersonTab(item){ + var businessNo = item.businessNo + var vehicleId = item.vehicleId + parent.closableTab.addTab({ + 'id': "carPersons-" + businessNo + "-" + vehicleId, + 'name': '娣诲姞闅忚浜哄憳', + 'url': '/basic/carPersons.jsf?businessNo=' + businessNo + '&vehicleId=' + vehicleId, + 'closable': true + }); +} function doUnbind() { if (!!I.AjaxdoUnbind) { -- Gitblit v1.9.3