Setp.vue 17.3 KB
Newer Older
wangbinfei committed
1 2
<template>
  <div class="eibs-tab">
wangna committed
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302
    <!-- ====================左边======================= -->
    <c-col :span="11">
      <c-col :span="22">
        <el-form-item label="Our Reference" prop="ccdgrp.rec.ownref">
          <c-input
            v-model="model.ccdgrp.rec.ownref"
            maxlength="8"
            placeholder="请输入Our Reference"
            disabled
          ></c-input>
        </el-form-item>
      </c-col>
      <c-col :span="2">
        <c-button
          style="margin: 0 12px 0 14px; padding: 0 12px"
          size="small"
          type="primary"
          disabled
        >
          <span style="font-family: '宋体'; font-weight: bold">i</span>
        </c-button>
      </c-col>

      <c-col :span="12">
        <el-form-item label="Currency" prop="ccdgrp.cbs.max.cur">
          <c-select
            v-model="model.ccdgrp.cbs.max.cur"
            style="width: 100%"
            placeholder="请选择Currency"
            disabled
          >
            <el-option
              v-for="item in codes.curtxt1"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </c-select>
        </el-form-item>
      </c-col>
      <c-col :span="12">
        <el-form-item
          style="text-align: left"
          label-width="20px"
          prop="ccdgrp.cbs.max.amt"
        >
          <c-input-currency
            v-model="model.ccdgrp.cbs.max.amt"
            style="text-align: left; width: 100%"
            placeholder="请输入"
            @keyup.enter.native="
              defaultFunction('ccdgrp.cbs.max.amt', model.ccdgrp.cbs.max.amt)
            "
            disabled
          ></c-input-currency>
        </el-form-item>
      </c-col>

      <c-col :span="12">
        <el-form-item label="Currency" prop="ccdgrp.cbs.opn1.cur">
          <c-select
            disabled
            v-model="model.ccdgrp.cbs.opn1.cur"
            style="width: 100%"
            placeholder="请选择Currency"
          >
            <el-option
              v-for="item in codes.curtxt1"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </c-select>
        </el-form-item>
      </c-col>
      <c-col :span="12">
        <el-form-item
          style="text-align: left"
          label-width="20px"
          prop="ccdgrp.cbs.opn1.amt"
        >
          <c-input-currency
            v-model="model.ccdgrp.cbs.opn1.amt"
            style="text-align: left; width: 100%"
            placeholder="请输入"
            @keyup.enter.native="
              defaultFunction('ccdgrp.cbs.opn1.amt', model.ccdgrp.cbs.opn1.amt)
            "
            disabled
          ></c-input-currency>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="Date of Draft" prop="ccdgrp.rec.chkdat">
          <c-date-picker
            type="date"
            v-model="model.ccdgrp.rec.chkdat"
            style="width: 100%"
            placeholder="请选择Date of Draft"
            disabled
          ></c-date-picker>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="Form of Clean Coll." prop="ccdgrp.rec.ccform">
          <c-select
            v-model="model.ccdgrp.rec.ccform"
            style="width: 100%"
            placeholder="请选择Form of Clean Coll."
            :code="codes.ccform"
            disabled
          >
          </c-select>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="Payment Disposition " prop="ccdgrp.rec.purflg">
          <c-select
            v-model="model.ccdgrp.rec.purflg"
            style="width: 100%"
            placeholder="请选择Payment Disposition "
            :code="codes.purflg"
            disabled
          >
          </c-select>
        </el-form-item>
      </c-col>

      <c-col :span="24" style="height: 24px; margin-top: 20px">
        <el-form-item label="Settle Tenor:" class="messageLabel"></el-form-item>
      </c-col>
      <c-col :span="24" style="margin-bottom: 35px">
        <c-istream-table
          label="Settle Tenor"
          ref="table"
          :list="model.liaall.tenstm.rows || []"
          :columns="stmData.columns"
          :showSelection="true"
          v-on:multipleSelect="multipleSelect"
          prop="liaall.tenstm"
        >
        </c-istream-table>
      </c-col>

      <c-col :span="12">
        <el-form-item label="Amount settled" prop="setmod.doccur">
          <c-select
            disabled
            v-model="model.setmod.doccur"
            style="width: 100%"
            placeholder="请选择Amount settled"
          >
            <el-option
              v-for="item in codes.curtxt1"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </c-select>
        </el-form-item>
      </c-col>
      <c-col :span="12">
        <el-form-item
          style="text-align: left"
          label-width="20px"
          prop="setmod.docamt"
        >
          <c-input-currency
            v-model="model.setmod.docamt"
            style="text-align: left; width: 100%"
            placeholder="请输入"
          ></c-input-currency>
        </el-form-item>
      </c-col>
    </c-col>

    <!-- ====================右边======================= -->
    <c-col :span="11" :offset="1">
      <c-col :span="24">
        <el-form-item label="Name" prop="ccdgrp.rec.nam">
          <c-input
            v-model="model.ccdgrp.rec.nam"
            maxlength="40"
            placeholder="请输入Name"
            disabled
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="Presenter Draft Nb." prop="ccdgrp.pre.pts.ref">
          <c-input
            v-model="model.ccdgrp.pre.pts.ref"
            maxlength="40"
            placeholder="请输入Presenter Draft Nb."
            disabled
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="" prop="ccdgrp.pre.pts.nam">
          <c-input
            v-model="model.ccdgrp.pre.pts.nam"
            maxlength="40"
            placeholder="请输入"
            disabled
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="Drawn on Bank Ref." prop="ccdgrp.dro.pts.ref">
          <c-input
            v-model="model.ccdgrp.dro.pts.ref"
            maxlength="40"
            placeholder="请输入Drawn on Bank Ref."
            disabled
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="" prop="ccdgrp.dro.pts.nam">
          <c-input
            v-model="model.ccdgrp.dro.pts.nam"
            maxlength="40"
            placeholder="请输入"
            disabled
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="Collecting Bank Ref." prop="ccdgrp.col.pts.ref">
          <c-input
            v-model="model.ccdgrp.col.pts.ref"
            maxlength="40"
            placeholder="请输入Collecting Bank Ref."
            disabled
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="" prop="ccdgrp.col.pts.nam">
          <c-input
            v-model="model.ccdgrp.col.pts.nam"
            maxlength="40"
            placeholder="请输入"
            disabled
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="" prop="ccdgrp.rec.frepayflg">
          <c-checkbox v-model="model.ccdgrp.rec.frepayflg"
            >Free of Payment</c-checkbox
          >
        </el-form-item>
      </c-col>

      <c-col :span="12">
        <el-form-item label="Reduction Amt." prop="setmod.doccur">
          <c-select
            disabled
            v-model="model.setmod.doccur"
            style="width: 100%"
            placeholder="请选择Currency"
          >
            <el-option
              v-for="item in codes.curtxt1"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </c-select>
        </el-form-item>
      </c-col>
      <c-col :span="12">
        <el-form-item
          style="text-align: left"
          label-width="5px"
          prop="setmod.redamt"
        >
          <c-input-currency
            :disabled="model.ccdgrp.rec.frepayflg == 'X'"
            v-model="model.setmod.redamt"
            style="text-align: left; width: 100%"
            placeholder="请输入Reduction Amt"
            @change="change"
          ></c-input-currency>
wangbinfei committed
303
        </el-form-item>
wangna committed
304 305 306 307 308 309 310
      </c-col>
    </c-col>

    <!-- <c-col :span="12">
        <c-form-item label="Drag  Drop Sender" prop="cctp0.recget.sdamod.dadsnd">
            <c-input  v-model="model.cctp0.recget.sdamod.dadsnd"  :placeholder="$t('other.please_enter')+'Drag  Drop Sender'"></c-input>
        </c-form-item>
wangbinfei committed
311
       </c-col>
wangna committed
312 313
                 
                  
wangbinfei committed
314
       <c-col :span="12">
wangna committed
315 316 317
        <c-form-item label="Name of CC contract" prop="ccdgrp.rec.nam">
            <c-input  v-model="model.ccdgrp.rec.nam" maxlength="40"  :placeholder="$t('other.please_enter')+'Name of CC contract'"></c-input>
        </c-form-item>
wangbinfei committed
318
       </c-col>
wangna committed
319 320
               
                  
wangbinfei committed
321
       <c-col :span="12">
wangna committed
322 323 324
        <c-form-item :label="$t('cctp0.S0000002')" prop="ccdgrp.rec.ownref">
            <c-input  v-model="model.ccdgrp.rec.ownref" maxlength="16"  :placeholder="$t('other.please_enter')+$t('cctp0.S0000002')"></c-input>
        </c-form-item>
wangbinfei committed
325 326 327
       </c-col>
                  
       <c-col :span="12">
wangna committed
328 329 330
        <c-form-item label="" prop="cctp0.recget.sdamod.seainf">
            <c-input  v-model="model.cctp0.recget.sdamod.seainf"  :placeholder="$t('other.please_enter')+''"></c-input>
        </c-form-item>
wangbinfei committed
331
       </c-col>
wangna committed
332 333
            
                  
wangbinfei committed
334
       <c-col :span="12">
wangna committed
335 336
        <el-form-item :label="$t('cctp0.S0000005')" prop="ccdgrp.cbs.max.cur">
            <c-select v-model="model.ccdgrp.cbs.max.cur" style="width:100%" :placeholder="$t('other.please_enter')+$t('cctp0.S0000005')">
wangbinfei committed
337 338 339 340 341
              </c-select>
        </el-form-item>
       </c-col>
                  
       <c-col :span="12">
wangna committed
342 343 344
        <c-form-item :label="$t('cctp0.S0000005')" prop="ccdgrp.cbs.max.amt">
            <c-input  v-model="model.ccdgrp.cbs.max.amt"  :placeholder="$t('other.please_enter')+$t('cctp0.S0000005')"></c-input>
        </c-form-item>
wangbinfei committed
345
       </c-col>
wangna committed
346 347
                 
                  
wangbinfei committed
348
       <c-col :span="12">
wangna committed
349 350 351
        <c-form-item :label="$t('cctp0.S0000013')" prop="ccdgrp.pre.pts.ref">
            <c-input  v-model="model.ccdgrp.pre.pts.ref" maxlength="16"  :placeholder="$t('other.please_enter')+$t('cctp0.S0000013')"></c-input>
        </c-form-item>
wangbinfei committed
352 353 354
       </c-col>
                  
       <c-col :span="12">
wangna committed
355 356 357
        <c-form-item label="Name of Party" prop="ccdgrp.pre.pts.nam">
            <c-input  v-model="model.ccdgrp.pre.pts.nam" maxlength="40"  :placeholder="$t('other.please_enter')+'Name of Party'"></c-input>
        </c-form-item>
wangbinfei committed
358
       </c-col>
wangna committed
359 360
                 
                  
wangbinfei committed
361
       <c-col :span="12">
wangna committed
362 363
        <el-form-item :label="$t('cctp0.S0000007')" prop="ccdgrp.cbs.opn1.cur">
            <c-select v-model="model.ccdgrp.cbs.opn1.cur" style="width:100%" :placeholder="$t('other.please_enter')+$t('cctp0.S0000007')">
wangbinfei committed
364 365 366 367 368
              </c-select>
        </el-form-item>
       </c-col>
                  
       <c-col :span="12">
wangna committed
369 370 371
        <c-form-item :label="$t('cctp0.S0000007')" prop="ccdgrp.cbs.opn1.amt">
            <c-input  v-model="model.ccdgrp.cbs.opn1.amt"  :placeholder="$t('other.please_enter')+$t('cctp0.S0000007')"></c-input>
        </c-form-item>
wangbinfei committed
372
       </c-col>
wangna committed
373 374
                 
                  
wangbinfei committed
375
       <c-col :span="12">
wangna committed
376 377 378
        <c-form-item :label="$t('cctp0.S0000015')" prop="ccdgrp.dro.pts.ref">
            <c-input  v-model="model.ccdgrp.dro.pts.ref" maxlength="16"  :placeholder="$t('other.please_enter')+$t('cctp0.S0000015')"></c-input>
        </c-form-item>
wangbinfei committed
379
       </c-col>
wangna committed
380 381
             
                  
wangbinfei committed
382
       <c-col :span="12">
wangna committed
383 384
        <el-form-item :label="$t('cctp0.S0000009')" prop="ccdgrp.rec.chkdat">
            <c-date-picker type="date"  v-model="model.ccdgrp.rec.chkdat" style="width:100%"  :placeholder="$t('other.please_enter')+$t('cctp0.S0000009')"></c-date-picker>
wangbinfei committed
385 386 387 388
        </el-form-item>
       </c-col>
                  
       <c-col :span="12">
wangna committed
389 390 391
        <c-form-item label="Name of Party" prop="ccdgrp.dro.pts.nam">
            <c-input  v-model="model.ccdgrp.dro.pts.nam" maxlength="40"  :placeholder="$t('other.please_enter')+'Name of Party'"></c-input>
        </c-form-item>
wangbinfei committed
392
       </c-col>
wangna committed
393
              
wangbinfei committed
394
       <c-col :span="12">
wangna committed
395 396 397
        <c-form-item :label="$t('cctp0.S0000010')" prop="ccdgrp.rec.ccform">
            <c-input  v-model="model.ccdgrp.rec.ccform" maxlength="1"  :placeholder="$t('other.please_enter')+$t('cctp0.S0000010')"></c-input>
        </c-form-item>
wangbinfei committed
398
       </c-col>
wangna committed
399
                
wangbinfei committed
400
       <c-col :span="12">
wangna committed
401 402 403
        <c-form-item :label="$t('cctp0.S0000017')" prop="ccdgrp.col.pts.ref">
            <c-input  v-model="model.ccdgrp.col.pts.ref" maxlength="16"  :placeholder="$t('other.please_enter')+$t('cctp0.S0000017')"></c-input>
        </c-form-item>
wangbinfei committed
404
       </c-col>
wangna committed
405 406
        
                  
wangbinfei committed
407
       <c-col :span="12">
wangna committed
408 409 410
        <c-form-item :label="$t('cctp0.S0000011')" prop="ccdgrp.rec.purflg">
            <c-input  v-model="model.ccdgrp.rec.purflg" maxlength="1"  :placeholder="$t('other.please_enter')+$t('cctp0.S0000011')"></c-input>
        </c-form-item>
wangbinfei committed
411 412 413
       </c-col>
                  
       <c-col :span="12">
wangna committed
414 415 416
        <c-form-item label="Name of Party" prop="ccdgrp.col.pts.nam">
            <c-input  v-model="model.ccdgrp.col.pts.nam" maxlength="40"  :placeholder="$t('other.please_enter')+'Name of Party'"></c-input>
        </c-form-item>
wangbinfei committed
417
       </c-col>
wangna committed
418
                  
wangbinfei committed
419
       <c-col :span="12">
wangna committed
420
	    <c-checkbox v-model="model.ccdgrp.rec.frepayflg">{{$t('cctset.C0000005')}}</c-checkbox>
wangbinfei committed
421 422 423
       </c-col>
                  
       <c-col :span="12">
wangna committed
424 425 426
        <c-form-item label="Tenor Stream" prop="liaall.tenstm">
            <c-input  v-model="model.liaall.tenstm"  :placeholder="$t('other.please_enter')+'Tenor Stream'"></c-input>
        </c-form-item>
wangbinfei committed
427
       </c-col>
wangna committed
428 429
                 
                  
wangbinfei committed
430
       <c-col :span="12">
wangna committed
431 432 433
        <c-form-item label="Reduction Amount" prop="setmod.redamt">
            <c-input  v-model="model.setmod.redamt"  :placeholder="$t('other.please_enter')+'Reduction Amount'"></c-input>
        </c-form-item>
wangbinfei committed
434
       </c-col>
wangna committed
435
                 
wangbinfei committed
436 437
       <c-col :span="12">
        <el-form-item label="document currency" prop="setmod.doccur">
wangna committed
438
            <c-select v-model="model.setmod.doccur" style="width:100%" :placeholder="$t('other.please_enter')+'document currency'">
wangbinfei committed
439 440 441 442 443
              </c-select>
        </el-form-item>
       </c-col>
                  
       <c-col :span="12">
wangna committed
444 445 446 447
        <c-form-item :label="$t('cctset.S0000006')" prop="setmod.docamt">
            <c-input  v-model="model.setmod.docamt"  :placeholder="$t('other.please_enter')+$t('cctset.S0000006')"></c-input>
        </c-form-item>
       </c-col> -->
wangbinfei committed
448 449 450
  </div>
</template>
<script>
wangna committed
451
import Api from "~/service/Api";
wangren committed
452
import commonProcess from "~/mixin/commonProcess";
wangna committed
453 454
import CodeTable from "~/config/CodeTable";
import Event from "~/model/Cctset/Event";
wangbinfei committed
455 456

export default {
wangna committed
457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493
  inject: ["root"],
  props: ["model", "codes"],
  mixins: [commonProcess],
  data() {
    return {
      stmData: {
        columns: [
          '1 1 "Type" 80',
          '2 2 "Dbt" 80',
          '3 3 "Cdt" 80',
          '4 4 "Cur" 80',
          '5 5 "Amt" 110 2 8 1 4',
          {
            index: 6,
            position: 6,
            width: 110,
            render: (item, scope) => {
              return scope.row[item.prop] === "null"
                ? ""
                : scope.row[item.prop];
            },
            label: "Mat.Dat.",
          },
        ],
        data: [],
      },
    };
  },
  methods: {
    ...Event,
    async change() {
      if (this.model.ccdgrp.rec.frepayflg === "X") {
        this.model.setmod.redamt = this.model.setmod.docamt;
      } else {
        this.model.setmod.redamt = "0.00";
      }
    },
wangbinfei committed
494

wangna committed
495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520
    async multipleSelect(selection) {
      if (selection.length > 1) {
        this.$notify({
          title: "error",
          message: "You cannot select more than one tenor",
          type: "error",
        });
      } else {
        let chkIds;
        if (selection.length === 0) {
          chkIds = [];
          this.model.liaall.tensetstm.rows = [];
          this.model.setmod.docamt = "0.00";
        } else {
          chkIds = [selection[0] + 1];
          this.model.setmod.docamt = this.model.ccdgrp.cbs.max.amt;
        }
        console.log(this.model.liaall.tensetstm);
        let params = { chkDst: "liaall.tenstm", chkIds };
        console.log(params);
        const rtnmsg = await this.executeRule("liaall.tenstm", params);
        console.log(rtnmsg);
        if (rtnmsg.respCode == SUCCESS) {
          this.updateModel(rtnmsg.data);
        } else {
          this.$notify.error({ title: "错误", message: "服务请求失败!" });
wangbinfei committed
521
        }
wangna committed
522
      }
wangbinfei committed
523
    },
wangna committed
524 525 526
  },
  created: function () {},
};
wangbinfei committed
527 528 529
</script>
<style>
</style>