| | |
| | | } from '@/js/Base64.js'; |
| | | import { |
| | | showInfo, |
| | | showError |
| | | showError, |
| | | showLoading, |
| | | hideLoading |
| | | } from "@/js/Page.js" |
| | | import classUtils from "@/js/utils.js" |
| | | import { |
| | |
| | | this.beforeNavigateBack() |
| | | }, |
| | | async onLoad(options) { |
| | | try { |
| | | showLoading("loading...") |
| | | console.log(options); |
| | | uni.setNavigationBarTitle({ |
| | | title: options.titlename |
| | |
| | | } |
| | | if (this.enter_view_event.id) |
| | | this.enterAfterEvent(this.enter_view_event); |
| | | |
| | | hideLoading() |
| | | } catch (ex) { |
| | | hideLoading() |
| | | showError(ex, this.translateSys("error")); |
| | | } |
| | | }, |
| | | methods: { |
| | | // |
| | |
| | | //页面进入后事件 |
| | | async enterAfterEvent(event) { |
| | | try { |
| | | showLoading("loading...") |
| | | let data_json = []; |
| | | let jsonlist = []; |
| | | let detailStyleList = this.detail1StyleDefList; |
| | |
| | | } else input_param[item.fieldId] = item.value; |
| | | }); |
| | | input_param = Base64.encode(JSON.stringify(input_param)); |
| | | this.runCustomEvent({ |
| | | await this.runCustomEvent({ |
| | | ed_type: 0, |
| | | start_transaction: true, |
| | | class_id: this.param.ClsID, |
| | |
| | | input_param, |
| | | data_json, |
| | | }) |
| | | hideLoading() |
| | | |
| | | } catch (ex) { |
| | | hideLoading() |
| | | showError(ex, this.translateSys('tip')); |
| | | } |
| | | }, |
| | |
| | | |
| | | }, |
| | | async onTriggerEvent(btn, enviroment) { |
| | | try { |
| | | showLoading("loading...") |
| | | |
| | | let data_json = []; |
| | | let jsonlist = []; |
| | | |
| | |
| | | input_param, |
| | | data_json, |
| | | }); |
| | | hideLoading() |
| | | } catch (ex) { |
| | | hideLoading() |
| | | showError(ex, this.translateSys("error")); |
| | | } |
| | | }, |
| | | async navigateBackEvent() { |
| | | try { |
| | | var $this = this; |
| | | if (!this.exit_view_event.id) |
| | | return |
| | | showLoading("loading...") |
| | | let data_json = []; |
| | | let jsonlist = []; |
| | | let detailStyleList = this.detail1StyleDefList; |
| | |
| | | input_param, |
| | | data_json, |
| | | }) |
| | | hideLoading() |
| | | if (result.ret != 0 && result.ret != 1) { |
| | | let cls_name = result.event_info?.cls_name |
| | | let event_name = result.event_info?.event_name |
| | |
| | | } |
| | | |
| | | } catch (ex) { |
| | | hideLoading() |
| | | showError(ex, this.translateSys('error') + "9.2") |
| | | |
| | | } |
| | |
| | | delta: 1, //返回层数,2则上上页 |
| | | }); |
| | | }, |
| | | async beforeNavigateBack() |
| | | { |
| | | async beforeNavigateBack() { |
| | | await this.navigateBackEvent() |
| | | const eventChannel = this.getOpenerEventChannel(); |
| | | eventChannel.emit('ExitViewPage'); |