Detp.vue 13.9 KB
Newer Older
zhengxiaokui committed
1 2
<template>
  <div class="eibs-tab">
zhengxiaokui committed
3
    <c-row>
4
      <!-- =========================================左边============================================= -->
zhengxiaokui committed
5
      <c-col :span="11">
zhengxiaokui committed
6 7 8 9 10 11 12
        <!-- Available with -->
        <c-col :span="24">
          <el-form-item label="指定银行" prop="ledgrp.rec.avbwth">
            <c-select
              v-model="model.ledgrp.rec.avbwth"
              style="width: 100%"
              placeholder="请选择指定银行"
zhengxiaokui committed
13
              :code="codes.avbwth"
zhengxiaokui committed
14 15 16 17 18 19 20
            >
            </c-select>
          </el-form-item>
        </c-col>

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

37
        <!-- 名称地址 -->
zhengxiaokui committed
38
        <c-col :span="24">
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57
          <el-form-item
            label=""
            prop="ledgrp.avb.pts.adrblk"
            v-if="model.ledgrp.rec.avbwth != 'O'"
          >
            <c-input
              type="textarea"
              :rows="3"
              v-model="model.ledgrp.avb.pts.adrblk"
              maxlength="140"
              show-word-limit
              placeholder="请输入Address Block"
              :disabled="model.ledgrp.rec.avbwth!=''"
            ></c-input>
          </el-form-item>
        </c-col>
        <c-col :span="24">
          <el-form-item label="" prop="ledgrp.blk.avbwthtxt"
            v-if="model.ledgrp.rec.avbwth == 'O'">
zhengxiaokui committed
58 59 60 61
            <c-input
              type="textarea"
              :rows="3"
              v-model="model.ledgrp.blk.avbwthtxt"
62
              maxlength="140"
zhengxiaokui committed
63 64 65 66 67 68 69 70 71 72 73 74
              show-word-limit
              placeholder="请输入名称地址"
            ></c-input>
          </el-form-item>
        </c-col>

        <c-col :span="24">
          <el-form-item label="兑付方式" prop="ledgrp.rec.avbby">
            <c-select
              v-model="model.ledgrp.rec.avbby"
              style="width: 100%"
              placeholder="请选择兑付方式"
75
              :code="codes.avbby0"
zhengxiaokui committed
76 77 78 79 80
            >
            </c-select>
          </el-form-item>
        </c-col>

jianglong committed
81
        <!-- 远期付款指示 延期付款指示-->
zhengxiaokui committed
82
        <c-col :span="24">
83
          <el-form-item label="远期付款指示" prop="ledgrp.blk.defdet">
zhengxiaokui committed
84 85 86 87
            <c-input
              type="textarea"
              :rows="3"
              v-model="model.ledgrp.blk.defdet"
88
              maxlength="140"
zhengxiaokui committed
89
              show-word-limit
90 91
              placeholder="请输入远期付款指示"
              :disabled="defdetFlag"
zhengxiaokui committed
92 93 94 95
            ></c-input>
          </el-form-item>
        </c-col>

96
        <!-- drafts at 汇票期限 -->
zhengxiaokui committed
97 98
        <c-col :span="24">
          <el-form-item label="汇票期限" prop="ledgrp.blk.dftat">
99 100 101 102 103 104 105 106 107 108 109
            <c-fullbox>
              <c-input
                type="textarea"
                :rows="3"
                v-model="model.ledgrp.blk.dftat"
                maxlength="105"
                show-word-limit
                placeholder="请输入汇票期限"
                :disabled="blkDftatFlag"
              ></c-input>
              <template slot="footer">
110
                <!-- @click="onLcrdftatButtxmsel" -->
111 112 113 114
                <c-button
                  size="small"
                  type="primary"
                  icon="el-icon-search"
115
                  @click="showGridPromptDialog('letp.lcrdftat.buttxmsel', null, null,{TXT: 'ledgrp.blk.dftat'}, {TXT: false},'doxpDialog')"
116 117 118 119 120 121
                  :disabled="blkDftatFlag"
                >
                  ...
                </c-button>
              </template>
            </c-fullbox>
zhengxiaokui committed
122 123 124 125 126 127 128
          </el-form-item>
        </c-col>

        <c-col :span="24">
          <c-ptap
            :model="model"
            :argadr="{
129
              title: '付款人',
zhengxiaokui committed
130 131 132 133
              grp: 'ledgrp',
              rol: 'drw',
            }"
            :noRef="true"
134
            :onlySearch="false"
zhengxiaokui committed
135 136
            @onSeainf="onSeainf"
            @onAplpDet="onDrwpDet"
137
            :disabledExtkey="blkDftatFlag"
138
            :disabled="blkDftatFlag"
zhengxiaokui committed
139
          >
zhengxiaokui committed
140 141 142
          </c-ptap>
        </c-col>

143
        <!-- Dispatch from   货物转运地(港) -->
zhengxiaokui committed
144
        <c-col :span="24">
145
          <el-form-item label="货物转运地(港)" prop="ledgrp.rec.shpfro">
zhengxiaokui committed
146 147 148
            <c-input
              type="textarea"
              show-word-limit
149 150 151
              v-model="model.ledgrp.rec.shpfro"
              maxlength="65"
              placeholder="请输入"
zhengxiaokui committed
152 153 154 155
            ></c-input>
          </el-form-item>
        </c-col>

156
        <!-- Air-/Port of Departure -->
zhengxiaokui committed
157
        <c-col :span="24">
158
          <el-form-item label="始发航空站/港口" prop="ledgrp.rec.porloa">
zhengxiaokui committed
159
            <c-input
160 161 162 163 164
              type="textarea"
              v-model="model.ledgrp.rec.porloa"
              maxlength="65"
              show-word-limit
              placeholder="请输入"
zhengxiaokui committed
165 166 167 168
            ></c-input>
          </el-form-item>
        </c-col>

169
        <!-- Air-/Port of Destination -->
zhengxiaokui committed
170
        <c-col :span="24">
171
          <el-form-item label="目的航空站/港口" prop="ledgrp.rec.pordis">
zhengxiaokui committed
172 173
            <c-input
              type="textarea"
174 175
              v-model="model.ledgrp.rec.pordis"
              maxlength="65"
zhengxiaokui committed
176
              show-word-limit
177
              placeholder="请输入"
zhengxiaokui committed
178 179 180 181
            ></c-input>
          </el-form-item>
        </c-col>

jianglong committed
182
        <!-- 最终目的地 -->
zhengxiaokui committed
183
        <c-col :span="24">
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
          <el-form-item label="最终目的地" prop="ledgrp.rec.shpto">
            <c-input
              type="textarea"
              v-model="model.ledgrp.rec.shpto"
              maxlength="65"
              show-word-limit
              placeholder="最终目的地"
            ></c-input>
          </el-form-item>
        </c-col>

        <!-- Shipment Period -->
        <c-col :span="24">
          <el-form-item label="装运期" prop="ledgrp.blk.shpper">
            <c-input
              type="textarea"
              v-model="model.ledgrp.blk.shpper"
              maxlength="65"
              show-word-limit
              placeholder="请输入装运期"
            ></c-input>
          </el-form-item>
        </c-col>
      </c-col>

      <!-- =========================================右边============================================= -->
      <c-col :span="11" :offset="1">
        <!-- Mixed Payment Details -->
        <c-col :span="24">
          <el-form-item label="混合付款指示" prop="ledgrp.blk.mixdet">
zhengxiaokui committed
214 215
            <c-input
              type="textarea"
216 217 218
              :rows="4"
              v-model="model.ledgrp.blk.mixdet"
              maxlength="140"
zhengxiaokui committed
219
              show-word-limit
220 221
              placeholder="混合付款指示"
              :disabled="model.ledgrp.rec.avbby != 'M'"
zhengxiaokui committed
222 223 224 225
            ></c-input>
          </el-form-item>
        </c-col>

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

    <!-- <c-col :span="12">
      <el-form-item label="Presentation Period" prop="ledgrp.blk.preper">
        <c-input
          type="textarea"
          v-model="model.ledgrp.blk.preper"
          maxlength="35"
          show-word-limit
          placeholder="请输入Presentation Period"
        ></c-input>
      </el-form-item>
    </c-col>

    <c-col :span="12">
      <el-form-item
        label="Days of presentation period"
        prop="ledgrp.rec.prepers18"
      >
        <c-input
          v-model="model.ledgrp.rec.prepers18"
          placeholder="请输入Days of presentation period"
        ></c-input>
      </el-form-item>
    </c-col>

    <c-col :span="12">
      <c-button
        size="small"
        type="primary"
        icon="el-icon-search"
        @click="onPreperButtxmsel"
      >
        ...
      </c-button>
    </c-col> 
    
        <c-col :span="12">
      <el-form-item
        label="Presentation period text"
        prop="ledgrp.rec.prepertxts18"
      >
        <c-input
          v-model="model.ledgrp.rec.prepertxts18"
          maxlength="35"
          placeholder="请输入Presentation period text"
        ></c-input>
      </el-form-item>
    </c-col>-->


        <!-- 交单期限 Days of presentation period-->
        <c-col :span="24">
          <el-form-item label="交单期限" prop="ledgrp.rec.prepers18">
            <c-fullbox>
              <c-input
                v-model="model.ledgrp.rec.prepers18"
                placeholder="请输入Days of presentation period"
              ></c-input>
              <template slot="footer">
285
                <!-- @click="onPreperButtxmsel" -->
286 287 288 289
                <c-button
                  size="small"
                  type="primary"
                  icon="el-icon-search"
290 291
                  @click="showGridPromptDialog('letp.preper.buttxmsel', null, null,{TXT: 'ledgrp.rec.prepers18'}, {TXT: false},'doxpDialog')"
                  disabled
292 293 294 295 296 297 298 299 300 301 302 303
                >
                  ...
                </c-button>
              </template>
            </c-fullbox>
          </el-form-item>
        </c-col>

        <!-- Days of presentation period -->
        <c-col :span="24">
          <el-form-item label="" prop="ledgrp.rec.prepertxts18">
            <c-input
304
              v-model="model.ledgrp.rec.prepertxts18"
305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322
              placeholder="请输入交单期天数"
            ></c-input>
          </el-form-item>
        </c-col>

        <!-- Additional Details to  Charges  -->
        <c-col :span="24">
          <el-form-item label="附加收费详情" prop="ledgrp.blk.feetxt">
            <c-fullbox>
              <c-input
                type="textarea"
                :rows="6"
                v-model="model.ledgrp.blk.feetxt"
                maxlength="210"
                show-word-limit
                placeholder="请输入附加收费详情"
              ></c-input>
              <template slot="footer">
323
                <!-- @click="onChariaButtxmsel" -->
324 325 326 327
                <c-button
                  size="small"
                  type="primary"
                  icon="el-icon-search"
328
                  @click="showGridPromptDialog('letp.charia.buttxmsel', null, null,{TXT: 'ledgrp.blk.feetxt'}, {TXT: false},'doxpDialog')"
329 330 331 332 333 334 335 336
                >
                  ...
                </c-button>
              </template>
            </c-fullbox>
          </el-form-item>
        </c-col>

zhengxiaokui committed
337
        <!-- Own Charges Borne by -->
338 339
        <c-col :span="24">
          <el-form-item label="费用状况" prop="ledgrp.rec.chato">
zhengxiaokui committed
340 341 342 343
            <c-select
              v-model="model.ledgrp.rec.chato"
              style="width: 100%"
              placeholder="请选择"
344
              :code="codes.chadet"
zhengxiaokui committed
345 346 347 348 349
            >
            </c-select>
          </el-form-item>
        </c-col>

350 351 352
        <!-- country or region code -->
        <c-col :span="24">
          <el-form-item label="国家或地区代码" prop="ledgrp.rec.stacty">
zhengxiaokui committed
353 354 355
            <c-select
              v-model="model.ledgrp.rec.stacty"
              style="width: 100%"
356 357
              placeholder="请选择国家或地区代码"
              :code="codes.ctytxt"
zhengxiaokui committed
358 359 360 361 362
            >
            </c-select>
          </el-form-item>
        </c-col>

363 364 365
        <!-- 付款期限 Maxinum Tenor-->
        <c-col :span="24">
          <el-form-item label="付款期限(天)" prop="ledgrp.rec.tenmaxday">
zhengxiaokui committed
366
            <c-input
367 368 369 370
              v-model.number="model.ledgrp.rec.tenmaxday"
              placeholder="请输入"
              :disabled="model.ledgrp.rec.avbby == 'P'"
              maxlength="4"
371
              @keyup.enter.native="$event.target.blur()"
zhengxiaokui committed
372
            ></c-input>
373
            <!-- @keyup.enter.native="$event.target.blur()" :回车触发失去焦点发生的事件 -->
zhengxiaokui committed
374 375 376 377
          </el-form-item>
        </c-col>
      </c-col>
    </c-row>
zhengxiaokui committed
378 379 380
  </div>
</template>
<script>
381 382 383 384 385
import Api from '~/service/Api'
import commonProcess from '~/mixin/commonProcess'
import CodeTable from '~/config/CodeTable'
import Ptap from '~/views/Public/Ptap'
import Event from '~/model/Letopn/Event'
zhengxiaokui committed
386 387

export default {
388 389 390
  inject: ['root'],
  components: { 'c-ptap': Ptap },
  props: ['model', 'codes'],
wangren committed
391
  mixins: [commonProcess],
zhengxiaokui committed
392
  data() {
393 394 395 396
    return {}
  },
  methods: { 
    ...Event,
397 398 399 400 401 402 403 404 405 406 407 408
    // 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 = ''
    //   }
    // },
    // avbbykeyEvent() {
    //   if (this.model.ledgrp.rec.avbby == 'P') {
    //     this.model.ledgrp.rec.tenmaxday = 0
    //     this.model.ledgrp.blk.defdet = ''
    //   }
    //   if (this.model.ledgrp.rec.avbby == 'D'||this.model.ledgrp.rec.avbby =='M') {
409
        
410 411 412
    //     this.model.ledgrp.blk.defdet = '' //汇票期限置空
    //     this.model.ledgrp.drw.pts.extkey = ''//付款人置空
    //     this.model.ledgrp.drw.pts.adrblk = ''  //名称地址置空.pts.adrblk
413

414 415
    //   }
    // },
416
  
zhengxiaokui committed
417 418
  },
  created: function () {},
419 420 421 422 423
  computed: {
    avbFlag: {
      get() {
        return (
          this.model.ledgrp.rec.avbwth == 'A' ||
424 425
          this.model.ledgrp.rec.avbwth == 'S' ||
          this.model.ledgrp.rec.avbwth == ''
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
        )
      },
    },
    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
451
  watch: {
452
    'model.ledgrp.avb.pts.adrblk': {
zhengxiaokui committed
453
      handler(val, oldVal) {
454
        this.model.ledgrp.blk.avbwthtxt = val
zhengxiaokui committed
455 456 457 458
      },
      immediate: true,
    },
  },
459
}
zhengxiaokui committed
460
</script>
461
<style></style>