From 625badef071d0931b3868b2ba672d51ce2cc5b91 Mon Sep 17 00:00:00 2001
From: cuiqian2004 <cuiqian2004@163.com>
Date: 星期三, 19 二月 2025 10:01:20 +0800
Subject: [PATCH] action set_subtable_page_row 处理 condition

---
 pages/modal/3037_2.vue | 1540 +++++++++++++++++++++++++++++-----------------------------
 1 files changed, 768 insertions(+), 772 deletions(-)

diff --git a/pages/modal/3037_2.vue b/pages/modal/3037_2.vue
index 5ef4a3f..6e08aaa 100644
--- a/pages/modal/3037_2.vue
+++ b/pages/modal/3037_2.vue
@@ -26,7 +26,7 @@
 						:type="item.name=='Input'?'text':item.name=='InputNumber'?'number':'text'" v-model="item.value"
 						:disabled="item.disabled" :placeholder="item.placeholder"
 						:style="{'width':item.setting.prefix && item.setting.suffix?'78%':item.setting.prefix || item.setting.suffix?'87%':'96%'}"
-						:focus="focusMateria" @focus="ontap(item)" @blur="onevent(item)" />
+						:focus="focusMateria" @focus="ontap(item)" @blur="onevent(item)" :maxlength="-1" />
 					<text v-if="item.setting.suffix" class="uni-icon" :class="[item.setting.suffix]"
 						@click="onchange(item)">&#xe568;</text>
 				</view>
@@ -39,13 +39,22 @@
 				</view>
 				<!-- 澶嶉�妗�-->
 				<checkbox-group class="check_rememberPwd" v-if="item.name=='Checkbox'"
-					:class="item.disabled?'input-disabled':''" @change="onModelValue(item)" :disabled="item.disabled"
-					:data-ischeck="item.value" :style="{'margin-left':'10rpx'}">
-					<label>
-						<checkbox :value="item.value" :checked="item.value" />
-						<text>{{item.label}}</text>
+					:class="item.disabled?'input-disabled':''" :disabled="item.disabled" @change="onCheckBoxValue"
+					:data-attr="item.fieldId">
+					<label v-for="(item2) in item.selections" :key="item2.value">
+						<checkbox :value="item2.value" :checked="item.value.includes(item2.value)" />
+						<text>{{item2.label}}</text>
 					</label>
 				</checkbox-group>
+				<!-- 鍗曢�妗�-->
+				<radio-group class="check_rememberPwd" v-if="item.name=='Radio'"
+					:class="item.disabled?'input-disabled':''" :disabled="item.disabled" @change="onRadioBoxValue"
+					:data-attr="item.fieldId">
+					<label v-for="(item2) in item.selections" :key="item2.value">
+						<radio :value="item2.value" :checked="item2.value === item.value" />
+						<text>{{item2.label}}</text>
+					</label>
+				</radio-group>
 				<!-- Switch寮�叧 -->
 				<switch v-if="item.name=='Switch'" :class="item.disabled?'input-disabled':''" :disabled="item.disabled"
 					v-model="item.value" @change="onModelValue(item)" :style="{'margin-left':'10rpx'}" />
@@ -70,7 +79,8 @@
 					<!-- 宸﹀彸甯冨眬 -->
 					<p class="tx_title2">{{param.Scan_Code.Name}}:</p>
 					<input type="text" class="attr_field" :value="scanCodeVal" @focus="scan_ontap" @blur="scan_onevent"
-						:style="param.Scan_Code.Have_Select_Button==true?'width: '+(100-(param.Scan_Code.Name.length * 5)-14)+'%;':'width: '+(100-(param.Scan_Code.Name.length * 5)-5)+'%;'">
+						:style="param.Scan_Code.Have_Select_Button==true?'width: '+(100-(param.Scan_Code.Name.length * 5)-14)+'%;':'width: '+(100-(param.Scan_Code.Name.length * 5)-5)+'%;'"
+						:maxlength="-1">
 					<div class="text-right2" v-if="param.Scan_Code.Have_Select_Button==true">
 						<a @tap="scan_classAttr_extButton()"><i class="ace-icon fa"
 								:class="param.Scan_Code.Img?param.Scan_Code.Img:'fa-plus-circle'"></i></a>
@@ -102,7 +112,7 @@
 									:type="item.name=='Input'?'text':item.name=='InputNumber'?'number':'text'"
 									v-model="item.value" :disabled="item.disabled" :placeholder="item.placeholder"
 									:style="{'width':item.setting.prefix && item.setting.suffix?'78%':item.setting.prefix || item.setting.suffix?'87%':'96%'}"
-									:focus="focusMateria" @focus="ontap(item)" @blur="onevent(item)" />
+									:focus="focusMateria" @focus="ontap(item)" @blur="onevent(item)" :maxlength="-1" />
 								<text v-if="item.setting.suffix" class="uni-icon" :class="[item.setting.suffix]"
 									@click="onchange(item)">&#xe568;</text>
 							</view>
@@ -119,13 +129,22 @@
 							</view>
 							<!-- 澶嶉�妗�-->
 							<checkbox-group class="check_rememberPwd" v-if="item.name=='Checkbox'"
-								:class="item.disabled?'input-disabled':''" @change="onModelValue(item)"
-								:data-ischeck="item.value" :disabled="item.disabled" :style="{'margin-left':'10rpx'}">
-								<label>
-									<checkbox :value="item.value" :checked="item.value" />
-									<text>{{item.label}}</text>
+								:class="item.disabled?'input-disabled':''" :disabled="item.disabled" @change="onCheckBoxValue"
+								:data-attr="item.fieldId">
+								<label v-for="(item2) in item.selections" :key="item2.value">
+									<checkbox :value="item2.value" :checked="item.value.includes(item2.value)" />
+									<text>{{item2.label}}</text>
 								</label>
 							</checkbox-group>
+							<!-- 鍗曢�妗�-->
+							<radio-group class="check_rememberPwd" v-if="item.name=='Radio'"
+								:class="item.disabled?'input-disabled':''" :disabled="item.disabled"
+								:style="{'margin-left':'10rpx'}" @change="onRadioBoxValue" :data-attr="cols.fieldId">
+								<label v-for="(item2) in item.selections" :key="item2.value">
+									<radio :value="item2.value" :checked="item2.value === item.value" />
+									<text>{{item2.label}}</text>
+								</label>
+							</radio-group>
 							<!-- Switch寮�叧 -->
 							<switch v-if="item.name=='Switch'" :class="item.disabled?'input-disabled':''"
 								:disabled="item.disabled" v-model="item.value" @change="onModelValue(item)"
@@ -156,7 +175,8 @@
 											v-model="cols.value" :disabled="cols.disabled"
 											:placeholder="cols.placeholder"
 											:style="{'width':cols.setting.prefix && cols.setting.suffix?'78%':cols.setting.prefix || cols.setting.suffix?'87%':'96%'}"
-											:focus="focusMateria" @focus="ontap(cols)" @blur="onevent(cols)" />
+											:focus="focusMateria" @focus="ontap(cols)" @blur="onevent(cols)"
+											:maxlength="-1" />
 										<text v-if="cols.setting.suffix" class="uni-icon" :class="[cols.setting.suffix]"
 											@click="onchange(cols)">&#xe568;</text>
 									</view>
@@ -174,23 +194,32 @@
 									</view>
 									<!-- 澶嶉�妗�-->
 									<checkbox-group class="check_rememberPwd" v-if="cols.name=='Checkbox'"
-										:class="cols.disabled?'input-disabled':''" :disabled="item.disabled"
-										@change="onModelValue(cols)" :data-ischeck="cols.value"
-										:style="{'margin-left':'10rpx'}">
-										<label>
-											<checkbox :value="cols.value" :checked="cols.value" />
-											<text>{{cols.label}}</text>
+										:class="cols.disabled?'input-disabled':''" :disabled="cols.disabled"
+										@change="onCheckBoxValue" :data-attr="cols.fieldId">
+										<label v-for="(cols2) in cols.selections" :key="cols2.value">
+											<checkbox :value="cols2.value"
+												:checked="cols.value.includes(cols2.value)" />
+											<text>{{cols2.label}}</text>
 										</label>
 									</checkbox-group>
+									<!-- 鍗曢�妗�-->
+									<radio-group class="check_rememberPwd" v-if="cols.name=='Radio'"
+										:class="cols.disabled?'input-disabled':''" :disabled="cols.disabled"
+										@change="onRadioBoxValue " :data-attr="cols.fieldId">
+										<label v-for="(cols2) in cols.selections" :key="cols2.value">
+											<radio :value="cols2.value" :checked="cols2.value === cols.value" />
+											<text>{{cols2.label}}</text>
+										</label>
+									</radio-group>
 									<!-- Switch寮�叧 -->
 									<switch v-if="cols.name=='Switch'" :class="cols.disabled?'input-disabled':''"
-										:disabled="item.disabled" v-model="cols.value" @change="onModelValue(cols)"
+										:disabled="cols.disabled" v-model="cols.value" @change="onModelValue(cols)"
 										:style="{'margin-left':'10rpx'}" />
 									<!-- 鏃ユ湡鏃堕棿 -->
 									<view class="input-wrapper"
 										v-if="(cols.name=='TimePicker' || cols.name=='DatePicker') && !cols.disabled">
 										<picker mode="date" class="date_iput" :class="cols.disabled?'input-disabled':''"
-											:disabled="item.disabled" :value="cols.value" @change="onModelValue(cols)">
+											:disabled="cols.disabled" :value="cols.value" @change="onModelValue(cols)">
 											<view class="picker">{{cols.value}}</view>
 										</picker>
 									</view>
@@ -213,10 +242,10 @@
 		<view class="view-floor">
 			<button type="default" @tap="cancel" class="btn_cancel"
 				v-if="param.Sub_Cls.Can_Add_Delete == true">{{translateSys('cancel')}}</button>
-			<button type="default" @tap="sava" class="btn_add"
-				v-if="param.Sub_Cls.Can_Add_Delete == true">{{title}}</button>
-			<button type="default" @tap="sava" class="btn_sava"
-				v-else-if="param.Sub_Cls.Can_Add_Delete == false">{{title}}</button>
+			<button type="default" @tap="sava" class="btn_add" v-if="param.Sub_Cls.Can_Add_Delete == true"
+				:class="saving?'btn_disabled':''" :disabled="saving">{{title}}</button>
+			<button type="default" @tap="sava" class="btn_sava" v-else-if="param.Sub_Cls.Can_Add_Delete == false"
+				:class="saving?'btn_disabled':''" :disabled="saving">{{title}}</button>
 		</view>
 		<!-- 鏅�寮圭獥 top bottom center left right -->
 		<view>
@@ -249,6 +278,17 @@
 <script>
 	import Base64 from '../../components/js-base64/base64.js'
 	import utils from "@/js/utils.js"
+	import {
+		appGetInfo,
+		dictGetInfo
+	} from "@/api/mobox.js"
+	import {
+		getUIStyleInfo,
+		runCustomEvent,
+		dataObjCreate,
+		dataObjDel
+	} from "@/api/data.js"
+
 	export default {
 		modules: {
 			Base64,
@@ -279,6 +319,7 @@
 				detail1_styledef: {},
 				detail1StyleDefList: [],
 				activelist: [],
+				saving: false,
 			};
 		},
 		onLoad(options) {
@@ -322,6 +363,7 @@
 				//浼犲叆鍙傛暟鍊� 				if (paramValue) {
 					const attrs = paramValue.attrs || [];
+
 					(this.$data.head_styledef?.form?.items || []).forEach(async (ele, index) => {
 						if (ele.name != "Layout") {
 							attrs.forEach(async (ele2, index2) => {
@@ -352,50 +394,61 @@
 					class_id: class_id,
 					ui_style_id: style_id,
 				};
-				this.$store.dispatch('UIStyleGetInfo', dataInfo).then(ret => {
-					// console.log(ret);
-					if (ret.err_code == 0) {
-						var styledef = "";
-						if (ret.result.style_def) {
-							//mobox2鐨剆tyle_def鏄痡son瀛楃涓�-							styledef = ret.result.style_def.replace(/\\/g, "");
-							//mobox3鐨剆tyle_def鏄痓ase64瀛楃涓�-							if (!ret.result.style_def.includes('"')) styledef = Base64.decode(ret.result
-								.style_def);
-						}
-						$this.$data.head_styledef = ret.result.style_def ? JSON.parse(styledef) : {};
-						// console.log($this.$data.head_styledef);
+				try {
+					const result = await getUIStyleInfo(dataInfo)
+
+					var styledef = "";
+					if (result.style_def) {
+						//mobox2鐨剆tyle_def鏄痡son瀛楃涓�+						styledef = result.style_def.replace(/\\/g, "");
+						//mobox3鐨剆tyle_def鏄痓ase64瀛楃涓�+						if (!result.style_def.includes('"')) styledef = Base64.decode(result
+							.style_def);
+					}
+					$this.$data.head_styledef = result.style_def ? JSON.parse(styledef) : {};
+					// console.log($this.$data.head_styledef);
+					if ($this.head_styledef.form?.items) {
 						$this.head_styledef.form.items.forEach(async (ele, index) => {
 							ele.show = true;
 							if (ele.useDict == true) { //鍒ゆ柇useDict鏄惁浣跨敤瀛楀吀
 								await this.DictGetInfo(ele.bind.dict, index, 'mast');
+							} else {
+								if (ele?.name === "Select") {
+									const selections = ele?.selections || []
+									//鏈夐粯璁ゅ�锛屾樉绀洪粯璁ゅ�
+									let itemName = ele.value || "";
+									if (itemName) {
+										$this.head_styledef.form
+											.model[ele.fieldId] = itemName;
+									}
+									$this.head_styledef.form.items[index].dict = selections.map((a) => {
+										return {
+											value: a.value,
+											text: a.label
+										}
+									})
+								}
+
 							}
 						});
-
-						if ($this.head_styledef.event?.length > 0) {
-							$this.head_styledef.event.forEach(async (a) => { //鍒ゆ柇鏄惁鏄垵濮嬪寲浜嬩欢
-								if (a.event_id == "initial") {
-									await this.loadInitEvent(a.scrip_id, 'head');
-								}
-							});
-						}
-					} else {
-						uni.showModal({
-							title: this.translateSys("error") + "1",
-							content: ret.err_msg,
-							showCancel: false,
-							confirmText: this.translateSys("cancel")
+					}
+					if ($this.head_styledef.event?.length > 0) {
+						$this.head_styledef.event.forEach(async (a) => { //鍒ゆ柇鏄惁鏄垵濮嬪寲浜嬩欢
+							if (a.event_id == "initial") {
+								await this.loadInitEvent(a.scrip_id, 'head');
+							}
 						});
 					}
-				}).catch(ex => {
+				} catch (ex) {
 					// console.log(ex);
+					let tip = typeof ex.errMsg == "string" ? ex.errMsg : ex
 					uni.showModal({
 						title: this.translateSys("error") + "1.1",
-						content: ex.errMsg,
+						content: tip,
 						showCancel: false,
 						confirmText: this.translateSys("cancel")
 					});
-				});
+				}
 
 			},
 			async Detail1_UIstyleGetInfo(class_id, style_id) { //鑾峰彇鑷畾涔夎〃鍗曟牱寮�@@ -404,52 +457,58 @@
 					class_id: class_id,
 					ui_style_id: style_id,
 				};
-				this.$store.dispatch('UIStyleGetInfo', dataInfo).then(ret => {
-					// console.log(ret);
-					if (ret.err_code == 0) {
-						var styledef = "";
-						if (ret.result.style_def) {
-							//mobox2鐨剆tyle_def鏄痡son瀛楃涓�-							styledef = ret.result.style_def.replace(/\\/g, "");
-							//mobox3鐨剆tyle_def鏄痓ase64瀛楃涓�-							if (!ret.result.style_def.includes('"')) styledef = Base64.decode(ret.result
-								.style_def);
-						}
-						$this.$data.detail1_styledef = ret.result.style_def ? JSON.parse(styledef) : {};
-						$this.$data.detail1_styledef.SelBut_Checked = true;
+				try {
+					const result = await getUIStyleInfo(dataInfo)
+					var styledef = "";
+					if (result.style_def) {
+						//mobox2鐨剆tyle_def鏄痡son瀛楃涓�+						styledef = result.style_def.replace(/\\/g, "");
+						//mobox3鐨剆tyle_def鏄痓ase64瀛楃涓�+						if (!result.style_def.includes('"')) styledef = Base64.decode(result
+							.style_def);
+					}
+					$this.$data.detail1_styledef = result.style_def ? JSON.parse(styledef) : {};
+					$this.$data.detail1_styledef.SelBut_Checked = true;
+					if ($this.detail1_styledef.form?.items) {
 						$this.detail1_styledef.form.items.forEach(async (ele, index) => {
 							if (ele.useDict == true) { //鍒ゆ柇useDict鏄惁浣跨敤瀛楀吀
 								await this.DictGetInfo(ele.bind.dict, index, 'sub');
+							} else {
+								if (ele?.name === "Select") {
+									const selections = ele?.selections || []
+									//鏈夐粯璁ゅ�锛屾樉绀洪粯璁ゅ�
+									let itemName = ele.value || "";
+									if (itemName) {
+										$this.detail1_styledef.form.items[ele.fieldId] = itemName;
+									}
+									$this.detail1_styledef.form.items[index].dict = selections.map((a) => {
+										return {
+											value: a.value,
+											text: a.label
+										}
+									})
+								}
 							}
 						});
-						if ($this.detail1_styledef.event?.length > 0) {
-							$detail1_styledefforEach(async (a) => { //鍒ゆ柇鏄惁鏄垵濮嬪寲浜嬩欢
-								if (a.event_id == "initial") {
-									await this.loadInitEvent(a.scrip_id, 'detail');
-								}
-							});
-						}
-						// var aa = JSON.stringify(this.detail1_styledef);
-						// $this.$data.detail1StyleDefList.push(JSON.parse(aa));
-						// console.log($this.$data.detail1StyleDefList);
-
-					} else {
-						uni.showModal({
-							title: this.translateSys("error") + "2",
-							content: ret.err_msg,
-							showCancel: false,
-							confirmText: this.translateSys("cancel")
+					}
+					if ($this.detail1_styledef.event?.length > 0) {
+						$detail1_styledefforEach(async (a) => { //鍒ゆ柇鏄惁鏄垵濮嬪寲浜嬩欢
+							if (a.event_id == "initial") {
+								await this.loadInitEvent(a.scrip_id, 'detail');
+							}
 						});
 					}
-				}).catch(ex => {
+				} catch (ex) {
 					// console.log(ex);
+					let tip = typeof ex.errMsg == "string" ? ex.errMsg : ex
 					uni.showModal({
 						title: this.translateSys("error") + "2.1",
-						content: ex.errMsg,
+						content: tip,
 						showCancel: false,
 						confirmText: this.translateSys("cancel")
 					});
-				});
+				}
+
 
 			},
 			async DictGetInfo(dict, index, type) { //Mobox3寰楀埌寰楀埌瀛楀吀淇℃伅瀛楀吀椤瑰垪琛�@@ -460,14 +519,14 @@
 					dict_name: dict.name
 				};
 				try {
-					const success = await this.getDictInfo(dataInfo)
+					const result = await dictGetInfo(dataInfo)
 					var list = [];
 					var itemName = '';
-					success.result.dict_item_list.forEach((item) => {
+					(result.dict_item_list || []).forEach((item) => {
 						if (item.is_default == '1')
-							itemName = item.name;
+							itemName = item.name
 						list.push({
-							text: item.value,
+							text: item.value ? item.value : item.name,
 							value: item.name,
 						});
 					});
@@ -501,36 +560,6 @@
 				}
 
 			},
-			getDictInfo(info) { //Mobox3寰楀埌寰楀埌瀛楀吀淇℃伅瀛楀吀椤瑰垪琛�-				const loginInfo = this.$store.getters.loginid
-				const mobxoSApi = this.$store.getters.getMobxoSApi
-				return new Promise((resolve, reject) => {
-					uni.request({
-						url: mobxoSApi + 'api/dict/GetInfo2?sessionid=' + loginInfo.result.session_id,
-						data: info,
-						method: 'POST',
-						dataType: "json",
-						success: (_res) => {
-							// console.log(_res);
-							const ret = _res.data
-							if (ret.err_code == 0) {
-								resolve(ret);
-							} else {
-								reject({
-									"errMsg": ret.err_msg
-								});
-							}
-						},
-						fail: (err) => {
-							// console.log(err);
-							reject(err);
-						}
-					})
-
-				})
-
-			},
-
 			async loadInitEvent(eventid, type) {
 				var $this = this;
 				var styledef = type == 'head' ? this.head_styledef : this.detail1_styledef;
@@ -543,200 +572,189 @@
 				};
 				console.log(dataInfo);
 				// return;
-				this.$store.dispatch('runCustomEvent', dataInfo).then(success => {
-					console.log(success);
-					if (success.err_code == 0) {
-						var data = success.result;
-						if (data.ret != 0) {
-							var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data
-								.err_info.join('<br/>') : '';
-							if (data.ret == 801) {
-								if (this.param.Only_Script_Error) {
-									let pos = tip.indexOf("锛�);
-									if (pos > -1) tip = tip.substring(pos + 1);
-								}
-								uni.showModal({
-									title: this.translateSys("tip"),
-									content: tip,
-									showCancel: false,
-									confirmText: this.translateSys("cancel")
-								});
-							} else uni.showModal({
-								title: this.translateSys("tip"),
-								content: tip + ',' + this.translateSys('tip') + ':' + data.ret,
-								showCancel: false,
-								confirmText: this.translateSys("cancel")
-							});
-							return false
-						} else {
-							var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join(
-								'<br/>') : '';
-							if (tip) uni.showModal({
+				runCustomEvent(dataInfo).then(data => {
+					console.log(data);
+
+					if (data.ret != 0) {
+						var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data
+							.err_info.join('<br/>') : '';
+						if (data.ret == 801) {
+							if (this.param.Only_Script_Error) {
+								let pos = tip.indexOf("锛�);
+								if (pos > -1) tip = tip.substring(pos + 1);
+							}
+							uni.showModal({
 								title: this.translateSys("tip"),
 								content: tip,
 								showCancel: false,
 								confirmText: this.translateSys("cancel")
 							});
+						} else uni.showModal({
+							title: this.translateSys("tip"),
+							content: tip + ',' + this.translateSys('tip') + ':' + data.ret,
+							showCancel: false,
+							confirmText: this.translateSys("cancel")
+						});
+						return false
+					} else {
+						var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join(
+							'<br/>') : '';
+						if (tip) uni.showModal({
+							title: this.translateSys("tip"),
+							content: tip,
+							showCancel: false,
+							confirmText: this.translateSys("cancel")
+						});
 
-							var actionlist = data.action;
-							if (actionlist) {
-								console.log(actionlist);
-								for (var i = 0; i < actionlist.length; i++) {
-									var action = actionlist[i];
-									if (action.action_type == 'set_dlg_attr') {
-										var result = action.value;
-										for (var i = 0; i < result.length; i++) {
-											if (result[i].choice_list) {
-												for (var c = 0; c < styledef.form.items.length; c++) {
-													var attr = styledef.form.items[c];
-													if (attr.name != 'Layout') {
-														if (attr.fieldId == result[i].attr) {
-															var dictItemList = [];
-															for (var d in result[i].choice_list) {
-																var val = result[i].choice_list[d];
-																dictItemList.push({
-																	"CN_S_NAME": val,
-																	"CN_S_VALUE": val,
-																	"text": val,
-																	"value": val
-																});
-															}
-															attr.dict = dictItemList;
-														}
-													} else if (attr.name == 'Layout') {
-														attr.setting.colList.forEach(col => {
-															if (col) {
-																if (col.fieldId == result[i].attr) {
-																	var dictItemList = [];
-																	for (var d in result[i]
-																			.choice_list) {
-																		var val = result[i]
-																			.choice_list[d];
-																		dictItemList.push({
-																			"CN_S_NAME": val,
-																			"CN_S_VALUE": val,
-																			"text": val,
-																			"value": val
-																		});
-																	}
-																	col.dict = dictItemList;
-																}
-															}
-														});
-													}
-
-												}
-											}
+						var actionlist = data.action;
+						if (actionlist) {
+							console.log(actionlist);
+							for (var i = 0; i < actionlist.length; i++) {
+								var action = actionlist[i];
+								if (action.action_type == 'set_dlg_attr') {
+									var result = action.value;
+									for (var i = 0; i < result.length; i++) {
+										if (result[i].choice_list) {
 											for (var c = 0; c < styledef.form.items.length; c++) {
 												var attr = styledef.form.items[c];
-												// console.log(attr[j].Name+'=='+result[i].attr);
-												//鍒ゆ柇琛ㄥ崟閲屾槸鍚︽湁杩斿洖瀛楁锛屾病鏈夊氨瑁呰浇鍒癿odel閲岋紝鐐瑰嚮纭畾鎻愪氦鐨勬椂鍊欏甫涓婅繖浜涙暟鎹�-												if ($this.head_styledef.form.model[result[i].attr] ==
-													undefined) {
-													$this.head_styledef.form.model[result[i].attr] = result[i]
-														.value;
-												}
-												//鍒ゆ柇鏄惁鏄爡鏍艰〃鍗� 												if (attr.name != 'Layout') {
 													if (attr.fieldId == result[i].attr) {
-														attr.value = '';
-														attr.oldvalue = '';
-														attr.value = result[i].value;
-														attr.oldvalue = result[i].value;
-														$this.head_styledef.form.model[attr.fieldId] = result[
-															i].value;
+														var dictItemList = [];
+														for (var d in result[i].choice_list) {
+															var val = result[i].choice_list[d];
+															dictItemList.push({
+																"CN_S_NAME": val,
+																"CN_S_VALUE": val,
+																"text": val,
+																"value": val
+															});
+														}
+														attr.dict = dictItemList;
 													}
 												} else if (attr.name == 'Layout') {
 													attr.setting.colList.forEach(col => {
 														if (col) {
 															if (col.fieldId == result[i].attr) {
-																col.value = '';
-																col.oldvalue = '';
-																col.value = result[i].value;
-																col.oldvalue = result[i].value;
-																$this.head_styledef.form.model[col
-																	.fieldId] = result[i].value;
+																var dictItemList = [];
+																for (var d in result[i]
+																		.choice_list) {
+																	var val = result[i]
+																		.choice_list[d];
+																	dictItemList.push({
+																		"CN_S_NAME": val,
+																		"CN_S_VALUE": val,
+																		"text": val,
+																		"value": val
+																	});
+																}
+																col.dict = dictItemList;
 															}
 														}
 													});
 												}
+
 											}
-											var length = 0;
-											if (!$this.$data.refdatastore.filter(function(s) {
-													return result[i].attr == s.attr
-												}).length) {
-												length = 1;
-												$this.$data.refdatastore.push(result[i]);
+										}
+										for (var c = 0; c < styledef.form.items.length; c++) {
+											var attr = styledef.form.items[c];
+											// console.log(attr[j].Name+'=='+result[i].attr);
+											//鍒ゆ柇琛ㄥ崟閲屾槸鍚︽湁杩斿洖瀛楁锛屾病鏈夊氨瑁呰浇鍒癿odel閲岋紝鐐瑰嚮纭畾鎻愪氦鐨勬椂鍊欏甫涓婅繖浜涙暟鎹�+											if ($this.head_styledef.form.model[result[i].attr] ==
+												undefined) {
+												$this.head_styledef.form.model[result[i].attr] = result[i]
+													.value;
 											}
-											if (length == 0) {
-												for (var j = 0; j < $this.$data.refdatastore.length; j++) {
-													if ($this.$data.refdatastore[j].attr == result[i].attr) {
-														$this.$data.refdatastore[j].value = result[i].value;
+											//鍒ゆ柇鏄惁鏄爡鏍艰〃鍗�+											if (attr.name != 'Layout') {
+												if (attr.fieldId == result[i].attr) {
+													attr.value = '';
+													attr.oldvalue = '';
+													attr.value = result[i].value;
+													attr.oldvalue = result[i].value;
+													$this.head_styledef.form.model[attr.fieldId] = result[
+														i].value;
+												}
+											} else if (attr.name == 'Layout') {
+												attr.setting.colList.forEach(col => {
+													if (col) {
+														if (col.fieldId == result[i].attr) {
+															col.value = '';
+															col.oldvalue = '';
+															col.value = result[i].value;
+															col.oldvalue = result[i].value;
+															$this.head_styledef.form.model[col
+																.fieldId] = result[i].value;
+														}
 													}
+												});
+											}
+										}
+										var length = 0;
+										if (!$this.$data.refdatastore.filter(function(s) {
+												return result[i].attr == s.attr
+											}).length) {
+											length = 1;
+											$this.$data.refdatastore.push(result[i]);
+										}
+										if (length == 0) {
+											for (var j = 0; j < $this.$data.refdatastore.length; j++) {
+												if ($this.$data.refdatastore[j].attr == result[i].attr) {
+													$this.$data.refdatastore[j].value = result[i].value;
 												}
 											}
 										}
-									} else if (data.action[i].action_type == 'set_dlg_attr_show') {
-										var result = action.value;
-										result.forEach(async (attr, key) => {
-											styledef.form.items.forEach(async (ele, index) => {
-												//鍒ゆ柇鏄惁鏄爡鏍艰〃鍗�-												if (ele.name != 'Layout') {
-													if (ele.fieldId == attr.attr) {
-														ele.show = attr.show;
-													}
-												} else if (ele.name == 'Layout') {
-													ele.setting.colList.forEach(
-														col => {
-															if (col) {
-																if (col.fieldId ==
-																	attr.attr) {
-																	col.show = attr
-																		.show;
-																}
-															}
-														});
-												}
-											});
-										});
-										var style_def = JSON.parse(JSON.stringify(styledef));
-										if (type == 'head') {
-											$this.$data.head_styledef = [];
-											$this.$data.head_styledef = style_def;
-											// console.log($this.$data.head_styledef);
-										} else {
-											$this.$data.detail1_styledef = [];
-											$this.$data.detail1_styledef = style_def;
-											// console.log($this.$data.detail1_styledef);
-										}
-									} else {
-										uni.showModal({
-											title: this.translateSys("tip"),
-											content: this.translate('execute_init_event_failed') +
-												this.translateSys("full_stop") +
-												this.translate('reason') + this.translateSys("colon") +
-												this.translateSys("quotation_mark_left") + action
-												.action_type + this.translateSys(
-													"quotation_mark_right") + this
-												.translate('tip_action_unprocessed'),
-											showCancel: false,
-											confirmText: this.translateSys("cancel")
-										});
 									}
+								} else if (data.action[i].action_type == 'set_dlg_attr_show') {
+									var result = action.value;
+									result.forEach(async (attr, key) => {
+										styledef.form.items.forEach(async (ele, index) => {
+											//鍒ゆ柇鏄惁鏄爡鏍艰〃鍗�+											if (ele.name != 'Layout') {
+												if (ele.fieldId == attr.attr) {
+													ele.show = attr.show;
+												}
+											} else if (ele.name == 'Layout') {
+												ele.setting.colList.forEach(
+													col => {
+														if (col) {
+															if (col.fieldId ==
+																attr.attr) {
+																col.show = attr
+																	.show;
+															}
+														}
+													});
+											}
+										});
+									});
+									var style_def = JSON.parse(JSON.stringify(styledef));
+									if (type == 'head') {
+										$this.$data.head_styledef = [];
+										$this.$data.head_styledef = style_def;
+										// console.log($this.$data.head_styledef);
+									} else {
+										$this.$data.detail1_styledef = [];
+										$this.$data.detail1_styledef = style_def;
+										// console.log($this.$data.detail1_styledef);
+									}
+								} else {
+									uni.showModal({
+										title: this.translateSys("tip"),
+										content: this.translate('execute_init_event_failed') +
+											this.translateSys("full_stop") +
+											this.translate('reason') + this.translateSys("colon") +
+											this.translateSys("quotation_mark_left") + action
+											.action_type + this.translateSys(
+												"quotation_mark_right") + this
+											.translate('tip_action_unprocessed'),
+										showCancel: false,
+										confirmText: this.translateSys("cancel")
+									});
 								}
 							}
 						}
-					} else {
-						uni.showModal({
-							title: this.translateSys("error") + "3",
-							content: this.translate('execute_init_event_failed') +
-								this.translateSys("full_stop") +
-								this.translate('reason') + this.translateSys("colon") + success
-								.err_msg,
-							showCancel: false,
-							confirmText: this.translateSys("cancel")
-						});
 					}
+
 				}).catch(ex => {
 					// console.log(ex);
 					uni.showModal({
@@ -806,7 +824,7 @@
 				// console.log(e.target);
 				var $this = this;
 				console.log(item);
-				if (item.oldvalue != item.value&& item.value.trim() != "") {
+				if (item.oldvalue != item.value && item.value.trim() != "") {
 					item.oldvalue = item.value;
 					var attr = item.fieldId;
 					$this.head_styledef.form.model[attr] = item.value;
@@ -845,7 +863,7 @@
 				console.log(item);
 				var $this = this;
 				console.log(item);
-				if (item.oldvalue != item.value&& item.value.trim() != "") {
+				if (item.oldvalue != item.value && item.value.trim() != "") {
 					item.oldvalue = item.value;
 					var attr = item.fieldId;
 					$this.head_styledef.form.model[attr] = item.value;
@@ -980,6 +998,17 @@
 					}
 				}
 			},
+			
+			onCheckBoxValue(e) { //缁戝畾Model鍊�+				let values = e.detail.value || []
+				let attr = e.currentTarget?.dataset?.attr || ""
+				this.head_styledef.form.model[attr] = values;
+			},
+			onRadioBoxValue(e) { //缁戝畾Model鍊�+				let value = e.detail.value || ""
+				let attr = e.currentTarget?.dataset?.attr || ""
+				this.head_styledef.form.model[attr] = value;
+			},
 			onModelValue(item) { //缁戝畾Model鍊� 				//console.log(e.target)
 				var attr = item.fieldId;
@@ -1003,25 +1032,18 @@
 					uni.showLoading({
 						title: this.translateSys("loading")
 					});
-					this.$store.dispatch('dataObjDel', dataInfo).then(success => {
+					dataObjDel(dataInfo).then(success => {
 						// console.log(success);
 						uni.hideLoading();
-						if (ret.err_code == 0) {
-							$this.$data.subPanelList.splice(index, 1);
-							uni.showModal({
-								title: this.translateSys("tip"),
-								content: this.translate("delete_success"),
-								showCancel: false,
-								confirmText: this.translateSys("cancel")
-							});
-						} else {
-							uni.showModal({
-								title: this.translateSys("error") + "9",
-								content: success.msg,
-								showCancel: false,
-								confirmText: this.translateSys("cancel")
-							});
-						}
+
+						$this.$data.subPanelList.splice(index, 1);
+						uni.showModal({
+							title: this.translateSys("tip"),
+							content: this.translate("delete_success"),
+							showCancel: false,
+							confirmText: this.translateSys("cancel")
+						});
+
 					}).catch(ex => {
 						console.log(ex);
 						uni.hideLoading();
@@ -1244,7 +1266,7 @@
 					info.dataJson = Base64.encode(JSON.stringify(info.dataJson)); //灏嗗瓧绗︿覆杞崲涓篵ase64缂栫爜
 				var obj_attr = {};
 				info.attr.forEach(item => {
-					obj_attr[item.attr] = item.val;
+					obj_attr[item.attr] = item.value;
 				});
 				if (!info.eventid.includes('{')) info.eventid = '{' + info.eventid + '}';
 				var dataInfo = {
@@ -1268,228 +1290,210 @@
 				};
 				console.log(dataInfo);
 				// return;
-				this.$store.dispatch('runCustomEvent', dataInfo).then(success => {
-					console.log(success);
-					if (success.err_code == 0) {
-						var data = success.result;
-						if (data.ret != 0) {
-							var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data
-								.err_info.join('<br/>') : '';
-							if (data.ret == 801) {
-								if (this.param.Only_Script_Error) {
-									let pos = tip.indexOf("锛�);
-									if (pos > -1) tip = tip.substring(pos + 1);
-								}
-								uni.showModal({
-									title: this.translateSys("tip"),
-									content: tip,
-									showCancel: false,
-									confirmText: this.translateSys("cancel")
-								});
-							} else uni.showModal({
-								title: this.translateSys("tip"),
-								content: tip + ',' + this.translateSys('tip') + ':' + data.ret,
-								showCancel: false,
-								confirmText: this.translateSys("cancel")
-							});
-							return false
-						} else {
-							var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join(
-								'<br/>') : '';
-							if (tip) uni.showModal({
+				runCustomEvent(dataInfo).then(data => {
+					console.log(data);
+					if (data.ret != 0) {
+						var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data
+							.err_info.join('<br/>') : '';
+						if (data.ret == 801) {
+							if (this.param.Only_Script_Error) {
+								let pos = tip.indexOf("锛�);
+								if (pos > -1) tip = tip.substring(pos + 1);
+							}
+							uni.showModal({
 								title: this.translateSys("tip"),
 								content: tip,
 								showCancel: false,
 								confirmText: this.translateSys("cancel")
 							});
+						} else uni.showModal({
+							title: this.translateSys("tip"),
+							content: tip + ',' + this.translateSys('tip') + ':' + data.ret,
+							showCancel: false,
+							confirmText: this.translateSys("cancel")
+						});
+						return false
+					} else {
+						var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join(
+							'<br/>') : '';
+						if (tip) uni.showModal({
+							title: this.translateSys("tip"),
+							content: tip,
+							showCancel: false,
+							confirmText: this.translateSys("cancel")
+						});
 
-							var actionlist = data.action;
-							if (actionlist) {
-								console.log(actionlist);
-								for (var i = 0; i < actionlist.length; i++) {
-									var action = actionlist[i];
-									if (action.action_type == 'set_dlg_attr') {
-										var result = action.value;
-										for (var i = 0; i < result.length; i++) {
-											if (result[i].choice_list) {
-												for (var c = 0; c < $this.head_styledef.form.items.length; c++) {
-													var attr = $this.head_styledef.form.items[c];
-													if (attr.name != 'Layout') {
-														if (attr.fieldId == result[i].attr) {
-															var dictItemList = [];
-															for (var d in result[i].choice_list) {
-																var val = result[i].choice_list[d];
-																dictItemList.push({
-																	"CN_S_NAME": val,
-																	"CN_S_VALUE": val,
-																	"text": val,
-																	"value": val
-																});
-															}
-															attr.dict = dictItemList;
-														}
-													} else if (attr.name == 'Layout') {
-														attr.setting.colList.forEach(col => {
-															if (col) {
-																if (col.fieldId == result[i].attr) {
-																	var dictItemList = [];
-																	for (var d in result[i].choice_list) {
-																		var val = result[i].choice_list[d];
-																		dictItemList.push({
-																			"CN_S_NAME": val,
-																			"CN_S_VALUE": val,
-																			"text": val,
-																			"value": val
-																		});
-																	}
-																	col.dict = dictItemList;
-																}
-															}
-														});
-													}
-												}
-											}
-											for (var c = 0; c < $this.$data.head_styledef.form.items.length; c++) {
-												var attr = $this.$data.head_styledef.form.items[c];
-												// console.log(attr[j].Name+'=='+result[i].attr);
+						var actionlist = data.action;
+						if (actionlist) {
+							console.log(actionlist);
+							for (var i = 0; i < actionlist.length; i++) {
+								var action = actionlist[i];
+								if (action.action_type == 'set_dlg_attr') {
+									var result = action.value;
+									for (var i = 0; i < result.length; i++) {
+										if (result[i].choice_list) {
+											for (var c = 0; c < $this.head_styledef.form.items.length; c++) {
+												var attr = $this.head_styledef.form.items[c];
 												if (attr.name != 'Layout') {
 													if (attr.fieldId == result[i].attr) {
-														attr.value = '';
-														attr.oldvalue = '';
-														attr.value = result[i].value;
-														attr.oldvalue = result[i].value;
-														$this.head_styledef.form.model[attr.fieldId] = result[i]
-															.value;
+														var dictItemList = [];
+														for (var d in result[i].choice_list) {
+															var val = result[i].choice_list[d];
+															dictItemList.push({
+																"CN_S_NAME": val,
+																"CN_S_VALUE": val,
+																"text": val,
+																"value": val
+															});
+														}
+														attr.dict = dictItemList;
 													}
 												} else if (attr.name == 'Layout') {
 													attr.setting.colList.forEach(col => {
 														if (col) {
 															if (col.fieldId == result[i].attr) {
-																col.value = '';
-																col.oldvalue = '';
-																col.value = result[i].value;
-																col.oldvalue = result[i].value;
-																$this.head_styledef.form.model[col
-																	.fieldId] = result[i].value;
+																var dictItemList = [];
+																for (var d in result[i].choice_list) {
+																	var val = result[i].choice_list[d];
+																	dictItemList.push({
+																		"CN_S_NAME": val,
+																		"CN_S_VALUE": val,
+																		"text": val,
+																		"value": val
+																	});
+																}
+																col.dict = dictItemList;
 															}
 														}
 													});
-												}
-
-											}
-											var length = 0;
-											if (!$this.$data.refdatastore.filter(function(s) {
-													return result[i].attr == s.attr
-												}).length) {
-												length = 1;
-												$this.$data.refdatastore.push(result[i]);
-											}
-											if (length == 0) {
-												for (var j = 0; j < $this.$data.refdatastore.length; j++) {
-													if ($this.$data.refdatastore[j].attr == result[i].attr) {
-														$this.$data.refdatastore[j].value = result[i].value;
-													}
 												}
 											}
 										}
-									} else if (action.action_type == 'set_dlg_attr_show') {
-										var result = action.value;
-										result.forEach(async (attr, key) => {
-											$this.$data.head_styledef.form.items.forEach(async (ele,
-												index) => {
-												//鍒ゆ柇鏄惁鏄爡鏍艰〃鍗�-												if (ele.name != 'Layout') {
-													if (ele.fieldId == attr.attr) {
-														ele.show = attr.show;
-													}
-												} else if (ele.name == 'Layout') {
-													ele.setting.colList.forEach(col => {
-														if (col) {
-															if (col.fieldId == attr
-																.attr) {
-																col.show = attr
-																	.show;
-															}
-														}
-													});
+										for (var c = 0; c < $this.$data.head_styledef.form.items.length; c++) {
+											var attr = $this.$data.head_styledef.form.items[c];
+											// console.log(attr[j].Name+'=='+result[i].attr);
+											if (attr.name != 'Layout') {
+												if (attr.fieldId == result[i].attr) {
+													attr.value = '';
+													attr.oldvalue = '';
+													attr.value = result[i].value;
+													attr.oldvalue = result[i].value;
+													$this.head_styledef.form.model[attr.fieldId] = result[i]
+														.value;
 												}
-											});
-										});
-										var head_styledef = JSON.parse(JSON.stringify($this.$data.head_styledef));
-										$this.$data.head_styledef = [];
-										$this.$data.head_styledef = head_styledef;
-										// console.log($this.$data.head_styledef);
-									} else if (action.action_type == 'set_global_attr') {
-										$this.$data.global_attr = action.value || [];
-									} else {
-										uni.showModal({
-											title: this.translateSys("tip"),
-											content: this.translateSys("quotation_mark_left") + action
-												.action_type + this.translateSys(
-													"quotation_mark_right") + this.translate(
-													"tip_action_unprocessed"),
-											showCancel: false,
-											confirmText: this.translateSys("cancel")
-										});
+											} else if (attr.name == 'Layout') {
+												attr.setting.colList.forEach(col => {
+													if (col) {
+														if (col.fieldId == result[i].attr) {
+															col.value = '';
+															col.oldvalue = '';
+															col.value = result[i].value;
+															col.oldvalue = result[i].value;
+															$this.head_styledef.form.model[col
+																.fieldId] = result[i].value;
+														}
+													}
+												});
+											}
+
+										}
+										var length = 0;
+										if (!$this.$data.refdatastore.filter(function(s) {
+												return result[i].attr == s.attr
+											}).length) {
+											length = 1;
+											$this.$data.refdatastore.push(result[i]);
+										}
+										if (length == 0) {
+											for (var j = 0; j < $this.$data.refdatastore.length; j++) {
+												if ($this.$data.refdatastore[j].attr == result[i].attr) {
+													$this.$data.refdatastore[j].value = result[i].value;
+												}
+											}
+										}
 									}
+								} else if (action.action_type == 'set_dlg_attr_show') {
+									var result = action.value;
+									result.forEach(async (attr, key) => {
+										$this.$data.head_styledef.form.items.forEach(async (ele,
+											index) => {
+											//鍒ゆ柇鏄惁鏄爡鏍艰〃鍗�+											if (ele.name != 'Layout') {
+												if (ele.fieldId == attr.attr) {
+													ele.show = attr.show;
+												}
+											} else if (ele.name == 'Layout') {
+												ele.setting.colList.forEach(col => {
+													if (col) {
+														if (col.fieldId == attr
+															.attr) {
+															col.show = attr
+																.show;
+														}
+													}
+												});
+											}
+										});
+									});
+									var head_styledef = JSON.parse(JSON.stringify($this.$data.head_styledef));
+									$this.$data.head_styledef = [];
+									$this.$data.head_styledef = head_styledef;
+									// console.log($this.$data.head_styledef);
+								} else if (action.action_type == 'set_global_attr') {
+									$this.$data.global_attr = action.value || [];
 								}
+
 							}
+						}
 
-							if (data.result) {
-								var result = data.result;
-								for (var i = 0; i < result.length; i++) {
-									for (var c = 0; c < $this.$data.head_styledef.form.items.length; c++) {
-										var attr = $this.$data.head_styledef.form.items[c];
-										if (attr.name != 'Layout') {
-											if (attr.fieldId == result[i].attr) {
-												attr.value = '';
-												attr.oldvalue = '';
-												attr.value = result[i].value;
-												attr.oldvalue = result[i].value;
-												$this.head_styledef.form.model[attr.fieldId] = result[i].value;
-											}
-										} else if (attr.name == 'Layout') {
-											attr.setting.colList.forEach(col => {
-												if (col) {
-													if (col.fieldId == result[i].attr) {
-														col.value = '';
-														col.oldvalue = '';
-														col.value = result[i].value;
-														col.oldvalue = result[i].value;
-														$this.head_styledef.form.model[col.fieldId] =
-															result[i].value;
-													}
-												}
-											});
+						if (data.result) {
+							var result = data.result;
+							for (var i = 0; i < result.length; i++) {
+								for (var c = 0; c < $this.$data.head_styledef.form.items.length; c++) {
+									var attr = $this.$data.head_styledef.form.items[c];
+									if (attr.name != 'Layout') {
+										if (attr.fieldId == result[i].attr) {
+											attr.value = '';
+											attr.oldvalue = '';
+											attr.value = result[i].value;
+											attr.oldvalue = result[i].value;
+											$this.head_styledef.form.model[attr.fieldId] = result[i].value;
 										}
-
-									}
-
-									var length = 0;
-									if (!$this.$data.refdatastore.filter(function(s) {
-											return result[i].attr == s.attr
-										}).length) {
-										length = 1;
-										$this.$data.refdatastore.push(result[i]);
-									}
-									if (length == 0) {
-										for (var j = 0; j < $this.$data.refdatastore.length; j++) {
-											if ($this.$data.refdatastore[j].attr == result[i].attr) {
-												$this.$data.refdatastore[j].value = result[i].value;
+									} else if (attr.name == 'Layout') {
+										attr.setting.colList.forEach(col => {
+											if (col) {
+												if (col.fieldId == result[i].attr) {
+													col.value = '';
+													col.oldvalue = '';
+													col.value = result[i].value;
+													col.oldvalue = result[i].value;
+													$this.head_styledef.form.model[col.fieldId] =
+														result[i].value;
+												}
 											}
+										});
+									}
+
+								}
+
+								var length = 0;
+								if (!$this.$data.refdatastore.filter(function(s) {
+										return result[i].attr == s.attr
+									}).length) {
+									length = 1;
+									$this.$data.refdatastore.push(result[i]);
+								}
+								if (length == 0) {
+									for (var j = 0; j < $this.$data.refdatastore.length; j++) {
+										if ($this.$data.refdatastore[j].attr == result[i].attr) {
+											$this.$data.refdatastore[j].value = result[i].value;
 										}
 									}
 								}
 							}
 						}
-					} else {
-						uni.showModal({
-							title: this.translateSys("error") + "3",
-							content: success.err_msg,
-							showCancel: false,
-							confirmText: this.translateSys("cancel")
-						});
 					}
+
 				}).catch(ex => {
 					// console.log(ex);
 					uni.showModal({
@@ -1561,270 +1565,262 @@
 				};
 				console.log(dataInfo);
 				// return;
-				this.$store.dispatch('runCustomEvent', dataInfo).then(success => {
-					console.log(success);
-					if (success.err_code == 0) {
-						var data = success.result;
-						if (data.ret != 0) {
-							var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data
-								.err_info.join('<br/>') : '';
-							if (data.ret == 801) {
-								if (this.param.Only_Script_Error) {
-									let pos = tip.indexOf("锛�);
-									if (pos > -1) tip = tip.substring(pos + 1);
-								}
-								uni.showModal({
-									title: this.translateSys("tip"),
-									content: tip,
-									showCancel: false,
-									confirmText: this.translateSys("cancel")
-								});
-							} else uni.showModal({
-								title: this.translateSys("tip"),
-								content: tip + this.translateSys('comma') + this.translate('result') + this
-									.translateSys('colon') + data.ret,
-								showCancel: false,
-								confirmText: this.translateSys("cancel")
-							});
-							return false
-						} else {
-							var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join(
-								'<br/>') : '';
-							if (tip) uni.showModal({
+				runCustomEvent(dataInfo).then(data => {
+					console.log(data);
+
+					if (data.ret != 0) {
+						var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data
+							.err_info.join('<br/>') : '';
+						if (data.ret == 801) {
+							if (this.param.Only_Script_Error) {
+								let pos = tip.indexOf("锛�);
+								if (pos > -1) tip = tip.substring(pos + 1);
+							}
+							uni.showModal({
 								title: this.translateSys("tip"),
 								content: tip,
 								showCancel: false,
 								confirmText: this.translateSys("cancel")
 							});
+						} else uni.showModal({
+							title: this.translateSys("tip"),
+							content: tip + this.translateSys('comma') + this.translate('result') + this
+								.translateSys('colon') + data.ret,
+							showCancel: false,
+							confirmText: this.translateSys("cancel")
+						});
+						return false
+					} else {
+						var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join(
+							'<br/>') : '';
+						if (tip) uni.showModal({
+							title: this.translateSys("tip"),
+							content: tip,
+							showCancel: false,
+							confirmText: this.translateSys("cancel")
+						});
 
-							var actionlist = data.action;
-							if (actionlist) {
-								console.log(actionlist);
-								for (var ii = 0; ii < actionlist.length; ii++) {
-									var action = actionlist[ii];
-									if (action.action_type == 'set_dlg_attr') {
-										var result = action.value;
-										for (var i = 0; i < result.length; i++) {
-											if (result[i].choice_list) {
-												for (var s = 0; s < $this.$data.subPanelList.length; s++) {
-													for (var c = 0; c < $this.$data.subPanelList[s]
-														.subClassAttrList.length; c++) {
-														var attr = $this.$data.subPanelList[s].subClassAttrList[c]
-															.Attr;
-														for (var j = 0; j < attr.length; j++) {
-															if (attr[j].Name == result[i].attr) {
-																if (utils.classUtils.attrTypeIsDict(attr[j]
-																		.Type)) {
-																	var dictItemList = [];
-																	for (var d in result[i].choice_list) {
-																		var val = result[i].choice_list[d];
-																		dictItemList.push({
-																			"CN_S_NAME": val,
-																			"CN_S_VALUE": val,
-																			"Name": val,
-																			"label": val,
-																			"value": val
-																		});
-																	}
-																	attr[j].dictitem = dictItemList;
-																	// attr[j].dictitem = result[i].choice_list;
+						var actionlist = data.action;
+						if (actionlist) {
+							console.log(actionlist);
+							for (var ii = 0; ii < actionlist.length; ii++) {
+								var action = actionlist[ii];
+								if (action.action_type == 'set_dlg_attr') {
+									var result = action.value;
+									for (var i = 0; i < result.length; i++) {
+										if (result[i].choice_list) {
+											for (var s = 0; s < $this.$data.subPanelList.length; s++) {
+												for (var c = 0; c < $this.$data.subPanelList[s]
+													.subClassAttrList.length; c++) {
+													var attr = $this.$data.subPanelList[s].subClassAttrList[c]
+														.Attr;
+													for (var j = 0; j < attr.length; j++) {
+														if (attr[j].Name == result[i].attr) {
+															if (utils.classUtils.attrTypeIsDict(attr[j]
+																	.Type)) {
+																var dictItemList = [];
+																for (var d in result[i].choice_list) {
+																	var val = result[i].choice_list[d];
+																	dictItemList.push({
+																		"CN_S_NAME": val,
+																		"CN_S_VALUE": val,
+																		"Name": val,
+																		"label": val,
+																		"value": val
+																	});
 																}
+																attr[j].dictitem = dictItemList;
+																// attr[j].dictitem = result[i].choice_list;
 															}
 														}
 													}
 												}
 											}
-											for (var s = 0; s < $this.$data.subPanelList.length; s++) {
-												for (var c = 0; c < $this.$data.subPanelList[s].subClassAttrList
-													.length; c++) {
-													var attr = $this.$data.subPanelList[s].subClassAttrList[c]
-														.Attr;
-													for (var j = 0; j < attr.length; j++) {
-														console.log(attr[j].Name + '==' + result[i].attr);
-														if (attr[j].Name == result[i].attr) {
-															attr[j].Value = result[i].value;
-															// attr.value = '';
-															// attr.oldvalue = '';
-															// attr.value = result[i].value;
-															// attr.oldvalue = result[i].value;
-														}
-													}
-												}
-											}
-											var length = 0;
-											if (!$this.$data.refdatastore.filter(function(s) {
-													return result[i].attr == s.attr
-												}).length) {
-												length = 1;
-												$this.$data.refdatastore.push(result[i]);
-											}
-											if (length == 0) {
-												for (var j = 0; j < $this.$data.refdatastore.length; j++) {
-													if ($this.$data.refdatastore[j].attr == result[i].attr) {
-														$this.$data.refdatastore[j].value = result[i].value;
+										}
+										for (var s = 0; s < $this.$data.subPanelList.length; s++) {
+											for (var c = 0; c < $this.$data.subPanelList[s].subClassAttrList
+												.length; c++) {
+												var attr = $this.$data.subPanelList[s].subClassAttrList[c]
+													.Attr;
+												for (var j = 0; j < attr.length; j++) {
+													console.log(attr[j].Name + '==' + result[i].attr);
+													if (attr[j].Name == result[i].attr) {
+														attr[j].Value = result[i].value;
+														// attr.value = '';
+														// attr.oldvalue = '';
+														// attr.value = result[i].value;
+														// attr.oldvalue = result[i].value;
 													}
 												}
 											}
 										}
-									} else if (action.action_type == 'set_global_attr') {
-										$this.$actiontr = action.value || [];
-									} else if (action.action_type == 'open_common_dlg') { //鎵撳紑渚ф粦寮规
-										var $this = this;
-										if (action.value.common_dlg_id == 'check_list') {
-											$this.$data.check_list = action.value.config;
-											if (action.value.config.appear_style == 'sideslip') //鍒ゆ柇鏄惁鏄晶婊�-												$this.$data.popupType = 'right';
-											else
-												$this.$data.popupType = 'center'
-											// open 鏂规硶浼犲叆鍙傛暟 绛夊悓鍦�uni-popup 缁勪欢涓婄粦瀹�type灞炴�
-											$this.$refs.popup.open($this.$data.popupType);
+										var length = 0;
+										if (!$this.$data.refdatastore.filter(function(s) {
+												return result[i].attr == s.attr
+											}).length) {
+											length = 1;
+											$this.$data.refdatastore.push(result[i]);
 										}
-									} else if (action.action_type == 'add_subcls_panel') { //涓讳粠鏁版嵁绫绘壂鐮佹煡璇㈡暟鎹�-										var result = action.value;
-										var $this = this;
-										var list_1 = JSON.parse(JSON.stringify(this.$data.detail1_styledef));
-										var scanCodeVal = $this.$data.scanCodeVal;
-										var rand = '';
-										for (var i = 0; i < 5; i++) { //鐢熸垚5浣嶉殢鏈烘暟
-											rand += Math.floor(Math.random() * 10);
-										}
-										if (inputParamter[0].attr) {
-											if (inputParamter[0].attr == "mast_input_3037") //鍒ゆ柇鏄富鏁版嵁绫绘壂鐮佹煡璇㈡暟鎹�-												scanCodeVal = "mast_input_3037-" + rand;
-										}
-										if (info.attr[0].attr) {
-											if (info.attr[0].attr == "mast_input_3037") //鍒ゆ柇鏄富鏁版嵁绫绘壂鐮佹煡璇㈡暟鎹�-												scanCodeVal = "mast_input_3037-" + rand;
-										}
-										$this.$data.subPanelList.push({
-											scanCodeVal: scanCodeVal,
-											subClassAttr: list_1
-										});
-										$this.activelist.push({
-											active: false
-										});
-										for (var i = 0; i < result.length; i++) {
-											for (var s = 0; s < $this.$data.subPanelList.length; s++) {
-												if ($this.$data.subPanelList[s].scanCodeVal == scanCodeVal) {
-													if (result[i].attr == "S_ID")
-														$this.$data.subPanelList[s].ObjID = result[i].value;
-													var _subClassAttr = $this.$data.subPanelList[s].subClassAttr
-														.form.items;
-													for (var c = 0; c < _subClassAttr.length; c++) {
-														if (_subClassAttr[c].name != 'Layout') {
-															if (_subClassAttr[c].fieldId == result[i].attr)
-																_subClassAttr[c].value = result[i].value;
-														} else if (_subClassAttr[c].name == 'Layout') {
-															_subClassAttr[c].setting.colList.forEach(col => {
-																if (col) {
-																	if (col.fieldId == result[i].attr)
-																		col.value = result[i].value;
-																}
-															});
-														}
-													}
-
-													// $this.$data.subPanelList[s].subClassAttr=list_1;
-												}
-											}
-											// console.log($this.$data.subPanelList);
-											var length = 0;
-											if (!$this.$data.refdatastore.filter(function(s) {
-													return result[i].attr == s.attr
-												}).length) {
-												length = 1;
-												$this.$data.refdatastore.push(result[i]);
-											}
-											if (length == 0) {
-												for (var j = 0; j < $this.$data.refdatastore.length; j++) {
-													if ($this.$data.refdatastore[j].attr == result[i].attr) {
-														$this.$data.refdatastore[j].value = result[i].value;
-													}
+										if (length == 0) {
+											for (var j = 0; j < $this.$data.refdatastore.length; j++) {
+												if ($this.$data.refdatastore[j].attr == result[i].attr) {
+													$this.$data.refdatastore[j].value = result[i].value;
 												}
 											}
 										}
-									} else {
-										uni.showModal({
-											title: this.translateSys("tip"),
-											content: this.translateSys("quotation_mark_left") + action
-												.action_type + this.translateSys(
-													"quotation_mark_right") + this.translate(
-													"tip_action_unprocessed"),
-											showCancel: false,
-											confirmText: this.translateSys("cancel")
-										});
 									}
+								} else if (action.action_type == 'set_global_attr') {
+									$this.$actiontr = action.value || [];
+								} else if (action.action_type == 'open_common_dlg') { //鎵撳紑渚ф粦寮规
+									var $this = this;
+									if (action.value.common_dlg_id == 'check_list') {
+										$this.$data.check_list = action.value.config;
+										if (action.value.config.appear_style == 'sideslip') //鍒ゆ柇鏄惁鏄晶婊�+											$this.$data.popupType = 'right';
+										else
+											$this.$data.popupType = 'center'
+										// open 鏂规硶浼犲叆鍙傛暟 绛夊悓鍦�uni-popup 缁勪欢涓婄粦瀹�type灞炴�
+										$this.$refs.popup.open($this.$data.popupType);
+									}
+								} else if (action.action_type == 'add_subcls_panel') { //涓讳粠鏁版嵁绫绘壂鐮佹煡璇㈡暟鎹�+									var result = action.value;
+									var $this = this;
+									var list_1 = JSON.parse(JSON.stringify(this.$data.detail1_styledef));
+									var scanCodeVal = $this.$data.scanCodeVal;
+									var rand = '';
+									for (var i = 0; i < 5; i++) { //鐢熸垚5浣嶉殢鏈烘暟
+										rand += Math.floor(Math.random() * 10);
+									}
+									if (inputParamter[0].attr) {
+										if (inputParamter[0].attr == "mast_input_3037") //鍒ゆ柇鏄富鏁版嵁绫绘壂鐮佹煡璇㈡暟鎹�+											scanCodeVal = "mast_input_3037-" + rand;
+									}
+									if (info.attr[0].attr) {
+										if (info.attr[0].attr == "mast_input_3037") //鍒ゆ柇鏄富鏁版嵁绫绘壂鐮佹煡璇㈡暟鎹�+											scanCodeVal = "mast_input_3037-" + rand;
+									}
+									$this.$data.subPanelList.push({
+										scanCodeVal: scanCodeVal,
+										subClassAttr: list_1
+									});
+									$this.activelist.push({
+										active: false
+									});
+									for (var i = 0; i < result.length; i++) {
+										for (var s = 0; s < $this.$data.subPanelList.length; s++) {
+											if ($this.$data.subPanelList[s].scanCodeVal == scanCodeVal) {
+												if (result[i].attr == "S_ID")
+													$this.$data.subPanelList[s].ObjID = result[i].value;
+												var _subClassAttr = $this.$data.subPanelList[s].subClassAttr
+													.form.items;
+												for (var c = 0; c < _subClassAttr.length; c++) {
+													if (_subClassAttr[c].name != 'Layout') {
+														if (_subClassAttr[c].fieldId == result[i].attr)
+															_subClassAttr[c].value = result[i].value;
+													} else if (_subClassAttr[c].name == 'Layout') {
+														_subClassAttr[c].setting.colList.forEach(col => {
+															if (col) {
+																if (col.fieldId == result[i].attr)
+																	col.value = result[i].value;
+															}
+														});
+													}
+												}
+
+												// $this.$data.subPanelList[s].subClassAttr=list_1;
+											}
+										}
+										// console.log($this.$data.subPanelList);
+										var length = 0;
+										if (!$this.$data.refdatastore.filter(function(s) {
+												return result[i].attr == s.attr
+											}).length) {
+											length = 1;
+											$this.$data.refdatastore.push(result[i]);
+										}
+										if (length == 0) {
+											for (var j = 0; j < $this.$data.refdatastore.length; j++) {
+												if ($this.$data.refdatastore[j].attr == result[i].attr) {
+													$this.$data.refdatastore[j].value = result[i].value;
+												}
+											}
+										}
+									}
+								} else {
+									uni.showModal({
+										title: this.translateSys("tip"),
+										content: this.translateSys("quotation_mark_left") + action
+											.action_type + this.translateSys(
+												"quotation_mark_right") + this.translate(
+												"tip_action_unprocessed"),
+										showCancel: false,
+										confirmText: this.translateSys("cancel")
+									});
 								}
 							}
+						}
 
-							if (data.result) {
-								var list_1 = JSON.parse(JSON.stringify(this.$data.detail1_styledef));
-								var scanCodeVal = $this.$data.scanCodeVal;
-								var rand = '';
-								for (var i = 0; i < 5; i++) { //鐢熸垚5浣嶉殢鏈烘暟
-									rand += Math.floor(Math.random() * 10);
-								}
-								if (inputParamter[0].attr) {
-									if (inputParamter[0].attr == "mast_input_3037") //鍒ゆ柇鏄富鏁版嵁绫绘壂鐮佹煡璇㈡暟鎹�-										scanCodeVal = "mast_input_3037-" + rand;
-								}
-								if (info.attr[0].attr) {
-									if (info.attr[0].attr == "mast_input_3037") //鍒ゆ柇鏄富鏁版嵁绫绘壂鐮佹煡璇㈡暟鎹�-										scanCodeVal = "mast_input_3037-" + rand;
-								}
-								$this.$data.subPanelList.push({
-									scanCodeVal: scanCodeVal,
-									subClassAttr: list_1
-								});
-								var result = data.result;
-								for (var i = 0; i < result.length; i++) {
-									for (var s = 0; s < $this.$data.subPanelList.length; s++) {
-										if ($this.$data.subPanelList[s].scanCodeVal == scanCodeVal) {
-											if (result[i].attr == "S_ID")
-												$this.$data.subPanelList[s].ObjID = result[i].value;
-											var _subClassAttr = $this.$data.subPanelList[s].subClassAttr.form
-												.items;
-											for (var c = 0; c < _subClassAttr.length; c++) {
-												if (_subClassAttr[c].name != 'Layout') {
-													if (_subClassAttr[c].fieldId == result[i].attr)
-														_subClassAttr[c].value = result[i].value;
-												} else if (_subClassAttr[c].name == 'Layout') {
-													_subClassAttr[c].setting.colList.forEach(col => {
-														if (col) {
-															if (col.fieldId == result[i].attr)
-																col.value = result[i].value;
-														}
-													});
-												}
+						if (data.result) {
+							var list_1 = JSON.parse(JSON.stringify(this.$data.detail1_styledef));
+							var scanCodeVal = $this.$data.scanCodeVal;
+							var rand = '';
+							for (var i = 0; i < 5; i++) { //鐢熸垚5浣嶉殢鏈烘暟
+								rand += Math.floor(Math.random() * 10);
+							}
+							if (inputParamter[0].attr) {
+								if (inputParamter[0].attr == "mast_input_3037") //鍒ゆ柇鏄富鏁版嵁绫绘壂鐮佹煡璇㈡暟鎹�+									scanCodeVal = "mast_input_3037-" + rand;
+							}
+							if (info.attr[0].attr) {
+								if (info.attr[0].attr == "mast_input_3037") //鍒ゆ柇鏄富鏁版嵁绫绘壂鐮佹煡璇㈡暟鎹�+									scanCodeVal = "mast_input_3037-" + rand;
+							}
+							$this.$data.subPanelList.push({
+								scanCodeVal: scanCodeVal,
+								subClassAttr: list_1
+							});
+							var result = data.result;
+							for (var i = 0; i < result.length; i++) {
+								for (var s = 0; s < $this.$data.subPanelList.length; s++) {
+									if ($this.$data.subPanelList[s].scanCodeVal == scanCodeVal) {
+										if (result[i].attr == "S_ID")
+											$this.$data.subPanelList[s].ObjID = result[i].value;
+										var _subClassAttr = $this.$data.subPanelList[s].subClassAttr.form
+											.items;
+										for (var c = 0; c < _subClassAttr.length; c++) {
+											if (_subClassAttr[c].name != 'Layout') {
+												if (_subClassAttr[c].fieldId == result[i].attr)
+													_subClassAttr[c].value = result[i].value;
+											} else if (_subClassAttr[c].name == 'Layout') {
+												_subClassAttr[c].setting.colList.forEach(col => {
+													if (col) {
+														if (col.fieldId == result[i].attr)
+															col.value = result[i].value;
+													}
+												});
 											}
 										}
 									}
+								}
 
-									var length = 0;
-									if (!$this.$data.refdatastore.filter(function(s) {
-											return result[i].attr == s.attr
-										}).length) {
-										length = 1;
-										$this.$data.refdatastore.push(result[i]);
-									}
-									if (length == 0) {
-										for (var j = 0; j < $this.$data.refdatastore.length; j++) {
-											if ($this.$data.refdatastore[j].attr == result[i].attr) {
-												$this.$data.refdatastore[j].value = result[i].value;
-											}
+								var length = 0;
+								if (!$this.$data.refdatastore.filter(function(s) {
+										return result[i].attr == s.attr
+									}).length) {
+									length = 1;
+									$this.$data.refdatastore.push(result[i]);
+								}
+								if (length == 0) {
+									for (var j = 0; j < $this.$data.refdatastore.length; j++) {
+										if ($this.$data.refdatastore[j].attr == result[i].attr) {
+											$this.$data.refdatastore[j].value = result[i].value;
 										}
 									}
 								}
 							}
 						}
-					} else {
-						uni.showModal({
-							title: this.translateSys("error") + "7",
-							content: success.err_msg,
-							showCancel: false,
-							confirmText: this.translateSys("cancel")
-						});
 					}
+
 				}).catch(ex => {
 					// console.log(ex);
 					uni.showModal({
@@ -1848,6 +1844,7 @@
 					}); //杩斿洖灞傛暟锛�鍒欎笂涓婇〉
 			},
 			scan_OKDataObjRunCustomEvent(eventID) {
+				this.saving = true
 				uni.showLoading({
 					title: this.translateSys("loading"),
 					mask: true
@@ -1921,63 +1918,57 @@
 				console.log(dataInfo);
 				// uni.hideLoading();
 				// 	return;
-				this.$store.dispatch('runCustomEvent', dataInfo).then(success => {
-					console.log(success);
+				runCustomEvent(dataInfo).then(data => {
+					console.log(data);
 					uni.hideLoading();
-					if (success.err_code == 0) {
-						var data = success.result;
-						if (data.ret != 0) {
-							var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data
-								.err_info.join('<br/>') : '';
-							if (data.ret == 801) {
-								if (this.param.Only_Script_Error) {
-									let pos = tip.indexOf("锛�);
-									if (pos > -1) tip = tip.substring(pos + 1);
-								}
-								uni.showModal({
-									title: this.translateSys("tip"),
-									content: tip,
-									showCancel: false,
-									confirmText: this.translateSys("cancel")
-								});
-							} else uni.showModal({
-								title: this.translateSys("tip"),
-								content: tip + ',' + this.translateSys('tip') + ':' + data.ret,
-								showCancel: false,
-								confirmText: this.translateSys("cancel")
-							});
-							return false
-						} else {
-							var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join(
-								'<br/>') : '';
-							if (tip) uni.showModal({
+					if (data.ret != 0) {
+						var tip = data.err_info ? typeof data.err_info == 'string' ? data.err_info : data
+							.err_info.join('<br/>') : '';
+						if (data.ret == 801) {
+							if (this.param.Only_Script_Error) {
+								let pos = tip.indexOf("锛�);
+								if (pos > -1) tip = tip.substring(pos + 1);
+							}
+							uni.showModal({
 								title: this.translateSys("tip"),
 								content: tip,
 								showCancel: false,
 								confirmText: this.translateSys("cancel")
 							});
-
-							var result = data.result;
-							if (eventID != $this.$data.param.After_OK_Event.ID)
-								$this.scan_OKDataObjRunCustomEvent($this.$data.param.After_OK_Event.ID);
-							else {
-								//鍒锋柊
-								uni.redirectTo({
-									url: '../modal/3037_2?param=' + JSON.stringify($this.$data.param) +
-										"&titlename=" + $this.$data.title
-								});
-							}
-						}
-					} else {
-						uni.showModal({
-							title: this.translateSys("error") + "8",
-							content: success.err_msg,
+						} else uni.showModal({
+							title: this.translateSys("tip"),
+							content: tip + ',' + this.translateSys('tip') + ':' + data.ret,
 							showCancel: false,
 							confirmText: this.translateSys("cancel")
 						});
+						this.saving = false
+						return false
+					} else {
+						var tip = data.info ? typeof data.info == 'string' ? data.info : data.info.join(
+							'<br/>') : '';
+						if (tip) uni.showModal({
+							title: this.translateSys("tip"),
+							content: tip,
+							showCancel: false,
+							confirmText: this.translateSys("cancel")
+						});
+
+						var result = data.result;
+						if (eventID != $this.$data.param.After_OK_Event.ID)
+							$this.scan_OKDataObjRunCustomEvent($this.$data.param.After_OK_Event.ID);
+						else {
+							//鍒锋柊
+							uni.redirectTo({
+								url: '../modal/3037_2?param=' + JSON.stringify($this.$data.param) +
+									"&titlename=" + $this.$data.title
+							});
+						}
 					}
+
+					this.saving = false
 				}).catch(ex => {
 					// console.log(ex);
+					this.saving = false
 					uni.hideLoading();
 					uni.showModal({
 						title: this.translateSys("error") + "8.1",
@@ -2278,6 +2269,11 @@
 			display: inline-block;
 		}
 
+		button.btn_disabled {
+			background-color: #ddd;
+			color: #888;
+		}
+
 		.class_attr_body .form-group {
 			margin: 20rpx 30rpx;
 			/* margin-left: -12px;

--
Gitblit v1.9.1