From e92aeae89a7430b326ab2157ed5004cc5c87d659 Mon Sep 17 00:00:00 2001
From: cuiqian2004 <cuiqian2004@163.com>
Date: 星期五, 28 十一月 2025 18:21:56 +0800
Subject: [PATCH] 75
---
pages/modal/3202.vue | 79 ++++++++++++++++++++++++++-------------
1 files changed, 53 insertions(+), 26 deletions(-)
diff --git a/pages/modal/3202.vue b/pages/modal/3202.vue
index 7860655..44ef81f 100644
--- a/pages/modal/3202.vue
+++ b/pages/modal/3202.vue
@@ -40,7 +40,9 @@
import classUtils from "@/js/utils.js"
import {
showInfo,
- showError
+ showError,
+ showLoading,
+ hideLoading
} from "@/js/Page.js"
import {
appGetInfo,
@@ -116,29 +118,36 @@
},
async onLoad(options) {
- // console.log(options);
- uni.setNavigationBarTitle({
- title: options.titlename
- }); //璁剧疆椤堕儴鏍囬
- this.title = options.titlename;
- this.param = JSON.parse(options.param);
- const paramValue = options.paramValue ? JSON.parse(options.paramValue) : undefined
- this.styledef = {};
- this.head_styledef = {
- form: {
- items: []
- }
- };
- this.detail1_styledef = {};
- this.detail1StyleDefList = [];
- this.items = [];
- this.active_id = '';
- this.activeItem = {};
- this.click_item_view = false
- if (this.param?.ClickItem_Event?.id)
- this.click_item_view = true
- await this.Detail1_UIstyleGetInfo(this.param.ClsID, this.param.ListItem_Panel.id);
- this.initial(paramValue)
+ try {
+ showLoading("loading...")
+ // console.log(options);
+ uni.setNavigationBarTitle({
+ title: options.titlename
+ }); //璁剧疆椤堕儴鏍囬
+ this.title = options.titlename;
+ this.param = JSON.parse(options.param);
+ const paramValue = options.paramValue ? JSON.parse(options.paramValue) : undefined
+ this.styledef = {};
+ this.head_styledef = {
+ form: {
+ items: []
+ }
+ };
+ this.detail1_styledef = {};
+ this.detail1StyleDefList = [];
+ this.items = [];
+ this.active_id = '';
+ this.activeItem = {};
+ this.click_item_view = false
+ if (this.param?.ClickItem_Event?.id)
+ this.click_item_view = true
+ await this.Detail1_UIstyleGetInfo(this.param.ClsID, this.param.ListItem_Panel.id);
+ this.initial(paramValue)
+ hideLoading()
+ } catch (ex) {
+ hideLoading()
+ showError(ex, this.translateSys("error"));
+ }
},
methods: {
@@ -218,6 +227,7 @@
};
runCustomEvent(dataInfo).then(result => {
console.log(result);
+
if (result.ret != 0 && result.ret != 1) {
let cls_name = result.event_info?.cls_name
let event_name = result.event_info?.event_name
@@ -584,10 +594,19 @@
this.initial()
},
//鐐瑰嚮鏄剧ず娴忚瀵硅薄鏄剧ず椤甸潰
- async onViewPageClick(style) {
+ onViewPageClick(style) {
+ this.handleButtonClick((done) => {
+ this.viewPageClick(style);
+ setTimeout(() => {
+ done(); // 閲嶇疆鐘舵�
+ }, 1000);
+ });
+ },
+ async viewPageClick(style) {
if (!this.clickItemEvent.id) {
return;
}
+ showLoading("loading...")
const $this = this
var obj_attr = this.head_styledef.form.model;
@@ -628,6 +647,7 @@
data_json,
}).then(result => {
// console.log(result);
+ hideLoading()
if (result.ret != 0 && result.ret != 1) {
let cls_name = result.event_info?.cls_name
let event_name = result.event_info?.event_name
@@ -693,6 +713,7 @@
}).catch(ex => {
// console.log(ex);
+ hideLoading()
showError(ex, this.translateSys("error") + "8.1")
});
},
@@ -746,7 +767,7 @@
//鎵ц瑙﹀彂浜嬩欢
async triggerEvent(btn, style, enviroment) {
const $this = this
-
+ showLoading("loading...")
var obj_attr = this.head_styledef.form.model;
// console.log(obj_attr);
var input_param = Base64.encode(
@@ -784,6 +805,7 @@
input_param,
data_json,
}).then(result => {
+ hideLoading()
// console.log(result);
if (result.ret != 0 && result.ret != 1) {
let cls_name = result.event_info?.cls_name
@@ -855,6 +877,7 @@
}).catch(ex => {
// console.log(ex);
+ hideLoading()
showError(ex, this.translateSys("error") + "8.1")
});
},
@@ -1017,6 +1040,7 @@
async onChange(event) {
try {
if (event.id) {
+ showLoading("loading...")
var obj_attr = this.head_styledef.form.model;
console.log(obj_attr);
var input_param = Base64.encode(
@@ -1049,6 +1073,7 @@
};
runCustomEvent(dataInfo).then(result => {
console.log(result);
+ hideLoading()
if (result.ret != 0 && result.ret != 1) {
let cls_name = result.event_info?.cls_name
let event_name = result.event_info?.event_name
@@ -1143,10 +1168,12 @@
}).catch(ex => {
// console.log(ex);
+ hideLoading()
showError(ex, this.translateSys("error") + "8.1")
});
}
} catch (ex) {
+ hideLoading()
showError(ex, this.translateSys('error') + "8.2")
}
--
Gitblit v1.9.1