cuiqian2004
2025-07-31 fe10cf437b17a2ea0ef63373cae2e5790ebc3930
pages/modal/3018.vue
@@ -1845,29 +1845,15 @@
                     .info
                     .join(
                        '<br/>') : '';
                  tip = tip || result.err_info
                  if (tip) uni.showModal({
                     title: this.translateSys('tip'),
                     content: tip,
                     showCancel: false,
                     confirmText: this.translateSys('close')
                  });
                  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;
                           this.setFormValues(action.value)
                        } else if (data.action[i].action_type == 'set_global_attr') {
                           $this.global_attr = data.action[i].value || [];
                        }
                     }
                  }
                  if (data.result_type == 2 && data.result) {
                     var result = data.result;
                  if (data.result_type == 2) {
                     var result = data.result || []
                     for (var i = 0; i < result.length; i++) {
                        for (var c = 0; c < $this.classAttrList.length; c++) {
                           var attr = $this.classAttrList[c].Attr;
@@ -1895,8 +1881,46 @@
                           }
                        }
                     }
                  } else if (typeof data.result == 'string') {
                     if (data.result) {
                     uni.showModal({
                        title: this.translateSys('tip'),
                        content: data.result,
                        showCancel: false,
                        confirmText: this.translateSys('close')
                     });
                  }
               }
                  try {
                     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;
                              this.setFormValues(action.value)
                           } else if (data.action[i].action_type == 'set_global_attr') {
                              $this.global_attr = data.action[i].value || [];
                           }
                        }
                     }
                  } catch (ex) {
                     let actionList = (data.action || []).map(a => a.action_type).join(';')
                     let tip = typeof ex == 'string' ? ex : ex.message
                     tip = `执行脚本返回的${actionList}时出现异常,请检查脚本返回的数据格式是否正确。${tip}`
                     uni.showModal({
                        title: this.translateSys('tip'),
                        content: tip,
                        showCancel: false,
                        confirmText: this.translateSys('close')
                     });
                     console.log(ex)
                     return
                  }
               }
            }).catch(ex => {
               let exStr = JSON.stringify(ex)