Ovwp.vue 16.1 KB
Newer Older
jxl committed
1 2
<template>
  <c-row>
huangxin committed
3 4 5
    <!-- =================顶部====================== -->
    <c-col :span="24">
      <c-col :span="11">
jxl committed
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
        <c-col :span="20">
          <el-form-item
            label="Reference"
            prop="bodgrp.rec.ownref"
            style="width: 100%"
          >
            <c-input
              v-model="model.bodgrp.rec.ownref"
              maxlength="16"
              placeholder="请输入Reference"
              style="width: 95%"
              disabled
            ></c-input>
          </el-form-item>
        </c-col>
huangxin committed
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
        <c-col :span="1">
          <c-button
            style="margin: 0 10px 0 0; padding: 0 10px"
            size="small"
            type="primary"
            icon="el-icon-search"
          ></c-button>
        </c-col>
        <c-col :span="3" style="text-align: right">
          <c-button
            style="margin: 0 0"
            size="small"
            type="primary"
            :disabled="this.flag"
          >
            获取
          </c-button>
        </c-col>
      </c-col>
      <c-col :span="11" :offset="1">
41
        <el-form-item label="Name" prop="bodgrp.rec.nam">
jxl committed
42 43 44 45 46 47 48 49
          <c-input
            align="middle"
            v-model="model.bodgrp.rec.nam"
            maxlength="40"
            disabled
            placeholder="请输入Externally Displayed Name to Identify the Contract"
          ></c-input>
        </el-form-item>
huangxin committed
50
      </c-col>
jxl committed
51
    </c-col>
huangxin committed
52 53 54
    <!-- ====================左边======================= -->
    <c-col :span="11">
      <c-col :span="24">
55
        <c-col :span="14">
huangxin committed
56
          <el-form-item
jxl committed
57
            label="Responsible User"
58
            prop="botp.usr.extkey"
jxl committed
59
            style="width: 100%"
huangxin committed
60
          >
jxl committed
61
            <c-input
huangxin committed
62 63 64 65 66
              style="width: 95%"
              v-model="model.botp.usr.extkey"
              maxlength="8"
              placeholder="请输入User ID"
              disabled
jxl committed
67
            ></c-input>
huangxin committed
68
          </el-form-item>
jxl committed
69
        </c-col>
huangxin committed
70 71 72 73 74 75 76
        <c-col :span="2">
          <c-button
            style="margin: 0 10px 0 0; padding: 0 10px"
            size="small"
            icon="el-icon-search"
            type="primary"
          ></c-button>
jxl committed
77
        </c-col>
huangxin committed
78 79 80 81
        <c-col :span="8">
          <c-checkbox v-model="model.bodgrp.rec.dircolflg"
            >Direct Collection</c-checkbox
          >
jxl committed
82
        </c-col>
huangxin committed
83
      </c-col>
84

jxl committed
85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102
      <c-col :span="12">
        <el-form-item label="Document Amount" prop="bodgrp.cbs.max.cur">
          <c-select
            disabled
            v-model="model.bodgrp.cbs.max.cur"
            style="width: 100%"
            placeholder="请选择Currency"
          >
            <el-option
              v-for="item in codes.cur"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </c-select>
        </el-form-item>
      </c-col>
huangxin committed
103
      <c-col :span="12">
jxl committed
104 105
        <el-form-item
          style="text-align: left"
106
          label-width="5px"
jxl committed
107 108 109
          prop="bodgrp.cbs.max.amt"
        >
          <c-input-currency
huangxin committed
110
            disabled
jxl committed
111 112 113
            v-model="model.bodgrp.cbs.max.amt"
            style="text-align: left; width: 100%"
            placeholder="请输入Document Amount"
huangxin committed
114 115 116
            @keyup.enter.native="
              defaultFunction('bodgrp.cbs.max.amt', model.bodgrp.cbs.max.amt)
            "
jxl committed
117 118 119
          ></c-input-currency>
        </el-form-item>
      </c-col>
huangxin committed
120
      <c-col :span="12">
121
        <el-form-item label="Open Amount" prop="bodgrp.cbs.opn1.cur">
jxl committed
122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137
          <c-select
            disabled
            v-model="model.bodgrp.cbs.opn1.cur"
            style="width: 100%"
            placeholder="请选择Currency"
          >
            <el-option
              v-for="item in codes.cur"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </c-select>
        </el-form-item>
      </c-col>
huangxin committed
138
      <c-col :span="12">
jxl committed
139 140
        <el-form-item
          style="text-align: left"
141
          label-width="5px"
jxl committed
142 143 144
          prop="bodgrp.cbs.opn1.amt"
        >
          <c-input-currency
huangxin committed
145
            disabled
jxl committed
146 147
            v-model="model.bodgrp.cbs.opn1.amt"
            style="text-align: left; width: 100%"
148
            placeholder="请输入Open Amount"
huangxin committed
149 150 151
            @keyup.enter.native="
              defaultFunction('bodgrp.cbs.opn1.amt', model.bodgrp.cbs.opn1.amt)
            "
jxl committed
152 153 154 155 156
          ></c-input-currency>
        </el-form-item>
      </c-col>
      <c-col :span="12">
        <el-form-item label="Order Date" prop="bodgrp.rec.rcvdat">
huangxin committed
157 158 159 160 161 162 163
          <c-date-picker
            type="date"
            disabled
            v-model="model.bodgrp.rec.rcvdat"
            style="width: 100%"
            placeholder="请选择Order Date"
          ></c-date-picker>
jxl committed
164
        </el-form-item>
huangxin committed
165 166
      </c-col>
      <c-col :span="12">
jxl committed
167
        <el-form-item label="Shipment date" prop="bodgrp.rec.shpdat">
huangxin committed
168 169 170 171 172 173
          <c-date-picker
            type="date"
            v-model="model.bodgrp.rec.shpdat"
            style="width: 100%"
            placeholder="请选择Shipment date"
          ></c-date-picker>
jxl committed
174
        </el-form-item>
huangxin committed
175 176 177
      </c-col>

      <c-col :span="12">
jxl committed
178
        <el-form-item label="Presentation Date" prop="bodgrp.rec.predat">
huangxin committed
179 180 181 182 183 184 185
          <c-date-picker
            type="date"
            disabled
            v-model="model.bodgrp.rec.predat"
            style="width: 100%"
            placeholder="请选择Presentation Date"
          ></c-date-picker>
jxl committed
186
        </el-form-item>
huangxin committed
187 188 189
      </c-col>

      <c-col :span="12">
jxl committed
190
        <el-form-item label="Dispatched on" prop="bodgrp.rec.advdat">
huangxin committed
191 192 193 194 195 196 197
          <c-date-picker
            type="date"
            disabled
            v-model="model.bodgrp.rec.advdat"
            style="width: 100%"
            placeholder="请选择Dispatched on"
          ></c-date-picker>
jxl committed
198
        </el-form-item>
huangxin committed
199
      </c-col>
jxl committed
200

huangxin committed
201
      <c-col :span="24">
jxl committed
202
        <el-form-item label="Collection Condition" prop="bodgrp.rec.doctypcod">
huangxin committed
203 204 205 206 207
          <c-select
            v-model="model.bodgrp.rec.doctypcod"
            style="width: 100%"
            placeholder="请选择Collection Condition"
          >
208 209 210 211 212 213 214
            <el-option
              v-for="item in codes.doctypcod"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
huangxin committed
215
          </c-select>
jxl committed
216
        </el-form-item>
huangxin committed
217
      </c-col>
jxl committed
218

huangxin committed
219
      <c-col :span="12">
jxl committed
220
        <el-form-item label="Maturity Date" prop="bodgrp.rec.matdat">
huangxin committed
221 222 223 224 225 226 227
          <c-date-picker
            type="date"
            disabled
            v-model="model.bodgrp.rec.matdat"
            style="width: 100%"
            placeholder="请选择Maturity Date"
          ></c-date-picker>
jxl committed
228
        </el-form-item>
huangxin committed
229 230 231
      </c-col>

      <c-col :span="12">
jxl committed
232
        <el-form-item label="发票类型" prop="bodgrp.rec.invtyp">
huangxin committed
233
          <c-select v-model="model.bodgrp.rec.invtyp" style="width: 100%">
234
            <el-option
235
              v-for="item in invtyp"
236 237 238 239 240
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
huangxin committed
241
          </c-select>
jxl committed
242
        </el-form-item>
huangxin committed
243 244 245
      </c-col>

      <c-col :span="12">
jxl committed
246
        <el-form-item label="Tenor Specification" prop="bodgrp.rec.matpercnt">
huangxin committed
247 248 249 250 251
          <c-input
            disabled
            v-model="model.bodgrp.rec.matpercnt"
            placeholder="请输入Tenor Specification"
          ></c-input>
jxl committed
252
        </el-form-item>
huangxin committed
253 254 255 256
      </c-col>
      <c-col :span="1" style="margin-left:-10px">
        <el-form-item label="Days"> </el-form-item>
      </c-col>
jxl committed
257

huangxin committed
258
      <c-col :span="24">
jxl committed
259
        <el-form-item label="Starting from" prop="bodgrp.rec.matperbeg">
huangxin committed
260 261 262 263 264 265
          <c-select
            disabled
            v-model="model.bodgrp.rec.matperbeg"
            style="width: 100%"
            placeholder="请选择Starting from"
          >
266 267 268 269 270 271 272
            <el-option
              v-for="item in codes.matperbeg"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
huangxin committed
273
          </c-select>
jxl committed
274
        </el-form-item>
huangxin committed
275
      </c-col>
jxl committed
276

huangxin committed
277
      <c-col :span="24">
jxl committed
278
        <el-form-item label="Tenor Details Text" prop="bodgrp.blk.bogdet">
huangxin committed
279 280 281 282 283 284 285 286
          <c-input
            type="textarea"
            :disabled="model.bodgrp.rec.doctypcod === 'P'"
            v-model="model.bodgrp.blk.bogdet"
            maxlength="43"
            show-word-limit
            placeholder="请输入Tenor Details Text"
          ></c-input>
jxl committed
287
        </el-form-item>
huangxin committed
288
      </c-col>
289

huangxin committed
290
      <!-- <c-col :span="24" style="height: 24px; margin-top: -10px">
291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322
        <el-form-item :label="model.botp.docgrdm.docdsclab" class="messageLabel">
          <c-button style="float: right" @click="addTableValue" type="primary">新增单据</c-button>
        </el-form-item>
      </c-col>
      <c-col :span="24" style="margin-bottom: 30px;">
        <c-table height="200px" style="text-align: center" :list="this.model.botp.docgrdm.docgrd || []"
          :paginationShow="false" :border="true">
          <el-table-column label="1st" width="auto">
            <template slot-scope="scope">
              <c-input v-model="scope.row.cmail1"></c-input>
            </template>

          </el-table-column>
          <el-table-column label="2st" width="auto">
            <template slot-scope="scope">
              <c-input v-model="scope.row.cmail2"></c-input>
            </template>
          </el-table-column>
          <el-table-column label="Document" prop="docnam" width="auto">
            <template slot-scope="scope">
              <c-select style="width: 100%" placeholder="请选择" v-model="scope.row.docnam">
                <el-option v-for="item in codeTable" :key="item.value" :label="item.label" :value="item.value">
                </el-option>
              </c-select>
            </template>
          </el-table-column>
          <el-table-column label="操作" width="170px" fixed="right">
            <template slot-scope="scope">
              <c-button @click="deleteTable(scope.$index)" type="primary">删除</c-button>
            </template>
          </el-table-column>
        </c-table>
huangxin committed
323
      </c-col> -->
huangxin committed
324 325 326 327 328 329 330 331 332 333
      <c-docpre
        :model="model"
        :argadr="{
          path: 'bodgrp.blk.docpre',
          grp: 'botp',
          code: 'docpre',
        }"
      ></c-docpre>

      <!-- <c-col :span="24">
huangxin committed
334
        <c-edit-table :model="model" v-bind="docgrd"> </c-edit-table>
huangxin committed
335
      </c-col> -->
huangxin committed
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
    </c-col>
    <!-- ====================右边======================= -->
    <c-col :span="11" :offset="1">
      <c-ptap
        :model="model"
        :argadr="{
          title: 'Drawer',
          grp: 'bodgrp',
          rol: 'drr',
        }"
        :disabled="true"
      >
      </c-ptap>
      <c-ptap
        :model="model"
        :argadr="{
          title: 'Collecting Bank',
          grp: 'bodgrp',
          rol: 'col',
        }"
        :disabled="true"
      >
      </c-ptap>
      <c-ptap
        :model="model"
        :argadr="{
          title: 'Drawee',
          grp: 'bodgrp',
          rol: 'dre',
        }"
        :disabled="true"
      >
      </c-ptap>
      <c-col :span="24">
        <el-form-item
          label="Country Code Risk Country!"
          prop="bodgrp.rec.stacty"
        >
          <c-select
            v-model="model.bodgrp.rec.stacty"
            style="width: 100%"
            placeholder="请选择Country Code Risk Country!"
          >
            <el-option
380 381 382 383 384 385
              v-for="item in codes.stacty"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
huangxin committed
386 387 388 389
          </c-select>
        </el-form-item>
      </c-col>
      <c-col :span="24">
390
        <el-form-item label="Goods Code" prop="bodgrp.rec.stagod">
huangxin committed
391 392 393 394 395 396
          <c-select
            v-model="model.bodgrp.rec.stagod"
            style="width: 100%"
            placeholder="请选择Goods Code"
          >
            <el-option
397 398 399 400 401 402
              v-for="item in codes.godcod"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
huangxin committed
403 404 405
          </c-select>
        </el-form-item>
      </c-col>
jxl committed
406
    </c-col>
huangxin committed
407
  </c-row>
jxl committed
408 409
</template>
<script>
huangxin committed
410
import Api from "~/service/Api";
wangren committed
411
import commonProcess from "~/mixin/commonProcess";
huangxin committed
412 413 414 415
import CodeTable from "~/config/CodeTable";
import Event from "~/model/Botame/Event";
import Utils from "~/utils";
import Ptap from "~/views/Public/Ptap";
huangxin committed
416
import Docpre from "~/views/Public/Docpre";
huangxin committed
417
export default {
huangxin committed
418 419 420 421
  components: {
    "c-ptap": Ptap,
    "c-docpre": Docpre,
  },
huangxin committed
422 423 424 425 426
  inject: ["root"],
  props: ["model", "codes"],
  mixins: [commonProcess],
  data() {
    return {
huangxin committed
427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450
      // docgrd: {
      //   columns: [
      //     {
      //       title: "lst",
      //       width: "80px",
      //       dataIndex: "cmail1",
      //       show: "input",
      //     },
      //     {
      //       title: "2nd",
      //       width: "80px",
      //       dataIndex: "cmail2",
      //       show: "input",
      //     },
      //     {
      //       title: "Document",
      //       width: "320px",
      //       dataIndex: "docnam",
      //       show: "select",
      //       code: "codeTable",
      //     },
      //   ],
      //   urls: "botp.docgrdm.docgrd",
      // },
huangxin committed
451 452 453

      invtyp: [{ label: "type1", value: "1" }],

huangxin committed
454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480
      // codeTable: [
      //   { label: "Airway Bills", value: "Airway Bills" },
      //   {
      //     label: "Beneficiary's Declaration",
      //     value: "Beneficiary's Declaration",
      //   },
      //   { label: "Bill of Lading Copies", value: "Bill of Lading Copies" },
      //   {
      //     label: "Bill of Lading Originals",
      //     value: "Bill of Lading Originals",
      //   },
      //   { label: "Certificate", value: "Certificate" },
      //   { label: "Certificate of Analysis", value: "Certificate of Analysis" },
      //   { label: "Certificate of Origin", value: "Certificate of Origin" },
      //   { label: "Certificate of Quality", value: "Certificate of Quality" },
      //   { label: "Certificate of Quantity", value: "Certificate of Quantity" },
      //   { label: "Commercial Invoice", value: "Commercial Invoice" },
      //   { label: "Courier Receipt", value: "Courier Receipt" },
      //   { label: "Draft", value: "Draft" },
      //   { label: "Export Licence", value: "Export Licence" },
      //   { label: "Fax Report", value: "Fax Report" },
      //   { label: "Inspection Cert", value: "Inspection Cert" },
      //   { label: "Insurance Policy", value: "Insurance Policy" },
      //   { label: "Packing List", value: "Packing List" },
      //   { label: "Shipment Advice", value: "Shipment Advice" },
      //   { label: "Weight List", value: "Weight List" },
      // ],
huangxin committed
481 482 483 484 485 486 487 488 489 490
      // newValue: {
      //   id: 0,
      //   cmail1: "",
      //   cmail2: "",
      //   docnam: "",
      //   description: "",
      //   serialNum: "",
      //   tableName: "",
      //   tcddoc: "",
      // },
huangxin committed
491
      // columns: ['0 0 "lst1" 100 ', '1 1 "lst2" 100', '2 2 "document" 200'],
492
    }
huangxin committed
493 494 495
  },
  methods: {
    ...Event,
496 497 498
    // change() {
    //   this.model.bodgrp.rec.matdat = this.model.oldbodgrp.rec.matdat;
    // },
huangxin committed
499 500 501 502 503 504 505 506 507
    // addTableValue(index) {
    //   var newTableValue = Object.assign({}, this.newValue);
    //   const serial = Utils.generateUUID();
    //   newTableValue.serialNum = serial;
    //   this.model.botp.docgrdm.docgrd.splice(index - 1, 0, newTableValue);
    //   },
    // deleteTable(index) {
    //   this.model.botp.docgrdm.docgrd.splice(index, 1);
    //     },
huangxin committed
508 509 510 511 512 513 514 515 516 517 518
    // async docpre() {
    //   let rtnmsg = await this.executeDefault('bodgrp.blk.docpre')
    //   if (rtnmsg.respCode == SUCCESS) {
    //     //TODO 处理数据逻辑
    //     this.updateModel(rtnmsg.data)
    //   }
    //   else {
    //     this.$notify.error({ title: '错误', message: '服务请求失败!' });
    //   }
    // },
  },
519 520 521 522
  // mounted() {
  //   this.change();
  //   console.log(this.model.bodgrp.rec.matdat);
  // },
523 524 525 526 527
  computed: {
    flag() {
      return this.model.bodgrp.drr.pts.adrelc == "";
    },
  },
huangxin committed
528 529 530
  created: function () {
    console.log(this.root);
  },
531
}
jxl committed
532 533 534
</script>
<style>
</style>