Detp.vue 11.7 KB
Newer Older
zhengxiaokui committed
1
<template>
xiameng committed
2
  <div class="eibs">
zhengxiaokui committed
3
    <c-row>
Eivi committed
4
      <!-- left -->
xiameng committed
5
      <c-col :span="12" style="padding-right: 20px;">
zhengxiaokui committed
6 7
        <!-- Available with -->
        <c-col :span="24">
jianglong committed
8
          <el-form-item label="可用银行" prop="ledgrp.rec.avbwth">
zhengxiaokui committed
9
            <c-select
Wuyuqiu committed
10
              v-model="model.ledgrp.rec.avbwth"
zhengxiaokui committed
11
              style="width: 100%"
jianglong committed
12
              placeholder="请选择可用银行"
Eivi committed
13
              :code="codes.avbwth"
14
              @change="avbwthEvent"
zhengxiaokui committed
15 16 17
            >
            </c-select>
          </el-form-item>
zhengxiaokui committed
18
        </c-col>
zhengxiaokui committed
19 20 21

        <c-col :span="24">
          <c-ptap
22
            v-if="model.ledgrp.rec.avbwth!='O'"
zhengxiaokui committed
23 24
            :model="model"
            :argadr="{
Eivi committed
25
              title: '',
zhengxiaokui committed
26 27 28 29
              grp: 'ledgrp',
              rol: 'avb',
            }"
            :noRef="true"
Wuyuqiu committed
30
            :onlySearch="true"
zhengxiaokui committed
31 32
            @onSeainf="onSeainf"
            @onAplpDet="onAvbpDet"
Wuyuqiu committed
33
            :disabledExtkey="!avbFlag"
zhengxiaokui committed
34 35
          >
          </c-ptap>
zhengxiaokui committed
36
        </c-col>
zhengxiaokui committed
37

Wuyuqiu committed
38 39 40 41 42 43 44 45 46 47 48 49 50 51
        <c-col :span="24">
          <el-form-item label="名称地址" prop="ledgrp.blk.avbwthtxt">
            <c-input
              type="textarea"
              :rows="3"
              v-model="model.ledgrp.blk.avbwthtxt"
              maxlength="140"
              show-word-limit
              placeholder="请输入名称地址"
              :disabled="model.ledgrp.rec.avbwth != 'O'"
            ></c-input>
          </el-form-item>
        </c-col>

zhengxiaokui committed
52
        <c-col :span="24">
jianglong committed
53
          <el-form-item label="兑付方式" prop="ledgrp.rec.avbby">
zhengxiaokui committed
54 55 56
            <c-select
              v-model="model.ledgrp.rec.avbby"
              style="width: 100%"
jianglong committed
57
              placeholder="请选择兑付方式"
zhengxiaokui committed
58
              :code="codes.avbby"
Wuyuqiu committed
59
              @change="avbbykeyEvent"
zhengxiaokui committed
60 61 62
            >
            </c-select>
          </el-form-item>
zhengxiaokui committed
63
        </c-col>
zhengxiaokui committed
64 65 66

        <c-col :span="24">
          <el-form-item
jianglong committed
67
            label="议付/延期付款指示"
zhengxiaokui committed
68 69 70 71 72 73 74 75
            prop="ledgrp.blk.defdet"
          >
            <c-input
              type="textarea"
              :rows="3"
              v-model="model.ledgrp.blk.defdet"
              maxlength="35"
              show-word-limit
jianglong committed
76
              placeholder="请输入议付延期付款指示"
Wuyuqiu committed
77
              :disabled="defdetFlag"
zhengxiaokui committed
78 79
            ></c-input>
          </el-form-item>
zhengxiaokui committed
80
        </c-col>
zhengxiaokui committed
81 82

        <c-col :span="24">
Eivi committed
83
          <el-form-item
jianglong committed
84
            label="汇票期限"
Eivi committed
85 86 87 88 89 90
            prop="ledgrp.blk.dftat"
            style="width: 100%"
          >
            <c-fullbox>
              <c-input
                type="textarea"
Wuyuqiu committed
91
                :rows="3"
Eivi committed
92
                v-model="model.ledgrp.blk.dftat"
Wuyuqiu committed
93
                maxlength="105"
Eivi committed
94
                show-word-limit
jianglong committed
95
                placeholder="请输入汇票期限"
Wuyuqiu committed
96
                :disabled="blkDftatFlag"
Eivi committed
97 98 99 100 101 102
              ></c-input>
              <template slot="footer">
                <c-button
                  style="margin-left: 10px; padding: 0 10px"
                  size="small"
                  type="primary"
Wuyuqiu committed
103 104
                  @click="onLcrdftatButtxmsel"
                  :disabled="blkDftatFlag"
Eivi committed
105 106 107 108 109
                >
                  ...
                </c-button>
              </template>
            </c-fullbox>
zhengxiaokui committed
110
          </el-form-item>
zhengxiaokui committed
111
        </c-col>
zhengxiaokui committed
112 113 114 115 116

        <c-col :span="24">
          <c-ptap
            :model="model"
            :argadr="{
jianglong committed
117
              title: '付款人',
zhengxiaokui committed
118 119 120 121
              grp: 'ledgrp',
              rol: 'drw',
            }"
            :noRef="true"
Wuyuqiu committed
122
            :onlySearch="false"
zhengxiaokui committed
123 124
            @onSeainf="onSeainf"
            @onAplpDet="onDrwpDet"
Wuyuqiu committed
125
            :disabled="blkDftatFlag"
Wuyuqiu committed
126
            :disabledExtkey="model.ledgrp.rec.avbby=='D'||model.ledgrp.rec.avbby=='M'||model.ledgrp.rec.avbby==''"
zhengxiaokui committed
127 128
          >
          </c-ptap>
zhengxiaokui committed
129
        </c-col>
Wuyuqiu committed
130 131
        <!-- Dispatch from -->
        <c-col :span="24">
jianglong committed
132
          <el-form-item label="装船/发运地" prop="ledgrp.rec.shpfro">
Wuyuqiu committed
133 134 135 136 137
            <c-input
              type="textarea"
              show-word-limit
              v-model="model.ledgrp.rec.shpfro"
              maxlength="65"
jianglong committed
138
              placeholder="请输入装船/发运地"
Wuyuqiu committed
139 140 141
            ></c-input>
          </el-form-item>
        </c-col>
Eivi committed
142

Wuyuqiu committed
143
        <c-col :span="24">
144
          <el-form-item label="始发(航空)站" prop="ledgrp.rec.porloa">
Wuyuqiu committed
145 146 147 148 149
            <c-input
              type="textarea"
              v-model="model.ledgrp.rec.porloa"
              maxlength="65"
              show-word-limit
jianglong committed
150
              placeholder="请输入始发(航空)站"
Wuyuqiu committed
151 152 153 154 155 156
            ></c-input>
          </el-form-item>
        </c-col>

        <c-col :span="24">
          <el-form-item
157
            label="终点(航空)站"
Wuyuqiu committed
158 159 160 161 162 163 164
            prop="ledgrp.rec.pordis"
          >
            <c-input
              type="textarea"
              v-model="model.ledgrp.rec.pordis"
              maxlength="65"
              show-word-limit
jianglong committed
165
              placeholder="请输入终点(航空)站"
Wuyuqiu committed
166 167 168
            ></c-input>
          </el-form-item>
        </c-col>
jianglong committed
169
        <!-- 最终目的地 -->
Wuyuqiu committed
170
        <c-col :span="24">
jianglong committed
171
          <el-form-item label="最终目的地" prop="ledgrp.rec.shpto">
Wuyuqiu committed
172 173 174 175 176
            <c-input
              type="textarea"
              v-model="model.ledgrp.rec.shpto"
              maxlength="65"
              show-word-limit
jianglong committed
177
              placeholder="请输入最终目的地"
Wuyuqiu committed
178 179 180 181 182 183
            ></c-input>
          </el-form-item>
        </c-col>

        <!-- Shipment Period -->
        <c-col :span="24">
jianglong committed
184
          <el-form-item label="装运期限" prop="ledgrp.blk.shpper">
Wuyuqiu committed
185 186 187 188 189
            <c-input
              type="textarea"
              v-model="model.ledgrp.blk.shpper"
              maxlength="65"
              show-word-limit
jianglong committed
190
              placeholder="请输入装运期限"
Wuyuqiu committed
191 192 193
            ></c-input>
          </el-form-item>
        </c-col>
zhengxiaokui committed
194 195
      </c-col>

Eivi committed
196
      <!-- right -->
xiameng committed
197
      <c-col :span="12" style="padding-left: 20px;">
zhengxiaokui committed
198
        <c-col :span="24">
jianglong committed
199
          <el-form-item label="混合付款" prop="ledgrp.blk.mixdet">
zhengxiaokui committed
200 201 202 203
            <c-input
              type="textarea"
              :rows="4"
              v-model="model.ledgrp.blk.mixdet"
Wuyuqiu committed
204
              maxlength="140"
zhengxiaokui committed
205
              show-word-limit
jianglong committed
206
              placeholder="请输入内容"
Wuyuqiu committed
207
              :disabled="model.ledgrp.rec.avbby != 'M'"
zhengxiaokui committed
208 209
            ></c-input>
          </el-form-item>
zhengxiaokui committed
210
        </c-col>
zhengxiaokui committed
211 212 213

        <!-- Days of presentation period -->
        <c-col :span="24">
jianglong committed
214
          <el-form-item label="交单期限" prop="ledgrp.rec.prepers18">
Eivi committed
215 216
            <c-fullbox>
              <c-input
217
                v-model.number="model.ledgrp.rec.prepers18"
jianglong committed
218
                placeholder="请输入交单期限"
Eivi committed
219 220 221 222 223
              ></c-input>
              <template slot="footer">
                <c-button
                  size="small"
                  type="primary"
xiameng committed
224
                  icon="el-icon-more"
Wuyuqiu committed
225
                  @click="onPreperButtxmsel"
226
                  disabled
Eivi committed
227
                >
xiameng committed
228
                  
Eivi committed
229 230 231
                </c-button>
              </template>
            </c-fullbox>
zhengxiaokui committed
232
          </el-form-item>
zhengxiaokui committed
233
        </c-col>
zhengxiaokui committed
234

Wuyuqiu committed
235 236 237 238
        <c-col :span="24">
          <el-form-item label="" prop="ledgrp.rec.prepertxts18">
            <c-input
              v-model="model.ledgrp.rec.prepertxts18"
wangna committed
239
              placeholder="请输入"
Wuyuqiu committed
240 241 242 243
            ></c-input>
          </el-form-item>
        </c-col>

zhengxiaokui committed
244 245
        <c-col :span="24">
          <el-form-item
jianglong committed
246
            label="附加收费详情"
zhengxiaokui committed
247 248
            prop="ledgrp.blk.feetxt"
          >
Eivi committed
249 250 251
            <c-fullbox>
              <c-input
                type="textarea"
Wuyuqiu committed
252
                :rows="6"
Eivi committed
253
                v-model="model.ledgrp.blk.feetxt"
Wuyuqiu committed
254
                maxlength="210"
Eivi committed
255
                show-word-limit
jianglong committed
256
                placeholder="请输入附加收费详情"
Eivi committed
257 258 259 260 261
              ></c-input>
              <template slot="footer">
                <c-button
                  size="small"
                  type="primary"
xiameng committed
262
                  icon="el-icon-more"
Wuyuqiu committed
263
                  @click="onChariaButtxmsel"
Eivi committed
264
                >
xiameng committed
265
                  
Eivi committed
266 267 268
                </c-button>
              </template>
            </c-fullbox>
zhengxiaokui committed
269
          </el-form-item>
zhengxiaokui committed
270
        </c-col>
zhengxiaokui committed
271 272

        <!-- Own Charges Borne by -->
Eivi committed
273
        <c-col :span="24">
jianglong committed
274
          <el-form-item label="收费条款" prop="ledgrp.rec.chato">
zhengxiaokui committed
275 276 277
            <c-select
              v-model="model.ledgrp.rec.chato"
              style="width: 100%"
jianglong committed
278
              placeholder="请选择收费条款"
Eivi committed
279
              :code="codes.chadet"
zhengxiaokui committed
280 281 282
            >
            </c-select>
          </el-form-item>
zhengxiaokui committed
283
        </c-col>
zhengxiaokui committed
284

Eivi committed
285
        <c-col :span="24">
jianglong committed
286
          <el-form-item label="国家地区代码" prop="ledgrp.rec.stacty">
zhengxiaokui committed
287 288 289
            <c-select
              v-model="model.ledgrp.rec.stacty"
              style="width: 100%"
jianglong committed
290
              placeholder="请选择国家地区代码"
Wuyuqiu committed
291
              :code="codes.ctytxt"
zhengxiaokui committed
292 293 294
            >
            </c-select>
          </el-form-item>
zhengxiaokui committed
295
        </c-col>
zhengxiaokui committed
296

Eivi committed
297
        <c-col :span="24">
xiameng committed
298
            <el-form-item label="最大期限/天" prop="ledgrp.rec.tenmaxday">
Eivi committed
299
              <c-input
300
                v-model.number="model.ledgrp.rec.tenmaxday"
jianglong committed
301
                placeholder="请输入远期最大期限"
Wuyuqiu committed
302 303 304 305 306 307 308
                :disabled="model.ledgrp.rec.avbby == 'P'"
                @keyup.enter.native="
                  defaultFunction(
                    'ledgrp.rec.tenmaxday',
                    model.ledgrp.rec.tenmaxday
                  )
                "
Eivi committed
309 310 311 312
              ></c-input>
            </el-form-item>
        </c-col>
      </c-col>
zhengxiaokui committed
313
    </c-row>
zhengxiaokui committed
314 315 316
  </div>
</template>
<script>
zhengxiaokui committed
317
import Api from "~/service/Api";
wangren committed
318
import commonProcess from "~/mixin/commonProcess";
zhengxiaokui committed
319 320 321
import CodeTable from "~/config/CodeTable";
import Ptap from "~/views/Public/Ptap";
import Event from "~/model/Letopn/Event";
zhengxiaokui committed
322 323

export default {
zhengxiaokui committed
324 325 326
  inject: ["root"],
  components: { "c-ptap": Ptap },
  props: ["model", "codes"],
wangren committed
327
  mixins: [commonProcess],
zhengxiaokui committed
328 329 330
  data() {
    return {};
  },
Wuyuqiu committed
331 332
  methods: {
    ...Event,
333 334 335 336 337 338
    avbwthEvent(){
      if (this.model.ledgrp.rec.avbwth != 'A'||this.model.ledgrp.rec.avbwth != 'O') {
        this.model.ledgrp.avb.pts.extkey = ''
        this.model.ledgrp.blk.avbwthtxt = ''
      }
    },
Wuyuqiu committed
339
    avbbykeyEvent() {
340
      if (this.model.ledgrp.rec.avbby == 'P') {
Wuyuqiu committed
341
        this.model.ledgrp.rec.tenmaxday = 0;
342
        this.model.ledgrp.blk.defdet = '';
Wuyuqiu committed
343 344
      }
      if (
345 346
        this.model.ledgrp.rec.avbby == 'D'||
        this.model.ledgrp.rec.avbby == 'M'
Wuyuqiu committed
347
      ) {
348 349 350
        this.model.ledgrp.blk.defdet = ''; //汇票期限置空
        this.model.ledgrp.drw.pts.extkey = ''; //付款人置空
        this.model.ledgrp.drw.pts.adrblk = ''; //名称地址置空.pts.adrblk
Wuyuqiu committed
351 352 353 354 355 356 357 358
      }
      this.executeCheck("ledgrp.rec.avbby").then((res) => {
        if (res.respCode == SUCCESS) {
          Utils.copyValueFromVO(this.model, res.data);
        }
      });
    },
  },
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
  computed: {
    avbFlag: {
      get() {
        return (
          this.model.ledgrp.rec.avbwth == 'A' ||
          this.model.ledgrp.rec.avbwth == 'S' 
        )
      },
    },
    defdetFlag: {
      get() {
        return (
          // this.model.ledgrp.rec.avbby == 'A' ||
          // this.model.ledgrp.rec.avbby == 'P' ||
          // this.model.ledgrp.rec.avbby == 'M' ||
          // this.model.ledgrp.rec.avbby == ''
          this.model.ledgrp.rec.avbby != 'D' &&
          this.model.ledgrp.rec.avbby != 'N'
        )
      },
    },
    blkDftatFlag: {
      get() {
        return (
          this.model.ledgrp.rec.avbby == 'D' ||
          this.model.ledgrp.rec.avbby == 'M' ||
          this.model.ledgrp.rec.avbby == ''
        )
      },
    },
  },
zhengxiaokui committed
390 391 392 393 394 395 396
  created: function () {},
  watch: {
    "model.ledgrp.avb.pts.adrblk": {
      handler(val, oldVal) {
        this.model.ledgrp.blk.avbwthtxt = val;
      },
      immediate: true,
zhengxiaokui committed
397
    },
zhengxiaokui committed
398 399
  },
};
zhengxiaokui committed
400 401 402
</script>
<style>
</style>