Event.js 4.7 KB
Newer Older
cl committed
1 2 3 4
import Api from "~/service/Api"
import Utils from "~/utils"

export default {
5 6 7
    onSeainf() {

    },
nanrui committed
8 9 10 11 12 13 14 15 16 17 18
    async handleSearch() {
        let colflg = this.model.cldgrp.rec.colflg;
        if (!colflg || colflg == '') {
            this.$notify.error({ title: '错误', message: 'Payemnt Disposition必输!' });
            return;
        }
        let cur = this.model.cur;
        if (!cur || cur == '') {
            this.$notify.error({ title: '错误', message: 'cur必输!' });
            return;
        }
19
        this.model.bptbck.bptbckg = [];
nanrui committed
20 21
        let rtnmsg = await this.executeRule("butsea")
        if (rtnmsg.respCode == SUCCESS) {
22
            this.updateModel(rtnmsg.data);
23
            console.log(rtnmsg.data.ccdbatg)
nanrui committed
24
            //TODO 处理数据逻辑
25
            this.model.bptbck.bptbckg = rtnmsg.data.ccdbatg;
26
            this.$refs.table.$refs.urls.$refs.table.toggleAllSelection();
nanrui committed
27 28 29 30 31
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
32
    async handleSearchAll() {
33
        let rtnmsg = await this.executeRule("search")
34 35 36 37
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 列表显示数据
            this.model.bptbck.bptbckg = rtnmsg.data.ccdbatg;
        }
38 39 40
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
41
    },
42 43 44 45
    async onCltpButgetref() {
        let rtnmsg = await this.executeRule("cltp.butgetref")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
46
            this.model.cldgrp.rec.ownref = rtnmsg.data.cldgrp_rec_ownref;
47 48 49 50 51 52 53 54 55
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
    async onGet() {
        let rtnmsg = await this.executeRule("get")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
cl committed
56

57 58 59 60 61 62 63 64 65
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
    async onColpDet() {
        let rtnmsg = await this.executeRule("colp.det")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
cl committed
66

67 68 69 70 71 72 73 74 75
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
    async onTrndocButshw() {
        let rtnmsg = await this.executeRule("trndoc.butshw")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
cl committed
76

77 78 79 80 81 82 83 84 85
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
    async onTrndocButadd() {
        let rtnmsg = await this.executeRule("trndoc.butadd")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
cl committed
86

87 88 89 90 91 92 93 94 95
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
    async onTrndocButnew() {
        let rtnmsg = await this.executeRule("trndoc.butnew")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
cl committed
96

97 98 99 100 101 102 103 104 105
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
    async onTrndocButattto() {
        let rtnmsg = await this.executeRule("trndoc.butattto")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
cl committed
106

107 108 109 110 111 112 113 114 115
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
    async onTrndocButdel() {
        let rtnmsg = await this.executeRule("trndoc.butdel")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
cl committed
116

117 118 119 120 121 122 123 124 125
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
    async onTrndocButatt() {
        let rtnmsg = await this.executeRule("trndoc.butatt")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
cl committed
126

127 128 129 130 131 132 133 134 135
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
    async onSetmodDet() {
        let rtnmsg = await this.executeRule("setmod.det")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
cl committed
136

137 138 139 140 141 142 143 144 145
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
    async onSetinsButtxmsel() {
        let rtnmsg = await this.executeRule("setins.buttxmsel")
        if (rtnmsg.respCode == SUCCESS) {
            //TODO 处理数据逻辑
146
            this.showGridPromptDialog(cldgrp.blk.setins);
cl committed
147

148 149 150 151 152
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    },
cl committed
153 154

}