InftrnpsDetail.vue 27.1 KB
Newer Older
suwenhao committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
<template>
    <div class="eContainer">
      <c-page title="">
        <!-- <div class="eContainer"> -->
        <c-content :height="120">
          <div class="eibs-tab">
            <el-form
              :model="model"
              ref="modelForm"
              tokenKey="modelForm"
              :validate-on-rule-change="false"
              label-width="150px"
              size="small"
            >
              <c-content>
                <!-- <c-col :span="24" style="margin:0 0 5px 0"> -->
                <c-col :span="12" style="height: 24px">
                  <el-form-item label="基本信息" class="messageLabel">
                  </el-form-item>
                </c-col>
                <c-col :span="11" style="text-align: right">
                  <c-button
                    size="small"
                    type="primary"
                    style="margin-left: 0"
suwenhao committed
26
                    @click="display(trn.inr)"
suwenhao committed
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46
                    >交易快照</c-button
                  >
                  <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>
                <!-- </c-col> -->
                <c-col :span="24" style="height: 10px; margin-bottom: 10px">
                  <el-divider></el-divider>
                </c-col>
    
                <!-- -------------------基础信息------------------- -->
    
suwenhao committed
47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82
                <!-- ========================= Left ========================= -->
              <c-col :span="11"> 
                  <c-col :span="24">
                      <c-col :span="22">
                          <el-form-item label="业务编号">
                              <c-input  v-model="trn.ownref" maxlength="16" disabled  placeholder="请输入业务编号"></c-input>
                          </el-form-item>
                      </c-col>             
                      <c-col :span="2" style="text-align: right">
                          <c-button
                              style="margin:0;padding: 0 14px;"
                              size="small"
                              type="primary"
                          >
                          <i class="el-icon-info" style="font-size:15px"></i>
                          </c-button>
                      </c-col>
                  </c-col>

                  <c-col :span="24">
                      <c-col :span="22">
                          <el-form-item label="交易代码">
                              <c-input  v-model="trn.inifrm" maxlength="6" disabled placeholder="请输入交易代码"></c-input>
                          </el-form-item>
                      </c-col> 
                      <c-col :span="2" style="text-align: right">
                          <c-button
                              style="margin:0;padding: 0 14px;"
                              size="small"
                              type="primary"
                          >
                          <i class="el-icon-info" style="font-size:15px"></i>
                          </c-button>
                      </c-col>
                  </c-col>

suwenhao committed
83 84 85 86
                  <c-col :span="24">
                    <c-col :span="13">
                      <el-form-item label="相关金额">
                        <c-input
suwenhao committed
87
                          v-model="trn.reloricur"
suwenhao committed
88 89 90 91 92 93 94 95 96
                          maxlength="3"
                          disabled
                          placeholder="请输入"
                        ></c-input>
                      </el-form-item>
                    </c-col>
                    <c-col :span="11">
                      <el-form-item label="" label-width="8px">
                        <c-input
suwenhao committed
97
                          v-model="trn.reloriamt"
suwenhao committed
98 99 100 101 102 103 104 105 106 107 108
                          disabled
                          placeholder="请输入"
                        ></c-input>
                      </el-form-item>
                    </c-col>
                  </c-col>
    
                  <c-col :span="24">
                    <c-col :span="13">
                      <el-form-item label="经办柜员">
                        <c-input
suwenhao committed
109
                          v-model="trn.usr"
suwenhao committed
110 111 112 113 114 115 116 117 118
                          maxlength="8"
                          disabled
                          placeholder="请输入经办柜员"
                        ></c-input>
                      </el-form-item>
                    </c-col>
    
                    <c-col :span="11">
                      <el-form-item label-width="40%" label="责任小组">
suwenhao committed
119
                        <!-- <c-input  v-model="trn.usg" maxlength="6" disabled  placeholder="请输入责任小组"></c-input> -->
suwenhao committed
120
                        <el-select
suwenhao committed
121
                          v-model="trn.usg"
suwenhao committed
122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139
                          style="width: 100%"
                          disabled
                        >
                          <el-option
                            v-for="item in codes.usgtxt"
                            :key="item.value"
                            :label="item.label"
                            :value="item.value"
                          />
                        </el-select>
                      </el-form-item>
                    </c-col>
                  </c-col>
    
                  <c-col :span="24">
                    <c-col :span="24">
                      <el-form-item label="根据识别号">
                        <c-input
suwenhao committed
140
                          v-model="trn.cortrninr"
suwenhao committed
141 142 143 144 145 146 147 148 149 150 151
                          maxlength="8"
                          disabled
                          placeholder="请输入根据识别号"
                        ></c-input>
                      </el-form-item>
                    </c-col>
    
                    <c-col :span="24">
                      <el-form-item label="执行日期">
                        <c-date-picker
                          type="date"
suwenhao committed
152
                          v-model="trn.exedat"
suwenhao committed
153 154 155 156 157 158 159 160 161 162 163 164 165
                          style="width: 100%"
                          disabled
                          placeholder="请选择执行日期"
                        ></c-date-picker>
                      </el-form-item>
                    </c-col>
                  </c-col>
    
                  <c-col :span="24">
                    <c-col :span="22">
                      <el-form-item label="信息文本">
                        <c-input
                          type="textarea"
suwenhao committed
166
                          v-model="trn.inftxt"
suwenhao committed
167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184
                          maxlength="65"
                          :rows="3"
                          show-word-limit
                          placeholder="请输入信息文本"
                        ></c-input>
                      </el-form-item>
                    </c-col>
                    <c-col :span="2" style="text-align: right">
                      <c-button
                        style="margin: 0; padding: 0 12px"
                        size="small"
                        icon="el-icon-search"
                        type="primary"
                      ></c-button>
                    </c-col>
                  </c-col>
                </c-col>
    
suwenhao committed
185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202
                <!-- ========================= Right ========================= -->
                <c-col :span="11" :offset="1">
                  <c-col :span="24">
                          <c-col :span="22">
                      <el-form-item label="TRN主键">
                              <c-input  v-model="trn.inr" disabled placeholder="请输入TRN主键"></c-input>
                      </el-form-item>
                          </c-col>
                          <c-col :span="2" style="text-align: right">
                              <c-button
                                  style="margin:0;padding: 0 14px;"
                                  size="small"
                                  type="primary"
                              >
                              <i class="el-icon-info" style="font-size:15px"></i>
                              </c-button>
                          </c-col>
                  </c-col>
suwenhao committed
203 204
    
                  <c-col :span="24">
suwenhao committed
205
                    <el-form-item label="交易名">
suwenhao committed
206
                      <c-input
suwenhao committed
207
                        v-model="trn.ininam"
suwenhao committed
208 209
                        maxlength="6"
                        disabled
suwenhao committed
210
                        placeholder="请输入交易名"
suwenhao committed
211 212 213 214 215 216 217
                      ></c-input>
                    </el-form-item>
                  </c-col>
    
                  <c-col :span="24">
                    <el-form-item label="摘要信息">
                      <c-input
suwenhao committed
218
                        v-model="trn.objnam"
suwenhao committed
219 220 221 222 223 224 225 226 227 228
                        maxlength="40"
                        disabled
                        placeholder="请输入"
                      ></c-input>
                    </el-form-item>
                  </c-col>
    
                  <c-col :span="24">
                    <el-form-item label="发布状态">
                      <el-select
suwenhao committed
229
                        v-model="trn.relflg"
suwenhao committed
230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246
                        style="width: 100%"
                        disabled
                      >
                        <el-option
                          v-for="item in codes.relstaEN"
                          :key="item.value"
                          :label="item.label"
                          :value="item.value"
                        />
                      </el-select>
                    </el-form-item>
                  </c-col>
    
                  <c-col :span="24">
                    <c-col :span="24">
                      <el-form-item label="经办柜员">
                        <c-input
suwenhao committed
247
                          v-model="trn.iniusr"
suwenhao committed
248 249 250 251 252 253 254 255 256 257
                          maxlength="8"
                          disabled
                          placeholder="请输入经办人"
                        ></c-input>
                      </el-form-item>
                    </c-col>
    
                    <c-col :span="24">
                      <el-form-item label="时间戳">
                        <c-input
suwenhao committed
258
                          v-model="trn.inidattim"
suwenhao committed
259 260 261 262 263 264 265 266 267
                          disabled
                          placeholder="请输入时间戳"
                        ></c-input>
                      </el-form-item>
                    </c-col>
                  </c-col>
    
                  <c-col :span="24">
                    <el-form-item label="信息标志">
suwenhao committed
268
                      <el-select v-model="trn.infdsp" style="width: 100%">
suwenhao committed
269 270 271 272 273 274 275 276 277 278 279 280 281
                        <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">
                    <el-form-item label="发送退回至">
                      <c-input
suwenhao committed
282
                        v-model="trn.etyextkey"
suwenhao committed
283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300
                        disabled
                        style="width: 100%"
                        placeholder=""
                      >
                      </c-input>
                    </el-form-item>
                  </c-col>
                </c-col>
    
                <!-- -------------------document------------------- -->
                <c-col :span="24" style="height: 24px">
                  <el-form-item label="面函/报文" class="messageLabel">
                  </el-form-item>
                </c-col>
                <c-col :span="24" style="height: 0px; margin-top: -5px">
                  <el-divider></el-divider>
                </c-col>
                <c-col :span="24">
suwenhao committed
301
                  <el-table
suwenhao committed
302 303
                    :list="documentsData.data"
                  >
suwenhao committed
304 305 306 307 308 309 310
                    <el-table-column
                      v-for="(item, index) in documentsData.columns"
                      :label="item.label"
                      :prop="item.prop"
                      :key="index"
                    >
                    </el-table-column>
suwenhao committed
311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459
                    <el-table-column label="介质" width="110px">
                      <template slot-scope="scope">
                        <el-form-item
                          label-width="0"
                          :prop="'trnmod.trndoc.doceot.' + scope.$index + '.cortyp'"
                        >
                          <c-select
                            v-model="scope.row.cortyp"
                            style="width: 100%"
                            disabled
                            placeholder="请选择"
                          >
                            <el-option
                              v-for="item in codes.doceotCortyp"
                              :key="item.value"
                              :label="item.label"
                              :value="item.value"
                            >
                            </el-option>
                          </c-select>
                        </el-form-item>
                      </template>
                    </el-table-column>
                    <el-table-column label="报文格式" width="150px">
                      <template slot-scope="scope">
                        <c-select
                          v-model="scope.row.docsnf"
                          style="width: 100%"
                          placeholder="请选择"
                          @change="executeDefault('trnmod.trndoc.doccur.docsnf')"
                        >
                          <el-option
                            v-for="item in codes.docsnf"
                            :key="item.value"
                            :label="item.label"
                            :value="item.value"
                          >
                          </el-option>
                        </c-select>
                      </template>
                    </el-table-column>
                    <el-table-column label="语言" width="150px">
                      <template slot-scope="scope">
                        <c-select
                          v-model="scope.row.docuil"
                          style="width: 100%"
                          placeholder="请选择"
                        >
                          <el-option
                            v-for="item in codes.uiltxt"
                            :key="item.value"
                            :label="item.label"
                            :value="item.value"
                          >
                          </el-option>
                        </c-select>
                      </template>
                    </el-table-column>
                    <el-table-column label="传送方式" width="110px">
                      <template slot-scope="scope">
                        <el-form-item
                          label-width="0"
                          :prop="'trnmod.trndoc.doceot.' + scope.$index + '.apf'"
                        >
                          <c-select
                            v-model="scope.row.apf"
                            disabled
                            style="width: 100%"
                            placeholder="请选择"
                          >
                            <el-option
                              v-for="item in codes.apftxt"
                              :key="item.value"
                              :label="item.label"
                              :value="item.value"
                            >
                            </el-option>
                          </c-select>
                        </el-form-item>
                      </template>
                    </el-table-column>
                    <el-table-column label="发送份数" width="70">
                      <template slot-scope="scope">
                        <c-input
                          v-model="scope.row.apfcpy1"
                          :readonly="true"
                          style="width: 100%"
                          placeholder="请选择"
                        >
                        </c-input>
                      </template>
                    </el-table-column>
                    <el-table-column label="抄送份数" width="70">
                      <template slot-scope="scope">
                        <c-input
                          v-model="scope.row.apfcpy2"
                          style="width: 100%"
                          placeholder="请选择"
                        >
                        </c-input>
                      </template>
                    </el-table-column>
                    <el-table-column label="" width="110px">
                      <template slot-scope="scope">
                        <el-form-item
                          label-width="0"
                          :prop="'trnmod.trndoc.doceot.' + scope.$index + '.staflg'"
                        >
                          <c-select
                            v-model="scope.row.staflg"
                            style="width: 100%"
                            placeholder="请选择"
                          >
                            <el-option
                              v-for="item in codes.swttlx"
                              :key="item.value"
                              :label="item.label"
                              :value="item.value"
                            >
                            </el-option>
                          </c-select>
                        </el-form-item>
                      </template>
                    </el-table-column>
                    <el-table-column label="操作" width="200px" fixed="right">
                      <template slot-scope="scope">
                        <c-button
                          type="primary"
                          size="small"
                          :disabled="
                            (scope.row.pandsc == 'MT799' &&
                              model.didgrp &&
                              model.didgrp.rec &&
                              model.didgrp.rec.elcflg == 'Y') ||
                            suppress
                          "
                          @click="show(scope.$index, scope.row)"
                          style="margin-right: 10px"
                          >预览</c-button
                        >
                        <c-button
                          size="small"
                          type="primary"
                          style="margin-left: 0"
                          @click="handleDetail(scope.row.index, scope.row)"
                          >详情</c-button
                        >
                      </template>
                    </el-table-column>
suwenhao committed
460
                  </el-table>
suwenhao committed
461
                </c-col>
suwenhao committed
462
                <!-- 经办复核 -->
suwenhao committed
463 464 465 466 467 468 469 470 471
                <c-col :span="24" style="height: 24px; margin-top: 20px">
                  <el-form-item label="经办/复核" class="messageLabel">
                  </el-form-item>
                </c-col>
                <c-col :span="24" style="height: 0px; margin-top: -5px">
                  <el-divider></el-divider>
                </c-col>
                <c-col :span="24">
                  <c-col :span="24" :offset="0">
suwenhao committed
472
                    <el-table
suwenhao committed
473 474 475 476 477
                      :list="SignaturesData.data"
                      :columns="SignaturesData.columns"
                      :paginationShow="false"
                      style="width: 100%"
                    >
suwenhao committed
478 479 480 481 482 483 484
                      <el-table-column
                        v-for="(item, index) in SignaturesData.columns"
                        :label="item.label"
                        :prop="item.prop"
                        :key="index"
                      >
                      </el-table-column>
suwenhao committed
485 486 487 488 489
                      <el-table-column label="行为" width="auto">
                        <template slot-scope="scope">
                          <span>{{ flg[scope.row.IDX] }}</span>
                        </template>
                      </el-table-column>
suwenhao committed
490
                    </el-table>
suwenhao committed
491 492 493 494 495 496 497 498 499 500 501 502 503
                  </c-col>
                </c-col>
    
                <!-- -------------------workflow------------------- -->
                <c-col :span="24" style="height: 24px; margin-top: 20px">
                  <el-form-item label="工作流服务" class="messageLabel">
                  </el-form-item>
                </c-col>
                <c-col :span="24" style="height: 0px; margin-top: -5px">
                  <el-divider></el-divider>
                </c-col>
                <c-col :span="24">
                  <c-col :span="24" :offset="0">
suwenhao committed
504 505
                    <el-table
                      :data="stmData.data"
suwenhao committed
506 507 508
                      :paginationShow="false"
                      style="width: 100%"
                    >
suwenhao committed
509 510 511 512 513 514 515 516 517 518 519 520 521 522 523
                      <el-table-column
                        v-for="(item, index) in stmData.columns"
                        :label="item.label"
                        :prop="item.prop"
                        :key="index"
                      >
                        <template slot-scope="scope">
                          <span>
                            {{ formatter(scope.row[scope.column.property]) }}
                            <!-- {{ scope.column.renderCell(scope.row[scope.column.property]) }} -->
                            <!-- {{!item.formatter ? socpe.row[item.prop] : item.formatter(scope.row[item.prop])}} -->
                          </span>
                        </template>
                      </el-table-column>
                    </el-table>
suwenhao committed
524 525 526 527 528 529 530 531 532 533 534 535 536 537
                  </c-col>
                </c-col>
              </c-content>
            </el-form>
          </div>
          <!-- </div> -->
        </c-content>
      </c-page>
      </div>
    </template>
    
    <script>
    import Trnrel from "../model";
    import Api from "~/service/Api";
suwenhao committed
538
    import commonApi from "~/mixin/commonApi";
suwenhao committed
539
    import CodeTable from "~/config/CodeTable";
540
    import event from "../event";
suwenhao committed
541 542 543
    
    export default {
      name: "InftrnpsDetail",
suwenhao committed
544
      mixins: [commonApi, event],
suwenhao committed
545 546 547
      data() {
        return {
          model: new Trnrel().data,
suwenhao committed
548
          trn: {},
suwenhao committed
549 550
          documentsData: {
            columns: [
551 552
              { label: '收报人', prop: 'cortyp' },
              { label: '描述', prop: 'extkey' },
suwenhao committed
553 554 555 556 557
            ],
            data: [],
          },
          SignaturesData: {
            columns: [
558 559 560
              { label: '类型', prop: 'sigidx' },
              { label: '用户', prop: 'nam' },
              { label: '日期/时间', prop: 'dattim' },
suwenhao committed
561 562 563 564 565 566 567 568 569 570 571 572 573
            ],
            data: [],
          },
          codes: {
            infdsp: CodeTable.infdsp,
            flg: CodeTable.flg,
            atptxt: CodeTable.atptxt,
            relstaEN: CodeTable.relstaEN,
            usgtxt: CodeTable.usgtxt,
            wfetrssta: CodeTable.wfetrssta,
          },
          stmData: {
            columns: [
suwenhao committed
574 575
              { label: '编号', prop: 'wfssub' },
              { label: '服务', prop: 'srv' },
suwenhao committed
576 577 578 579 580 581 582
              {
                index: 3,
                position: 3,
                width: 100,
                pattern: "code",
                label: "交易状态",
                code: CodeTable.wfetrssta,
suwenhao committed
583 584 585 586 587 588 589 590 591 592 593
                prop: 'sta',
                renderCell: (h, val) => {
                  let label;
                  for(let i of CodeTable.wfetrssta) {
                    if(i.value === val) {
                      label = i.label;
                      break;
                    }
                  }
                  return label
                }
suwenhao committed
594
              },
suwenhao committed
595 596 597 598
              { label: '最新更新', prop: 'dattim' },
              { label: '重试', prop: 'retdur' },
              { label: '文本', prop: 'txt' },
              { label: '相反文本', prop: 'txt2' },
suwenhao committed
599 600 601 602 603 604
              {
                index: 8,
                position: 8,
                width: "auto",
                pattern: "dateFormat",
                label: "目标时间",
suwenhao committed
605
                prop: 'tardattim'
suwenhao committed
606
              },
607

suwenhao committed
608 609 610 611 612 613 614 615 616 617 618 619 620
            ],
            data: [],
          },
          flg: [],
          atptxt: "",
          relstaEN: "",
          usgtxt: "",
        };
      },
      mounted() {
        this.loadData();
      },
      methods: {
suwenhao committed
621 622 623 624 625 626 627 628 629 630
        formatter(val) {
          let label;
          for(let i of CodeTable.wfetrssta) {
            if(i.value === val) {
              label = i.label;
              break;
            }
          }
          return label
        },
suwenhao committed
631 632 633 634 635 636 637 638 639 640 641
        async handleDetail(index, row) {
          const params = {
            index: row.idx,
          };
          let rtnmsg = await Api.post(
            `${this.requestPrefix}/executeDocpanDetail`,
            this.wrapper(params)
          );
          if (rtnmsg.respCode == SUCCESS) {
            this.title = row.pandsc;
            (this.centerDialogVisible = true), this.updateModel(rtnmsg.data);
suwenhao committed
642
            this.dialog = this.trnmod.trndoc.doceot[row.idx];
suwenhao committed
643 644 645
            this.index = row.idx;
          }
        },
646
        //加载数据
suwenhao committed
647
        loadData() {
648
          let model = JSON.parse(sessionStorage.getItem("InftrnpsDetail"));
suwenhao committed
649
          this.trn = model.trn;
650 651
          this.documentsData.data = model.smh;
          this.SignaturesData.data = model.trs;
suwenhao committed
652
          this.stmData.data = model.wfe;
suwenhao committed
653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714
        },
        exit() {
          this.$store.dispatch("TagsView/delView", this.$route);
          this.$router.history.push("/taskList");
        },
        async show(idx, row) {
          var params = {
            selDst: "recpan.smhstm",
            selIds: [idx + 1],
            selBtnId: "A",
          };
          let rtnmsg = await Api.post(
            `/business/trnrel/executeRule/recpan.smhstm`,
            this.wrapper(params)
          );
          if (rtnmsg.respCode == SUCCESS) {
            this.title = "面函";
            let viewurl = "/#/docpan/show";
            let XMLdata;
            if (row.类型 == "LET") {
              window.sessionStorage.docTXT = "";
              window.sessionStorage.docXML = rtnmsg.data.docimm_xmldocblk;
            } 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 {
            const h = this.$createElement;
            const msg = rtnmsg.respMsg || "请求执行失败!";
            this.$notify.error({
              title: "错误",
              message: h("p", { style: "word-break:break-all;" }, msg),
            });
          }
        },
      },
    };
    </script>
    <style scoped>
    .el-col >>> .el-divider--horizontal {
      margin-top: 10px;
    }
    .formItemLabel >>> .el-form-item__label {
      text-align: left;
      font-weight: bold;
    }
    .el-col >>> .el-divider--horizontal {
      margin-top: 5px;
    }
    .messageLabel >>> .el-form-item__label {
      text-align: left;
      font-weight: bold;
      font-size: 15px;
      color:#1561E0;
      width: auto!important;
    }
    </style>