From 4889b8de1c676fa1c2298c6d54b433c271ecd0fb Mon Sep 17 00:00:00 2001 From: jt <jt@activesoft.com.cn> Date: 星期二, 09 四月 2024 15:20:48 +0800 Subject: [PATCH] 1.toWhereBase64String方法需要支持Orcale数据库,取消固定小写值查询改进 2.调用runCustomEvent时给了obj_attr数据就要给data_obj_id数据改进 --- pages/modal/3018_2.vue | 99 ++++++++++++++++++++++++++++++++++++++++--------- 1 files changed, 81 insertions(+), 18 deletions(-) diff --git a/pages/modal/3018_2.vue b/pages/modal/3018_2.vue index cffd284..19eaf40 100644 --- a/pages/modal/3018_2.vue +++ b/pages/modal/3018_2.vue @@ -670,7 +670,6 @@ }, ontap(item){ //鎵爜鍔熻兘 - //console.log(e.target) getApp().onScan((result)=>{ //console.log(result.decodedata); uni.hideKeyboard(); @@ -687,7 +686,7 @@ // $this.focusMateria=true; //绗簩涓緭鍏ユ鑾峰彇鐒︾偣 setTimeout(function(){ uni.hideKeyboard(); - },100); + },1000); // },500); } var eventid = item.bind.onChangeEvent.id; //鍐呭鍙樺寲鍚庝簨浠�@@ -722,6 +721,7 @@ console.log(item); if(item.oldvalue != item.value){ item.oldvalue = item.value; + item.value = item.value; var attr = item.fieldId; $this.head_styledef.form.model[attr] = item.value; //瀛愭暟鎹被鎵爜鍖轰簨浠惰剼鏈�@@ -916,7 +916,7 @@ if(!info.eventid.includes('{')) info.eventid = '{'+info.eventid+'}'; var dataInfo={ ed_type: info.edtype, - start_transaction: '', + start_transaction: true, class_id: info.clsid, class_name: '', event_id: info.eventid, @@ -959,24 +959,61 @@ 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.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; + 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); - if(attr.fieldId==result[i].attr){ - attr.value = result[i].value; - $this.head_styledef.form.model[attr.fieldId] =result[i].value; + //鍒ゆ柇琛ㄥ崟閲屾槸鍚︽湁杩斿洖瀛楁锛屾病鏈夊氨瑁呰浇鍒癿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; + } + } 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) { @@ -998,15 +1035,41 @@ } } } + // var head_styledef = JSON.parse(JSON.stringify($this.head_styledef)); + // $this.head_styledef=[]; + // $this.head_styledef = head_styledef; + console.log($this.head_styledef); 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.fieldId==result[i].attr){ - attr.value = result[i].value; - $this.head_styledef.form.model[attr.fieldId] =result[i].value; + //鍒ゆ柇琛ㄥ崟閲屾槸鍚︽湁杩斿洖瀛楁锛屾病鏈夊氨瑁呰浇鍒癿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; + } + } 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; + } + } + }); } } @@ -1081,7 +1144,7 @@ if(!eventid.includes('{')) eventid= '{'+ eventid +'}'; var dataInfo={ ed_type: "0", - start_transaction: '', + start_transaction: true, class_id: this.$data.param.DataCls.id, class_name: '', event_id: eventid, -- Gitblit v1.9.1