InftrnpsDetail.vue 26.9 KB
Newer Older
liuxin committed
1 2
<template>
    <c-page title="">
liushikai committed
3 4
        <!-- <div class="eContainer"> -->
            <c-content :height="120">
liushikai committed
5
            <div class="eibs-tab">
潘际乾 committed
6
                <!-- <c-col :span="24">
liuxin committed
7 8 9
                    <div style="float:right;margin-bottom:10px">
                        <el-button size="small">交易快照</el-button>
                        <el-button size="small">智能提示</el-button>
liuxin committed
10
                        <el-button size="small" @click="exit">返回</el-button>
liuxin committed
11
                    </div>
liuxin committed
12
                </c-col> -->
liuxin committed
13
                                       
liuxin committed
14 15 16 17 18
                <!-- <c-col :span="12">
                    <el-form-item label="Drag  Drop Sender">
                        <c-input  v-model="model.recpan.recget.sdamod.dadsnd"  placeholder="请输入Drag  Drop Sender"></c-input>
                    </el-form-item>
                </c-col>              -->
19
                
20 21 22 23 24 25 26 27 28
                <el-form
                    :model="model"
                    ref="modelForm"
                    tokenKey="modelForm"
                    :validate-on-rule-change="false"
                    label-width="150px"
                    size="small"
                    >
                    <c-content>
潘际乾 committed
29
                        <!-- <c-col :span="24" style="margin:0 0 5px 0"> -->
liushikai committed
30
                            <c-col :span="12" style="height:24px;">
liuxin committed
31 32 33
                                <el-form-item label="基本信息" class="messageLabel">
                                </el-form-item>
                            </c-col>
34
                            <c-col :span="11" style="text-align:right;">
35
                                <c-button size="small" type="primary" style="margin-left:0" @click="display(model.trn.inr)">交易快照</c-button>
liuxin committed
36 37 38
                                <c-button size="small" type="primary" style="margin-left:0">智能提示</c-button>
                                <c-button size="small" @click="exit" type="primary" style="margin-left:0">返回</c-button>
                            </c-col>
liushikai committed
39
                        <!-- </c-col> -->
潘际乾 committed
40
                        <c-col :span="24" style="height: 10px;margin-bottom:10px">
liuxin committed
41 42
                            <el-divider></el-divider>
                        </c-col>
liuxin committed
43
                        
liuxin committed
44

liuxin committed
45
                        <!-- -------------------基础信息------------------- -->
liuxin committed
46

47
                        <!-- ========================= Left ========================= -->
liuxin committed
48
                        <c-col :span="11"> 
49 50 51 52 53 54
                            <c-col :span="24">
                                <c-col :span="22">
                                    <el-form-item label="Reference">
                                        <c-input  v-model="model.trn.ownref" maxlength="16" disabled  placeholder="请输入Reference"></c-input>
                                    </el-form-item>
                                </c-col>             
liuxin committed
55
                                <c-col :span="2" style="text-align: right">
56
                                    <c-button
liushikai committed
57
                                        style="margin:0;padding: 0 14px;"
58 59 60 61 62 63
                                        size="small"
                                        type="primary"
                                    >
                                    <span style="font-size:15px;font-family:'宋体';font-weight:bold">i</span>
                                    </c-button>
                                </c-col>
liuxin committed
64
                            </c-col>
liuxin committed
65

66 67 68 69 70 71
                            <c-col :span="24">
                                <c-col :span="22">
                                    <el-form-item label="Transaction  ID">
                                        <c-input  v-model="model.recpan.atp.cod" maxlength="6" disabled placeholder="请输入Transaction  ID"></c-input>
                                    </el-form-item>
                                </c-col> 
liuxin committed
72
                                <c-col :span="2" style="text-align: right">
73
                                    <c-button
liushikai committed
74
                                        style="margin:0;padding: 0 14px;"
75 76 77 78 79 80
                                        size="small"
                                        type="primary"
                                    >
                                    <span style="font-size:15px;font-family:'宋体';font-weight:bold">i</span>
                                    </c-button>
                                </c-col>
81
                            </c-col>
liuxin committed
82

83
                            <c-col :span="24">
liushikai committed
84
                                <c-col :span="13">
85 86 87 88
                                    <el-form-item label="Relevant Amount">
                                        <c-input  v-model="model.trn.reloricur" maxlength="3" disabled  placeholder="请输入Relevant Amount"></c-input>
                                    </el-form-item>
                                </c-col>
liushikai committed
89 90
                                <c-col :span="11">
                                    <el-form-item  label="" label-width="8px">
91
                                        <c-input  v-model="model.trn.reloriamt" disabled placeholder="请输入Relevant Amount for Release in Original Currency"></c-input>
92
                                    </el-form-item>
93 94
                                </c-col> 
                            </c-col>      
liuxin committed
95

96
                            <c-col :span="24">
liushikai committed
97
                                <c-col :span="13">
98 99 100 101 102
                                    <el-form-item label="Responsible">
                                        <c-input  v-model="model.trn.usr" maxlength="8" disabled  placeholder="请输入Responsible"></c-input>
                                    </el-form-item>
                                </c-col>             
                                                            
liushikai committed
103 104
                                <c-col :span="11">
                                    <el-form-item label-width="40%" label="Group">
105 106 107 108 109 110 111 112 113
                                        <!-- <c-input  v-model="model.trn.usg" maxlength="6" disabled  placeholder="请输入Responsible Group"></c-input> -->
                                        <el-select v-model="model.trn.usg" style="width: 100%" disabled>
                                            <el-option
                                                v-for="item in codes.usgtxt"
                                                :key="item.value"
                                                :label="item.label"
                                                :value="item.value"
                                            />
                                        </el-select>
114 115
                                    </el-form-item>
                                </c-col>  
liuxin committed
116 117
                            </c-col>

118
                            <c-col :span="24">
liushikai committed
119
                                <c-col :span="24">
120 121 122 123 124
                                    <el-form-item label="Based on Ident No.">
                                        <c-input  v-model="model.trn.cortrninr" maxlength="8" disabled placeholder="请输入Based on Ident No."></c-input>
                                    </el-form-item>
                                </c-col>             
                                                            
liushikai committed
125 126
                                <c-col :span="24">
                                    <el-form-item label="Execution Date">
127 128 129 130
                                        <c-date-picker type="date"  v-model="model.trn.exedat" style="width:100%" disabled placeholder="请选择Execution Date"></c-date-picker>
                                    </el-form-item>
                                </c-col>
                            </c-col>
liuxin committed
131

liuxin committed
132 133 134 135 136 137 138 139
                            <c-col :span="24">
                                <c-col :span="22">
                                    <el-form-item label="Infotext">
                                        <c-input type="textarea" v-model="model.trn.inftxt" maxlength="65" :rows="3" show-word-limit placeholder="请输入Infotext" ></c-input>
                                    </el-form-item>
                                </c-col>
                                <c-col :span="2" style="text-align: right">
                                    <c-button
liushikai committed
140
                                        style="margin:0;padding: 0 12px;"
liuxin committed
141 142 143 144 145 146 147
                                        size="small"
                                        icon="el-icon-search"
                                        type="primary"
                                    ></c-button>
                                </c-col>
                            </c-col>

148 149 150
                        </c-col>

                        <!-- ========================= Right ========================= -->
liushikai committed
151
                        <c-col :span="11" :offset="1">
152
                            <c-col :span="24">
liushikai committed
153 154
                                    <c-col :span="22">
                                <el-form-item label="Ident No.">
155
                                        <c-input  v-model="model.trn.inr" disabled placeholder="请输入Ident No."></c-input>
liushikai committed
156
                                </el-form-item>
157
                                    </c-col>
liushikai committed
158
                                    <c-col :span="2" style="text-align: right">
159
                                        <c-button
liushikai committed
160
                                            style="margin:0;padding: 0 14px;"
161 162 163 164 165
                                            size="small"
                                            type="primary"
                                        >
                                        <span style="font-size:15px;font-family:'宋体';font-weight:bold">i</span>
                                        </c-button>
liuxin committed
166
                                    </c-col>
167
                            </c-col>
liuxin committed
168

169
                            <c-col :span="24">
liushikai committed
170
                                <el-form-item  label="Transaction  ID">
171
                                    <!-- <el-select v-model="model.recpan.atp.cod" style="width: 100%" disabled>
172 173 174 175 176 177
                                        <el-option
                                            v-for="item in codes.atptxt"
                                            :key="item.value"
                                            :label="item.label"
                                            :value="item.value"
                                        />
178 179
                                    </el-select> -->
                                    <c-input  v-model="this.atptxt" maxlength="6" disabled placeholder="请输入Transaction  ID"></c-input>
180
                                </el-form-item>
181 182 183
                            </c-col>

                            <c-col :span="24">
liushikai committed
184
                                <el-form-item  label="Drop Receiver">
185
                                    <c-input  v-model="model.trn.objnam" maxlength="40" disabled placeholder="请输入External Readable Object Identification"></c-input>
186
                                </el-form-item>
187 188 189
                            </c-col>

                            <c-col :span="24">
liushikai committed
190
                                <el-form-item  label="Release Status">
191 192 193 194 195 196 197 198 199 200
                                    <!-- <c-input v-model="model.trn.relflg" style="width:100%" disabled placeholder="请选择Release Status of Transaction">
                                    </c-input> -->
                                    <el-select v-model="model.trn.relflg" style="width: 100%" disabled>
                                        <el-option
                                            v-for="item in codes.relstaEN"
                                            :key="item.value"
                                            :label="item.label"
                                            :value="item.value"
                                        />
                                    </el-select>
201
                                </el-form-item>
202
                                
203 204
                            </c-col>

liushikai committed
205 206
                            <!-- <c-col :span="24">
                                <el-form-item  label="Signatures Required/Obtained">
207 208
                                <c-row>
                                    <c-col :span="11">
209
                                        <c-input  v-model="model.trn.relreq" maxlength="3" disabled placeholder="请输入Signatures Required/Obtained"></c-input>
210 211 212 213 214
                                    </c-col>
                                    <c-col :span="2">
                                        <span style="margin-left:40%">/</span>
                                    </c-col>
                                    <c-col :span="11">
215
                                        <c-input  v-model="model.trn.relres" maxlength="3" disabled placeholder="请输入Applied Signatures"></c-input>
216 217 218 219
                                    </c-col>
                                </c-row>
                                </el-form-item>
                            </c-col>
liuxin committed
220

221
                            <c-col :span="24">
liushikai committed
222
                                <el-form-item  label="Completion text">
223 224
                                    <c-input style="font-weight:bold"  v-model="model.recpan.cpltxt" disabled  placeholder="请输入Based on Ident No."></c-input>
                                </el-form-item>
liushikai committed
225
                            </c-col> -->
liuxin committed
226
                            <c-col :span="24">
liushikai committed
227
                                <c-col :span="24">
liuxin committed
228 229 230 231 232
                                    <el-form-item label="Entered by">
                                        <c-input  v-model="model.recpan.cretrs.usr" maxlength="8" disabled placeholder="请输入Entered by"></c-input>
                                    </el-form-item>
                                </c-col>             
                                                            
liushikai committed
233 234
                                <c-col :span="24">
                                    <el-form-item label="Timestamp">
liuxin committed
235 236 237 238
                                        <c-input  v-model="model.recpan.cretrs.dattim" disabled placeholder="请输入Timestamp"></c-input>
                                    </el-form-item>
                                </c-col>  
                            </c-col>
liuxin committed
239

liuxin committed
240
                            <c-col :span="24">
liushikai committed
241
                                <el-form-item  label="Infoflag">
liuxin committed
242 243 244 245 246 247 248 249 250 251 252 253
                                    <el-select v-model="model.trn.infdsp" style="width: 100%">
                                        <el-option
                                            v-for="item in codes.infdsp"
                                            :key="item.value"
                                            :label="item.label"
                                            :value="item.value"
                                        />
                                    </el-select>
                                </el-form-item>
                            </c-col>

                            <c-col :span="24">
liushikai committed
254
                                <el-form-item  label="Send for Repair to">
liuxin committed
255 256 257 258 259
                                    <c-input v-model="model.recpan.usr.extkey" disabled style="width:100%" placeholder="请选择extkey">
                                    </c-input>
                                </el-form-item>
                            </c-col>

260 261 262
                        </c-col>
                        
                        <!-- -------------------分割线------------------- -->
潘际乾 committed
263
                        <!-- <c-col :span="24">
264 265
                            <div style="border-bottom: 10px solid rgb(232, 232, 232);">
                            </div>
liuxin committed
266
                        </c-col> -->
潘际乾 committed
267
                        <!-- <c-col :span="24" style="height:25px">
268 269
                            <el-divider></el-divider>
                        </c-col> -->
liuxin committed
270 271

                        <!-- -------------------document------------------- -->
潘际乾 committed
272
                        <c-col :span="24" style="height:24px">
liushikai committed
273
                            <el-form-item label="面函/报文" class="messageLabel">
liuxin committed
274 275
                            </el-form-item>
                        </c-col>
潘际乾 committed
276
                        <c-col :span="24" style="height: 0px;margin-top:-5px">
liuxin committed
277 278
                            <el-divider></el-divider>
                        </c-col>
潘际乾 committed
279
                        <c-col :span="24">
280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295
                            <!-- <c-input  v-model="model.recpan.smhstm"  placeholder="请输入Documents"></c-input> -->
                            <c-istream-table :list="documentsData.data" :columns="documentsData.columns" :paginationShow="false" style="width:100%">
                                <el-table-column
                                    fixed="right"
                                    prop="display"
                                    label="操作"
                                    width="170px"
                                >
                                <template slot="header">
                                    <c-col :span="11" style="text-align:left"><span>操作</span></c-col>
                                    <c-col :span="12" style="text-align:right"><c-button icon="el-icon-s-tools"></c-button></c-col>
                                    </template>
                                    <template slot-scope="scope">
                                        <c-button
                                            style="margin-left: 0"
                                            size="small"
296
                                            type="primary"
297 298
                                            @click="show(scope.$index,scope.row)"
                                        >
299
                                            显示
300
                                        </c-button>
301
                                        <c-button
302 303
                                            style="margin-left: 0"
                                            size="small"
304
                                            type="primary"
305
                                        >
306 307
                                            打印
                                        </c-button>
308 309 310
                                    </template>
                                </el-table-column>
                            </c-istream-table>
311
                        </c-col> 
liuxin committed
312
                        
313 314 315 316 317 318
                        <!-- <c-col :span="12">
                            <el-form-item label="User ID">
                                <c-input  v-model="model.recpan.usr.extkey" maxlength="8"  placeholder="请输入User ID"></c-input>
                            </el-form-item>
                        </c-col>             
                                    
liuxin committed
319
                        <c-col :span="12">
320 321
                            <el-form-item label="">
                                <c-input  v-model="model.recpan.usrget.sdamod.seainf"  placeholder="请输入"></c-input>
liuxin committed
322
                            </el-form-item>
323 324
                        </c-col>             
                                                        -->
325
                        <c-col :span="24" style="height:24px;margin-top:20px">
liushikai committed
326
                            <el-form-item label="经办/复核" class="messageLabel">
liuxin committed
327 328
                            </el-form-item>
                        </c-col>
潘际乾 committed
329
                        <c-col :span="24" style="height:0px;margin-top:-5px">
liuxin committed
330 331
                            <el-divider></el-divider>
                        </c-col>
潘际乾 committed
332
                        <c-col :span="24">
liuxin committed
333
                            <!-- <c-input  v-model="model.recpan.trsstm"  placeholder="请输入Signatures"></c-input> -->
334
                            <c-col :span="24" :offset="0">
liuxin committed
335
                                <c-istream-table :list="SignaturesData.data" :columns="SignaturesData.columns" :paginationShow="false" style="width:100%">
336
                                    <el-table-column label="Action" width="auto">
liuxin committed
337
                                        <template slot-scope="scope">
338
                                            <span>{{flg[scope.row.IDX]}}</span>
liuxin committed
339
                                            <!-- <el-select v-model="action[scope.row.IDX]" style="100%" disabled>
liuxin committed
340 341 342 343 344 345
                                                <el-option
                                                    v-for="item in codes.flg"
                                                    :key="item.value"
                                                    :label="item.label"
                                                    :value="item.value"
                                                />
liuxin committed
346
                                            </el-select> -->
liuxin committed
347 348
                                        </template>
                                    </el-table-column>
liuxin committed
349
                                </c-istream-table>
liuxin committed
350
                            </c-col> 
351 352
                        </c-col>  

liuxin committed
353
                        <!-- -------------------workflow------------------- -->
354
                        <c-col :span="24" style="height:24px;margin-top:20px">
liushikai committed
355
                            <el-form-item label="工作流服务" class="messageLabel">
liuxin committed
356 357
                            </el-form-item>
                        </c-col>
潘际乾 committed
358
                        <c-col :span="24" style="height:0px;margin-top:-5px">
liuxin committed
359
                            <el-divider></el-divider>
360
                        </c-col>
潘际乾 committed
361
                        <c-col :span="24">
362
                            <c-col :span="24" :offset="0">
liuxin committed
363
                                    <c-istream-table :list="stmData.data" :columns="stmData.columns" :paginationShow="false" style="width:100%">
364
                                    </c-istream-table>
liuxin committed
365
                            </c-col>
366
                        </c-col>                       
liuxin committed
367

368 369
                    </c-content>                  
                </el-form>      
liuxin committed
370
            </div>
liushikai committed
371 372
        <!-- </div> -->
            </c-content>
liuxin committed
373 374 375 376
    </c-page>
</template>

<script>
潘际乾 committed
377
import Trnrel from "~/model/Trnrel";
liuxin committed
378
import Api from "~/service/Api"
wangren committed
379
import commonProcess from "~/mixin/commonProcess";
liuxin committed
380 381
import CodeTable from "~/config/CodeTable"
import Event from "~/model/Trnrel/Event"
hulei committed
382
import DocUtils from '~/utils/DocUtils'
liuxin committed
383 384

export default {
385
    name: "InftrnpsDetail",
wangren committed
386
    mixins: [commonProcess],
liuxin committed
387 388 389 390 391
    data(){
        return {
            model: new Trnrel().data,
            documentsData: {
                columns: [
liuxin committed
392
                    "1 1 \"Type\" 300 1 0:0 1 CORTYP",
liuxin committed
393
                    "2 2 \"External Key\" 300",
liuxin committed
394
                    "3 3 \"Document\" auto",
liuxin committed
395 396 397 398 399
                    ],
                data: [],
            },
            SignaturesData: {
                columns: [
400
                    '1 2:1 "User" 300',
liushikai committed
401 402
                    // '2 3:1 "Date / Time" 300',
                    {index:2,position:3,width:300,pattern:'time',label:'Date / Time'},
liuxin committed
403
                    // '3 5:1 "Action" 400',
404
                    '4 1:1 "Type" 300'
liuxin committed
405 406 407
                    ],
                data: [],
            },
408 409 410 411 412 413
            codes: { infdsp: CodeTable.infdsp,
                     flg : CodeTable.flg,
                     atptxt : CodeTable.atptxt,
                     relstaEN : CodeTable.relstaEN,
                     usgtxt : CodeTable.usgtxt,
                     wfetrssta : CodeTable.wfetrssta },
liuxin committed
414 415
            stmData: {
                columns: [
liuxin committed
416
                    '1 1 "ID" 100',
417
                    '2 2 "Service" 100',
418
                    // '3 3 "Status" 100',
419
                    {index:3,position:3,width:100,pattern:'code',label:'Status',code: CodeTable.wfetrssta},
420
                    '4 4 "Last Update" 100',
liuxin committed
421
                    '5 5 "Retries" 100',
422 423
                    '6 6 "Text" 200',
                    '7 7 "Contrary Text" 200',
liushikai committed
424 425
                    // '8 8 "Target Time" auto'
                    {index:8,position:8,width:'auto',pattern:'dateFormat',label:'Target Time'},
liuxin committed
426 427 428
                    ],
                data: [],
            },
429 430 431 432
            flg:[],
            atptxt:'',
            relstaEN:'',
            usgtxt:'',
liuxin committed
433 434 435 436 437 438
        }
    },
    mounted() {
        this.loadData()
    },
    methods: {
hulei committed
439
        ...Event,
liuxin committed
440
        loadData() {
441 442
            // const { data } = this.$route.query
            this.model = JSON.parse(sessionStorage.getItem('InftrnpsDetail'));
liuxin committed
443 444 445
            this.documentsData.data = this.model.recpan.smhstm.rows;
            this.SignaturesData.data = this.model.recpan.trsstm.rows;
            this.stmData.data = this.model.recpan.wfestm.rows;
446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463
            this.flg = this.ArrCalCode(this.SignaturesData.data, this.codes.flg, 3);
            this.atptxt = this.strCalCode(this.model.recpan.atp.cod, this.codes.atptxt);
            this.relstaEN = this.strCalCode(this.model.trn.relflg, this.codes.relstaEN);
            this.usgtxt = this.strCalCode(this.model.trn.usg, this.codes.usgtxt);
        },
        strCalCode(str, code){
            var result = '';
            for(let i = 0; i < code.length; i++){
                if(code[i].value === code){
                    result = code[i].label;
                    continue;
                }
            }
            if(result === ''){
                return str;
            }else{
                return result;
            }
464
        },
465
        ArrCalCode(table, code, index){
466 467 468
            var result = [];
            for (let i = 0; i < table.length; i++) {
                const d = table[i];
liuxin committed
469
                const items = d.split("\t");
470
                result[i] = items[index];
liuxin committed
471
                for(let j = 0; j < code.length; j++){
472 473
                    if(code[j].value === result[i]){
                        result[i] = code[j].label;
liuxin committed
474 475 476
                        continue;
                    }
                }
liuxin committed
477
            }
478
            return result;
liuxin committed
479 480 481 482 483
        },
        exit(){
            this.$store.dispatch("TagsView/delView", this.$route)
            this.$router.history.push("/taskList");
        },
484 485
        async show(idx,row){       
            var params = {selDst:"recpan.smhstm",selIds:[idx+1],selBtnId:"A"}
潘际乾 committed
486
            let rtnmsg = await Api.post(`/business/trnrel/executeRule/recpan.smhstm`, this.wrapper(params))
hulei committed
487 488 489 490
            if (rtnmsg.respCode == SUCCESS) {
                this.title = "面函"
                let viewurl = "/#/docpan/show";
                let XMLdata;
491
                if (row.Type == 'LET') {
hulei committed
492
                    window.sessionStorage.docTXT = ''
493
                    window.sessionStorage.docXML = rtnmsg.data.docimm_xmldocblk;
hulei committed
494 495 496 497 498 499 500 501
                }
                else if (row.pandsc == "MT799") {
                    window.sessionStorage.docTXT = ''
                    XMLdata = rtnmsg.data.litbenl1blk
                }
                window.open(viewurl, 'newwindow', 'height=1200,width=800,top=100,left=100,toolbar=no,resizable=no,menubar=no,location=no, status=no');
            }
            else {
hulei committed
502
                const h = this.$createElement
hulei committed
503 504
                const msg = rtnmsg.respMsg||'请求执行失败!'
                this.$notify.error({ title: '错误', message: h('p',{style: 'word-break:break-all;'}, msg) })
hulei committed
505 506
            }
        }
liuxin committed
507 508 509
    }
}
</script>
liuxin committed
510 511 512 513 514 515 516 517
<style scoped>
.el-col >>> .el-divider--horizontal {
    margin-top: 10px;
}
.formItemLabel >>> .el-form-item__label{
    text-align: left;
    font-weight:bold;
}
liuxin committed
518 519 520 521 522 523 524 525
.el-col >>> .el-divider--horizontal {
  margin-top: 5px;
}
.messageLabel >>> .el-form-item__label{
    text-align: left;
    font-weight:bold;
    font-size: 12px;
}
liuxin committed
526
</style>