From 8f9dce08ec70dc436b86a782e7bcb13872e52390 Mon Sep 17 00:00:00 2001
From: zhangyanpeng <bob.zhang@highdatas.com>
Date: 星期二, 20 八月 2024 20:06:24 +0800
Subject: [PATCH] 调整

---
 css/myelement.css                                 |    3 
 module/fee/page/popup/outBasePreGrantList.html    |  282 ++++++++++++++
 module/fee/page/popup/popup_edit_fee_execute.html |  242 +++++++++---
 module/flow/page/flow_sales_list.html             |  341 +----------------
 module/fee/page/fee_qty.html                      |    2 
 module/tool/page/popup_list_dataname.html         |  219 +++++++++++
 module/fee/page/fee_execute.html                  |   45 -
 7 files changed, 724 insertions(+), 410 deletions(-)

diff --git a/css/myelement.css b/css/myelement.css
index 52fc6ca..f893a12 100644
--- a/css/myelement.css
+++ b/css/myelement.css
@@ -390,6 +390,9 @@
 .h_table .el-input--mini .el-input__inner {
     height: 24px;
     line-height: 24px;
+}
+
+.h_table .el-input-number .el-input__inner {
 	text-align: right;
 	padding-left: 5px;
 	padding-right: 5px;
diff --git a/module/fee/page/fee_execute.html b/module/fee/page/fee_execute.html
index aa2d175..dad83b9 100644
--- a/module/fee/page/fee_execute.html
+++ b/module/fee/page/fee_execute.html
@@ -14,7 +14,7 @@
 				new ListVue({
 					el: "#vbody",
 					data: {
-						dataname: "fee_guide_settle_execute",
+						dataname: "fee_task_execute",
 						title: "鎵ц鍗�",
 						orderby: "",
 						filterfieldClick: {},
@@ -158,31 +158,8 @@
 										notclick_val: "",//涓嶅彲鐐瑰嚮鐨勫��,1銆佹槸鏁扮粍["11","22"]锛�2銆佷互鈥�;鈥濆垎闅旂殑瀛楃涓�"111;222"
 										notclick_bindfield: [],//褰撹瀛楁鍊肩瓑浜庢寚瀹氬瓧娈靛�兼椂涓嶅彲鐐瑰嚮["filterfield": "111"]
 										onclick: function(obj) {//鏁版嵁鍊肩偣鍑讳簨浠�
-											var sceneCode_ = "browse";
 											//濡傛灉鏄垱寤轰汉涓旀槸褰曞叆鐘舵�佹垨閫�鍥炵姸鎬佸垯鏄紪杈戠姸鎬�
-											if (obj.row.creator_id == window.top.vue.userinfo.id && (obj.row.state_code == "Input" || obj.row.state_code == "input" || obj.row.state_code == "Rejected")) {
-												sceneCode_ = "edit";
-											}
-											
-											var config = {
-												totab: true, //true: 浠ab瀵艰埅鐨勬柟寮忔墦寮�
-												width: "1100px",
-												height: "520px",
-												icon: "icon-product",
-												text: "鍟嗕笟淇℃伅 " + (obj.row.name ? obj.row.name : ""),
-												id: "customer_edit_browse" + obj.row.id,//totab: true鏃堕渶璁剧疆锛岀敤浜庡垽鏂槸鍚﹀凡鎵撳紑姝ら〉闈�
-												url: "module/md/page/customer/page/customer_edit.html",
-												data: obj.row,
-												delta: {closeCode:"1"},
-												sceneCode: sceneCode_,//"refuseedit",//"approval", //"add"//"browse",
-												callback: function(obj, callback) {
-													me.onQuery();
-													if (callback) {
-														callback();
-													}
-												}
-											};
-											me.doPopupByPublic(config);
+											me.editData("browse", obj.row);
 										},
 									},	
 								},
@@ -193,11 +170,12 @@
 							var me = this;
 							me.selectedrow = obj.row;
 						},
-						
-						editData(sceneCode) {
+						addData() {
+							this.editData("add", {});
+						},
+						editData(sceneCode, row) {
 							var me = this;
-							var row = me.selectedrow;
-							if(!row){
+							if(sceneCode == "edit" && !row){
 								Root.message({
 									type: 'warning',
 									message: '璇烽�夋嫨涓�鏉℃暟鎹�'
@@ -209,9 +187,9 @@
 								width: "900px",
 								height: "500px",
 								icon: "icon-product",
-								text: "鏁伴噺鍗曠紪杈�",
-								id: "popup_edit_fee_qty" + sceneCode + row.id,//totab: true鏃堕渶璁剧疆锛岀敤浜庡垽鏂槸鍚﹀凡鎵撳紑姝ら〉闈�
-								url: "module/fee/page/popup/popup_edit_fee_qty.html",
+								text: "鎵ц鍗曠紪杈�",
+								id: "popup_edit_fee_execute" + sceneCode + row.id,//totab: true鏃堕渶璁剧疆锛岀敤浜庡垽鏂槸鍚﹀凡鎵撳紑姝ら〉闈�
+								url: "module/fee/page/popup/popup_edit_fee_execute.html",
 								data: row,
 								delta: {},
 								sceneCode: sceneCode,//"refuseedit",//"approval", //"add"//"browse",
@@ -280,7 +258,8 @@
 					
 					<div :class="page_title == 'right' ? 'h_page_button_left' : 'h_page_button_right'">
 						<el-button-group style="margin-left: 3px;">
-							<el-button :disabled="!(selectedrow.id)" @click="editData('edit') " :icon="buttonsconfig.alter.icon":icon="buttonsconfig.alter.icon">{{buttonsconfig.alter.name}}</el-button>
+							<el-button  @click="addData() " :icon="buttonsconfig.add.icon">{{buttonsconfig.add.name}}</el-button>
+							<el-button :disabled="!(selectedrow.id)" @click="editData('edit', selectedrow) " :icon="buttonsconfig.alter.icon">{{buttonsconfig.alter.name}}</el-button>
 						</el-button-group>
 						
 						<el-button v-show="cbuttons_r.export ? cbuttons_r.export : false" @click="onDownload" :icon="buttonsconfig.export.icon">{{buttonsconfig.export.name}}</el-button>
diff --git a/module/fee/page/fee_qty.html b/module/fee/page/fee_qty.html
index 2612384..f2d7f06 100644
--- a/module/fee/page/fee_qty.html
+++ b/module/fee/page/fee_qty.html
@@ -280,7 +280,7 @@
 					
 					<div :class="page_title == 'right' ? 'h_page_button_left' : 'h_page_button_right'">
 						<el-button-group style="margin-left: 3px;">
-							<el-button :disabled="!(selectedrow.id)" @click="editData('edit') " :icon="buttonsconfig.alter.icon":icon="buttonsconfig.alter.icon">{{buttonsconfig.alter.name}}</el-button>
+							<el-button :disabled="!(selectedrow.id)" @click="editData('edit') " :icon="buttonsconfig.alter.icon">{{buttonsconfig.alter.name}}</el-button>
 						</el-button-group>
 						
 						<el-button v-show="cbuttons_r.export ? cbuttons_r.export : false" @click="onDownload" :icon="buttonsconfig.export.icon">{{buttonsconfig.export.name}}</el-button>
diff --git a/module/fee/page/popup/outBasePreGrantList.html b/module/fee/page/popup/outBasePreGrantList.html
new file mode 100644
index 0000000..fbef1b8
--- /dev/null
+++ b/module/fee/page/popup/outBasePreGrantList.html
@@ -0,0 +1,282 @@
+<!doctype html>
+<html>
+	<head>
+		<meta charset="utf-8"><meta http-equiv="Expires" content="0"><meta http-equiv="Pragma" content="no-cache"><meta http-equiv="Cache-control" content="no-cache"><meta http-equiv="Cache" content="no-cache">
+		<title>妞嶅叆鍗曞垪琛�</title>
+		
+		<script type="text/javascript">
+			var pageVue = null;
+			function loadJsCss(callback) {
+				var jscss_urls = [];
+				window.top.initJsCss(document, jscss_urls, callback);
+			};
+			
+			function initVue() {
+				new ListVue({
+					el: "#vbody",
+					data: {
+						dataname: "v_out_base_pre_grant",
+						title: "閫夋嫨鎵ц娴佸悜",
+
+						pageAttr: {
+							heightType: "popuppage"
+						},
+
+						default_filterFields: [
+							{isshow: "T", field: "code", name: "鍖婚櫌缂栫爜", filterfield:"", filteroperator: "like", type: ""},
+						],
+
+						default_tableFields: [
+							{field: "code", name: "鍖婚櫌缂栫爜", isshow: "T", align: "center",width: "150"},
+							{field: "name", name: "鍖婚櫌", isshow: "T", align: "center"},
+						],
+
+						default_tableData: [
+							{"code":"478389", "name":"姝﹁婀栧寳鎬婚槦鍖婚櫌",},
+							{"code":"012345", "name":"甯稿窞甯傞噾鍧涘尯涓尰鍖婚櫌",},
+						],
+						
+						filterfieldClick: {},
+						tablefieldClick: {},
+						formfieldClick: {},
+						detailCancelDate: "",
+						tableHeight: 550,
+						basicfilterAttr: {
+							istitle: false,
+							title: "琛ㄥ崟鍚嶇О",
+							columnnumber: 5,
+							labelwidth: "0px",
+							labelposition: "left",//"left",// right//top
+							size: "mini",
+							border: "1px solid #c6c6c600"
+						},
+						selectedrows: [],
+						pagesize: 10,
+						filterData: {}
+					},
+					
+					created() {
+						this.popupParames = clone(Root.popupParames);
+						// this.title = this.popupParames.title || this.popupParames.text
+						if (this.popupParames.filter) {
+							this.filterTxt = this.popupParames.filter
+						}
+						if (this.popupParames.delta && this.popupParames.delta.selectmap) {
+							this.filterData = this.popupParames.delta.selectmap;
+						}
+						if (this.popupParames.sceneCode) {
+							if (this.popupParames.sceneCode == "add") {//鏂板
+								this.isedit = true;
+							}
+						}
+					},
+					
+					mounted() {
+						//鑾峰彇鏁版嵁
+						this.initData();
+
+						// 浠ユ湇鍔$殑鏂瑰紡璋冪敤鐨� Loading 闇�瑕佸紓姝ュ叧闂�
+						this.$nextTick(() => { 
+							//閲嶆柊璁剧疆寮圭獥瀹介珮
+							this.$nextTick(function(){
+								//let w_ = this.$refs.popup_body.offsetWidth + "px";
+								let w_ = "1000px";
+								let h_ = "650px";
+								Root.setPopupWH(w_, h_);
+							})
+						});
+					},
+					
+					methods:{
+						//鍏抽棴寮圭獥
+						closeDialog() {
+							this.docloseDialog(true);
+						},
+						
+						//鍏抽棴鍓嶈皟鍥炶皟
+						saveAfter() {
+							var me = this;
+							var selectedrows = this.$refs.table1.getShoppingcart();
+							
+							if(this.popupParames.callback) {
+								let obj = {
+									type: this.activeTabName,
+									list: clone(selectedrows)
+									// row: clone(this.selectedrow)
+								}
+								this.popupParames.callback(obj, function() {
+									me.docloseDialog();
+								});
+							}
+							else {
+								me.docloseDialog();
+							}
+						},
+						
+						initData() {
+							var me = this;
+							this.onQuery(function(result, callback) { //鏌ヨ鍚庣殑鍥炶皟锛岀敤浜庤幏鍙栧瓧娈电殑
+								if (result.meta && result.meta[me.dataname] && result.meta[me.dataname].fields) {
+									var metas = clone(result.meta[me.dataname].fields);
+									var filterFields_ = [];
+									var tableFields_ = [];
+									
+									metas.map(f=>{
+										f.isshow = "T";
+										
+										if (f.isfilter) {
+											filterFields_.push(clone(f));
+										}
+										else {
+											var filter_f = clone(f);
+											filter_f.isshow = "F";
+											filterFields_.push(filter_f);
+										}
+										
+										tableFields_.push(clone(f));
+									})
+									if (!me.filterFields || (me.filterFields && me.filterFields.length == 0)) {
+										me.filterFields = clone(filterFields_);
+										me.tableFields = clone(tableFields_);
+										
+										//瀛楁鏁扮粍杞瓧娈祇bj锛岀洰鐨勪负浜嗙瓫閫夋椂鑾峰彇瀛楁灞炴��
+										me.fieldsToFieldsObj();
+										
+										//璁剧疆瀛楁浜嬩欢
+										me.tableFieldClick();
+									}
+								}
+								
+								if (callback) {
+									callback();
+								}
+								hideLoading();
+							});
+						},
+						
+						onQueryAfter() {
+							var me = this;
+							
+							var tableData_ = clone(me.tableData);
+							tableData_.map(row=>{
+								var key_ = row.id
+								if (me.filterData[key_]) {
+									row.h_classname = "z_notrowclick";
+								}
+							})
+							me.tableData = clone(tableData_);
+						},
+						
+						tableFieldClick() {
+							var me = this;
+							//绛涢�夊瓧娈典簨浠惰缃�
+							this.filterfieldClick = {
+								
+							};
+
+							//琛ㄦ牸瀛楁浜嬩欢璁剧疆
+							this.tablefieldClick = {
+								
+								
+							};
+						
+							//琛ㄥ崟瀛楁浜嬩欢璁剧疆
+							this.formfieldClick = {
+								
+							};
+						},
+						
+						selectionChange(obj){
+							var me = this;
+							me.selectedrows = obj;
+						},
+						saveShoppingcart(list) {
+							var me = this;
+							me.selectedrows = list;
+						},
+												
+						// onRowDblClick() {
+						// 	if (this.isedit) {
+						// 		this.saveAfter();
+						// 	}
+						// },
+					}
+				});
+			};
+			
+			loadJsCss(function () {
+				initVue();
+			});
+		</script>
+
+		<style>
+			/* 鍦╲ue.js涓� v-cloak 杩欎釜鎸囦护鏄槻姝㈤〉闈㈠姞杞芥椂鍑虹幇 vuejs 鐨勫彉閲忓悕鑰岃璁$殑 */
+			[v-cloak] {
+				display: none !important;
+			}
+			.h_table .h_h_table .h_table_tool_right .h_table_right_filter {
+				width: 85% !important;
+			}
+		</style>
+	</head>
+	
+	<body style="margin: 0px;">
+		<div v-cloak id="vbody">
+			<div id="page_root">
+				<div ref="popup_body" style="padding: 0 20px;">
+					<!-- 鏍囬 -->
+					<div class="popup_el-dialog__header">
+						<div class="dialog-title">
+						  <i class="iconfont icon-customermanagement"></i>
+						  <span>{{title}}</span>
+						</div>
+					</div>	
+
+					<!-- 涓讳綋 -->
+					<div class="h_dialog__body">
+						<h-table
+							v-if="isRefresh && tableFields && tableFields.length"
+							ref="table1"
+							:table-fields="tableFields" 
+							:table-data="tableData" 
+							:pagesize="pagesize"
+							:pagenum="pagenum"
+							:total="total"
+							:table-height="tableHeight"
+							:table-field-click="tablefieldClick"
+							:is-highlight-row="isedit"
+							:filtersobj="filterObj"
+							:basicfilterfieldslength="5"
+							:basicfilter-attr="basicfilterAttr"
+							:isdraggableorder="false"
+							:isqueryloading="tableloading"
+							
+							v-on:get-data="getData"
+							v-on:row-click="rowClick"
+							
+							:select-table-data="selectedrows"
+							:is-selection="true"
+							:isshow-shoppingcart="true"
+							v-on:selection-change="selectionChange"
+							v-on:save-shoppingcart="saveShoppingcart"
+							>
+						</h-table>
+					</div>
+					
+					<!-- 搴曢儴宸ュ叿鏍� -->
+					<div class="el-dialog__footer" v-show="tableFields && tableFields.length">
+						<el-button size="small" type="default" @click="closeDialog">鍙� 娑�</el-button>
+						<el-button size="small" v-if="isedit" type="primary" @click="saveAfter">纭� 瀹�</el-button>
+					</div>
+				</div>
+			</div>
+		</div>
+		
+		<div id="page_loading" style="position: absolute; top:0px; width: 100vw; height: 50vh;">
+			<div class="spinner">
+			  <div class="cube1"></div>
+			  <div class="cube2"></div>
+			</div>
+		</div>
+	</body>
+</html>
diff --git a/module/fee/page/popup/popup_edit_fee_execute.html b/module/fee/page/popup/popup_edit_fee_execute.html
index f214595..e6f92a0 100644
--- a/module/fee/page/popup/popup_edit_fee_execute.html
+++ b/module/fee/page/popup/popup_edit_fee_execute.html
@@ -16,18 +16,18 @@
 					el: "#vbody",
 					data: {
 						dataname: "fee_task_execute",
-						table_dataname: "fee_working_out_base_execute",
+						table_dataname: "v_fee_working_grant_detail",
 						title: "鎵ц鍗曚俊鎭�",
 						dataRequest: [
 							{
-								name: "fee_working_out_base_execute", // 涓氬姟璐熻矗浜哄瓧娈�
-								dataname: "fee_working_out_base_execute",
+								name: "v_fee_working_grant_detail", // 涓氬姟璐熻矗浜哄瓧娈�
+								dataname: "v_fee_working_grant_detail",
 								url: "root/data/getEntitySet",
-								paramsobj: {dataname: "fee_working_out_base_execute", attachMeta: true, filter: "1<>1"},
+								paramsobj: {dataname: "v_fee_working_grant_detail", attachMeta: true, filter: "1<>1"},
 								isnotoption: true, //true:涓嶆槸閫夐」
 							}
 						],
-						meta_fee_working_out_base_execute: [],
+						meta_v_fee_working_grant_detail: [],
 						
 						options_md_org_master: [],
 						md_bu_org_obj: {},
@@ -51,6 +51,7 @@
 						formFields: [],
 						
 						newformData: {
+							code: createBaseCode("ZX"),
 							state_code: "Input",
 							state_name: "褰曞叆",
 							is_active: true,
@@ -58,7 +59,9 @@
 							type_code: "Customer", // Standard鏍囧噯浠风洰琛ㄣ�丆ustomer缁忛攢鍟嗕环鐩〃
 						},
 						formData: {},
-						
+						formDataDefault: {
+							guide_id: "fee_guide_settle_execute"
+						},
 						isRefresh: true,
 						tableFields: [],
 						tableData: [],
@@ -92,13 +95,14 @@
 						approveremark: '',//濉啓鐞嗙敱
 						passOrRefuse:false,
 						loading_pass: false,
+						tablebuttonClick: []
 					},
 					created() {
 						this.popupParames = clone(Root.popupParames);
 						// this.title = this.popupParames.title || this.popupParames.text
 						if (this.popupParames.data) {
-							if (this.popupParames.data._datano) {
-								this.title = this.title + this.popupParames.data._datano;
+							if (this.popupParames.data.code) {
+								this.title = this.title + this.popupParames.data.code;
 							}
 							this.formData = clone(this.popupParames.data);
 						}
@@ -137,9 +141,9 @@
 								this.formAttr.disabled = true;
 								this.isapproval = true;
 								
-								if (this.formData.current_step_name && this.formData.current_step_name == "杩愯惀閮ㄩ棬澶嶆牳") {
-									this.isedit = true;
-								}
+								// if (this.formData.current_step_name && this.formData.current_step_name == "杩愯惀閮ㄩ棬澶嶆牳") {
+								// 	this.isedit = true;
+								// }
 								
 							}
 							else if (this.popupParames.sceneCode == "refuseedit") {//鎷掔粷鍚庣殑缂栬緫
@@ -176,15 +180,15 @@
 									}
 								}
 								// 鑾峰彇鍙樻洿鐨勫瓧娈�
-								if (me.dataRequestObj.fee_working_out_base_execute) {
-								    let meta_ = me.dataRequestObj.fee_working_out_base_execute.meta.fee_working_out_base_execute.fields;
+								if (me.dataRequestObj.v_fee_working_grant_detail) {
+								    let meta_ = me.dataRequestObj.v_fee_working_grant_detail.meta.v_fee_working_grant_detail.fields;
 									meta_.map(f=>{
 										f.isshow = "T";
-										if (f.field == "_qty_trans" || f.field == "_qty_cal" || f.field == "_qty_final" || f.field == "_amt_final") {
+										if (f.field == "grant_amt" || f.field == "grant_qty") {
 											f.isfixed = "right";
 										}
 									})
-									me.meta_fee_working_out_base_execute = clone(meta_)
+									me.meta_v_fee_working_grant_detail = clone(meta_)
 								}
 								me.initData();
 							});
@@ -240,36 +244,14 @@
 									
 									metas.map(f=>{
 										f.isshow = "T";
-										if (f.field == "company_id") {
-											// f.isshow = "F";
-											f.options = me.options_md_org_master
+										if (f.field == "amt") {
+											f.inputtype = "span"
 										}
-										
-										if (f.field == "product_id") {
-											f.props = {label: "value", value: "code", multiple: false};
-											if (me.options_product.length) {
-												f.options = clone(me.options_product);
-											}
-											else if (me.formData.bu_id && me.md_bu_product_obj[me.formData.bu_id]) {
-												f.options = clone(me.md_bu_product_obj[me.formData.bu_id].children);
-											}
-											else {
-												f.options = [];
-											}
-										}
-										
-										// if (f.field == "customer_name" && (me.popupParames.sceneCode == "addbyagreement" || me.popupParames.sceneCode == "editbyagreement")) {
-										// 	f.disabled = true;
-										// }
-										// if ((f.field == "date_from" || f.field == "date_to") && (me.popupParames.sceneCode == "addbyagreement" || me.popupParames.sceneCode == "editbyagreement")) {
-										// 	f.isshow = false;
-										// }
-										
 										formFields_.push(clone(f));
 									})
 									if (!me.formFields || (me.formFields && me.formFields.length == 0)) {
 										me.formFields = clone(formFields_);
-										me.tableFields = clone(me.meta_fee_working_out_base_execute);
+										me.tableFields = clone(me.meta_v_fee_working_grant_detail);
 										
 										//璁剧疆瀛楁浜嬩欢
 										me.tableFieldClick();
@@ -305,6 +287,11 @@
 										me.formFields = clone(formFields_);
 									}
 									me.onTableQuery();
+								}
+								
+								// 鏄惁闇�瑕佸脊鍑烘鍏ュ崟閫夋嫨绐�
+								if(me.popupParames.sceneCode == "add") {
+									me.selectDetailPopup(true);
 								}
 							})
 						},
@@ -360,29 +347,122 @@
 							};
 							
 							this.tablefieldClick = {
-								_qty_trans: {
+								grant_qty: {
 								    input: {
 										onchange: function(obj) {
-											obj.row._qty_trans = obj.row._qty_trans * 1;
-											if (obj.row._qty_cal) {
-												obj.row._qty_final = (obj.row._qty_cal * 1) - (obj.row._qty_trans * 1)
-												obj.row._amt_final = obj.row._qty_final  * obj.row._taxunitprice
+											obj.row.grant_qty = obj.row.grant_qty * 1;
+											var grant_price = 0;
+											if (obj.row.grant_price) {
+												grant_price = obj.row.grant_price
 											}
-											
-											me.saveTableRow(obj.row);
+											else if (table_row.grant_qty && table_row.grant_amt) {
+												grant_price = table_row.grant_amt / table_row.grant_qty
+											}
+											obj.row.grant_amt = grant_price  * obj.row.grant_qty
+											if (obj.row.id) {
+												me.saveTableRow(obj.row);
+											}
 										}
 								    }
 								},
 							}
+							
+							this.tablebuttonClick = [
+								{
+									// name: "鏂板", // type: "primary", // icon: "el-icon-edit",
+									isbuttonshow: me.isedit,
+									code: "add", isselected: false, classname: "",
+									onclick: function(obj) {
+										me.selectDetailPopup(false)
+									}
+								},
+								// {
+								// 	// name: "鍒犻櫎", // type: "primary", // icon: "el-icon-edit",
+								// 	isbuttonshow: me.isedit,	type: "danger",
+								// 	code: "delete", isselected: true, classname: "",
+								// 	disabled: function(selectRowList) {
+								// 		var bo_ = true;
+								// 		if (selectRowList[0] && selectRowList[0].state_code == "Input") {
+								// 			bo_ = false;
+								// 		}
+								// 		return bo_
+								// 	},
+								// 	onclick: function(obj) {
+								// 		me.delData()
+								// 	}
+								// },
+							]
+							
+						},
+						
+						selectDetailPopup(isclose) {
+							var me = this;
+							//鎺掗櫎宸查�夌墿鏂�
+							var selectmap_ = {};
+							me.tableData.map(row=>{
+								if (row.sell_qty_id) {
+									var key_ = row.sell_qty_id
+									selectmap_[key_] = true
+								}
+							})
+							var filter_ = "";
+							var config = {
+								totab: false, //true: 浠ab瀵艰埅鐨勬柟寮忔墦寮�
+								width: "1000px",
+								height: "650px",
+								icon: "icon-product",
+								filter: filter_,
+								text: "閫夋嫨鎵ц娴佸悜",
+								id: "outBasePreGrantList" + "add",//totab: true鏃堕渶璁剧疆锛岀敤浜庡垽鏂槸鍚﹀凡鎵撳紑姝ら〉闈�
+								url: "module/fee/page/popup/outBasePreGrantList.html",
+								delta: {selectmap: selectmap_},
+								sceneCode: "add", //"refuseedit",//"approval", //"add"//"browse",
+								closecallback: function() {
+									if (isclose) {
+										me.closeDialog();
+									}
+								},
+								callback: function(obj, callback) {
+									me.loadDetailData(obj);
+									if (callback) {
+										callback();
+									}
+								}
+							};
+							me.doPopupByPublic(config);
+						},
+						
+						// 棣栨鍒涘缓鎾ら攢鍗曠殑妞嶅叆鍗曟暟鎹�
+						loadDetailData(obj) {
+							var me = this;
+							me.formData.guide_id = me.formDataDefault.guide_id;
+							
+							// 鏄庣粏琛ㄦ牸鏁版嵁
+							var list_h = clone(obj.list); //璐墿杞﹁繑鍥炰竴涓暟缁�
+							var tableData_ = clone(me.tableData);
+							list_h.map(row=>{
+								console.log(row);
+								var table_row = clone(row);
+								table_row.id = null
+								table_row.task_id = null
+								table_row.data_no = row.datano
+								table_row.sell_qty_id = row.id
+								table_row.out_fee_id = row.out_fee_id
+								table_row.grant_qty = row.qty_check - (row.qty_grant ? row.qty_grant : 0)
+								table_row.grant_amt = row.amt_check ? row.amt_check/row.qty_check * (row.qty_check - (row.qty_grant ? row.qty_grant : 0)) : 0
+								table_row.grant_price = row.amt_check ? row.amt_check/row.qty_check : 0
+								
+								tableData_.unshift(table_row)
+							})
+							me.tableData = clone(tableData_);
 						},
 						
 						saveTableRow(row) {
 							var me = this;
 							var entity_ = clone(row);
 							var entity = {
-								_qty_trans: entity_._qty_trans,
-								_qty_final: entity_._qty_final,
-								_amt_final: entity_._amt_final,
+								grant_qty: entity_.grant_qty,
+								grant_amt: entity_.grant_amt,
 								id: entity_.id
 							};
 							
@@ -567,7 +647,7 @@
 							let param_ = {
 								dataname: this.table_dataname,
 								filter: filter_,
-								orderby: "_dataNo",
+								orderby: "dataNo",
 								page: {
 									pageno: this.pagenum,
 									pagesize: this.pagesize
@@ -613,26 +693,52 @@
 						saveRowTable(callback) {
 							var me = this;
 							var operator_ = "saveEntity";//淇濆瓨
-							// if(me.iscommit) {
-							// 	operator_ = "commit";//鎻愪氦
-							// }
+							if(me.iscommit) {
+								operator_ = "commit";//鎻愪氦
+							}
 							
 							var entity_ = clone(this.formData);
-							var entity = {
-								_qty_trans: entity_._qty_trans,
-								_qty_final: entity_._qty_final,
-								_amt_final: entity_._amt_final,
-								id: entity_.id
-							};
+							var tableData_v = clone(this.tableData);
+							// var entity = {
+							// 	_qty_trans: entity_._qty_trans,
+							// 	_qty_final: entity_._qty_final,
+							// 	_amt_final: entity_._amt_final,
+							// 	id: entity_.id
+							// };
+							var tableData_ = [];
+							var sum_grant_amt = 0;
+							tableData_v.map(r=>{
+								var r_ = {
+									data_no: r.data_no || r.datano,
+									sell_qty_id: r.sell_qty_id,
+									out_fee_id: r.out_fee_id,
+									grant_qty: r.grant_qty,
+									grant_amt: r.grant_amt,
+								}
+								if (r.id) {
+									r_.id = r.id
+								}
+								if (entity_.id) {
+									r_.task_id = entity_.id
+								}
+								
+								if (r.grant_amt) {
+									sum_grant_amt += r.grant_amt;
+								}
+								
+								tableData_.push(r_)
+							})
 							
+							entity_.amt = sum_grant_amt;
 							let param = {
-								dataname: me.dataname,
+								dataname: "fee_task_execute",
 								data: {},
 							}
 							if (me.formData.id) {
 								param.id = me.formData.id
 							}
-							param.data[me.dataname] = entity;
+							param.data["fee_task_execute"] = entity_;
+							param.data["fee_working_grant_detail"] = tableData_;
 							
 							Server.call("root/data/" + operator_, param, function(result) {
 								console.log(result);
@@ -895,11 +1001,15 @@
 									:pagesize="pagesize"
 									:pagenum="pagenum"
 									:total="total"
-									:table-height="dheight - 252 - 64"
+									:table-height="dheight - 147 - 64 - (isedit ? 28 : 0)"
 									:is-highlight-row="true"
 									:isdraggableorder="false"
-									:isshowtool="false"
+									:isbasicfilterfields="false"
 									:isshow-shoppingcart="false"
+									:isbasicfilterfields="false"
+									:isfilterfield="false"
+									
+									:table-buttons-click="tablebuttonClick"
 									
 									v-on:get-data="getData"
 								>
@@ -929,9 +1039,9 @@
 							<el-button  size="small" v-if="isapproval" type="danger" plain @click="onShowApproval('goback')">閫�鍥炲埌涓婁竴姝�</el-button>
 						</el-button-group>
 						<el-button size="small" type="default" @click="closeDialog">鍙� 娑�</el-button>
-						<!-- <el-button size="small" v-if="isedit || isrefuseedit" type="primary" :loading="loading_save" @click="saveRowTable()":icon="buttonsconfig.save.icon">{{buttonsconfig.save.name}}</el-button>
+						<el-button size="small" v-if="isedit || isrefuseedit" type="primary" :loading="loading_save" @click="saveRowTable()":icon="buttonsconfig.save.icon">{{buttonsconfig.save.name}}</el-button>
 						<el-button size="small" v-if="isedit && !formData.agreement_id" type="success" :loading="loading_submit" @click="submitRowTable":icon="buttonsconfig.submit.icon">{{buttonsconfig.submit.name}}</el-button>
-						 -->
+						
 						<el-button size="small" v-if="isrefuseedit" type="success" @click="">鍐嶆鎻愪氦</el-button>
 						
 						<el-button size="small" v-if="isapproval" type="success" @click="onShowApproval('approve')">閫� 杩�</el-button>
diff --git a/module/flow/page/flow_sales_list.html b/module/flow/page/flow_sales_list.html
index 3c4f134..ee43c37 100644
--- a/module/flow/page/flow_sales_list.html
+++ b/module/flow/page/flow_sales_list.html
@@ -18,7 +18,7 @@
 						title: "閿�鍞祦鍚�",
 						//Tab椤硅缃�
 						tabs_d: [
-							{code: "month", name: "鏈堟祦鍚�", dataname: "flow_month_sell", filterTxt: "", orderby: ""},
+							{code: "month", name: "鏈堟祦鍚�", dataname: "flow_month_sell_sum", filterTxt: "", orderby: ""},
 							{code: "daily", name: "鏃ユ祦鍚�", dataname: "flow_daily_sell", filterTxt: "", orderby: ""},
 						],
 						d_tabs: {
@@ -41,9 +41,10 @@
 							{isshow: "T", field: "org_code", name: "缁忛攢鍟嗙紪鐮�", filterfield:"", filteroperator: "like", type: ""},
 							{isshow: "T", field: "org_name", name: "缁忛攢鍟嗗悕绉�", filterfield:"", filteroperator: "like", type: ""},
 						],
+						dataversion: "鏈堝害鍒濈増",
 						default_filterObj: {
 							month: {
-								dataversion: "鏈堝害鍒濈増"
+								// dataversion: "鏈堝害鍒濈増"
 								//year: new Date().getFullYear().toString(),
 								//month: (new Date().getMonth() + 1).toString(),
 								// month: dateFormat(new Date(), "yyyy-MM"),
@@ -218,163 +219,33 @@
 						tableFieldClick() {
 							var me = this;
 							//杈栧尯鍖婚櫌鍒楄〃
-							var tablefieldClick_hospital = {
-								code: {//瀛楁浜嬩欢璁剧疆
+							var tablefieldClick_month = {
+								// flow_month_sell_qty__qty_check
+								// flow_month_sell_qty__amt_check
+								// flow_month_sell_qty__qty_grant
+								// flow_month_sell_qty__amt_grant
+								
+								flow_month_sell_qty__qty_check: {//瀛楁浜嬩欢璁剧疆
 									val: {//鏈夊�兼椂鐨勭偣鍑讳簨浠�
 										onclick: function(obj) {//鏁版嵁鍊肩偣鍑讳簨浠�
-											me.showInfo(obj); 
+											var filter_ = "_datano='"+ obj.row.datano +"'"
+											me.showInfo(obj, "v_fee_working_qty_task", filter_, "缁撶畻鏄庣粏"); 
+										},
+									},
+								},
+								flow_month_sell_qty__qty_grant: {//瀛楁浜嬩欢璁剧疆
+									val: {//鏈夊�兼椂鐨勭偣鍑讳簨浠�
+										onclick: function(obj) {//鏁版嵁鍊肩偣鍑讳簨浠�
+											var filter_ = "datano='"+ obj.row.datano +"'"
+											me.showInfo(obj, "v_fee_working_grant_task", filter_, "鎵ц鏄庣粏"); 
 										},
 									},
 								}
 							};
-							//杈栧尯鍙樻洿
-							var tablefieldClick_info = {
-								//waiting
-								hospital_code: {//瀛楁浜嬩欢璁剧疆
-									val: {//鏈夊�兼椂鐨勭偣鍑讳簨浠�
-										onclick: function(obj) {//鏁版嵁鍊肩偣鍑讳簨浠�
-											me.showChangeInfo(obj); 
-										},
-									},
-								},
-								state_name: {//鐘舵��
-									val: {//鏈夊�兼椂鐨勭偣鍑讳簨浠�
-										notclick_val: ["鑽夌","鑽夌"],
-										notclick_bindfield: [],
-										onclick: function(obj) {
-											var config = {
-												totab: false,
-												width: "1100px",
-												height: "520px",
-												icon: "icon-product",
-												text: "娴佺▼姝ラ",
-												id: "popup_workflow_step_user" + obj.row.id,
-												url: "module/tool/page/popup_workflow_step_user.html?v=2023020703",
-												data: obj.row,
-												delta: {},
-												sceneCode: "browse",
-												callback: function(obj, callback) {
-													if (callback) {
-														callback();
-													}
-												}
-											};
-											me.doPopupByPublic(config);
-										},
-									},	
-								},
-							};
-							//鍖婚櫌鎺堟潈鍒楄〃
-							var tablefieldClick_org = {
-								category_name: {//鎺堟潈浜у搧
-									val: {
-										notclick_val: "",//涓嶅彲鐐瑰嚮鐨勫��,1銆佹槸鏁扮粍["11","22"]锛�2銆佷互鈥�;鈥濆垎闅旂殑瀛楃涓�"111;222"
-										notclick_bindfield: [
-											{
-												field: "id", 
-												val: null,
-											}
-										],//褰撹瀛楁鍊肩瓑浜庢寚瀹氬瓧娈靛�兼椂涓嶅彲鐐瑰嚮["filterfield": "111"]
-										onclick: function(obj) {//鏁版嵁鍊肩偣鍑讳簨浠�
-											me.showAuthInfo(obj.row)
-										},
-									},
-									defaultval: {
-										val: "鏌ョ湅",//绌哄�兼椂鐨勬樉绀哄��
-										onclick: function(obj) {//榛樿鍊肩偣鍑讳簨浠�,姝や簨浠堕渶瑕佽缃畍al鎵嶆湁鏁�
-											me.showAuthInfo(obj.row)
-										}
-									},
-								},
-								state_name: {//鐘舵��
-									val: {//鏈夊�兼椂鐨勭偣鍑讳簨浠�
-										notclick_val: ["鑽夌","鑽夌"],
-										notclick_bindfield: [],
-										onclick: function(obj) {
-											var config = {
-												totab: false,
-												width: "1100px",
-												height: "520px",
-												icon: "icon-product",
-												text: "娴佺▼姝ラ",
-												id: "popup_workflow_step_user" + obj.row.id,
-												url: "module/tool/page/popup_workflow_step_user.html?v=2023020703",
-												data: obj.row,
-												delta: {},
-												sceneCode: "browse",
-												callback: function(obj, callback) {
-													if (callback) {
-														callback();
-													}
-												}
-											};
-											me.doPopupByPublic(config);
-										},
-									},	
-								},
-							};
-							//鎺堟潈鍙樻洿
-							var tablefieldClick_auth = {
-								state_name: {//鐘舵��
-									val: {//鏈夊�兼椂鐨勭偣鍑讳簨浠�
-										notclick_val: ["鑽夌","鑽夌"],
-										notclick_bindfield: [],
-										onclick: function(obj) {
-											var config = {
-												totab: false,
-												width: "1100px",
-												height: "520px",
-												icon: "icon-product",
-												text: "娴佺▼姝ラ",
-												id: "popup_workflow_step_user" + obj.row.id,
-												url: "module/tool/page/popup_workflow_step_user.html?v=2023020703",
-												data: obj.row,
-												delta: {},
-												sceneCode: "browse",
-												callback: function(obj, callback) {
-													if (callback) {
-														callback();
-													}
-												}
-											};
-											me.doPopupByPublic(config);
-										},
-									},	
-								},
-								type_name: {//鎺堟潈浜у搧
-									val: {
-										notclick_val: "",//涓嶅彲鐐瑰嚮鐨勫��,1銆佹槸鏁扮粍["11","22"]锛�2銆佷互鈥�;鈥濆垎闅旂殑瀛楃涓�"111;222"
-										notclick_bindfield: [],//褰撹瀛楁鍊肩瓑浜庢寚瀹氬瓧娈靛�兼椂涓嶅彲鐐瑰嚮["filterfield": "111"]
-										onclick: function(obj) {//鏁版嵁鍊肩偣鍑讳簨浠�
-											me.showAuthChange(obj.row)
-										},
-									},
-									defaultval: {
-										val: "鏌ョ湅",//绌哄�兼椂鐨勬樉绀哄��
-										onclick: function(obj) {//榛樿鍊肩偣鍑讳簨浠�,姝や簨浠堕渶瑕佽缃畍al鎵嶆湁鏁�
-											me.showAuthChange(obj.row)
-										}
-									},
-								},
-							};
 							
 							var filterfieldClick = {};
-							
-							//鍖婚櫌绠$悊鍒楄〃-杈栧尯鍖婚櫌tab
-							if (this.selectTabObj.code == "hospital") {
-								this.selectTabObj.tablefieldClick = tablefieldClick_hospital;
-							}
-							//杈栧尯鏂板/鍙樻洿-杈栧尯瀹℃壒涓�佸叏閮ㄨ緰鍖虹敵璇穞ab
-							else if (this.selectTabObj.code == "infoUnderApproval" || this.selectTabObj.code == "infoAll") {
-								this.selectTabObj.tablefieldClick = tablefieldClick_info;
-							}
-							//鍖婚櫌鎺堟潈鍒楄〃-鍖婚櫌鎺堟潈tab
-							else if (this.selectTabObj.code == "authorize") {
-								this.selectTabObj.tablefieldClick = tablefieldClick_org;
-							}
-							//鎺堟潈鍙樻洿-鎺堟潈瀹℃壒涓�佸叏閮ㄦ巿鏉冪敵璇穞ab
-							else if (this.selectTabObj.code == "authUnderApproval" || this.selectTabObj.code == "authAll") {
-								this.selectTabObj.tablefieldClick = tablefieldClick_auth;
+							if (this.selectTabObj.code == "month") {
+								this.selectTabObj.tablefieldClick = tablefieldClick_month;
 							}
 							
 							this.filterfieldClick = filterfieldClick;
@@ -465,173 +336,23 @@
 							}
 						},
 						
-						delDataPolicy(obj, row) {
-							let me = this;
-							let name_ = "璇ユ暟鎹�";
-							
-							if (!row.id) {
-								Root.message({
-									type: 'warning',
-									message: '璇烽�夋嫨鍒犻櫎鏁版嵁'
-								});  
-								return
-							}
-							if (row.md_hospital__name) {
-								name_ = "_" + row.md_hospital__name + "_";
-							}
-							
-							Root.confirm('纭畾鍒犻櫎' + name_ + '鍚楋紵', '鍒犻櫎鎻愮ず', {
-							  confirmButtonText: '鍒犻櫎',
-							  cancelButtonText: '鍙栨秷',
-							  type: 'warning'
-							}).then(() => {
-								let param = {
-									id: row.id,
-									dataname: me.selectTabObj.dataname,
-								}
-								Server.call("root/data/deleteEntity", param, function(result) {
-									Root.message({
-										type: 'success',
-										message: '鍒犻櫎鎴愬姛!'
-									});
-									me.onQuery();
-								});
-							}).catch(() => {
-								Root.message({
-									type: 'info',
-									message: '宸插彇娑堝垹闄�'
-								});          
-							});
-						},
-						
-						commitData(obj) {
+						// 閫氱敤鏌ョ湅寮圭獥
+						showInfo(obj, dataname, filter, text) {
 							var me = this;
-							Root.confirm('纭畾鎻愪氦杈栧尯鍖婚櫌' + obj.md_hospital__name + '鍚楋紵', '鎻愪氦鎻愮ず', {
-							  confirmButtonText: '鎻愪氦',
-							  cancelButtonText: '鍙栨秷',
-							  type: 'warning'
-							}).then(() => {
-								var param = {
-									dataname: me.selectTabObj.dataname,
-									id: obj.id,
-									to_state: "OpeningApproval" 
-								}
-								console.log(me.selectTabObj)
-								Server.call("root/data/commit", param, function(result) {
-									console.log(result);
-									if (result.success) {
-										Root.message({
-											type: 'success',
-											message: '鎻愪氦鎴愬姛'
-										}); 
-										me.onQuery();
-									}
-								});
-							}).catch(() => {
-								Root.message({
-									type: 'info',
-									message: '宸插彇娑�'
-								});          
-							});
-						},
-						
-						openPolicy(sceneCode, row) {
-							let me = this;
-							var text = "";
-							
-							// type_code: "", // Standard鏍囧噯浠风洰琛ㄣ�丆ustomer缁忛攢鍟嗕环鐩〃
-							if (sceneCode == "add") {
-							}
-							else if (sceneCode == "edit" || sceneCode == "browse") {
-								if(!row){
-									Root.message({
-										type: 'warning',
-										message: '璇烽�夋嫨涓�鏉℃暟鎹�'
-									});
-									return;
-								}
-								
-								// if (row.customer_name) {
-								// 	text = row.customer_name;
-								// }
-								
-							}
-							
 							var config = {
 								totab: false, //true: 浠ab瀵艰埅鐨勬柟寮忔墦寮�
-								width: "900px",
-								height: "320px",
-								icon: "icon-product",
-								text: "杈栧尯鍖婚櫌" + text,
-								id: "popup_position_hospital" + row.id + sceneCode,//totab: true鏃堕渶璁剧疆锛岀敤浜庡垽鏂槸鍚﹀凡鎵撳紑姝ら〉闈�
-								url: "module/md/page/terminal/page/popup/popup_position_hospital.html",
-								data: row,
-								delta: {dataname: me.selectTabObj.dataname,},
-								sceneCode: sceneCode,//"refuseedit",//"approval", //"add"//"browse",
-								callback: function(obj, callback) {
-									me.onQuery();
-									if (callback) {
-										callback();
-									}
-								}
-							};
-							me.doPopupByPublic(config);
-						},
-						
-
-						//杈栧尯鍖婚櫌鏂板
-						onAddData() {
-							var me = this;
-							
-							var config = {
-								totab: true, //true: 浠ab瀵艰埅鐨勬柟寮忔墦寮�
-								width: "900px",
-								height: "900px",
-								icon: "icon-product",
-								text: "鍖婚櫌绠$悊淇℃伅",
-								id: "hospital_list_info",//totab: true鏃堕渶璁剧疆锛岀敤浜庡垽鏂槸鍚﹀凡鎵撳紑姝ら〉闈�
-								url: "module/md/page/terminal/page/hospital_list_info.html",
-								data: {},
-								delta: {},
-								sceneCode: "add",//"refuseedit",//"approval", //"add"//"browse",
-								callback: function(obj, callback) {
-									//isSales鎻愪氦鍚庡埛鏂�'杈栧尯瀹℃壒涓�'tab
-									// if(me.isSales) {
-										var tab = {
-											name: 'infoUnderApproval',
-										};
-										me.activeTabName = 'infoUnderApproval';
-										me.handleClick(tab);
-										me.onQuery();
-									// } else {
-									// 	me.onQuery();
-									// }
-
-									if (callback) {
-										callback();
-									}
-								}
-							};
-							me.doPopupByPublic(config);
-						},
-						
-						//杈栧尯鍖婚櫌淇℃伅鏌ョ湅
-						showInfo(obj) {
-							var me = this;
-							
-							var config = {
-								totab: true, //true: 浠ab瀵艰埅鐨勬柟寮忔墦寮�
 								width: "1200px",
 								height: "600px",
 								icon: "icon-product",
-								text: obj.row.name  + " 鍖婚櫌绠$悊淇℃伅",
+								text: text,
 								id: "hospital_list_info" + "browse" + obj.row.id,//totab: true鏃堕渶璁剧疆锛岀敤浜庡垽鏂槸鍚﹀凡鎵撳紑姝ら〉闈�
-								url: "module/md/page/terminal/page/hospital_list_info.html",
-								data: obj.row,
+								url: "module/tool/page/popup_list_dataname.html",
+								data: {},
+								dataname: dataname,
+								filter: filter, // "sell_qty_id='"+ obj.row.id +"'",
 								delta: {},
 								sceneCode: "browse", //"add"//"browse",
 								callback: function(obj, callback) {
-									me.onQuery();
 									if (callback) {
 										callback();
 									}
@@ -1015,7 +736,7 @@
 
 					<div style="float: right; margin-right: 18px;">
 						<el-button-group
-							v-if="selectTabObj && selectTabObj.code == 'month' && selectTabObj.filterObj.dataversion == '鏈堝害鍒濈増'"
+							v-if="selectTabObj && selectTabObj.code == 'month' && dataversion == '鏈堝害鍒濈増'"
 							style="margin-left: 3px;">
 							<el-button :disabled="!(selectTabObj.selectedrow && selectTabObj.selectedrow.biz_date)"
 								type="primary" @click="onAddSS" :icon="buttonsconfig.add.icon">鐢宠瘔</el-button>
@@ -1035,7 +756,7 @@
 						<span v-if="selectTabObj && selectTabObj.code == 'daily'">{{newdate_day}}</span>
 						<el-radio-group style="margin-left: 10px;"
 							v-if="selectTabObj && selectTabObj.filterObj && selectTabObj.code=='month'"
-							v-model="selectTabObj.filterObj.dataversion" size="mini" fill="#4cb108">
+							v-model="dataversion" size="mini" fill="#4cb108">
 							<el-radio-button label="鏈堝害鍒濈増">鍒濈増</el-radio-button>
 							<el-radio-button label="鏈堝害缁堢増">缁堢増</el-radio-button>
 						</el-radio-group>
diff --git a/module/tool/page/popup_list_dataname.html b/module/tool/page/popup_list_dataname.html
new file mode 100644
index 0000000..e42c05d
--- /dev/null
+++ b/module/tool/page/popup_list_dataname.html
@@ -0,0 +1,219 @@
+<!doctype html>
+<html>
+	<head>
+		<meta charset="utf-8"><meta http-equiv="Expires" content="0"><meta http-equiv="Pragma" content="no-cache"><meta http-equiv="Cache-control" content="no-cache"><meta http-equiv="Cache" content="no-cache">
+		<title>鍒楄〃寮圭獥</title>
+		
+		<script type="text/javascript">
+			var pageVue = null;
+			function loadJsCss(callback) {
+				var jscss_urls = [];
+				window.top.initJsCss(document, jscss_urls, callback);
+			};
+			
+			function initVue() {
+				new ListVue({
+					el: "#vbody",
+					data: {
+						dataname: "", 
+						title: "鍒楄〃寮圭獥",
+						pageAttr: {
+							heightType: "popuppage"
+						},
+                        default_tableFields:  [],
+						filterAttr: {
+							columnnumber: 3,
+							labelwidth: "100px",
+							labelposition: "right",//"left",//"right",
+							size: "medium",
+							border: "0px solid #c6c6c600"
+						},
+						filterfieldClick: {},
+						tablefieldClick: {},
+						formfieldClick: {},
+						
+						selectedrows: [],
+					},
+					created() {
+						this.popupParames = clone(Root.popupParames);
+						this.title = this.popupParames.title || this.popupParames.text
+						if (this.popupParames.filter) {
+							this.filterTxt = this.popupParames.filter
+						}
+						
+						if (this.popupParames.dataname) {
+							this.dataname = this.popupParames.dataname;
+						}
+						else if (this.popupParames.delta.dataname) {
+							this.dataname = this.popupParames.delta.dataname;
+						}
+						
+						if (this.popupParames.sceneCode) {
+							if (this.popupParames.sceneCode == "add") {//鏂板
+								this.isedit = true;
+							}
+						}
+					},
+					
+					mounted() {
+						//鑾峰彇鏁版嵁
+						this.initData();
+						this.$nextTick(() => { // 浠ユ湇鍔$殑鏂瑰紡璋冪敤鐨� Loading 闇�瑕佸紓姝ュ叧闂�
+							hideLoading();
+						});
+					},
+					
+					methods:{
+						//鍏抽棴寮圭獥
+						closeDialog() {
+							this.docloseDialog(true);
+						},
+						
+						//鍏抽棴鍓嶈皟鍥炶皟
+						saveAfter() {
+							var me = this;
+							var selectedrows = this.$refs.table1.getShoppingcart();
+							
+							if(this.popupParames.callback) {
+								let obj = {
+									list: clone(selectedrows)
+									// row: clone(this.selectedrow)
+								}
+								this.popupParames.callback(obj, function() {
+									me.docloseDialog();
+								});
+							}
+							else {
+								me.docloseDialog();
+							}
+						},
+						
+						initData() {
+							var me = this;
+							this.onQuery(function(result, callback) {//鏌ヨ鍚庣殑鍥炶皟锛岀敤浜庤幏鍙栧瓧娈电殑
+								if (result.meta && result.meta[me.dataname] && result.meta[me.dataname].fields) {
+									var metas = clone(result.meta[me.dataname].fields);
+									var filterFields_ = [];
+									var tableFields_ = [];
+									
+									metas.map(f=>{
+										f.isshow = "T";
+										
+										if (f.isfilter) {
+											filterFields_.push(clone(f));
+										}
+										else {
+											var filter_f = clone(f);
+											filter_f.isshow = "F";
+										}
+										
+										tableFields_.push(clone(f));
+									})
+									if (!me.filterFields || (me.filterFields && me.filterFields.length == 0)) {
+										me.filterFields = clone(filterFields_);
+										me.tableFields = clone(tableFields_);
+										
+										//瀛楁鏁扮粍杞瓧娈祇bj锛岀洰鐨勪负浜嗙瓫閫夋椂鑾峰彇瀛楁灞炴��
+										me.fieldsToFieldsObj();
+										
+										//璁剧疆瀛楁浜嬩欢
+										me.tableFieldClick();
+									}
+									
+								}
+								
+								if (callback) {
+									callback();
+								}
+							});
+						},
+						
+						tableFieldClick() {
+							var me = this;
+							//绛涢�夊瓧娈典簨浠惰缃�
+							this.filterfieldClick = {
+							};
+							//琛ㄦ牸瀛楁浜嬩欢璁剧疆
+							this.tablefieldClick = {
+							};
+							//琛ㄥ崟瀛楁浜嬩欢璁剧疆
+							this.formfieldClick = {
+							};
+						},
+						
+						selectionChange(obj){
+							var me = this;
+							me.selectedrows = obj;
+						},
+						saveShoppingcart(list) {
+							var me = this;
+							me.selectedrows = list;
+						},
+						
+						onRowDblClick() {
+							if (this.isedit) {
+								this.saveAfter();
+							}
+						},
+						
+					}
+				});
+			};
+			
+			loadJsCss(function () {
+				initVue();
+			});
+		</script>
+		<style>
+			/* 鍦╲ue.js涓� v-cloak 杩欎釜鎸囦护鏄槻姝㈤〉闈㈠姞杞芥椂鍑虹幇 vuejs 鐨勫彉閲忓悕鑰岃璁$殑 */
+			[v-cloak] {
+				display: none !important;
+			}
+		</style>
+		
+	</head>
+	
+	<body style="margin: 0px;">
+		<div v-cloak id="vbody">
+			<div id="page_root">
+				<div ref="popup_body" style="padding: 0 20px;">
+					<div class="h_dialog__body">
+						<h-table
+							v-if="isRefresh && tableFields.length"
+							ref="table1"
+							:table-fields="tableFields" 
+							:table-data="tableData" 
+							:pagesize="pagesize"
+							:pagenum="pagenum"
+							:total="total"
+							:table-height="tableHeight"
+							:table-field-click="tablefieldClick"
+							:is-highlight-row="isedit"
+							:is-show-index="false"
+							:filtersobj="filterObj"
+							:isdraggableorder="false"
+							
+							v-on:get-data="getData"
+							v-on:row-click="rowClick"
+						>
+						</h-table>
+					</div>
+					
+					<!-- 搴曢儴宸ュ叿鏍� -->
+					<div class="el-dialog__footer">
+						<el-button size="small" type="default" @click="closeDialog">鍙� 娑�</el-button>
+						<el-button size="small" v-if="isedit" type="primary" @click="saveAfter">纭� 瀹�</el-button>
+					</div>
+				</div>
+			</div>
+		</div>
+		
+		<div id="page_loading" style="position: absolute; top:0px; width: 100vw; height: 50vh;">
+			<div class="spinner">
+			  <div class="cube1"></div>
+			  <div class="cube2"></div>
+			</div>
+		</div>
+		
+	</body>
+</html>

--
Gitblit v1.8.0