You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2721 lines
100 KiB

  1. <template>
  2. <div class="mod-config">
  3. <el-form :inline="true" label-position="top" label-width="100px" style="margin-top: 0px;">
  4. <el-form-item :label="'工厂编码:'">
  5. <el-input v-model="searchData.site" style="width: 120px"></el-input>
  6. </el-form-item>
  7. <el-form-item :label="'报关单号:'">
  8. <el-input v-model="searchData.declarationNo" clearable style="width: 120px"></el-input>
  9. </el-form-item>
  10. <el-form-item :label="'发货通知单:'">
  11. <el-input v-model="searchData.delNo" clearable style="width: 120px"></el-input>
  12. </el-form-item>
  13. <el-form-item :label="'CMC Invoice:'">
  14. <el-input v-model="searchData.cmcInvoice" clearable style="width: 120px"></el-input>
  15. </el-form-item>
  16. <el-form-item :label="'出口日期'" >
  17. <el-date-picker
  18. style="width: 120px"
  19. v-model="searchData.startDate"
  20. type="date"
  21. format="yyyy-MM-dd"
  22. value-format="yyyy-MM-dd"
  23. placeholder="选择日期">
  24. </el-date-picker>
  25. </el-form-item>
  26. <el-form-item :label="'To'" >
  27. <el-date-picker
  28. style="width: 120px"
  29. v-model="searchData.endDate"
  30. type="date"
  31. format="yyyy-MM-dd"
  32. value-format="yyyy-MM-dd"
  33. placeholder="选择日期">
  34. </el-date-picker>
  35. </el-form-item>
  36. <el-form-item label=" ">
  37. <el-button @click="searchTable()" type="primary" style="margin-left: 2px">{{'查询'}}</el-button>
  38. </el-form-item><br>
  39. <el-form-item label=" ">
  40. <el-button @click="chooseBrandType()" type="primary" style="margin-left: 2px">{{'导出报关要素'}}</el-button>
  41. </el-form-item>
  42. <el-form-item label=" ">
  43. <el-button @click="chooseHsCodeDescType" type="primary" style="margin-left: 2px">{{'导出报关单'}}</el-button>
  44. </el-form-item>
  45. <el-form-item label=" ">
  46. <el-button @click="exportInvoiceList()" type="primary" style="margin-left: 2px">{{'导出发票'}}</el-button>
  47. </el-form-item>
  48. <el-form-item label=" ">
  49. <el-button @click="exportPakingList()" type="primary" style="margin-left: 2px">{{'导出箱单'}}</el-button>
  50. </el-form-item>
  51. <el-form-item label=" ">
  52. <el-button @click="exportGoodsList()" type="primary" style="margin-left: 2px">{{'导出出口货物委托书'}}</el-button>
  53. </el-form-item>
  54. <!-- <el-form-item label=" ">
  55. <el-button @click="exportContract()" type="primary" style="margin-left: 2px">{{'导出合同'}}</el-button>
  56. </el-form-item>-->
  57. <el-form-item label=" ">
  58. <el-button @click="exportAllOpen()" type="primary" style="margin-left: 2px" :loading="exportAllLoading">{{'一键导出'}}</el-button>
  59. </el-form-item>
  60. </el-form>
  61. <el-table
  62. @row-click="changeData"
  63. highlight-current-row
  64. @current-change="handleCurrentChange"
  65. :height="height"
  66. :data="dataList"
  67. ref="mainTable"
  68. border
  69. v-loading="dataListLoading"
  70. style="width: 100%;">
  71. <el-table-column
  72. header-align="center"
  73. align="center"
  74. width="150"
  75. label="操作">
  76. <template slot-scope="scope">
  77. <a type="text" size="small" @click="deleteBG(scope.row)">删除报关单</a>
  78. </template>
  79. </el-table-column>
  80. <el-table-column
  81. v-for="(item,index) in columnList" :key="index"
  82. :sortable="item.columnSortable"
  83. :prop="item.columnProp"
  84. :header-align="item.headerAlign"
  85. :show-overflow-tooltip="item.showOverflowTooltip"
  86. :align="item.align"
  87. :fixed="item.fixed==''?false:item.fixed"
  88. :min-width="item.columnWidth"
  89. :label="item.columnLabel">
  90. <template slot-scope="scope">
  91. <span v-if="!item.columnHidden"> {{scope.row[item.columnProp]}}</span>
  92. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]"
  93. style="width: 100px; height: 80px"/></span>
  94. </template>
  95. </el-table-column>
  96. </el-table>
  97. <el-pagination
  98. @size-change="sizeChangeHandle"
  99. @current-change="currentChangeHandle"
  100. :current-page="pageIndex"
  101. :page-sizes="[20, 50, 100, 1000]"
  102. :page-size="pageSize"
  103. :total="totalPage"
  104. layout="total, sizes, prev, pager, next, jumper">
  105. </el-pagination>
  106. <el-tabs style="font-size: 12px;min-height: 200px" class="customer-tab" v-model="activeName" type="border-card" @tab-click="tabClick" >
  107. <el-tab-pane label="明细" name="detail">
  108. <el-table
  109. :height="height"
  110. :data="dataList2"
  111. border
  112. style="width: 100%;">
  113. <el-table-column
  114. v-for="(item,index) in columnList2" :key="index"
  115. v-if="shouldShowDetailColumn(item)"
  116. :sortable="item.columnSortable"
  117. :prop="item.columnProp"
  118. :header-align="item.headerAlign"
  119. :show-overflow-tooltip="item.showOverflowTooltip"
  120. :align="item.align"
  121. :fixed="item.fixed==''?false:item.fixed"
  122. :min-width="item.columnWidth"
  123. :label="item.columnLabel">
  124. <template slot-scope="scope">
  125. <span v-if="!item.columnHidden">{{ scope.row[item.columnProp] }}</span>
  126. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  127. </template>
  128. </el-table-column>
  129. </el-table>
  130. </el-tab-pane>
  131. </el-tabs>
  132. <el-dialog title="一键导出" :close-on-click-modal="false" style="top: -85px" v-drag :visible.sync="exportAllFlag" :width="'740px'">
  133. <el-form label-position="top" style="margin-left: 7px;margin-top: 5px;margin-bottom: 5px">
  134. <el-row :gutter="20">
  135. <el-col :span="6">
  136. <el-form-item :label="'合同协议号'" >
  137. <el-input v-model="exportHeader.contractNo" disabled></el-input>
  138. </el-form-item>
  139. </el-col>
  140. <el-col :span="6">
  141. <el-form-item :label="'运输方式'" >
  142. <el-input v-model="exportHeader.transportMode" disabled></el-input>
  143. </el-form-item>
  144. </el-col>
  145. <el-col :span="6">
  146. <el-form-item :label="'运抵国'" >
  147. <el-input v-model="exportHeader.arrivalCountry" disabled></el-input>
  148. </el-form-item>
  149. </el-col>
  150. <el-col :span="6">
  151. <el-form-item :label="'贸易国'" >
  152. <el-input v-model="exportHeader.tradeCountry" disabled></el-input>
  153. </el-form-item>
  154. </el-col>
  155. </el-row>
  156. <el-row :gutter="20" style="margin-top: 5px">
  157. <div class="custom-divider"><span class="text" style="left: 22%">报关要素</span></div>
  158. <!-- 报关要素-->
  159. <el-col :span="12">
  160. <el-form-item :label="'品牌'" >
  161. <el-radio v-model="brandType" label="境外品牌(其他)">境外品牌其他</el-radio>
  162. <el-radio v-model="brandType" label="无品牌">无品牌</el-radio>
  163. </el-form-item>
  164. </el-col>
  165. <el-col :span="12">
  166. <el-form-item :label="'品名类型'" >
  167. <el-radio v-model="hsCodeDescType" label="Y">中文</el-radio>
  168. <el-radio style="margin-left: 50px;" v-model="hsCodeDescType" label="N">英文</el-radio>
  169. </el-form-item>
  170. </el-col>
  171. <el-col :span="12">
  172. <el-form-item :label="'托/箱'" >
  173. <el-radio v-model="packageUnit" label="托"></el-radio>
  174. <el-radio v-model="packageUnit" label="箱"></el-radio>
  175. </el-form-item>
  176. </el-col>
  177. <el-col :span="12">
  178. <el-form-item :label="'重量'" >
  179. <el-radio v-model="declarationWeight" label="不显示">不显示</el-radio>
  180. <el-radio v-model="declarationWeight" label="显示">显示</el-radio>
  181. </el-form-item>
  182. </el-col>
  183. </el-row>
  184. <el-row :gutter="20">
  185. <div class="custom-divider">
  186. <span class="text">
  187. 发票
  188. <a v-if="!exportInvoice.templateName" href="#" @click="openTemplate('发票')" style="margin-left: 10px; color: #0130ff; text-decoration: none;">模版</a>
  189. <a v-else href="#" @click="openTemplate('发票')" style="margin-left: 10px; color: #0130ff; text-decoration: none;">{{exportInvoice.templateName}}</a>
  190. </span>
  191. </div>
  192. <!-- 发票-->
  193. <el-col :span="8" >
  194. <el-form-item :label="''" >
  195. <el-checkbox v-model="exportInvoice.hsCodeDesc">品名</el-checkbox>
  196. </el-form-item>
  197. </el-col>
  198. <el-col :span="8" >
  199. <el-form-item :label="''" >
  200. <el-checkbox v-model="exportInvoice.contractFlag">合同</el-checkbox>
  201. </el-form-item>
  202. </el-col>
  203. <el-col :span="8" >
  204. <el-form-item :label="''" >
  205. <el-checkbox v-model="exportInvoice.hsCodeFlag">Hs Code</el-checkbox>
  206. </el-form-item>
  207. </el-col>
  208. <el-col :span="12">
  209. <el-form-item :label="'品名类型'" >
  210. <el-radio v-model="exportInvoice.hsCodeDescType" label="Y">中文</el-radio>
  211. <el-radio style="margin-left: 50px;" v-model="exportInvoice.hsCodeDescType" label="N">英文</el-radio>
  212. </el-form-item>
  213. </el-col>
  214. <el-col :span="12">
  215. <el-form-item :label="' '" >
  216. <el-checkbox v-model="exportInvoice.showWeight">显示毛净重</el-checkbox>
  217. </el-form-item>
  218. </el-col>
  219. <el-col :span="24" style="">
  220. <el-form-item :label="'发票备注'" >
  221. <el-input type="textarea" :rows="2" v-model="exportInvoice.fpremark"></el-input>
  222. </el-form-item>
  223. </el-col>
  224. <!-- 箱单-->
  225. </el-row>
  226. <el-row :gutter="20" style="margin-top: 30px">
  227. <div class="custom-divider">
  228. <span class="text">
  229. 箱单
  230. <a v-if="!exportPaking.templateName" href="#" @click="openTemplate('箱单')" style="margin-left: 10px; color: #0130ff; text-decoration: none;">模版</a>
  231. <a v-else href="#" @click="openTemplate('箱单')" style="margin-left: 10px; color: #0130ff; text-decoration: none;">{{exportPaking.templateName}}</a>
  232. </span>
  233. </div>
  234. <el-col :span="8" >
  235. <el-form-item :label="''" >
  236. <el-checkbox v-model="exportPaking.goodsLabel">货物明细</el-checkbox>
  237. </el-form-item>
  238. </el-col>
  239. <el-col :span="12" >
  240. <el-form-item :label="''" >
  241. <el-checkbox v-model="exportPaking.highPalletFlag">是否显示最高托盘尺寸</el-checkbox>
  242. </el-form-item>
  243. </el-col>
  244. <el-col :span="8" v-show="currentRow.buNo==='03-RFID'">
  245. <el-form-item :label="''" >
  246. <el-checkbox v-model="exportPaking.upc">UPC</el-checkbox>
  247. </el-form-item>
  248. </el-col>
  249. <el-form-item :label="''" >
  250. <el-checkbox v-model="exportPaking.so">SO</el-checkbox>
  251. </el-form-item>
  252. <el-col :span="8">
  253. <el-form-item :label="'序号类型'" >
  254. <el-radio v-model="exportPaking.itemNo" label="Y">序号</el-radio>
  255. <el-radio v-model="exportPaking.itemNo" label="N">栈板号</el-radio>
  256. </el-form-item>
  257. </el-col>
  258. <!-- <el-col :span="8" v-show="currentRow.buNo==='01-Label' || currentRow.buNo==='03-RFID'">
  259. <el-form-item :label="'栈板重量参数'" >
  260. <el-input v-model="exportPaking.palletWeight"></el-input>
  261. </el-form-item>
  262. </el-col>-->
  263. <el-col :span="8">
  264. <el-form-item :label="'RFID Base Material'" >
  265. <el-checkbox v-model="exportPaking.material"></el-checkbox>
  266. </el-form-item>
  267. </el-col>
  268. <el-col :span="8">
  269. <el-form-item :label="'HS Code'" >
  270. <el-input :disabled="!exportPaking.material" v-model="exportPaking.hsCode"></el-input>
  271. </el-form-item>
  272. </el-col>
  273. <el-col :span="8">
  274. <el-form-item :label="'Non-reusable plastic packaging'" >
  275. <el-checkbox v-model="exportPaking.packaging"></el-checkbox>
  276. </el-form-item>
  277. </el-col>
  278. <el-col :span="8">
  279. <el-form-item :label="'plastic packaging'" >
  280. <el-input :disabled="!exportPaking.packaging" v-model="exportPaking.kgs"></el-input>
  281. </el-form-item>
  282. </el-col>
  283. <el-col :span="8">
  284. <el-form-item :label="'Shipping Mark'" >
  285. <el-input v-model="exportPaking.shippingMark"></el-input>
  286. </el-form-item>
  287. </el-col>
  288. <el-col :span="8" v-show="currentRow.buNo==='01-Label' || currentRow.buNo==='03-RFID'">
  289. <el-form-item :label="'制造地'" >
  290. <el-input v-model="exportPaking.origin"></el-input>
  291. </el-form-item>
  292. </el-col>
  293. <el-col :span="24" style="">
  294. <el-form-item :label="'箱单备注'" >
  295. <el-input type="textarea" :rows="2" v-model="exportPaking.xdremark"></el-input>
  296. </el-form-item>
  297. </el-col>
  298. </el-row>
  299. <el-row :gutter="20" style="margin-top: 30px">
  300. <!-- 出口货物委托书-->
  301. <div class="custom-divider"><span class="text" style="left: 25%">出口货物委托书</span></div>
  302. <el-col :span="8">
  303. <el-form-item :label="'贸易方式'" >
  304. <el-input v-model="exportGoods.salesMethod"></el-input>
  305. </el-form-item>
  306. </el-col>
  307. <el-col :span="8">
  308. <el-form-item :label="'币制'" >
  309. <el-input v-model="exportGoods.currency"></el-input>
  310. </el-form-item>
  311. </el-col>
  312. <el-col :span="8">
  313. <el-form-item :label="'货物产地'" >
  314. <el-input v-model="exportGoods.madeArea"></el-input>
  315. </el-form-item>
  316. </el-col>
  317. <el-col :span="8">
  318. <el-form-item :label="'发货港'" >
  319. <el-input v-model="exportGoods.sendPort"></el-input>
  320. </el-form-item>
  321. </el-col>
  322. <el-col :span="8">
  323. <el-form-item :label="'唛头'" >
  324. <el-input v-model="exportGoods.voyage"></el-input>
  325. </el-form-item>
  326. </el-col>
  327. <el-col :span="8">
  328. <el-form-item :label="'提/送货日期'" >
  329. <el-input v-model="exportGoods.deliveryGoodsDate"></el-input>
  330. </el-form-item>
  331. </el-col>
  332. <el-col :span="8">
  333. <el-form-item :label="'船期'" >
  334. <el-input v-model="exportGoods.shippingDate"></el-input>
  335. </el-form-item>
  336. </el-col>
  337. <el-col :span="16">
  338. <el-form-item :label="'发货人'" >
  339. <el-input type="textarea"
  340. :rows="4" v-model="exportGoods.shipper"></el-input>
  341. </el-form-item>
  342. </el-col>
  343. </el-row>
  344. </el-form>
  345. <!-- <el-table v-show="currentRow.buNo==='02-Hardtag' || currentRow.buNo==='04-MHM'"
  346. :height="240"
  347. :data="propertiesList"
  348. stripe
  349. highlight-current-row
  350. border :row-style="{ height: '30px' }"
  351. style="width: 100%;margin-top: 70px">
  352. <el-table-column
  353. prop="hsCode"
  354. header-align="center"
  355. align="center"
  356. label="HS Code">
  357. </el-table-column>
  358. <el-table-column
  359. prop="hsCodeDesc"
  360. header-align="center"
  361. align="center"
  362. label="品名">
  363. </el-table-column>
  364. <el-table-column
  365. prop="ehundred"
  366. header-align="center"
  367. align="center"
  368. label="品牌">
  369. <template slot-scope="scope">
  370. <el-select v-model="scope.row.brand" placeholder="请选择" style="width: 150px">
  371. <el-option :value="i.availableValue" :label="i.availableValue" v-for="(i,key) in scope.row.availableList" :key="key"></el-option>
  372. </el-select>
  373. </template>
  374. </el-table-column>
  375. </el-table>-->
  376. <el-table v-show="currentRow.buNo==='03-RFID'"
  377. :height="180"
  378. :data="notifyPartDetailList"
  379. stripe class="expClass"
  380. highlight-current-row
  381. border :row-style="{ height: '30px' }"
  382. style="width: 100%;margin-top: 70px">
  383. <el-table-column
  384. prop="pn"
  385. header-align="center"
  386. align="center"
  387. label="PN">
  388. </el-table-column>
  389. <el-table-column
  390. prop="ehundred"
  391. header-align="center"
  392. align="center"
  393. label="E100">
  394. <template slot-scope="scope">
  395. <el-input v-model="scope.row.ehundred" style="width: 100px;"></el-input>
  396. </template>
  397. </el-table-column>
  398. <el-table-column
  399. prop="lossratio"
  400. header-align="center"
  401. align="center"
  402. label="纯FSC纸重量损耗">
  403. <template slot-scope="scope">
  404. <el-input v-model="scope.row.lossratio" style="width: 100px;"></el-input>
  405. </template>
  406. </el-table-column>
  407. </el-table>
  408. <el-footer style="height:40px;margin-top: 80px;text-align:center">
  409. <el-button type="primary" @click="exportAll()">导出Excel</el-button>
  410. <el-button type="success" @click="exportAllPdf()">导出PDF</el-button>
  411. <el-button type="info" @click="exportAllFlag=false">关闭</el-button>
  412. </el-footer>
  413. </el-dialog>
  414. <el-dialog title="导出报关要素" :close-on-click-modal="false" v-drag :visible.sync="brandTypeFlag"
  415. :width="(currentRow.buNo==='02-Hardtag' || currentRow.buNo==='04-MHM')?'600px':'300px'">
  416. <el-form label-position="top" style="margin-left: 7px;margin-top: 10px;margin-bottom: 20px">
  417. <el-row :gutter="20">
  418. <el-col :span="(currentRow.buNo==='02-Hardtag' || currentRow.buNo==='04-MHM')?12:24">
  419. <el-form-item :label="'品牌'" >
  420. <el-radio v-model="brandType" label="境外品牌(其他)">境外品牌其他</el-radio>
  421. <el-radio v-model="brandType" label="无品牌">无品牌</el-radio>
  422. </el-form-item>
  423. </el-col>
  424. <el-col :span="(currentRow.buNo==='02-Hardtag' || currentRow.buNo==='04-MHM')?12:24">
  425. <el-form-item :label="'品名类型'" >
  426. <el-radio v-model="hsCodeDescType" label="Y">中文</el-radio>
  427. <el-radio style="margin-left: 102px;" v-model="hsCodeDescType" label="N">英文</el-radio>
  428. </el-form-item>
  429. </el-col>
  430. </el-row>
  431. </el-form>
  432. <el-table v-show="currentRow.buNo==='02-Hardtag' || currentRow.buNo==='04-MHM'"
  433. :height="240"
  434. :data="propertiesList"
  435. stripe
  436. highlight-current-row
  437. border :row-style="{ height: '30px' }"
  438. style="width: 100%;">
  439. <el-table-column
  440. prop="hsCode"
  441. header-align="center"
  442. align="center"
  443. label="HS Code">
  444. </el-table-column>
  445. <el-table-column
  446. prop="hsCodeDesc"
  447. header-align="center"
  448. align="center"
  449. label="品名">
  450. </el-table-column>
  451. <el-table-column
  452. prop="ehundred"
  453. header-align="center"
  454. align="center"
  455. label="品牌">
  456. <template slot-scope="scope">
  457. <el-select v-model="scope.row.brand" placeholder="请选择" style="width: 150px">
  458. <el-option :value="i.availableValue" :label="i.availableValue" v-for="(i,key) in scope.row.availableList" :key="key"></el-option>
  459. </el-select>
  460. </template>
  461. </el-table-column>
  462. </el-table>
  463. <el-footer style="height:40px;margin-top: 10px;text-align:center">
  464. <el-button type="primary" @click="downloadDeclarationElements()">确定</el-button>
  465. <el-button type="primary" @click="brandTypeFlag=false">关闭</el-button>
  466. </el-footer>
  467. </el-dialog>
  468. <el-dialog title="导出报关单" :close-on-click-modal="false" v-drag :visible.sync="declarationFlag" width="300px">
  469. <el-form label-position="top" style="margin-left: 7px;margin-top: 10px;">
  470. <el-row :gutter="20">
  471. <el-col :span="24">
  472. <el-form-item :label="'品名类型'" >
  473. <el-radio v-model="hsCodeDescType" label="Y">中文</el-radio>
  474. <el-radio v-model="hsCodeDescType" label="N">英文</el-radio>
  475. </el-form-item>
  476. </el-col>
  477. <el-col :span="24">
  478. <el-form-item :label="'托/箱'" >
  479. <el-radio v-model="packageUnit" label="托"></el-radio>
  480. <el-radio v-model="packageUnit" label="箱"></el-radio>
  481. </el-form-item>
  482. </el-col>
  483. <el-col :span="24">
  484. <el-form-item :label="'重量'" >
  485. <el-radio v-model="declarationWeight" label="不显示">不显示</el-radio>
  486. <el-radio v-model="declarationWeight" label="显示">显示</el-radio>
  487. </el-form-item>
  488. </el-col>
  489. </el-row>
  490. </el-form>
  491. <el-footer style="height:40px;margin-top: 10px;text-align:center">
  492. <el-button type="primary" @click="downloadDeclaration()()">确定</el-button>
  493. <el-button type="primary" @click="declarationFlag=false">关闭</el-button>
  494. </el-footer>
  495. </el-dialog>
  496. <el-dialog title="导出发票" :close-on-click-modal="false" v-drag :visible.sync="exportInvoiceFlag" width="450px">
  497. <el-form label-position="top" style="margin-left: 2px;margin-top: 10px;">
  498. <el-row :gutter="20">
  499. <el-col :span="24">
  500. <el-form-item :label="''" >
  501. <template #label>
  502. <span slot="label" style="" class="big-label">
  503. <a href="#" @click="openTemplate('发票')">发票模版</a>
  504. </span>
  505. </template>
  506. <el-input v-model="exportInvoice.templateName" disabled ></el-input>
  507. </el-form-item>
  508. </el-col>
  509. <el-col :span="12" >
  510. <el-form-item :label="''" >
  511. <el-checkbox v-model="exportInvoice.hsCodeDesc">品名</el-checkbox>
  512. </el-form-item>
  513. </el-col>
  514. <el-col :span="12" >
  515. <el-form-item :label="''" >
  516. <el-checkbox v-model="exportInvoice.hsCodeFlag">Hs Code</el-checkbox>
  517. </el-form-item>
  518. </el-col>
  519. <el-col :span="12" >
  520. <el-form-item :label="''" >
  521. <el-checkbox v-model="exportInvoice.contractFlag">合同</el-checkbox>
  522. </el-form-item>
  523. </el-col>
  524. <el-col :span="12" >
  525. <el-form-item :label="''" >
  526. <el-checkbox v-model="exportInvoice.goodsLabel">货物明细</el-checkbox>
  527. </el-form-item>
  528. </el-col>
  529. <el-col :span="12">
  530. <el-form-item :label="'品名类型'" >
  531. <el-radio v-model="exportInvoice.hsCodeDescType" label="Y">中文</el-radio>
  532. <el-radio v-model="exportInvoice.hsCodeDescType" label="N">英文</el-radio>
  533. </el-form-item>
  534. </el-col>
  535. <el-col :span="12">
  536. <el-form-item :label="' '" >
  537. <el-checkbox v-model="exportInvoice.showWeight">显示毛净重</el-checkbox>
  538. </el-form-item>
  539. </el-col>
  540. <el-col :span="12">
  541. <el-form-item :label="'RFID Base Material'" >
  542. <el-checkbox v-model="exportInvoice.material"></el-checkbox>
  543. </el-form-item>
  544. </el-col>
  545. <el-col :span="12">
  546. <el-form-item :label="'HS Code'" >
  547. <el-input :disabled="!exportInvoice.material" v-model="exportInvoice.hsCode"></el-input>
  548. </el-form-item>
  549. </el-col>
  550. <el-col :span="12">
  551. <el-form-item :label="'Non-reusable plastic packaging'" >
  552. <el-checkbox v-model="exportInvoice.packaging"></el-checkbox>
  553. </el-form-item>
  554. </el-col>
  555. <el-col :span="12">
  556. <el-form-item :label="'plastic packaging'" >
  557. <el-input :disabled="!exportInvoice.packaging" v-model="exportInvoice.kgs"></el-input>
  558. </el-form-item>
  559. </el-col>
  560. <el-col :span="12" v-show="currentRow.buNo==='01-Label' || currentRow.buNo==='03-RFID'">
  561. <el-form-item :label="'制造地'" >
  562. <el-input v-model="exportInvoice.origin"></el-input>
  563. </el-form-item>
  564. </el-col>
  565. <el-col :span="24" style="">
  566. <el-form-item :label="'备注'" >
  567. <el-input type="textarea" :rows="3" v-model="exportInvoice.fpremark"></el-input>
  568. </el-form-item>
  569. </el-col>
  570. </el-row>
  571. </el-form>
  572. <el-table v-show="currentRow.buNo==='03-RFID'"
  573. :height="240"
  574. :data="notifyPartDetailList"
  575. stripe class="expClass"
  576. highlight-current-row
  577. border :row-style="{ height: '30px' }"
  578. style="width: 100%;margin-top: 60px">
  579. <el-table-column
  580. prop="pn"
  581. header-align="center"
  582. align="center"
  583. label="PN">
  584. </el-table-column>
  585. <el-table-column
  586. prop="ehundred"
  587. header-align="center"
  588. align="center"
  589. label="E100">
  590. <template slot-scope="scope">
  591. <el-input v-model="scope.row.ehundred" style="width: 100px;"></el-input>
  592. </template>
  593. </el-table-column>
  594. <el-table-column
  595. prop="lossratio"
  596. header-align="center"
  597. align="center"
  598. label="纯FSC纸重量损耗">
  599. <template slot-scope="scope">
  600. <el-input v-model="scope.row.lossratio" style="width: 100px;"></el-input>
  601. </template>
  602. </el-table-column>
  603. </el-table>
  604. <el-footer style="height:40px;margin-top: 70px;text-align:center">
  605. <el-button type="primary" @click="downloadInvoice()">确定</el-button>
  606. <el-button type="primary" @click="exportInvoiceFlag=false">关闭</el-button>
  607. </el-footer>
  608. </el-dialog>
  609. <el-dialog title="导出箱单" :close-on-click-modal="false" v-drag :visible.sync="exportPakingFlag" width="450px">
  610. <el-form label-position="top" style="margin-left: 2px;margin-top: 10px;">
  611. <el-row :gutter="20">
  612. <el-col :span="24">
  613. <el-form-item :label="''" >
  614. <template #label>
  615. <span slot="label" style="" class="big-label">
  616. <a href="#" @click="openTemplate('箱单')">箱单模版</a>
  617. </span>
  618. </template>
  619. <el-input v-model="exportPaking.templateName" disabled ></el-input>
  620. </el-form-item>
  621. </el-col>
  622. <el-col :span="12" v-show="currentRow.buNo==='03-RFID'">
  623. <el-form-item :label="''" >
  624. <el-checkbox v-model="exportPaking.upc">UPC</el-checkbox>
  625. </el-form-item>
  626. </el-col>
  627. <el-col :span="12" v-show="currentRow.buNo==='03-RFID'">
  628. <el-form-item :label="''" >
  629. <el-checkbox v-model="exportPaking.so">SO</el-checkbox>
  630. </el-form-item>
  631. </el-col>
  632. <el-col :span="12">
  633. <el-form-item :label="'序号类型'" >
  634. <el-radio v-model="exportPaking.itemNo" label="Y">序号</el-radio>
  635. <el-radio v-model="exportPaking.itemNo" label="N">栈板号</el-radio>
  636. </el-form-item>
  637. </el-col>
  638. <el-col :span="12" v-show="currentRow.buNo==='04-MHM'">
  639. <el-form-item :label="'品名类型'" >
  640. <el-radio v-model="exportPaking.hsCodeDescType" label="Y">中文</el-radio>
  641. <el-radio v-model="exportPaking.hsCodeDescType" label="N">英文</el-radio>
  642. </el-form-item>
  643. </el-col>
  644. <!-- <el-col :span="12" >
  645. <el-form-item :label="''" >
  646. <el-checkbox v-model="exportPaking.boxChange">显示箱数零头</el-checkbox>
  647. </el-form-item>
  648. </el-col>-->
  649. <el-col :span="12" >
  650. <el-form-item :label="' '" >
  651. <el-checkbox v-model="exportPaking.goodsLabel">货物明细</el-checkbox>
  652. </el-form-item>
  653. </el-col>
  654. <el-col :span="12" >
  655. <el-form-item :label="' '" >
  656. <el-checkbox v-model="exportPaking.highPalletFlag">是否显示最高托盘尺寸</el-checkbox>
  657. </el-form-item>
  658. </el-col>
  659. <el-col :span="12">
  660. <el-form-item :label="'Shipping Mark'" >
  661. <el-input v-model="exportPaking.shippingMark"></el-input>
  662. </el-form-item>
  663. </el-col>
  664. <!-- <el-col :span="12" v-show="currentRow.buNo==='01-Label' || currentRow.buNo==='03-RFID'">
  665. <el-form-item :label="'栈板重量参数'" >
  666. <el-input v-model="exportPaking.palletWeight"></el-input>
  667. </el-form-item>
  668. </el-col>-->
  669. <el-col :span="12">
  670. <el-form-item :label="'RFID Base Material'" >
  671. <el-checkbox v-model="exportPaking.material"></el-checkbox>
  672. </el-form-item>
  673. </el-col>
  674. <el-col :span="12">
  675. <el-form-item :label="'HS Code'" >
  676. <el-input :disabled="!exportPaking.material" v-model="exportPaking.hsCode"></el-input>
  677. </el-form-item>
  678. </el-col>
  679. <el-col :span="12">
  680. <el-form-item :label="'Non-reusable plastic packaging'" >
  681. <el-checkbox v-model="exportPaking.packaging"></el-checkbox>
  682. </el-form-item>
  683. </el-col>
  684. <el-col :span="12">
  685. <el-form-item :label="'plastic packaging'" >
  686. <el-input :disabled="!exportPaking.packaging" v-model="exportPaking.kgs"></el-input>
  687. </el-form-item>
  688. </el-col>
  689. <el-col :span="12" v-show="currentRow.buNo==='01-Label' || currentRow.buNo==='03-RFID'">
  690. <el-form-item :label="'制造地'" >
  691. <el-input v-model="exportPaking.origin"></el-input>
  692. </el-form-item>
  693. </el-col>
  694. <el-col :span="24" style="">
  695. <el-form-item :label="'备注'" >
  696. <el-input type="textarea" :rows="3" v-model="exportPaking.xdremark"></el-input>
  697. </el-form-item>
  698. </el-col>
  699. </el-row>
  700. </el-form>
  701. <el-table v-show="currentRow.buNo==='03-RFID'"
  702. :height="240"
  703. :data="notifyPartDetailList"
  704. stripe class="expClass"
  705. highlight-current-row
  706. border :row-style="{ height: '30px' }"
  707. style="width: 100%;margin-top: 60px">
  708. <el-table-column
  709. prop="pn"
  710. header-align="center"
  711. align="center"
  712. label="PN">
  713. </el-table-column>
  714. <el-table-column
  715. prop="ehundred"
  716. header-align="center"
  717. align="center"
  718. label="E100">
  719. <template slot-scope="scope">
  720. <el-input v-model="scope.row.ehundred" style="width: 100px;"></el-input>
  721. </template>
  722. </el-table-column>
  723. <el-table-column
  724. prop="lossratio"
  725. header-align="center"
  726. align="center"
  727. label="纯FSC纸重量损耗">
  728. <template slot-scope="scope">
  729. <el-input v-model="scope.row.lossratio" style="width: 100px;"></el-input>
  730. </template>
  731. </el-table-column>
  732. </el-table>
  733. <el-footer style="height:40px;margin-top: 70px;text-align:center">
  734. <el-button type="primary" @click="downloadPackingList()">确定</el-button>
  735. <el-button type="primary" @click="exportPakingFlag=false">关闭</el-button>
  736. </el-footer>
  737. </el-dialog>
  738. <el-dialog title="导出出口货物委托书" :close-on-click-modal="false" v-drag :visible.sync="exportGoodsFlag" width="500px">
  739. <el-form label-position="top" style="margin-left: 7px;margin-top: 10px;">
  740. <el-row :gutter="20">
  741. <el-col :span="12">
  742. <el-form-item :label="'品名类型'" >
  743. <el-radio v-model="exportGoods.hsCodeDescType" label="Y">中文</el-radio>
  744. <el-radio v-model="exportGoods.hsCodeDescType" label="N">英文</el-radio>
  745. </el-form-item>
  746. </el-col>
  747. <el-col :span="12">
  748. <el-form-item :label="'贸易方式'" >
  749. <el-input v-model="exportGoods.salesMethod"></el-input>
  750. </el-form-item>
  751. </el-col>
  752. <el-col :span="12">
  753. <el-form-item :label="'币制'" >
  754. <el-input v-model="exportGoods.currency"></el-input>
  755. </el-form-item>
  756. </el-col>
  757. <el-col :span="12">
  758. <el-form-item :label="'货物产地'" >
  759. <el-input v-model="exportGoods.madeArea"></el-input>
  760. </el-form-item>
  761. </el-col>
  762. <el-col :span="12">
  763. <el-form-item :label="'发货港'" >
  764. <el-input v-model="exportGoods.sendPort"></el-input>
  765. </el-form-item>
  766. </el-col>
  767. <el-col :span="12">
  768. <el-form-item :label="'唛头'" >
  769. <el-input v-model="exportGoods.voyage"></el-input>
  770. </el-form-item>
  771. </el-col>
  772. <el-col :span="12">
  773. <el-form-item :label="'提/送货日期'" >
  774. <el-input v-model="exportGoods.deliveryGoodsDate"></el-input>
  775. </el-form-item>
  776. </el-col>
  777. <el-col :span="12">
  778. <el-form-item :label="'船期'" >
  779. <el-input v-model="exportGoods.shippingDate"></el-input>
  780. </el-form-item>
  781. </el-col>
  782. <el-col :span="24">
  783. <el-form-item :label="'发货人'" >
  784. <el-input type="textarea"
  785. :rows="4" v-model="exportGoods.shipper"></el-input>
  786. </el-form-item>
  787. </el-col>
  788. </el-row>
  789. </el-form>
  790. <el-footer style="height:40px;margin-top: 80px;text-align:center">
  791. <el-button type="primary" @click="downloadExportGoods()">确定</el-button>
  792. <el-button type="primary" @click="exportGoodsFlag=false">关闭</el-button>
  793. </el-footer>
  794. </el-dialog>
  795. <el-dialog title="模版" @close="closeTemplateDialog" @open="openTemplateDialog" :visible.sync="templateFlag" width="559px" v-drag>
  796. <el-form inline="inline" label-position="top" :model="templateData" style="margin-left: 7px;margin-top: -5px;">
  797. <el-form-item label="模版名称">
  798. <el-input v-model="templateData.name" clearable style="width: 150px"></el-input>
  799. </el-form-item>
  800. <el-form-item label="运输方式">
  801. <el-input v-model="templateData.shippingMode" clearable style="width: 150px"></el-input>
  802. </el-form-item>
  803. <el-form-item label=" ">
  804. <el-button type="primary" style="padding: 3px 12px" @click="searchTemplateList()">查询</el-button>
  805. </el-form-item>
  806. </el-form>
  807. <el-table
  808. :height="height + 110"
  809. :data="templateList"
  810. stripe
  811. highlight-current-row
  812. border
  813. @row-dblclick="templateRowDblclick"
  814. style="width: 100%;">
  815. <el-table-column
  816. prop="buNo"
  817. header-align="center"
  818. align="center"
  819. label="BuNo">
  820. </el-table-column>
  821. <el-table-column
  822. prop="name"
  823. header-align="center"
  824. align="center"
  825. label="模版名称">
  826. </el-table-column>
  827. <el-table-column
  828. prop="shippingMode"
  829. header-align="center"
  830. align="center"
  831. label="运输方式">
  832. </el-table-column>
  833. </el-table>
  834. <el-footer style="height:40px;margin-top: 10px;text-align:center">
  835. <el-button @click="templateFlag = false">关闭</el-button>
  836. </el-footer>
  837. </el-dialog>
  838. </div>
  839. </template>
  840. <script>
  841. import {} from "@/api/sysLanguage.js"
  842. import {
  843. searchDeclarationHeader,
  844. searchDeclarationDetail,
  845. deleteDeclaration,
  846. downloadDeclarationElements,
  847. getNotifyPartDetail,
  848. getCustomerInfo,
  849. searchTemplateList,
  850. getPropertiesListByDeclaration,
  851. searchEcssCoDelPalletHeaderData
  852. }from "@/api/ecss/ecss.js"
  853. import { getTableUserListLanguage} from "@/api/table.js"
  854. import {getTableDefaultListLanguage} from "../../../api/table";
  855. import {EventBus} from "../../../main";
  856. import ExportUtil from "@/utils/export";
  857. export default {
  858. name: "declaration",
  859. components:{
  860. },
  861. data() {
  862. return {
  863. bizhi:'',
  864. exportAllFlag:false,
  865. templateFlag:false,
  866. templateData:{
  867. type:'',
  868. buNo:'',
  869. customName:'',
  870. name:'',
  871. shippingMode:''
  872. },
  873. templateList:[],
  874. customerInfoList:[],
  875. notifyPartDetailList:[],
  876. propertiesList:[],
  877. currentRow:{},
  878. exportHeader:{
  879. contractNo:'',
  880. transportMode:'',
  881. arrivalCountry:'',
  882. tradeCountry:''
  883. },
  884. exportGoodsFlag:false,
  885. exportGoods:{
  886. salesMethod:'EXW',
  887. currency: 'USD',
  888. madeArea: 'Nantong, China',
  889. sendPort:'Shanghai, China',
  890. deliveryGoodsDate:'',
  891. voyage :'',
  892. shippingDate:'',
  893. hsCodeDescType:'N',
  894. shipper:'Checkpoint Commercial (Shanghai) Co., Ltd. 保点贸易(上海)有限公司\t\t\t\t\t\t\n' +
  895. 'Room 1411, No. 31, Lane 2419, Hunan Road, Pudong New Area, Shanghai\t\t\t\t\t\t\n' +
  896. '电话/Tel: (86-21)38112888 传真/Fax: (86-21)38112990\t\t\t\t\t\t\n' +
  897. '上海市浦东新区沪南路2419弄31号1411室\t\t\t\t\t\t\n'
  898. },
  899. brandTypeFlag:false,
  900. declarationFlag:false,
  901. exportInvoiceFlag:false,
  902. exportInvoice:{
  903. origin:"made in china",
  904. templateName:'',
  905. hsCodeDesc:'',
  906. contractFlag:'',
  907. packaging:'',
  908. kgs:'',
  909. hsCode:'',
  910. material:'',
  911. hsCodeDescType:'',
  912. goodsLabel:true,
  913. hsCodeFlag:true,
  914. showWeight:false,
  915. fpremark:''
  916. },
  917. exportPakingFlag:false,
  918. exportPaking:{
  919. origin:"made in china",
  920. itemNo:'',
  921. upc:'',
  922. so:'',
  923. shippingMark:'',
  924. palletWeight:'',
  925. templateName:'',
  926. hsCodeDesc:'',
  927. contractFlag:'',
  928. packaging:'',
  929. kgs:'',
  930. hsCode:'',
  931. material:'',
  932. hsCodeDescType:'',
  933. goodsLabel:true,
  934. boxChange:'',
  935. xdremark:'',
  936. highPalletFlag:''
  937. },
  938. brandType:'',
  939. hsCodeDescType:'Y',
  940. packageUnit: '托',
  941. declarationWeight: '不显示',
  942. exportParam: {},
  943. pageIndex: 1,
  944. pageSize: 100,
  945. totalPage: 0,
  946. height: 200,
  947. dataList:[],
  948. dataList2:[],
  949. dataListLoading: false,
  950. exportAllLoading: false,
  951. searchData: {
  952. page: 1,
  953. limit: 100,
  954. site:"",
  955. declarationNo:'',
  956. delNo:'',
  957. cmcInvoice:'',
  958. startDate:'',
  959. endDate:'',
  960. },
  961. buttons:{
  962. search:'查询',
  963. },
  964. activeName:'detail',
  965. columnList: [
  966. {
  967. userId: this.$store.state.user.name,
  968. functionId: 801006,
  969. serialNumber: '801006Table1Site',
  970. tableId: "801006Table1",
  971. tableName: "报关单主记录",
  972. columnProp: "site",
  973. headerAlign: "center",
  974. align: "left",
  975. columnLabel: "工厂编号",
  976. columnHidden: false,
  977. columnImage: false,
  978. columnSortable: false,
  979. sortLv: 0,
  980. status: true,
  981. fixed: '',
  982. columnWidth: 80
  983. },
  984. {
  985. userId: this.$store.state.user.name,
  986. functionId: 801006,
  987. serialNumber: '801006Table1DeclarationNo',
  988. tableId: "801006Table1",
  989. tableName: "报关单主记录",
  990. columnProp: "declarationNo",
  991. headerAlign: "center",
  992. align: "left",
  993. columnLabel: "报关单号",
  994. columnHidden: false,
  995. columnImage: false,
  996. columnSortable: false,
  997. sortLv: 0,
  998. status: true,
  999. fixed: '',
  1000. columnWidth: 100
  1001. },
  1002. {
  1003. userId: this.$store.state.user.name,
  1004. functionId: 801006,
  1005. serialNumber: '801006Table1CmcInvoice',
  1006. tableId: "801006Table1",
  1007. tableName: "报关单主记录",
  1008. columnProp: "cmcInvoice",
  1009. headerAlign: "center",
  1010. align: "left",
  1011. columnLabel: "合同协议号",
  1012. columnHidden: false,
  1013. columnImage: false,
  1014. columnSortable: false,
  1015. sortLv: 0,
  1016. status: true,
  1017. fixed: '',
  1018. columnWidth: 80
  1019. },
  1020. {
  1021. userId: this.$store.state.user.name,
  1022. functionId: 801006,
  1023. serialNumber: '801006Table1CustomsOfficeCode',
  1024. tableId: "801006Table1",
  1025. tableName: "报关单主记录",
  1026. columnProp: "customsOfficeCode",
  1027. headerAlign: "center",
  1028. align: "left",
  1029. columnLabel: "海关编号",
  1030. columnHidden: false,
  1031. columnImage: false,
  1032. columnSortable: false,
  1033. sortLv: 0,
  1034. status: true,
  1035. fixed: '',
  1036. columnWidth: 80
  1037. },
  1038. {
  1039. userId: this.$store.state.user.name,
  1040. functionId: 801006,
  1041. serialNumber: '801006Table1InputCode',
  1042. tableId: "801006Table1",
  1043. tableName: "报关单主记录",
  1044. columnProp: "inputCode",
  1045. headerAlign: "center",
  1046. align: "left",
  1047. columnLabel: "录入编号",
  1048. columnHidden: false,
  1049. columnImage: false,
  1050. columnSortable: false,
  1051. sortLv: 0,
  1052. status: true,
  1053. fixed: '',
  1054. columnWidth: 80
  1055. },
  1056. {
  1057. userId: this.$store.state.user.name,
  1058. functionId: 801006,
  1059. serialNumber: '801006Table1DutyStatus',
  1060. tableId: "801006Table1",
  1061. tableName: "报关单主记录",
  1062. columnProp: "dutyStatus",
  1063. headerAlign: "center",
  1064. align: "left",
  1065. columnLabel: "征免性质",
  1066. columnHidden: false,
  1067. columnImage: false,
  1068. columnSortable: false,
  1069. sortLv: 0,
  1070. status: true,
  1071. fixed: '',
  1072. columnWidth: 80
  1073. },
  1074. {
  1075. userId: this.$store.state.user.name,
  1076. functionId: 801006,
  1077. serialNumber: '801006Table1LocalShipper',
  1078. tableId: "801006Table1",
  1079. tableName: "报关单主记录",
  1080. columnProp: "localShipper",
  1081. headerAlign: "center",
  1082. align: "left",
  1083. columnLabel: "境内发货人",
  1084. columnHidden: false,
  1085. columnImage: false,
  1086. columnSortable: false,
  1087. sortLv: 0,
  1088. status: true,
  1089. fixed: '',
  1090. columnWidth: 130
  1091. },
  1092. {
  1093. userId: this.$store.state.user.name,
  1094. functionId: 801006,
  1095. serialNumber: '801006Table1LocalShipAddress',
  1096. tableId: "801006Table1",
  1097. tableName: "报关单主记录",
  1098. columnProp: "localShipAddress",
  1099. headerAlign: "center",
  1100. align: "left",
  1101. columnLabel: "境内发货人地址",
  1102. columnHidden: false,
  1103. columnImage: false,
  1104. columnSortable: false,
  1105. sortLv: 0,
  1106. status: true,
  1107. fixed: '',
  1108. columnWidth: 180
  1109. },
  1110. {
  1111. userId: this.$store.state.user.name,
  1112. functionId: 801006,
  1113. serialNumber: '801006Table1ShipType',
  1114. tableId: "801006Table1",
  1115. tableName: "报关单主记录",
  1116. columnProp: "shipType",
  1117. headerAlign: "center",
  1118. align: "left",
  1119. columnLabel: "出境关别",
  1120. columnHidden: false,
  1121. columnImage: false,
  1122. columnSortable: false,
  1123. sortLv: 0,
  1124. status: true,
  1125. fixed: '',
  1126. columnWidth: 80
  1127. },
  1128. {
  1129. userId: this.$store.state.user.name,
  1130. functionId: 801006,
  1131. serialNumber: '801006Table1ShipDate',
  1132. tableId: "801006Table1",
  1133. tableName: "报关单主记录",
  1134. columnProp: "shipDate",
  1135. headerAlign: "center",
  1136. align: "left",
  1137. columnLabel: "出口日期",
  1138. columnHidden: false,
  1139. columnImage: false,
  1140. columnSortable: false,
  1141. sortLv: 0,
  1142. status: true,
  1143. fixed: '',
  1144. columnWidth: 100
  1145. },
  1146. {
  1147. userId: this.$store.state.user.name,
  1148. functionId: 801006,
  1149. serialNumber: '801006Table1SubmitDate',
  1150. tableId: "801006Table1",
  1151. tableName: "报关单主记录",
  1152. columnProp: "submitDate",
  1153. headerAlign: "center",
  1154. align: "left",
  1155. columnLabel: "申报日期",
  1156. columnHidden: false,
  1157. columnImage: false,
  1158. columnSortable: false,
  1159. sortLv: 0,
  1160. status: true,
  1161. fixed: '',
  1162. columnWidth: 100
  1163. },
  1164. {
  1165. userId: this.$store.state.user.name,
  1166. functionId: 801006,
  1167. serialNumber: '801006Table1FilingNo',
  1168. tableId: "801006Table1",
  1169. tableName: "报关单主记录",
  1170. columnProp: "filingNo",
  1171. headerAlign: "center",
  1172. align: "left",
  1173. columnLabel: "备案号",
  1174. columnHidden: false,
  1175. columnImage: false,
  1176. columnSortable: false,
  1177. sortLv: 0,
  1178. status: true,
  1179. fixed: '',
  1180. columnWidth: 100
  1181. },
  1182. {
  1183. userId: this.$store.state.user.name,
  1184. functionId: 801006,
  1185. serialNumber: '801006Table1OverseasShipper',
  1186. tableId: "801006Table1",
  1187. tableName: "报关单主记录",
  1188. columnProp: "overseasShipper",
  1189. headerAlign: "center",
  1190. align: "left",
  1191. columnLabel: "境外收货人",
  1192. columnHidden: false,
  1193. columnImage: false,
  1194. columnSortable: false,
  1195. sortLv: 0,
  1196. status: true,
  1197. fixed: '',
  1198. columnWidth: 80
  1199. },
  1200. {
  1201. userId: this.$store.state.user.name,
  1202. functionId: 801006,
  1203. serialNumber: '801006Table1ShippingMode',
  1204. tableId: "801006Table1",
  1205. tableName: "报关单主记录",
  1206. columnProp: "shippingMode",
  1207. headerAlign: "center",
  1208. align: "left",
  1209. columnLabel: "运输方式",
  1210. columnHidden: false,
  1211. columnImage: false,
  1212. columnSortable: false,
  1213. sortLv: 0,
  1214. status: true,
  1215. fixed: '',
  1216. columnWidth: 80
  1217. },
  1218. {
  1219. userId: this.$store.state.user.name,
  1220. functionId: 801006,
  1221. serialNumber: '801006Table1ShippingData',
  1222. tableId: "801006Table1",
  1223. tableName: "报关单主记录",
  1224. columnProp: "shippingData",
  1225. headerAlign: "center",
  1226. align: "left",
  1227. columnLabel: "运输工具以及航次号",
  1228. columnHidden: false,
  1229. columnImage: false,
  1230. columnSortable: false,
  1231. sortLv: 0,
  1232. status: true,
  1233. fixed: '',
  1234. columnWidth: 120
  1235. },
  1236. {
  1237. userId: this.$store.state.user.name,
  1238. functionId: 801006,
  1239. serialNumber: '801006Table1DeliverNo',
  1240. tableId: "801006Table1",
  1241. tableName: "报关单主记录",
  1242. columnProp: "deliverNo",
  1243. headerAlign: "center",
  1244. align: "left",
  1245. columnLabel: "提运单号",
  1246. columnHidden: false,
  1247. columnImage: false,
  1248. columnSortable: false,
  1249. sortLv: 0,
  1250. status: true,
  1251. fixed: '',
  1252. columnWidth: 100
  1253. },
  1254. {
  1255. userId: this.$store.state.user.name,
  1256. functionId: 801006,
  1257. serialNumber: '801006Table1SalesPartner',
  1258. tableId: "801006Table1",
  1259. tableName: "报关单主记录",
  1260. columnProp: "salesPartner",
  1261. headerAlign: "center",
  1262. align: "left",
  1263. columnLabel: "生产销售单位",
  1264. columnHidden: false,
  1265. columnImage: false,
  1266. columnSortable: false,
  1267. sortLv: 0,
  1268. status: true,
  1269. fixed: '',
  1270. columnWidth: 180
  1271. },
  1272. {
  1273. userId: this.$store.state.user.name,
  1274. functionId: 801006,
  1275. serialNumber: '801006Table1RegulatoryMethod',
  1276. tableId: "801006Table1",
  1277. tableName: "报关单主记录",
  1278. columnProp: "regulatoryMethod",
  1279. headerAlign: "center",
  1280. align: "left",
  1281. columnLabel: "监管方式",
  1282. columnHidden: false,
  1283. columnImage: false,
  1284. columnSortable: false,
  1285. sortLv: 0,
  1286. status: true,
  1287. fixed: '',
  1288. columnWidth: 80
  1289. },
  1290. {
  1291. userId: this.$store.state.user.name,
  1292. functionId: 801006,
  1293. serialNumber: '801006Table1DutyStatus',
  1294. tableId: "801006Table1",
  1295. tableName: "报关单主记录",
  1296. columnProp: "dutyStatus",
  1297. headerAlign: "center",
  1298. align: "left",
  1299. columnLabel: "征免性质",
  1300. columnHidden: false,
  1301. columnImage: false,
  1302. columnSortable: false,
  1303. sortLv: 0,
  1304. status: true,
  1305. fixed: '',
  1306. columnWidth: 80
  1307. },
  1308. {
  1309. userId: this.$store.state.user.name,
  1310. functionId: 801006,
  1311. serialNumber: '801006Table1PermitNumber',
  1312. tableId: "801006Table1",
  1313. tableName: "报关单主记录",
  1314. columnProp: "permitNumber",
  1315. headerAlign: "center",
  1316. align: "left",
  1317. columnLabel: "许可证号",
  1318. columnHidden: false,
  1319. columnImage: false,
  1320. columnSortable: false,
  1321. sortLv: 0,
  1322. status: true,
  1323. fixed: '',
  1324. columnWidth: 80
  1325. },
  1326. {
  1327. userId: this.$store.state.user.name,
  1328. functionId: 801006,
  1329. serialNumber: '801006Table1SalesArea',
  1330. tableId: "801006Table1",
  1331. tableName: "报关单主记录",
  1332. columnProp: "salesArea",
  1333. headerAlign: "center",
  1334. align: "left",
  1335. columnLabel: "贸易国(地区)",
  1336. columnHidden: false,
  1337. columnImage: false,
  1338. columnSortable: false,
  1339. sortLv: 0,
  1340. status: true,
  1341. fixed: '',
  1342. columnWidth: 80
  1343. },
  1344. {
  1345. userId: this.$store.state.user.name,
  1346. functionId: 801006,
  1347. serialNumber: '801006Table1ReceiveArea',
  1348. tableId: "801006Table1",
  1349. tableName: "报关单主记录",
  1350. columnProp: "receiveArea",
  1351. headerAlign: "center",
  1352. align: "left",
  1353. columnLabel: "运抵国(地区)",
  1354. columnHidden: false,
  1355. columnImage: false,
  1356. columnSortable: false,
  1357. sortLv: 0,
  1358. status: true,
  1359. fixed: '',
  1360. columnWidth: 80
  1361. },
  1362. {
  1363. userId: this.$store.state.user.name,
  1364. functionId: 801006,
  1365. serialNumber: '801006Table1ShippingPort',
  1366. tableId: "801006Table1",
  1367. tableName: "报关单主记录",
  1368. columnProp: "shippingPort",
  1369. headerAlign: "center",
  1370. align: "left",
  1371. columnLabel: "运港",
  1372. columnHidden: false,
  1373. columnImage: false,
  1374. columnSortable: false,
  1375. sortLv: 0,
  1376. status: true,
  1377. fixed: '',
  1378. columnWidth: 80
  1379. },
  1380. {
  1381. userId: this.$store.state.user.name,
  1382. functionId: 801006,
  1383. serialNumber: '801006Table1ExitPort',
  1384. tableId: "801006Table1",
  1385. tableName: "报关单主记录",
  1386. columnProp: "exitPort",
  1387. headerAlign: "center",
  1388. align: "left",
  1389. columnLabel: "离境口岸",
  1390. columnHidden: false,
  1391. columnImage: false,
  1392. columnSortable: false,
  1393. sortLv: 0,
  1394. status: true,
  1395. fixed: '',
  1396. columnWidth: 80
  1397. },
  1398. {
  1399. userId: this.$store.state.user.name,
  1400. functionId: 801006,
  1401. serialNumber: '801006Table1Documents',
  1402. tableId: "801006Table1",
  1403. tableName: "报关单主记录",
  1404. columnProp: "documents",
  1405. headerAlign: "center",
  1406. align: "left",
  1407. columnLabel: "随附单证及编号",
  1408. columnHidden: false,
  1409. columnImage: false,
  1410. columnSortable: false,
  1411. sortLv: 0,
  1412. status: true,
  1413. fixed: '',
  1414. columnWidth: 120
  1415. },
  1416. {
  1417. userId: this.$store.state.user.name,
  1418. functionId: 801006,
  1419. serialNumber: '801006Table1Remark',
  1420. tableId: "801006Table1",
  1421. tableName: "报关单主记录",
  1422. columnProp: "remark",
  1423. headerAlign: "center",
  1424. align: "left",
  1425. columnLabel: "标记唛码及备注",
  1426. columnHidden: false,
  1427. columnImage: false,
  1428. columnSortable: false,
  1429. sortLv: 0,
  1430. status: true,
  1431. fixed: '',
  1432. columnWidth: 120
  1433. },
  1434. {
  1435. userId: this.$store.state.user.name,
  1436. functionId: 801006,
  1437. serialNumber: '801006Table1PackageType',
  1438. tableId: "801006Table1",
  1439. tableName: "报关单主记录",
  1440. columnProp: "packageType",
  1441. headerAlign: "center",
  1442. align: "left",
  1443. columnLabel: "包装种类",
  1444. columnHidden: false,
  1445. columnImage: false,
  1446. columnSortable: false,
  1447. sortLv: 0,
  1448. status: true,
  1449. fixed: '',
  1450. columnWidth: 80
  1451. },
  1452. {
  1453. userId: this.$store.state.user.name,
  1454. functionId: 801006,
  1455. serialNumber: '801006Table1PackageQty',
  1456. tableId: "801006Table1",
  1457. tableName: "报关单主记录",
  1458. columnProp: "packageQty",
  1459. headerAlign: "center",
  1460. align: "right",
  1461. columnLabel: "件数",
  1462. columnHidden: false,
  1463. columnImage: false,
  1464. columnSortable: false,
  1465. sortLv: 0,
  1466. status: true,
  1467. fixed: '',
  1468. columnWidth: 60
  1469. },
  1470. {
  1471. userId: this.$store.state.user.name,
  1472. functionId: 801006,
  1473. serialNumber: '801006Table1GrossWeight',
  1474. tableId: "801006Table1",
  1475. tableName: "报关单主记录",
  1476. columnProp: "grossWeight",
  1477. headerAlign: "center",
  1478. align: "right",
  1479. columnLabel: "毛重(KG)",
  1480. columnHidden: false,
  1481. columnImage: false,
  1482. columnSortable: false,
  1483. sortLv: 0,
  1484. status: true,
  1485. fixed: '',
  1486. columnWidth: 80
  1487. },
  1488. {
  1489. userId: this.$store.state.user.name,
  1490. functionId: 801006,
  1491. serialNumber: '801006Table1NetWeight',
  1492. tableId: "801006Table1",
  1493. tableName: "报关单主记录",
  1494. columnProp: "netWeight",
  1495. headerAlign: "center",
  1496. align: "right",
  1497. columnLabel: "净重(KG)",
  1498. columnHidden: false,
  1499. columnImage: false,
  1500. columnSortable: false,
  1501. sortLv: 0,
  1502. status: true,
  1503. fixed: '',
  1504. columnWidth: 80
  1505. },
  1506. {
  1507. userId: this.$store.state.user.name,
  1508. functionId: 801006,
  1509. serialNumber: '801006Table1PaymentType',
  1510. tableId: "801006Table1",
  1511. tableName: "报关单主记录",
  1512. columnProp: "paymentType",
  1513. headerAlign: "center",
  1514. align: "left",
  1515. columnLabel: "成交方式",
  1516. columnHidden: false,
  1517. columnImage: false,
  1518. columnSortable: false,
  1519. sortLv: 0,
  1520. status: true,
  1521. fixed: '',
  1522. columnWidth: 80
  1523. },
  1524. {
  1525. userId: this.$store.state.user.name,
  1526. functionId: 801006,
  1527. serialNumber: '801006Table1ShipPrice',
  1528. tableId: "801006Table1",
  1529. tableName: "报关单主记录",
  1530. columnProp: "shipPrice",
  1531. headerAlign: "center",
  1532. align: "right",
  1533. columnLabel: "运费",
  1534. columnHidden: false,
  1535. columnImage: false,
  1536. columnSortable: false,
  1537. sortLv: 0,
  1538. status: true,
  1539. fixed: '',
  1540. columnWidth: 60
  1541. },
  1542. {
  1543. userId: this.$store.state.user.name,
  1544. functionId: 801006,
  1545. serialNumber: '801006Table1Premium',
  1546. tableId: "801006Table1",
  1547. tableName: "报关单主记录",
  1548. columnProp: "premium",
  1549. headerAlign: "center",
  1550. align: "right",
  1551. columnLabel: "保费",
  1552. columnHidden: false,
  1553. columnImage: false,
  1554. columnSortable: false,
  1555. sortLv: 0,
  1556. status: true,
  1557. fixed: '',
  1558. columnWidth: 60
  1559. },
  1560. {
  1561. userId: this.$store.state.user.name,
  1562. functionId: 801006,
  1563. serialNumber: '801006Table1OtherPrice',
  1564. tableId: "801006Table1",
  1565. tableName: "报关单主记录",
  1566. columnProp: "otherPrice",
  1567. headerAlign: "center",
  1568. align: "right",
  1569. columnLabel: "杂费",
  1570. columnHidden: false,
  1571. columnImage: false,
  1572. columnSortable: false,
  1573. sortLv: 0,
  1574. status: true,
  1575. fixed: '',
  1576. columnWidth: 60
  1577. },
  1578. {
  1579. userId: this.$store.state.user.name,
  1580. functionId: 801006,
  1581. serialNumber: '801006Table1SpecialRelationshipComfirm',
  1582. tableId: "801006Table1",
  1583. tableName: "报关单主记录",
  1584. columnProp: "specialRelationshipComfirm",
  1585. headerAlign: "center",
  1586. align: "left",
  1587. columnLabel: "特殊关系确认",
  1588. columnHidden: false,
  1589. columnImage: false,
  1590. columnSortable: false,
  1591. sortLv: 0,
  1592. status: true,
  1593. fixed: '',
  1594. columnWidth: 60
  1595. },
  1596. {
  1597. userId: this.$store.state.user.name,
  1598. functionId: 801006,
  1599. serialNumber: '801006Table1PriceInfluenceConfirm',
  1600. tableId: "801006Table1",
  1601. tableName: "报关单主记录",
  1602. columnProp: "priceInfluenceConfirm",
  1603. headerAlign: "center",
  1604. align: "left",
  1605. columnLabel: "价格影响确认",
  1606. columnHidden: false,
  1607. columnImage: false,
  1608. columnSortable: false,
  1609. sortLv: 0,
  1610. status: true,
  1611. fixed: '',
  1612. columnWidth: 60
  1613. },
  1614. {
  1615. userId: this.$store.state.user.name,
  1616. functionId: 801006,
  1617. serialNumber: '801006Table1RoyaltyPaymentsConfirm',
  1618. tableId: "801006Table1",
  1619. tableName: "报关单主记录",
  1620. columnProp: "royaltyPaymentsConfirm",
  1621. headerAlign: "center",
  1622. align: "left",
  1623. columnLabel: "支付特许使用费确认",
  1624. columnHidden: false,
  1625. columnImage: false,
  1626. columnSortable: false,
  1627. sortLv: 0,
  1628. status: true,
  1629. fixed: '',
  1630. columnWidth: 60
  1631. },
  1632. {
  1633. userId: this.$store.state.user.name,
  1634. functionId: 801006,
  1635. serialNumber: '801006Table1DelNo',
  1636. tableId: "801006Table1",
  1637. tableName: "报关单主记录",
  1638. columnProp: "delNo",
  1639. headerAlign: "center",
  1640. align: "left",
  1641. columnLabel: "发货通知单号",
  1642. columnHidden: false,
  1643. columnImage: false,
  1644. columnSortable: false,
  1645. sortLv: 0,
  1646. status: true,
  1647. fixed: '',
  1648. columnWidth: 90
  1649. },
  1650. ],
  1651. columnList2: [
  1652. {
  1653. userId: this.$store.state.user.name,
  1654. functionId: 801006,
  1655. serialNumber: '801006Table2ItemNo',
  1656. tableId: "801006Table2",
  1657. tableName: "报关单子记录",
  1658. columnProp: "itemNo",
  1659. headerAlign: "center",
  1660. align: "right",
  1661. columnLabel: "序号",
  1662. columnHidden: false,
  1663. columnImage: false,
  1664. columnSortable: false,
  1665. sortLv: 0,
  1666. status: true,
  1667. fixed: '',
  1668. columnWidth: 50
  1669. },
  1670. {
  1671. userId: this.$store.state.user.name,
  1672. functionId: 801006,
  1673. serialNumber: '801006Table2HsCode',
  1674. tableId: "801006Table2",
  1675. tableName: "报关单子记录",
  1676. columnProp: "hsCode",
  1677. headerAlign: "center",
  1678. align: "left",
  1679. columnLabel: "HS Code",
  1680. columnHidden: false,
  1681. columnImage: false,
  1682. columnSortable: false,
  1683. sortLv: 0,
  1684. status: true,
  1685. fixed: '',
  1686. columnWidth: 100
  1687. },
  1688. {
  1689. userId: this.$store.state.user.name,
  1690. functionId: 801006,
  1691. serialNumber: '801006Table2HsCodeDesc',
  1692. tableId: "801006Table2",
  1693. tableName: "报关单子记录",
  1694. columnProp: "hsCodeDesc",
  1695. headerAlign: "center",
  1696. align: "left",
  1697. columnLabel: "品名",
  1698. columnHidden: false,
  1699. columnImage: false,
  1700. columnSortable: false,
  1701. sortLv: 0,
  1702. status: true,
  1703. fixed: '',
  1704. columnWidth: 100
  1705. },
  1706. {
  1707. userId: this.$store.state.user.name,
  1708. functionId: 801006,
  1709. serialNumber: '801006Table2HsCodeDesc',
  1710. tableId: "801006Table2",
  1711. tableName: "报关单子记录",
  1712. columnProp: "brand",
  1713. headerAlign: "center",
  1714. align: "left",
  1715. columnLabel: "品牌",
  1716. columnHidden: false,
  1717. columnImage: false,
  1718. columnSortable: false,
  1719. sortLv: 0,
  1720. status: true,
  1721. fixed: '',
  1722. columnWidth: 80
  1723. },
  1724. {
  1725. userId: this.$store.state.user.name,
  1726. functionId: 801006,
  1727. serialNumber: '801006Table2Qty',
  1728. tableId: "801006Table2",
  1729. tableName: "报关单子记录",
  1730. columnProp: "qty",
  1731. headerAlign: "center",
  1732. align: "right",
  1733. columnLabel: "数量",
  1734. columnHidden: false,
  1735. columnImage: false,
  1736. columnSortable: false,
  1737. sortLv: 0,
  1738. status: true,
  1739. fixed: '',
  1740. columnWidth: 60
  1741. },
  1742. {
  1743. userId: this.$store.state.user.name,
  1744. functionId: 801006,
  1745. serialNumber: '801006Table2NetWeight',
  1746. tableId: "801006Table2",
  1747. tableName: "报关单子记录",
  1748. columnProp: "netWeight",
  1749. headerAlign: "center",
  1750. align: "right",
  1751. columnLabel: "净重",
  1752. columnHidden: false,
  1753. columnImage: false,
  1754. columnSortable: false,
  1755. sortLv: 0,
  1756. status: true,
  1757. fixed: '',
  1758. columnWidth: 60
  1759. },
  1760. {
  1761. userId: this.$store.state.user.name,
  1762. functionId: 801006,
  1763. serialNumber: '801006Table2UnitPrice',
  1764. tableId: "801006Table2",
  1765. tableName: "报关单子记录",
  1766. columnProp: "unitPrice",
  1767. headerAlign: "center",
  1768. align: "right",
  1769. columnLabel: "单价",
  1770. columnHidden: false,
  1771. columnImage: false,
  1772. columnSortable: false,
  1773. sortLv: 0,
  1774. status: true,
  1775. fixed: '',
  1776. columnWidth: 60
  1777. },
  1778. {
  1779. userId: this.$store.state.user.name,
  1780. functionId: 801006,
  1781. serialNumber: '801006Table2TotalPrice',
  1782. tableId: "801006Table2",
  1783. tableName: "报关单子记录",
  1784. columnProp: "totalPrice",
  1785. headerAlign: "center",
  1786. align: "right",
  1787. columnLabel: "总价",
  1788. columnHidden: false,
  1789. columnImage: false,
  1790. columnSortable: false,
  1791. sortLv: 0,
  1792. status: true,
  1793. fixed: '',
  1794. columnWidth: 60
  1795. },
  1796. {
  1797. userId: this.$store.state.user.name,
  1798. functionId: 801006,
  1799. serialNumber: '801006Table2Currency',
  1800. tableId: "801006Table2",
  1801. tableName: "报关单子记录",
  1802. columnProp: "currency",
  1803. headerAlign: "center",
  1804. align: "left",
  1805. columnLabel: "币制",
  1806. columnHidden: false,
  1807. columnImage: false,
  1808. columnSortable: false,
  1809. sortLv: 0,
  1810. status: true,
  1811. fixed: '',
  1812. columnWidth: 60
  1813. },
  1814. {
  1815. userId: this.$store.state.user.name,
  1816. functionId: 801006,
  1817. serialNumber: '801006Table2MadeArea',
  1818. tableId: "801006Table2",
  1819. tableName: "报关单子记录",
  1820. columnProp: "madeArea",
  1821. headerAlign: "center",
  1822. align: "left",
  1823. columnLabel: "原产国(地区)",
  1824. columnHidden: false,
  1825. columnImage: false,
  1826. columnSortable: false,
  1827. sortLv: 0,
  1828. status: true,
  1829. fixed: '',
  1830. columnWidth: 80
  1831. },
  1832. {
  1833. userId: this.$store.state.user.name,
  1834. functionId: 801006,
  1835. serialNumber: '801006Table2Destination',
  1836. tableId: "801006Table2",
  1837. tableName: "报关单子记录",
  1838. columnProp: "destination",
  1839. headerAlign: "center",
  1840. align: "left",
  1841. columnLabel: "最终目的国(地区)",
  1842. columnHidden: false,
  1843. columnImage: false,
  1844. columnSortable: false,
  1845. sortLv: 0,
  1846. status: true,
  1847. fixed: '',
  1848. columnWidth: 100
  1849. },
  1850. {
  1851. userId: this.$store.state.user.name,
  1852. functionId: 801006,
  1853. serialNumber: '801006Table2SourceArea',
  1854. tableId: "801006Table2",
  1855. tableName: "报关单子记录",
  1856. columnProp: "sourceArea",
  1857. headerAlign: "center",
  1858. align: "left",
  1859. columnLabel: "境内货源地",
  1860. columnHidden: false,
  1861. columnImage: false,
  1862. columnSortable: false,
  1863. sortLv: 0,
  1864. status: true,
  1865. fixed: '',
  1866. columnWidth: 80
  1867. },
  1868. ],
  1869. }
  1870. },
  1871. mounted() {
  1872. this.$nextTick(() => {
  1873. this.height = (window.innerHeight - 240)/2;
  1874. })
  1875. },
  1876. methods: {
  1877. shouldShowDetailColumn(item) {
  1878. const isLabelOrRfid = this.currentRow && (this.currentRow.buNo === '01-Label' || this.currentRow.buNo === '03-RFID')
  1879. return !(item.columnProp === 'brand' && isLabelOrRfid)
  1880. },
  1881. // 每页数
  1882. sizeChangeHandle (val) {
  1883. this.pageSize = val
  1884. this.pageIndex = 1
  1885. this.searchTable()
  1886. },
  1887. // 当前页
  1888. currentChangeHandle (val) {
  1889. this.pageIndex = val
  1890. this.searchTable()
  1891. },
  1892. changeData(row){
  1893. this.currentRow = JSON.parse(JSON.stringify(row));
  1894. this.refreshCurrentTabTable ();
  1895. },
  1896. searchTable(){
  1897. this.searchData.limit = this.pageSize
  1898. this.searchData.page = this.pageIndex
  1899. searchDeclarationHeader(this.searchData).then(({data}) => {
  1900. //区分请求成功和失败的状况
  1901. if (data && data.code == 0) {
  1902. this.dataList = data.page.list
  1903. this.pageIndex = data.page.currPage
  1904. this.pageSize = data.page.pageSize
  1905. this.totalPage = data.page.totalCount
  1906. if(this.dataList.length>0){
  1907. this.$refs.mainTable.setCurrentRow(this.dataList[0]);
  1908. this.changeData(this.dataList[0])
  1909. }else {
  1910. this.changeData(null)
  1911. }
  1912. } else {
  1913. this.dataList = [];
  1914. }
  1915. });
  1916. },
  1917. tabClick (tab, event) {
  1918. // 刷新列表数据
  1919. this.refreshCurrentTabTable()
  1920. },
  1921. refreshCurrentTabTable(){
  1922. if(this.currentRow===''||this.currentRow===null){
  1923. this.currentRow={site:'',declarationNo:''}
  1924. }
  1925. if(this.activeName==='detail'){
  1926. searchDeclarationDetail(this.currentRow).then(({data}) => {
  1927. //区分请求成功和失败的状况
  1928. if (data && data.code == 0) {
  1929. this.dataList2 = data.rows
  1930. this.bizhi = data.rows[0].currency
  1931. } else {
  1932. this.dataList2 = [];
  1933. }
  1934. });
  1935. }
  1936. },
  1937. deleteBG(row){
  1938. this.$confirm('是否删除此条数据?', '提示', {
  1939. confirmButtonText: '确定',
  1940. cancelButtonText: '取消',
  1941. type: 'warning'
  1942. }).then(() => {
  1943. deleteDeclaration(row).then(({data}) => {
  1944. if (data && data.code === 0) {
  1945. this.searchTable()
  1946. this.$message({
  1947. message: '操作成功',
  1948. type: 'success',
  1949. duration: 1500,
  1950. onClose: () => {}
  1951. })
  1952. } else {
  1953. this.$alert(data.msg, '错误', {
  1954. confirmButtonText: '确定'
  1955. })
  1956. }
  1957. })
  1958. }).catch(() => {
  1959. this.$message({
  1960. type: 'info',
  1961. message: '已取消删除'
  1962. });
  1963. });
  1964. },
  1965. handleCurrentChange(val) {
  1966. this.currentRow = val;
  1967. },
  1968. chooseBrandType() {
  1969. if (!this.currentRow || !this.currentRow.buNo) {
  1970. this.$message.warning('请选择报关单!')
  1971. return
  1972. }
  1973. this.brandType='境外品牌(其他)'
  1974. this.brandTypeFlag = true
  1975. if (this.currentRow.buNo==='02-Hardtag' || this.currentRow.buNo==='04-MHM') {
  1976. this.currentRow.brand='品牌'
  1977. getPropertiesListByDeclaration(this.currentRow).then(({data}) => {
  1978. if (data && data.code == 0) {
  1979. this.propertiesList = data.rows
  1980. } else {
  1981. this.propertiesList = [];
  1982. }
  1983. });
  1984. }
  1985. },
  1986. chooseHsCodeDescType() {
  1987. if (!this.currentRow || !this.currentRow.buNo) {
  1988. this.$message.warning('请选择报关单!')
  1989. return
  1990. }
  1991. //this.hsCodeDescType=''
  1992. this.declarationFlag = true
  1993. },
  1994. searchTemplateOne() {
  1995. this.templateData.buNo = this.currentRow.buNo
  1996. this.templateData.customName = this.currentRow.customName
  1997. //this.templateData.shippingMode = this.currentRow.shippingMode
  1998. searchTemplateList(this.templateData).then(({data}) => {
  1999. if (data && data.code === 0){
  2000. if (data.rows && data.rows.length > 0) {
  2001. this.templateRowDblclick(data.rows[0]);
  2002. }
  2003. }
  2004. })
  2005. },
  2006. exportInvoiceList() {
  2007. if (!this.currentRow || !this.currentRow.buNo) {
  2008. this.$message.warning('请选择报关单!')
  2009. return
  2010. }
  2011. this.exportInvoice.templateName=''
  2012. this.exportInvoice.hsCodeDesc=this.currentRow.hsCodeDesc
  2013. this.exportInvoice.contractFlag=this.currentRow.contractFlag
  2014. this.exportInvoice.packaging=this.currentRow.packaging
  2015. this.exportInvoice.kgs=this.currentRow.kgs
  2016. this.exportInvoice.hsCode=this.currentRow.hsCode
  2017. this.exportInvoice.material=this.currentRow.material
  2018. this.exportInvoice.hsCodeDescType=this.currentRow.hsCodeDescType
  2019. this.exportInvoice.goodsLabel=this.currentRow.goodsLabel
  2020. this.exportInvoice.origin="made in china"
  2021. //this.exportInvoice = this.currentRow
  2022. if (!this.exportInvoice.origin) {
  2023. this.exportInvoice.origin = 'made in china'
  2024. }
  2025. if (!this.exportInvoice.itemNo) {
  2026. this.exportInvoice.itemNo = 'Y'
  2027. }
  2028. this.notifyPartDetailList = [];
  2029. this.exportInvoiceFlag = true
  2030. if (this.currentRow.buNo==='03-RFID') {
  2031. getNotifyPartDetail(this.currentRow).then(({data}) => {
  2032. //区分请求成功和失败的状况
  2033. if (data && data.code == 0) {
  2034. this.notifyPartDetailList = data.rows
  2035. this.notifyPartDetailList.forEach(o => {
  2036. if (!o.lossratio) {
  2037. o.lossratio = '1.05';
  2038. }
  2039. });
  2040. } else {
  2041. this.notifyPartDetailList = [];
  2042. }
  2043. });
  2044. }
  2045. this.templateData.type='发票'
  2046. this.searchTemplateOne();
  2047. },
  2048. exportPakingList() {
  2049. if (!this.currentRow || !this.currentRow.buNo) {
  2050. this.$message.warning('请选择报关单!')
  2051. return
  2052. }
  2053. this.exportPaking.origin='made in china'
  2054. this.exportPaking.itemNo=this.currentRow.itemNo
  2055. this.exportPaking.upc=this.currentRow.upc
  2056. this.exportPaking.so=this.currentRow.so
  2057. this.exportPaking.shippingMark=this.currentRow.cmcInvoice
  2058. this.exportPaking.palletWeight=this.currentRow.palletWeight
  2059. this.exportPaking.hsCodeDesc=this.currentRow.hsCodeDesc
  2060. this.exportPaking.contractFlag=this.currentRow.contractFlag
  2061. this.exportPaking.packaging=this.currentRow.packaging
  2062. this.exportPaking.kgs=this.currentRow.kgs
  2063. this.exportPaking.hsCode=this.currentRow.hsCode
  2064. this.exportPaking.material=this.currentRow.material
  2065. this.exportPaking.hsCodeDescType=this.currentRow.hsCodeDescType
  2066. this.exportPaking.goodsLabel=this.currentRow.goodsLabel
  2067. this.exportPaking.boxChange=this.currentRow.boxChange
  2068. //this.exportPaking = this.currentRow
  2069. if (!this.exportPaking.origin) {
  2070. this.exportPaking.origin = 'made in china'
  2071. }
  2072. if (!this.exportPaking.itemNo) {
  2073. this.exportPaking.itemNo = 'Y'
  2074. }
  2075. this.notifyPartDetailList = [];
  2076. this.exportPaking.templateName=''
  2077. this.exportPakingFlag = true
  2078. if (this.currentRow.buNo==='03-RFID') {
  2079. getNotifyPartDetail(this.currentRow).then(({data}) => {
  2080. //区分请求成功和失败的状况
  2081. if (data && data.code == 0) {
  2082. this.notifyPartDetailList = data.rows
  2083. this.notifyPartDetailList.forEach(o => {
  2084. if (!o.lossratio) {
  2085. o.lossratio = '1.05';
  2086. }
  2087. });
  2088. } else {
  2089. this.notifyPartDetailList = [];
  2090. }
  2091. });
  2092. }
  2093. this.templateData.type='箱单'
  2094. this.searchTemplateOne();
  2095. },
  2096. exportGoodsList() {
  2097. if (!this.currentRow || !this.currentRow.buNo) {
  2098. this.$message.warning('请选择报关单!')
  2099. return
  2100. }
  2101. this.exportGoods.hsCodeDescType = 'N'
  2102. this.exportGoods.salesMethod = 'EXW'
  2103. this.exportGoods.currency = this.dataList2.length>0?this.dataList2[0].currency:'USD'
  2104. this.exportGoods.madeArea = 'Nantong, China'
  2105. this.exportGoods.sendPort = 'Shanghai, China'
  2106. this.exportGoods.deliveryGoodsDate = ''
  2107. this.exportGoods.voyage = this.currentRow.buNo==='01-Label' || this.currentRow.buNo==='03-RFID'?this.currentRow.cmcInvoice:''
  2108. this.exportGoods.shippingDate = ''
  2109. this.exportGoodsFlag = true
  2110. },
  2111. // 导出
  2112. downloadDeclarationElements() {
  2113. if (!this.currentRow || !this.currentRow.buNo) {
  2114. this.$message.warning('请选择报关单!')
  2115. return
  2116. }
  2117. let exportParam={}
  2118. exportParam.declarationNo = this.currentRow.declarationNo
  2119. exportParam.site = this.currentRow.site
  2120. exportParam.delNo = this.currentRow.delNo
  2121. exportParam.brandType = this.brandType
  2122. exportParam.hsCodeDescType=this.hsCodeDescType
  2123. if (this.propertiesList.length>0) {
  2124. this.currentRow.brand='品牌'
  2125. exportParam.brand = '品牌'
  2126. exportParam.propertiesList = this.propertiesList
  2127. }
  2128. let error;
  2129. ExportUtil.export(
  2130. "/ecss/coDel/downloadDeclarationElements",
  2131. exportParam, "报关要素 "+this.currentRow.cmcInvoice+" "+this.currentRow.destination+"-"+this.currentRow.shippingMode+".xlsx"
  2132. );
  2133. this.brandTypeFlag = false
  2134. },
  2135. downloadDeclaration() {
  2136. if (!this.currentRow || !this.currentRow.buNo) {
  2137. this.$message.warning('请选择报关单!')
  2138. return
  2139. }
  2140. if (!this.packageUnit ) {
  2141. this.$message.warning('请选择托/箱!')
  2142. return
  2143. }
  2144. let exportParam={}
  2145. exportParam.declarationNo = this.currentRow.declarationNo
  2146. exportParam.site = this.currentRow.site
  2147. exportParam.delNo = this.currentRow.delNo
  2148. exportParam.hsCodeDescType=this.hsCodeDescType
  2149. exportParam.packageUnit=this.packageUnit
  2150. exportParam.declarationWeight = this.declarationWeight
  2151. ExportUtil.export(
  2152. "/ecss/coDel/downloadDeclaration",
  2153. exportParam, "报关单 "+this.currentRow.cmcInvoice+" "+this.currentRow.destination+"-"+this.currentRow.shippingMode+".xlsx"
  2154. );
  2155. this.declarationFlag = false
  2156. },
  2157. downloadInvoice() {
  2158. if (!this.currentRow || !this.currentRow.buNo) {
  2159. this.$message.warning('请选择报关单!')
  2160. return
  2161. }
  2162. let exportParam=this.exportInvoice
  2163. exportParam.hsCodeDescTypeInvoice=this.exportInvoice.hsCodeDescType
  2164. exportParam.declarationNo = this.currentRow.declarationNo
  2165. exportParam.site = this.currentRow.site
  2166. exportParam.delNo = this.currentRow.delNo
  2167. exportParam.notifyPartDetailList = this.notifyPartDetailList
  2168. ExportUtil.export(
  2169. "/ecss/coDel/downloadInvoice",
  2170. exportParam, "CI "+this.currentRow.cmcInvoice+" "+this.currentRow.destination+"-"+this.currentRow.shippingMode+".xlsx"
  2171. );
  2172. this.exportInvoiceFlag=false
  2173. this.searchTable()
  2174. },
  2175. downloadPackingList() {
  2176. if (!this.currentRow || !this.currentRow.buNo) {
  2177. this.$message.warning('请选择报关单!')
  2178. return
  2179. }
  2180. if ((this.currentRow.buNo==='01-Label' || this.currentRow.buNo==='03-RFID')
  2181. && !this.exportPaking.origin) {
  2182. this.$message.warning('请填写制造地!')
  2183. return
  2184. }
  2185. /* if ((this.currentRow.buNo==='01-Label' || this.currentRow.buNo==='03-RFID')
  2186. && !this.exportPaking.palletWeight) {
  2187. this.$message.warning('请填写栈板重量!')
  2188. return
  2189. }*/
  2190. if (this.exportPaking.material && !this.exportPaking.hsCode) {
  2191. this.$message.warning('请填写hsCode!')
  2192. return
  2193. }
  2194. if (this.exportPaking.packaging && !this.exportPaking.kgs) {
  2195. this.$message.warning('请填写plastic packaging!')
  2196. return
  2197. }
  2198. let exportParam=this.exportPaking
  2199. exportParam.declarationNo = this.currentRow.declarationNo
  2200. exportParam.site = this.currentRow.site
  2201. exportParam.delNo = this.currentRow.delNo
  2202. exportParam.notifyPartDetailList = this.notifyPartDetailList
  2203. ExportUtil.export(
  2204. "/ecss/coDel/downloadPackingList",
  2205. exportParam, "PL "+this.currentRow.cmcInvoice+" "+this.currentRow.destination+"-"+this.currentRow.shippingMode+".xlsx"
  2206. );
  2207. this.exportPakingFlag = false;
  2208. this.searchTable()
  2209. },
  2210. downloadExportGoods() {
  2211. if (!this.currentRow || !this.currentRow.buNo) {
  2212. this.$message.warning('请选择报关单!')
  2213. return
  2214. }
  2215. let exportParam=this.exportGoods
  2216. exportParam.declarationNo = this.currentRow.declarationNo
  2217. exportParam.site = this.currentRow.site
  2218. exportParam.delNo = this.currentRow.delNo
  2219. ExportUtil.export(
  2220. "/ecss/coDel/downloadExportGoods",
  2221. exportParam, "Booking "+this.currentRow.cmcInvoice+" "+this.currentRow.destination+"-"+this.currentRow.shippingMode+".xlsx"
  2222. );
  2223. this.exportGoodsFlag = false;
  2224. this.searchTable()
  2225. },
  2226. exportContract(){
  2227. if (!this.currentRow || !this.currentRow.buNo) {
  2228. this.$message.warning('请选择报关单!')
  2229. return
  2230. }
  2231. let exportParam=this.exportGoods
  2232. exportParam.declarationNo = this.currentRow.declarationNo
  2233. exportParam.site = this.currentRow.site
  2234. exportParam.delNo = this.currentRow.delNo
  2235. ExportUtil.export(
  2236. "/ecss/coDel/downloadContract",
  2237. exportParam, this.currentRow.cmcInvoice+"合同.xlsx"
  2238. );
  2239. this.searchTable()
  2240. },
  2241. exportAll(){
  2242. if (!this.currentRow || !this.currentRow.buNo) {
  2243. this.$message.warning('请选择报关单!')
  2244. return
  2245. }
  2246. if (!this.packageUnit ) {
  2247. this.$message.warning('请选择托/箱!')
  2248. return
  2249. }
  2250. let exportParam=this.exportPaking
  2251. exportParam.salesMethod=this.exportGoods.salesMethod
  2252. exportParam.currency=this.exportGoods.currency
  2253. exportParam.madeArea=this.exportGoods.madeArea
  2254. exportParam.sendPort=this.exportGoods.sendPort
  2255. exportParam.deliveryGoodsDate=this.exportGoods.deliveryGoodsDate
  2256. exportParam.voyage=this.exportGoods.voyage
  2257. exportParam.shippingDate=this.exportGoods.shippingDate
  2258. exportParam.hsCodeDescType=this.exportGoods.hsCodeDescType
  2259. exportParam.shipper=this.exportGoods.shipper
  2260. exportParam.brandType = this.brandType
  2261. exportParam.hsCodeDescType=this.hsCodeDescType
  2262. exportParam.packageUnit=this.packageUnit
  2263. exportParam.declarationWeight = this.declarationWeight
  2264. if (this.propertiesList.length>0) {
  2265. this.currentRow.brand='品牌'
  2266. exportParam.brand = '品牌'
  2267. exportParam.propertiesList = this.propertiesList
  2268. }
  2269. exportParam.hsCodeDesc = this.exportInvoice.hsCodeDesc
  2270. exportParam.hsCodeDescTypeInvoice=this.exportInvoice.hsCodeDescType
  2271. exportParam.hsCodeFlag=this.exportInvoice.hsCodeFlag
  2272. exportParam.contractFlag = this.exportInvoice.contractFlag
  2273. exportParam.fpremark = this.exportInvoice.fpremark
  2274. exportParam.showWeight = this.exportInvoice.showWeight
  2275. exportParam.declarationNo = this.currentRow.declarationNo
  2276. exportParam.site = this.currentRow.site
  2277. exportParam.delNo = this.currentRow.delNo
  2278. exportParam.notifyPartDetailList = this.notifyPartDetailList
  2279. ExportUtil.export(
  2280. "/ecss/coDel/downloadAll",
  2281. exportParam, this.currentRow.cmcInvoice+" "+this.currentRow.destination+"-"+this.currentRow.shippingMode+".xlsx"
  2282. );
  2283. this.exportAllFlag = false
  2284. this.searchTable()
  2285. },
  2286. async exportAllOpen() {
  2287. if (!this.currentRow || !this.currentRow.buNo) {
  2288. this.$message.warning('请选择报关单!')
  2289. return
  2290. }
  2291. this.exportAllLoading = true
  2292. try {
  2293. // 抬头信息
  2294. this.exportHeader.contractNo = this.currentRow.cmcInvoice || ''
  2295. this.exportHeader.transportMode = this.currentRow.shippingMode || ''
  2296. this.exportHeader.arrivalCountry = this.currentRow.receiveArea || ''
  2297. this.exportHeader.tradeCountry = this.currentRow.salesArea || ''
  2298. // 获取装箱数据,根据托数设置托/箱默认值
  2299. try {
  2300. // 只传递必要的字段,避免日期格式问题
  2301. const queryData = {
  2302. site: this.currentRow.site,
  2303. buNo: this.currentRow.buNo,
  2304. delNo: this.currentRow.delNo
  2305. }
  2306. const palletData = await searchEcssCoDelPalletHeaderData(queryData)
  2307. if (palletData && palletData.data && palletData.data.code === 0) {
  2308. const palletList = palletData.data.rows || []
  2309. // 计算总托数
  2310. const totalPalletQty = palletList.reduce((sum, item) => {
  2311. return sum + (item.palletQty || 0)
  2312. }, 0)
  2313. // 根据托数设置默认值:托数不为0选择"托",托数为0选择"箱"
  2314. this.packageUnit = totalPalletQty > 0 ? '托' : '箱'
  2315. } else {
  2316. // 如果获取装箱数据失败,默认选择"箱"
  2317. this.packageUnit = '箱'
  2318. }
  2319. } catch (error) {
  2320. console.error('获取装箱数据失败:', error)
  2321. // 如果获取装箱数据失败,默认选择"箱"
  2322. this.packageUnit = '箱'
  2323. }
  2324. // 报关要素
  2325. this.brandType='境外品牌(其他)'
  2326. if (this.currentRow.buNo==='02-Hardtag' || this.currentRow.buNo==='04-MHM') {
  2327. this.currentRow.brand='品牌'
  2328. getPropertiesListByDeclaration(this.currentRow).then(({data}) => {
  2329. if (data && data.code == 0) {
  2330. this.propertiesList = data.rows
  2331. } else {
  2332. this.propertiesList = [];
  2333. }
  2334. });
  2335. }
  2336. // 发票
  2337. this.exportInvoice.templateName=''
  2338. this.exportInvoice.hsCodeDesc=this.currentRow.hsCodeDesc
  2339. this.exportInvoice.contractFlag=this.currentRow.contractFlag
  2340. this.exportInvoice.packaging=this.currentRow.packaging
  2341. this.exportInvoice.kgs=this.currentRow.kgs
  2342. this.exportInvoice.hsCode=this.currentRow.hsCode
  2343. this.exportInvoice.material=this.currentRow.material
  2344. this.exportInvoice.hsCodeDescType=this.currentRow.hsCodeDescType
  2345. this.exportInvoice.goodsLabel=this.currentRow.goodsLabel
  2346. this.exportInvoice.origin="made in china"
  2347. if (!this.exportInvoice.origin) {
  2348. this.exportInvoice.origin = 'made in china'
  2349. }
  2350. if (!this.exportInvoice.itemNo) {
  2351. this.exportInvoice.itemNo = 'Y'
  2352. }
  2353. this.notifyPartDetailList = [];
  2354. this.templateData.type='发票'
  2355. await this.searchTemplateOne();
  2356. // 箱单
  2357. //this.exportPaking.origin='made in china'
  2358. this.exportPaking.itemNo=this.currentRow.itemNo
  2359. this.exportPaking.upc=this.currentRow.upc
  2360. this.exportPaking.so=this.currentRow.so
  2361. this.exportPaking.shippingMark=this.exportHeader.contractNo
  2362. this.exportPaking.palletWeight=this.currentRow.palletWeight
  2363. this.exportPaking.hsCodeDesc=this.currentRow.hsCodeDesc
  2364. this.exportPaking.contractFlag=this.currentRow.contractFlag
  2365. this.exportPaking.packaging=this.currentRow.packaging
  2366. this.exportPaking.kgs=this.currentRow.kgs
  2367. this.exportPaking.hsCode=this.currentRow.hsCode
  2368. this.exportPaking.material=this.currentRow.material
  2369. this.exportPaking.hsCodeDescType=this.currentRow.hsCodeDescType
  2370. this.exportPaking.goodsLabel=this.currentRow.goodsLabel
  2371. this.exportPaking.boxChange=this.currentRow.boxChange
  2372. if (!this.exportPaking.origin) {
  2373. this.exportPaking.origin = 'made in china'
  2374. }
  2375. if (!this.exportPaking.itemNo) {
  2376. this.exportPaking.itemNo = 'Y'
  2377. }
  2378. this.notifyPartDetailList = [];
  2379. this.exportPaking.templateName=''
  2380. if (this.currentRow.buNo==='03-RFID') {
  2381. await getNotifyPartDetail(this.currentRow).then(({data}) => {
  2382. //区分请求成功和失败的状况
  2383. if (data && data.code == 0) {
  2384. this.notifyPartDetailList = data.rows
  2385. this.notifyPartDetailList.forEach(o => {
  2386. if (!o.lossratio) {
  2387. o.lossratio = '1.05';
  2388. }
  2389. });
  2390. } else {
  2391. this.notifyPartDetailList = [];
  2392. }
  2393. });
  2394. }
  2395. this.templateData.type='箱单'
  2396. await searchTemplateList(this.templateData).then(({data}) => {
  2397. if (data && data.code === 0){
  2398. if (data.rows && data.rows.length > 0) {
  2399. let row = data.rows[0];
  2400. this.exportPaking.templateName=row.name
  2401. this.exportPaking.upc=row.upc
  2402. this.exportPaking.so=row.so
  2403. //this.exportPaking.shippingMark=row.shippingMark
  2404. this.exportPaking.palletWeight=row.palletWeight
  2405. this.exportPaking.boxChange=row.boxChange
  2406. this.exportPaking.itemNo=row.itemNo
  2407. this.exportPaking.origin=this.currentRow.origin?this.currentRow.origin:row.origin
  2408. this.exportPaking.packaging=this.currentRow.packaging?this.currentRow.packaging:row.packaging
  2409. this.exportPaking.kgs=this.currentRow.kgs?this.currentRow.kgs:row.kgs
  2410. this.exportPaking.hsCode=this.currentRow.hsCode?this.currentRow.hsCode:row.hsCode
  2411. this.exportPaking.material=this.currentRow.material?this.currentRow.material:row.material
  2412. this.exportPaking.hsCodeDescType=this.currentRow.hsCodeDescType?this.currentRow.hsCodeDescType:row.hsCodeDescType
  2413. this.exportPaking.goodsLabel=this.currentRow.goodsLabel?this.currentRow.goodsLabel:row.goodsLabel
  2414. this.notifyPartDetailList.forEach(o => {
  2415. // 开启fsc损耗则给默认值
  2416. if (o.lossratio) {
  2417. if (row.fscWeight) {
  2418. o.lossratio = o.lossratio;
  2419. } else {
  2420. o.lossratio = '';
  2421. }
  2422. } else {
  2423. if (row.fscWeight) {
  2424. o.lossratio = '1.05';
  2425. } else {
  2426. o.lossratio = '';
  2427. }
  2428. }
  2429. });
  2430. }
  2431. }
  2432. })
  2433. this.exportGoods.salesMethod = 'EXW'
  2434. this.exportGoods.currency = this.bizhi
  2435. this.exportGoods.madeArea = 'Nantong, China'
  2436. this.exportGoods.sendPort = 'Shanghai, China'
  2437. this.exportGoods.deliveryGoodsDate = ''
  2438. this.exportGoods.voyage = this.currentRow.buNo==='01-Label' || this.currentRow.buNo==='03-RFID'?this.currentRow.cmcInvoice:''
  2439. this.exportGoods.shippingDate = '';
  2440. //this.templateData.type='出口货物委托书'
  2441. //await this.searchTemplateOne();
  2442. if (this.currentRow.buNo==='03-RFID') {
  2443. this.exportPaking.kgs=4.5
  2444. } else {
  2445. this.exportPaking.kgs=2.5
  2446. }
  2447. if (this.packageUnit==='箱') {
  2448. this.exportPaking.kgs=0.1
  2449. }
  2450. this.exportPaking.shippingMark=this.exportHeader.contractNo
  2451. this.exportAllFlag = true
  2452. } finally {
  2453. this.exportAllLoading = false
  2454. }
  2455. },
  2456. exportAllPdf(){
  2457. if (!this.currentRow || !this.currentRow.buNo) {
  2458. this.$message.warning('请选择报关单!')
  2459. return
  2460. }
  2461. if (!this.packageUnit ) {
  2462. this.$message.warning('请选择托/箱!')
  2463. return
  2464. }
  2465. let exportParam=this.exportPaking
  2466. exportParam.salesMethod=this.exportGoods.salesMethod
  2467. exportParam.currency=this.exportGoods.currency
  2468. exportParam.madeArea=this.exportGoods.madeArea
  2469. exportParam.sendPort=this.exportGoods.sendPort
  2470. exportParam.deliveryGoodsDate=this.exportGoods.deliveryGoodsDate
  2471. exportParam.voyage=this.exportGoods.voyage
  2472. exportParam.shippingDate=this.exportGoods.shippingDate
  2473. exportParam.hsCodeDescType=this.exportGoods.hsCodeDescType
  2474. exportParam.shipper=this.exportGoods.shipper
  2475. exportParam.brandType = this.brandType
  2476. exportParam.hsCodeDescType=this.hsCodeDescType
  2477. exportParam.packageUnit=this.packageUnit
  2478. exportParam.declarationWeight = this.declarationWeight
  2479. if (this.propertiesList.length>0) {
  2480. this.currentRow.brand='品牌'
  2481. exportParam.brand = '品牌'
  2482. exportParam.propertiesList = this.propertiesList
  2483. }
  2484. exportParam.hsCodeDesc = this.exportInvoice.hsCodeDesc
  2485. exportParam.hsCodeDescTypeInvoice=this.exportInvoice.hsCodeDescType
  2486. exportParam.hsCodeFlag=this.exportInvoice.hsCodeFlag
  2487. exportParam.contractFlag = this.exportInvoice.contractFlag
  2488. exportParam.fpremark = this.exportInvoice.fpremark
  2489. exportParam.showWeight = this.exportInvoice.showWeight
  2490. exportParam.declarationNo = this.currentRow.declarationNo
  2491. exportParam.site = this.currentRow.site
  2492. exportParam.delNo = this.currentRow.delNo
  2493. exportParam.notifyPartDetailList = this.notifyPartDetailList
  2494. ExportUtil.export(
  2495. "/ecss/coDel/downloadAllPdf",
  2496. exportParam, this.currentRow.cmcInvoice+" "+this.currentRow.destination+"-"+this.currentRow.shippingMode+".pdf"
  2497. );
  2498. this.exportAllFlag = false
  2499. this.searchTable()
  2500. },
  2501. getCustomerInfo() {
  2502. getCustomerInfo(this.currentRow).then(({data}) => {
  2503. //区分请求成功和失败的状况
  2504. if (data && data.code == 0) {
  2505. this.customerInfoList = data.rows
  2506. } else {
  2507. this.customerInfoList = [];
  2508. }
  2509. });
  2510. },
  2511. // 动态列开始 获取 用户保存的 格式列
  2512. async getTableUserColumn (tableId, columnId) {
  2513. let queryTableUser = {
  2514. userId: this.$store.state.user.name,
  2515. functionId: this.$route.meta.menuId,
  2516. tableId: tableId,
  2517. status: true,
  2518. languageCode: this.$i18n.locale
  2519. }
  2520. await getTableUserListLanguage(queryTableUser).then(({data}) => {
  2521. if (data.rows.length > 0) {
  2522. //this.columnList1 = []
  2523. switch (columnId) {
  2524. case 1:
  2525. this.columnList = data.rows
  2526. break;
  2527. // case 2:
  2528. // this.columnDetailList = data.rows
  2529. // break;
  2530. // case 3:
  2531. // this.columnList2 = data.rows
  2532. // break;
  2533. // case 4:
  2534. // this.columnList3 = data.rows
  2535. // break;
  2536. }
  2537. } else {
  2538. this.getColumnList(tableId, columnId)
  2539. }
  2540. })
  2541. },
  2542. // 获取 tableDefault 列
  2543. async getColumnList (tableId, columnId) {
  2544. let queryTable = {
  2545. functionId: this.$route.meta.menuId,
  2546. tableId: tableId,
  2547. languageCode: this.$i18n.locale
  2548. }
  2549. await getTableDefaultListLanguage(queryTable).then(({data}) => {
  2550. if (!data.rows.length == 0) {
  2551. switch (columnId) {
  2552. case 1:
  2553. this.columnList = data.rows
  2554. break;
  2555. // case 2:
  2556. // this.columnDetailList = data.rows
  2557. // break;
  2558. // case 3:
  2559. // this.columnList2 = data.rows
  2560. // break;
  2561. // case 4:
  2562. // this.columnList3 = data.rows
  2563. // break;
  2564. }
  2565. } else {
  2566. // this.showDefault = true.
  2567. }
  2568. })
  2569. },
  2570. openTemplate (type) {
  2571. this.templateData.type=type;
  2572. this.templateData.buNo = this.currentRow.buNo
  2573. this.templateData.customName = this.currentRow.customName
  2574. //this.templateData.shippingMode = this.currentRow.shippingMode
  2575. this.templateFlag = true;
  2576. },
  2577. openTemplateDialog () {
  2578. //请求
  2579. this.searchTemplateList();
  2580. },
  2581. closeTemplateDialog () {
  2582. this.templateList = []
  2583. this.templateFlag = false
  2584. },
  2585. searchTemplateList () {
  2586. this.templateData.buNo = this.currentRow.buNo
  2587. this.templateData.customName = ''
  2588. searchTemplateList(this.templateData).then(({data}) => {
  2589. if (data && data.code === 0){
  2590. this.templateList = data.rows;
  2591. }
  2592. })
  2593. },
  2594. templateRowDblclick (row) {
  2595. if (this.templateData.type=='发票') {
  2596. this.exportInvoice.templateName=row.name
  2597. this.exportInvoice.hsCodeDesc=row.hsCodeDesc
  2598. this.exportInvoice.contractFlag=row.contractFlag
  2599. this.exportInvoice.origin=this.currentRow.origin?this.currentRow.origin:row.origin
  2600. this.exportInvoice.packaging=this.currentRow.packaging?this.currentRow.packaging:row.packaging
  2601. this.exportInvoice.kgs=this.currentRow.kgs?this.currentRow.kgs:row.kgs
  2602. this.exportInvoice.hsCode=this.currentRow.hsCode?this.currentRow.hsCode:row.hsCode
  2603. this.exportInvoice.material=this.currentRow.material?this.currentRow.material:row.material
  2604. this.exportInvoice.hsCodeDescType=row.hsCodeDescType
  2605. this.exportInvoice.hsCodeFlag=row.hsCodeFlag
  2606. this.exportInvoice.goodsLabel=this.currentRow.goodsLabel?this.currentRow.goodsLabel:row.goodsLabel
  2607. this.exportInvoice.fpremark = row.remark
  2608. this.exportInvoice.showWeight = row.showWeight
  2609. this.exportPaking.so=row.so
  2610. } else if (this.templateData.type=='箱单'){
  2611. this.exportPaking.templateName=row.name
  2612. this.exportPaking.upc=row.upc
  2613. this.exportPaking.so=row.so
  2614. //this.exportPaking.shippingMark=row.shippingMark
  2615. this.exportPaking.palletWeight=row.palletWeight
  2616. this.exportPaking.boxChange=row.boxChange
  2617. this.exportPaking.itemNo=row.itemNo
  2618. this.exportPaking.origin=this.currentRow.origin?this.currentRow.origin:row.origin
  2619. this.exportPaking.packaging=this.currentRow.packaging?this.currentRow.packaging:row.packaging
  2620. this.exportPaking.kgs=this.currentRow.kgs?this.currentRow.kgs:row.kgs
  2621. this.exportPaking.hsCode=this.currentRow.hsCode?this.currentRow.hsCode:row.hsCode
  2622. this.exportPaking.material=this.currentRow.material?this.currentRow.material:row.material
  2623. this.exportPaking.hsCodeDescType=this.currentRow.hsCodeDescType?this.currentRow.hsCodeDescType:row.hsCodeDescType
  2624. this.exportPaking.goodsLabel=this.currentRow.goodsLabel?this.currentRow.goodsLabel:row.goodsLabel
  2625. this.exportPaking.xdremark = row.remark,
  2626. this.exportPaking.highPalletFlag = row.highPalletFlag
  2627. } else if (this.templateData.type=='出口货物委托书'){
  2628. this.exportGoods.salesMethod = row.salesMethod
  2629. this.exportGoods.currency = row.currency
  2630. this.exportGoods.madeArea = row.madeArea
  2631. this.exportGoods.sendPort = row.sendPort
  2632. this.exportGoods.deliveryGoodsDate = row.deliveryGoodsDate
  2633. this.exportGoods.voyage = this.currentRow.buNo==='01-Label' || this.currentRow.buNo==='03-RFID'?this.currentRow.cmcInvoice:row.voyage
  2634. this.exportGoods.shippingDate = row.shippingDate;
  2635. this.exportGoods.shipper=row.shipper
  2636. }
  2637. if (this.templateData.type!=='出口货物委托书') {
  2638. this.notifyPartDetailList.forEach(o => {
  2639. // 开启fsc损耗则给默认值
  2640. if (o.lossratio) {
  2641. if (row.fscWeight) {
  2642. o.lossratio = o.lossratio;
  2643. } else {
  2644. o.lossratio = '';
  2645. }
  2646. } else {
  2647. if (row.fscWeight) {
  2648. o.lossratio = '1.05';
  2649. } else {
  2650. o.lossratio = '';
  2651. }
  2652. }
  2653. });
  2654. }
  2655. this.templateFlag = false
  2656. },
  2657. },
  2658. activated() {
  2659. this.searchTable()
  2660. },
  2661. created() {
  2662. // 动态列
  2663. this.getTableUserColumn(this.$route.meta.menuId+'table1',1)
  2664. }
  2665. }
  2666. </script>
  2667. <style scoped>
  2668. /deep/ .expClass .cell {
  2669. line-height: 24px;
  2670. font-size: 12px;
  2671. height: 24px;
  2672. }
  2673. .custom-divider {
  2674. position: relative;
  2675. height: 1px;
  2676. background: #ebeef5;
  2677. margin: 10px 0;
  2678. width: 720px;
  2679. }
  2680. .custom-divider .text {
  2681. position: absolute;
  2682. left: 20%;
  2683. top: -10px;
  2684. transform: translateX(-50%);
  2685. padding: 0 15px;
  2686. background: white;
  2687. color: #909399;
  2688. }
  2689. </style>