detailPage.vue 65 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121
  1. <template>
  2. <div>
  3. <div class="customer-head">
  4. <div class="customer-back" v-if="!home">
  5. <el-button
  6. type="danger"
  7. style="border: none;background: none;color: red"
  8. icon="el-icon-arrow-left"
  9. @click="backToList(0)"
  10. >返回列表
  11. </el-button>
  12. </div>
  13. <div class="customer-back" v-else>
  14. <el-button
  15. type="danger"
  16. style="border: none;background: none;color: red"
  17. icon="el-icon-arrow-left"
  18. @click="backToList(1)"
  19. >返回列表
  20. </el-button>
  21. <el-button
  22. type="danger"
  23. style="border: none;background: none;color: red"
  24. icon="el-icon-arrow-left"
  25. @click="backToList(2)"
  26. >返回台账
  27. </el-button>
  28. </div>
  29. </div>
  30. <containerTitle title="委托信息" style="margin-top: 50px"></containerTitle>
  31. <basic-container>
  32. <avue-form :option="goodsOptionForm" v-model="goodsForm">
  33. <template slot-scope="scope" slot="corpId">
  34. <crop-select
  35. v-model="goodsForm.corpId"
  36. disabled
  37. ></crop-select>
  38. </template>
  39. <template slot-scope="scope" slot="station">
  40. <port-info
  41. v-model="goodsForm.station"
  42. :disabled="goodsForm.status >= 1"
  43. />
  44. </template>
  45. <template slot-scope="scope" slot="agentId">
  46. <crop-select
  47. :disabled="goodsForm.status >= 1"
  48. v-model="goodsForm.agentId"
  49. ></crop-select>
  50. </template>
  51. <template slot-scope="scope" slot="polId">
  52. <port-info
  53. v-model="goodsForm.polId"
  54. :disabled="goodsForm.status >= 1"
  55. />
  56. </template>
  57. <template slot-scope="scope" slot="podId">
  58. <port-info
  59. v-model="goodsForm.podId"
  60. :disabled="goodsForm.status >= 1"
  61. />
  62. </template>
  63. </avue-form>
  64. </basic-container>
  65. <containerTitle title="其他信息"></containerTitle>
  66. <basic-container :showBtn="true" ref="other">
  67. <avue-form :option="goodsOptionFormTwo" v-model="goodsForm">
  68. <template slot-scope="scope" slot="corpId">
  69. <crop-select
  70. v-model="goodsForm.corpId"
  71. disabled
  72. ></crop-select>
  73. </template>
  74. <template slot-scope="scope" slot="station">
  75. <port-info
  76. v-model="goodsForm.station"
  77. :disabled="goodsForm.status >= 1"
  78. />
  79. </template>
  80. <template slot-scope="scope" slot="agentId">
  81. <crop-select
  82. :disabled="goodsForm.status >= 1"
  83. v-model="goodsForm.agentId"
  84. ></crop-select>
  85. </template>
  86. <template slot-scope="scope" slot="polId">
  87. <port-info
  88. v-model="goodsForm.polId"
  89. type="id"
  90. :disabled="goodsForm.status >= 1"
  91. />
  92. </template>
  93. <template slot-scope="scope" slot="podId">
  94. <port-info
  95. v-model="goodsForm.podId"
  96. type="id"
  97. :disabled="goodsForm.status >= 1"
  98. />
  99. </template>
  100. </avue-form>
  101. </basic-container>
  102. <containerTitle
  103. title="起止地信息"></containerTitle>
  104. <basic-container>
  105. <el-table
  106. ref="singleTable"
  107. :data="tableData"
  108. size="mini"
  109. :header-cell-style="{color:'#000',background:'#fafafa'}"
  110. style="width: 100%">
  111. <el-table-column
  112. property="date"
  113. align="center"
  114. width="40">
  115. <template slot-scope="scope">
  116. <span v-if="scope.$index == 0">
  117. <el-button type="primary" size="mini" circle>起</el-button>
  118. </span>
  119. <span v-else-if="scope.$index === tableData.length-1">
  120. <el-button type="success" size="mini" circle>止</el-button>
  121. </span>
  122. <span v-else>
  123. <el-button type="warning" size="mini" circle>途</el-button>
  124. <!-- <el-button v-if="goodsForm.status === 2" type="warning" size="mini" circle>途</el-button>-->
  125. <!-- <el-tooltip v-else class="item" effect="dark" content="删除" placement="right">-->
  126. <!-- <el-button type="danger" icon="el-icon-delete" size="mini" circle-->
  127. <!-- @click="deleteAddress(scope)"></el-button>-->
  128. <!-- </el-tooltip>-->
  129. </span>
  130. </template>
  131. </el-table-column>
  132. <el-table-column
  133. type="index"
  134. label="序号"
  135. align="center"
  136. width="60">
  137. </el-table-column>
  138. <el-table-column
  139. property="corpName"
  140. label="货运地点"
  141. align="center"
  142. show-overflow-tooltip
  143. width="200">
  144. </el-table-column>
  145. <!-- <el-table-column-->
  146. <!-- property="province"-->
  147. <!-- label="省市区"-->
  148. <!-- align="center"-->
  149. <!-- width="280">-->
  150. <!-- <template slot-scope="scope">-->
  151. <!-- <el-cascader-->
  152. <!-- size="small"-->
  153. <!-- style="width: 100%;"-->
  154. <!-- v-model="scope.row.region"-->
  155. <!-- disabled-->
  156. <!-- :props="treeOption"></el-cascader>-->
  157. <!-- </template>-->
  158. <!-- </el-table-column>-->
  159. <el-table-column
  160. property="contacts"
  161. align="center"
  162. width="150"
  163. show-overflow-tooltip
  164. label="联系人">
  165. </el-table-column>
  166. <el-table-column
  167. property="tel"
  168. align="center"
  169. width="180"
  170. show-overflow-tooltip
  171. label="电话">
  172. </el-table-column>
  173. <el-table-column
  174. property="address"
  175. align="center"
  176. show-overflow-tooltip
  177. label="详细地址">
  178. </el-table-column>
  179. <el-table-column
  180. property="remarks"
  181. align="center"
  182. show-overflow-tooltip
  183. label="备注">
  184. </el-table-column>
  185. </el-table>
  186. </basic-container>
  187. <containerTitle title="车辆信息"></containerTitle>
  188. <basic-container>
  189. <avue-crud
  190. :data="entrustList"
  191. @selection-change="selectionChange"
  192. :option="entrustOptionTwoT"
  193. ref="crudBoxTwo"
  194. v-if="KeyBoxTwo>0"
  195. @resetColumn="resetColumnBoxTwo"
  196. @saveColumn="saveColumnBoxTwo"
  197. @row-save="(row,done,loading)=>{rowSaveT(row,0,done,loading)}"
  198. @row-update="rowSaveWell">
  199. <template slot="menuLeft" slot-scope="{size}">
  200. <el-button type="success" icon="el-icon-check" :size="size" @click="batchScheduling"
  201. :disabled="selectionList.length === 0" v-if="roleNameTwo.indexOf('总调度') === -1">批量调度
  202. </el-button>
  203. </template>
  204. <template slot="plateNo" slot-scope="{row}" v-if="!row.$cellEdit">
  205. <span class="el-button--text" style="cursor: pointer" @click="openTrack(row)">{{ row.plateNo }}</span>
  206. </template>
  207. <!-- <template slot-scope="{row}" slot="fleetId">-->
  208. <!-- <crop-select-->
  209. <!-- v-if="row.$cellEdit"-->
  210. <!-- v-model="row.fleetId"-->
  211. <!-- @getCorpData="(data)=>{getfleetIdT(data,row)}"-->
  212. <!-- corpType="CD"-->
  213. <!-- ></crop-select>-->
  214. <!-- <span v-else>{{ row.fleetName }}</span>-->
  215. <!-- </template>-->
  216. <template slot-scope="{row,index}" slot="menu">
  217. <el-button
  218. type="text"
  219. size="small"
  220. v-if="row.status===0"
  221. @click="rowSaveT(row,index)"
  222. >{{ row.$cellEdit ? '保 存' : '修 改' }}
  223. </el-button>
  224. <el-button
  225. type="text"
  226. size="small"
  227. v-if="row.status===0"
  228. @click="rowSaveThree(row,index)"
  229. >{{ row.$cellEdit ? '确认调度派车' : '调度派车' }}
  230. </el-button>
  231. <el-button
  232. size="small"
  233. type="text"
  234. @click="designate(row, index)"
  235. v-if="row.status === 0"
  236. >调 度
  237. </el-button>
  238. <el-button
  239. size="small"
  240. type="text"
  241. @click="cancelDesignate(row, index)"
  242. v-if="row.status===1"
  243. >取消调度
  244. </el-button>
  245. <el-button
  246. size="small"
  247. type="text"
  248. @click="changeFleetT(row, index)"
  249. v-if="row.status !== 0 || row.status !==1 || row.status !==4"
  250. >变 更
  251. </el-button>
  252. <el-button
  253. size="small"
  254. type="text"
  255. @click="recordsOfChanges(row, index)"
  256. v-if="row.status > 1"
  257. >变更记录
  258. </el-button>
  259. <el-button
  260. size="small"
  261. type="text"
  262. @click="annexOpen(row, index)"
  263. >附 件
  264. </el-button>
  265. </template>
  266. </avue-crud>
  267. </basic-container>
  268. <span>
  269. <!-- <containerTitle title="费用明细"></containerTitle>-->
  270. <!-- <basic-container>-->
  271. <!-- <el-tabs v-model="activeIndex" @tab-click="handleSelect">-->
  272. <!-- <el-tab-pane label="应收" name="1"></el-tab-pane>-->
  273. <!-- <el-tab-pane label="应付" name="2"></el-tab-pane>-->
  274. <!-- </el-tabs>-->
  275. <!-- <avue-crud-->
  276. <!-- v-if="activeIndex === '1'"-->
  277. <!-- :data="collectionList"-->
  278. <!-- :option="collectionOption"-->
  279. <!-- ref="collection"-->
  280. <!-- @row-save="(row,done,loading)=>{rowSave(row,0,done,loading)}"-->
  281. <!-- @row-update="rowSave"-->
  282. <!-- @row-del="makeDel">-->
  283. <!-- <template slot-scope="{row}" slot="corpId">-->
  284. <!-- <crop-select-->
  285. <!-- v-if="row.$cellEdit"-->
  286. <!-- v-model="row.corpId"-->
  287. <!-- @getCorpData="(data)=>{getfleetId(data,row)}"-->
  288. <!-- ></crop-select>-->
  289. <!-- <span v-else>{{row.corpName}}</span>-->
  290. <!-- </template>-->
  291. <!-- <template slot-scope="{row}" slot="feeId">-->
  292. <!-- <breakdown-select-->
  293. <!-- v-if="row.$cellEdit"-->
  294. <!-- v-model="row.feeId"-->
  295. <!-- @selectValue="(value) => selectValue(value,row)"-->
  296. <!-- :configuration="breakConfiguration"-->
  297. <!-- >-->
  298. <!-- </breakdown-select>-->
  299. <!-- <span v-else>{{ row.feeName }}</span>-->
  300. <!-- </template>-->
  301. <!-- <template slot-scope="{row,index}" slot="menu">-->
  302. <!-- <el-button-->
  303. <!-- type="text"-->
  304. <!-- size="small"-->
  305. <!-- :icon="row.$cellEdit?'el-icon-circle-plus-outline':'el-icon-edit'"-->
  306. <!-- @click="rowCell(row,index)"-->
  307. <!-- >{{row.$cellEdit?'保存':'编辑'}}</el-button>-->
  308. <!-- <el-button type="text"-->
  309. <!-- icon="el-icon-delete"-->
  310. <!-- size="small"-->
  311. <!-- @click="$refs.collection.rowDel(row,index)"-->
  312. <!-- >删除</el-button>-->
  313. <!-- </template>-->
  314. <!-- <template slot="menuLeft">-->
  315. <!-- <el-button type="primary" icon="el-icon-plus" @click="addRowCollection" size="small">录入明细</el-button>-->
  316. <!-- </template>-->
  317. <!-- </avue-crud>-->
  318. <!-- <avue-crud-->
  319. <!-- v-if="activeIndex === '2'"-->
  320. <!-- :data="paymentList"-->
  321. <!-- :option="paymentOption"-->
  322. <!-- ref="payment"-->
  323. <!-- @row-save="(row,done,loading)=>{rowSave(row,0,done,loading)}"-->
  324. <!-- @row-update="rowSave"-->
  325. <!-- @row-del="feeDel"-->
  326. <!-- >-->
  327. <!-- <template slot-scope="{row}" slot="corpId">-->
  328. <!-- <crop-select-->
  329. <!-- v-if="row.$cellEdit"-->
  330. <!-- v-model="row.corpId"-->
  331. <!-- @getCorpData="(data)=>{getfleetId(data,row)}"-->
  332. <!-- ></crop-select>-->
  333. <!-- <span v-else>{{row.corpName}}</span>-->
  334. <!-- </template>-->
  335. <!-- <template slot-scope="{row}" slot="feeId">-->
  336. <!-- <breakdown-select-->
  337. <!-- v-if="row.$cellEdit"-->
  338. <!-- v-model="row.feeId"-->
  339. <!-- @selectValue="(value) => selectValue(value,row)"-->
  340. <!-- :configuration="breakConfiguration"-->
  341. <!-- >-->
  342. <!-- </breakdown-select>-->
  343. <!-- <span v-else>{{ row.feeName }}</span>-->
  344. <!-- </template>-->
  345. <!-- <template slot-scope="{row,index}" slot="menu">-->
  346. <!-- <el-button-->
  347. <!-- type="text"-->
  348. <!-- size="small"-->
  349. <!-- :icon="row.$cellEdit?'el-icon-circle-plus-outline':'el-icon-edit'"-->
  350. <!-- @click="paymentRowCell(row,index)"-->
  351. <!-- >{{row.$cellEdit?'保存':'编辑'}}</el-button>-->
  352. <!-- <el-button type="text"-->
  353. <!-- icon="el-icon-delete"-->
  354. <!-- size="small"-->
  355. <!-- @click="$refs.payment.rowDel(row,index)"-->
  356. <!-- >删除</el-button>-->
  357. <!-- </template>-->
  358. <!-- <template slot="menuLeft">-->
  359. <!-- <el-button type="primary" icon="el-icon-plus" @click="addRowPayment" size="small">录入明细</el-button>-->
  360. <!-- </template>-->
  361. <!-- </avue-crud>-->
  362. <!-- </basic-container>-->
  363. </span>
  364. <containerTitle title="杂费明细"></containerTitle>
  365. <basic-container>
  366. <el-tabs v-model="activeIndex" @tab-click="handleSelect">
  367. <el-tab-pane label="应收" name="1"></el-tab-pane>
  368. <el-tab-pane label="应付" name="2"></el-tab-pane>
  369. </el-tabs>
  370. <avue-crud
  371. v-if="activeIndex === '1'"
  372. :data="collectionList"
  373. :key="key"
  374. :option="collectionOption"
  375. ref="collection"
  376. @resetColumn="resetColumnCollection"
  377. @saveColumn="saveColumnCollection"
  378. @row-save="(row,done,loading)=>{rowSave(row,0,done,loading)}"
  379. @row-update="rowSave"
  380. @row-del="makeDel">
  381. <template slot-scope="{row}" slot="corpId">
  382. <crop-select
  383. v-if="row.$cellEdit"
  384. v-model="row.corpId"
  385. @getCorpData="(data)=>{getfleetId(data,row)}"
  386. ></crop-select>
  387. <span v-else>{{ row.corpName }}</span>
  388. </template>
  389. <template slot="plateNoHeader" slot-scope="{column}">
  390. {{ column.label }}<span style="color:#F56C6C">*</span>
  391. </template>
  392. <template slot="feeIdHeader" slot-scope="{column}">
  393. {{ column.label }}<span style="color:#F56C6C">*</span>
  394. </template>
  395. <template slot-scope="{row}" slot="feeId">
  396. <breakdown-select
  397. v-if="row.$cellEdit"
  398. v-model="row.feeId"
  399. @selectValue="(value) => selectValue(value,row)"
  400. :configuration="breakConfiguration"
  401. >
  402. </breakdown-select>
  403. <span v-else>{{ row.feeName }}</span>
  404. </template>
  405. <template slot-scope="{row,index}" slot="menu">
  406. <el-button
  407. type="text"
  408. size="small"
  409. :icon="row.$cellEdit?'el-icon-circle-plus-outline':'el-icon-edit'"
  410. @click="rowCell(row,index)"
  411. >{{ row.$cellEdit ? '保存' : '编辑' }}
  412. </el-button>
  413. <el-button type="text"
  414. icon="el-icon-delete"
  415. size="small"
  416. @click="$refs.collection.rowDel(row,index)"
  417. >删除
  418. </el-button>
  419. <el-button
  420. size="small"
  421. type="text"
  422. icon="el-icon-s-order"
  423. @click="annexOpen(row, index)"
  424. >附 件
  425. </el-button>
  426. </template>
  427. <template slot="menuLeft">
  428. <el-button
  429. v-if="roleNameTwo.indexOf('总调度') === -1"
  430. type="primary" icon="el-icon-plus" @click="addRowCollection"
  431. size="small">录入明细
  432. </el-button>
  433. </template>
  434. </avue-crud>
  435. <avue-crud
  436. v-if="activeIndex === '2'"
  437. :data="paymentList"
  438. :option="paymentOption"
  439. ref="payment"
  440. @resetColumn="resetColumnPayment"
  441. @saveColumn="saveColumnPayment"
  442. @row-save="(row,done,loading)=>{rowSave(row,0,done,loading)}"
  443. @row-update="rowSave"
  444. @row-del="feeDel"
  445. >
  446. <template slot-scope="{row}" slot="corpId">
  447. <crop-select
  448. v-if="row.$cellEdit"
  449. v-model="row.corpId"
  450. @getCorpData="(data)=>{getfleetId(data,row)}"
  451. ></crop-select>
  452. <span v-else>{{ row.corpName }}</span>
  453. </template>
  454. <template slot="plateNoHeader" slot-scope="{column}">
  455. {{ column.label }}<span style="color:#F56C6C">*</span>
  456. </template>
  457. <template slot="feeIdHeader" slot-scope="{column}">
  458. {{ column.label }}<span style="color:#F56C6C">*</span>
  459. </template>
  460. <template slot-scope="{row}" slot="feeId">
  461. <breakdown-select
  462. v-if="row.$cellEdit"
  463. v-model="row.feeId"
  464. @selectValue="(value) => selectValue(value,row)"
  465. :configuration="breakConfiguration"
  466. >
  467. </breakdown-select>
  468. <span v-else>{{ row.feeName }}</span>
  469. </template>
  470. <template slot-scope="{row,index}" slot="menu">
  471. <el-button
  472. type="text"
  473. size="small"
  474. :icon="row.$cellEdit?'el-icon-circle-plus-outline':'el-icon-edit'"
  475. @click="paymentRowCell(row,index)"
  476. >{{ row.$cellEdit ? '保存' : '编辑' }}
  477. </el-button>
  478. <el-button type="text"
  479. icon="el-icon-delete"
  480. size="small"
  481. :disabled="goodsForm.status === 1"
  482. @click="$refs.payment.rowDel(row,index)"
  483. >删除
  484. </el-button>
  485. <el-button
  486. size="small"
  487. type="text"
  488. icon="el-icon-s-order"
  489. @click="annexOpen(row, index)"
  490. >附 件
  491. </el-button>
  492. </template>
  493. <template slot="menuLeft">
  494. <el-button
  495. v-if="roleNameTwo.indexOf('总调度') === -1"
  496. type="primary" icon="el-icon-plus" @click="addRowPayment"
  497. size="small">录入明细
  498. </el-button>
  499. </template>
  500. </avue-crud>
  501. </basic-container>
  502. <containerTitle title="上传附件"></containerTitle>
  503. <c-upload
  504. typeUpload="CD"
  505. :data="orderFilesList"
  506. display
  507. deleteUrl="/api/blade-client/common-file/remove"
  508. :enumerationValue="86.2"
  509. >
  510. <template slot="c_button">
  511. <el-button
  512. type="primary"
  513. size="small"
  514. :loading="c_button"
  515. @click="schedulingFileSaving"
  516. >保存附件
  517. </el-button>
  518. </template>
  519. </c-upload>
  520. <el-dialog
  521. title="批量调度"
  522. :visible.sync="dialogVisible"
  523. append-to-body
  524. width="70%">
  525. <avue-form :option="option" v-model="form" ref="form">
  526. <template slot="fleetId">
  527. <crop-select
  528. v-model="form.fleetId"
  529. corpType="CD"
  530. ></crop-select>
  531. </template>
  532. </avue-form>
  533. <span slot="footer" class="dialog-footer">
  534. <el-button @click="dialogVisible = false" size="small">取 消</el-button>
  535. <el-button type="primary" @click="saveScheduling" size="small">调 度</el-button>
  536. </span>
  537. </el-dialog>
  538. <el-dialog
  539. title="变更"
  540. :visible.sync="dialogChange"
  541. append-to-body
  542. width="70%">
  543. <avue-form :option="optionData" v-model="formData" ref="saveForm">
  544. <template slot="fleetId">
  545. <crop-select
  546. v-model="formData.fleetId"
  547. corpType="CD"
  548. :disabled="formData === 4"
  549. @getCorpData="getCorpData"
  550. ></crop-select>
  551. </template>
  552. </avue-form>
  553. <span slot="footer" class="dialog-footer">
  554. <el-button @click="dialogChange = false" size="small">关 闭</el-button>
  555. <el-button type="primary" @click="confirmChange" size="small">确 定</el-button>
  556. </span>
  557. </el-dialog>
  558. <el-dialog
  559. title="变更记录"
  560. :visible.sync="dialogRecord"
  561. append-to-body
  562. width="70%">
  563. <avue-crud :data="dataRecord" :option="optionRecord" style="margin-top: -43px"></avue-crud>
  564. <span slot="footer" class="dialog-footer">
  565. <el-button @click="dialogRecord = false" size="small">关 闭</el-button>
  566. </span>
  567. </el-dialog>
  568. <el-dialog
  569. title="附件"
  570. :visible.sync="enclosure"
  571. append-to-body
  572. width="70%">
  573. <c-upload
  574. typeUpload="GZ"
  575. :basic="true"
  576. deleteUrl="/api/blade-client/common-file/remove"
  577. :data="orderList"
  578. :enumerationValue="76"
  579. ></c-upload>
  580. <span slot="footer" class="dialog-footer">
  581. <el-button @click="enclosure = false" size="small">取 消</el-button>
  582. <el-button type="primary" @click="saveAnnex" size="small">保 存</el-button>
  583. </span>
  584. </el-dialog>
  585. <track-playback :dialogVisible="dialogVisibleTwo" :lineArr="lineArr" ref="playback"></track-playback>
  586. </div>
  587. </template>
  588. <script>
  589. import {getLazyTree} from "@/api/base/region";
  590. import {
  591. saveDelegationList,
  592. detailDelegationList,
  593. removeCollection,
  594. dispatchCollection,
  595. queryVehicle,
  596. cancelDispatchCollection,
  597. dispatchBatch,
  598. fleetDriverSave,
  599. recordingDetails,
  600. changeFleet,
  601. incidentalSubmit, saveFile, getFee, fleetList, conserveDispatch,
  602. checkAttachment, sendACarCollection
  603. } from "@/api/landTransportation";
  604. import website from "@/config/website";
  605. import {getDeptTree} from "@/api/system/dept";
  606. import {customerList} from "@/api/basicData/basicFeesDesc";
  607. import {gaude, location} from "@/api/gaude";
  608. export default {
  609. props: {
  610. id: {
  611. type: String
  612. },
  613. home: {
  614. type: Boolean
  615. }
  616. },
  617. data() {
  618. return {
  619. formData: {},
  620. enclosure: false,
  621. dialogVisibleTwo:false,
  622. lineArr: [],
  623. formAnnex: {},
  624. key: 0,
  625. formDataList: {},
  626. orderList: [],
  627. dialogChange: false,
  628. optionData: {
  629. span: 12,
  630. menuBtn: false,
  631. column: [{
  632. label: "车队",
  633. prop: "fleetId",
  634. }, {
  635. label: "应付陆运费",
  636. prop: "landAmountC",
  637. precision: 2,
  638. controls: false,
  639. type: 'number',
  640. }]
  641. },
  642. form: {},
  643. dataRecord: [],
  644. dialogRecord: false,
  645. optionRecord: {
  646. stripe: true,
  647. refreshBtn: false,
  648. columnBtn: false,
  649. menu: false,
  650. addBtn: false,
  651. align: 'center',
  652. column: [
  653. {
  654. label: '变更内容',
  655. prop: 'content'
  656. }, {
  657. label: '变更人',
  658. prop: 'changeUserName'
  659. }, {
  660. label: '变更时间',
  661. prop: 'changeTime'
  662. }
  663. ]
  664. },
  665. option: {
  666. span: 12,
  667. menuBtn: false,
  668. column: [{
  669. label: "车队",
  670. prop: "fleetId",
  671. rules: [{
  672. required: true,
  673. message: " ",
  674. trigger: "blur"
  675. }]
  676. }, {
  677. label: "应付陆运费",
  678. prop: "landAmountC",
  679. precision: 2,
  680. controls: false,
  681. type: 'number',
  682. }]
  683. },
  684. activeIndex: '1',
  685. dialogVisible: false,
  686. c_button: false,
  687. goodsForm: {},
  688. orderFilesList: [],
  689. selectionList: [],
  690. roleName: localStorage.getItem("roleName").split(',')[0],
  691. roleNameTwo: localStorage.getItem("roleName").split(','),
  692. breakConfiguration: {
  693. multipleChoices: false,
  694. multiple: false,
  695. disabled: false,
  696. searchShow: true,
  697. collapseTags: false,
  698. clearable: true,
  699. placeholder: '请点击右边按钮选择',
  700. dicData: []
  701. },
  702. advantageProjectData: [],
  703. treeOption: {
  704. label: 'title',
  705. value: 'id',
  706. lazy: true,
  707. lazyLoad(node, resolve) {
  708. const parentId = node.level === 0 ? '00' : node.data.id;
  709. getLazyTree(parentId).then(res => {
  710. resolve(
  711. res.data.data.map(item => {
  712. return {
  713. ...item,
  714. leaf: !item.hasChildren
  715. };
  716. })
  717. );
  718. });
  719. }
  720. },
  721. tableData: [],
  722. entrustListT: [],
  723. KeyBoxTwo: 0,
  724. entrustOptionTwoTBackup: {
  725. selectable: (row, index) => {
  726. return row.status === 0
  727. },
  728. align: 'center',
  729. menuAlign: 'center',
  730. index: true,
  731. cellBtn: false,
  732. refreshBtn: false,
  733. selection: true,
  734. selectionWidth: 55,
  735. menu:true,
  736. tip: false,
  737. addBtn: false,
  738. cancelBtn: false,
  739. editBtn: false,
  740. addRowBtn: false,
  741. delBtn: false,
  742. showSummary: true,
  743. // editBtn:false,
  744. summaryText: "合计",
  745. sumColumnList: [
  746. {
  747. name: 'landWeight',
  748. type: 'sum',
  749. decimals: 2
  750. }, {
  751. name: 'landAmountC',
  752. type: 'sum',
  753. decimals: 2
  754. }, {
  755. name: 'landAmountD',
  756. type: 'sum',
  757. decimals: 2
  758. }, {
  759. name: 'oneFeeD',
  760. type: 'sum',
  761. decimals: 2
  762. }, {
  763. name: 'twoFeeD',
  764. type: 'sum',
  765. decimals: 2
  766. }, {
  767. name: 'threeFeeD',
  768. type: 'sum',
  769. decimals: 2
  770. }, {
  771. name: 'fourFeeD',
  772. type: 'sum',
  773. decimals: 2
  774. }, {
  775. name: 'fiveFeeD',
  776. type: 'sum',
  777. decimals: 2
  778. }, {
  779. name: 'oneFeeC',
  780. type: 'sum',
  781. decimals: 2
  782. }, {
  783. name: 'twoFeeC',
  784. type: 'sum',
  785. decimals: 2
  786. }, {
  787. name: 'threeFeeC',
  788. type: 'sum',
  789. decimals: 2
  790. }, {
  791. name: 'fourFeeC',
  792. type: 'sum',
  793. decimals: 2
  794. }, {
  795. name: 'fiveFeeC',
  796. type: 'sum',
  797. decimals: 2
  798. }, {
  799. name: 'landAmountD',
  800. type: 'sum',
  801. decimals: 2
  802. }, {
  803. name: 'ctnQuantity',
  804. type: 'sum',
  805. decimals: 0
  806. }],
  807. column: [{
  808. label: '货运日期',
  809. type: "datetime",
  810. cell: true,
  811. format: 'yyyy-MM-dd HH:mm',
  812. valueFormat: 'yyyy-MM-dd HH:mm:ss',
  813. width: 200,
  814. index: 1,
  815. prop: 'arrivalTime'
  816. }, {
  817. label: '实际到厂时间',
  818. prop: 'realArrivalTime',
  819. overHidden: true,
  820. type: "date",
  821. searchRange: true,
  822. defaultTime: ['00:00:00', '23:59:59'],
  823. format: "yyyy-MM-dd HH:mm",
  824. valueFormat: "yyyy-MM-dd HH:mm:ss",
  825. index: 2,
  826. width: 140,
  827. }, {
  828. label: '尺寸箱型',
  829. width: 100,
  830. slot: true,
  831. index: 3,
  832. prop: 'ctnType'
  833. }, {
  834. label: '箱量',
  835. width: 50,
  836. index: 4,
  837. prop: 'ctnQuantity'
  838. }, {
  839. label: '车队',
  840. width: 200,
  841. index: 5,
  842. type: 'select',
  843. cascader: ['plateNo'],
  844. overHidden: true,
  845. cell: true,
  846. prop: 'fleetId',
  847. dicUrl: "/api/blade-client/corpsdesc/list?size=1000&current=1&&corpType=CD",
  848. props: {
  849. label: "cname",
  850. value: "id",
  851. res: "data.records"
  852. }
  853. }, {
  854. label: '车号',
  855. width: 150,
  856. index: 6,
  857. cell: false,
  858. prop: 'plateNo',
  859. type: "select",
  860. dicUrl: "/api/blade-client/land-vehicle/vehicle-list?fleetId={{key}}",
  861. props: {
  862. label: "plateNo",
  863. value: "plateNo"
  864. },
  865. }, {
  866. label: '司机',
  867. width: 115,
  868. index: 7,
  869. prop: 'driverName'
  870. }, {
  871. label: '电话',
  872. width: 160,
  873. index: 8,
  874. prop: 'tel'
  875. }, {
  876. label: '完工日期',
  877. prop: 'finishedTime',
  878. overHidden: true,
  879. type: "date",
  880. searchRange: true,
  881. defaultTime: ['00:00:00', '23:59:59'],
  882. format: "yyyy-MM-dd HH:mm",
  883. valueFormat: "yyyy-MM-dd HH:mm:ss",
  884. index: 9,
  885. width: 140,
  886. }, {
  887. label: '货物名称',
  888. overHidden: true,
  889. width: 160,
  890. index: 10,
  891. prop: 'goods'
  892. }, {
  893. label: '件数',
  894. width: 100,
  895. overHidden: true,
  896. controls: false,
  897. cell: true,
  898. index: 11,
  899. prop: 'quantity',
  900. type: 'number',
  901. precision: 0
  902. }
  903. // , {
  904. // label: '包装',
  905. // width: 100,
  906. // overHidden: true,
  907. // cell: true,
  908. // prop: 'packing',
  909. // type: 'select',
  910. // dicUrl: "/api/blade-system/dict-biz/dictionary?code=packaging",
  911. // props: {
  912. // label: "dictValue",
  913. // value: "dictValue"
  914. // },
  915. // }
  916. , {
  917. label: '重量',
  918. width: 160,
  919. prop: 'landWeight',
  920. controls: false,
  921. precision: 2,
  922. index: 12,
  923. type: 'number'
  924. }, {
  925. label: '尺码',
  926. width: 100,
  927. overHidden: true,
  928. cell: true,
  929. index: 13,
  930. prop: 'size',
  931. }, {
  932. label: '单柜运费',
  933. index: 14,
  934. prop: 'landAmountD'
  935. },
  936. {
  937. label: '状态',
  938. width: 100,
  939. index: 15,
  940. type: 'select',
  941. dicUrl: "/api/blade-system/dict-biz/dictionary?code=land_order_status",
  942. props: {
  943. label: "dictValue",
  944. value: "dictKey"
  945. },
  946. dataType: "string",
  947. prop: 'status'
  948. }, {
  949. label: '应付陆运费',
  950. cell: true,
  951. index: 16,
  952. prop: 'landAmountC'
  953. }, {
  954. label: '委托备注',
  955. width: 245,
  956. index: 17,
  957. prop: 'remarks'
  958. }, {
  959. label: '车队备注',
  960. width: 245,
  961. index: 18,
  962. prop: 'fleetRemarks'
  963. }, {
  964. label: '司机备注',
  965. width: 245,
  966. index: 19,
  967. prop: 'driverRemarks'
  968. }, {
  969. label: '应收场站费',
  970. width: 100,
  971. precision: 2,
  972. index: 20,
  973. controls: false,
  974. cell: true,
  975. type: 'number',
  976. prop: 'oneFeeD'
  977. }, {
  978. label: '应收港杂费',
  979. width: 100,
  980. precision: 2,
  981. cell: true,
  982. index: 21,
  983. controls: false,
  984. type: 'number',
  985. prop: 'twoFeeD'
  986. }, {
  987. label: '应收扣款',
  988. width: 100,
  989. index: 22,
  990. precision: 2,
  991. cell: true,
  992. controls: false,
  993. type: 'number',
  994. prop: 'threeFeeD'
  995. }, {
  996. label: '应收待时费',
  997. width: 100,
  998. precision: 2,
  999. index: 23,
  1000. cell: true,
  1001. controls: false,
  1002. type: 'number',
  1003. prop: 'fourFeeD'
  1004. }, {
  1005. label: '应收其他',
  1006. width: 100,
  1007. index: 24,
  1008. precision: 2,
  1009. cell: true,
  1010. type: 'number',
  1011. controls: false,
  1012. prop: 'fiveFeeD'
  1013. }, {
  1014. label: '应收费用备注',
  1015. width: 245,
  1016. index: 25,
  1017. cell: true,
  1018. prop: 'feeRemarksD'
  1019. }, {
  1020. label: '应付场站费',
  1021. width: 100,
  1022. index: 26,
  1023. precision: 2,
  1024. cell: true,
  1025. controls: false,
  1026. type: 'number',
  1027. prop: 'oneFeeC'
  1028. }, {
  1029. label: '应付港杂费',
  1030. width: 100,
  1031. precision: 2,
  1032. index: 27,
  1033. cell: true,
  1034. controls: false,
  1035. type: 'number',
  1036. prop: 'twoFeeC'
  1037. }, {
  1038. label: '应付扣款',
  1039. width: 100,
  1040. index: 28,
  1041. precision: 2,
  1042. controls: false,
  1043. type: 'number',
  1044. cell: true,
  1045. prop: 'threeFeeC'
  1046. }, {
  1047. label: '应付待时费',
  1048. width: 100,
  1049. precision: 2,
  1050. index: 29,
  1051. controls: false,
  1052. cell: true,
  1053. type: 'number',
  1054. prop: 'fourFeeC'
  1055. }, {
  1056. label: '应付其他',
  1057. width: 100,
  1058. precision: 2,
  1059. index: 30,
  1060. type: 'number',
  1061. cell: true,
  1062. controls: false,
  1063. prop: 'fiveFeeC'
  1064. }, {
  1065. label: '应付费用备注',
  1066. width: 245,
  1067. index: 31,
  1068. cell: true,
  1069. prop: 'feeRemarksC'
  1070. }
  1071. ]
  1072. },
  1073. entrustOptionTwoT: {},
  1074. entrustList: [],
  1075. goodsOptionForm: {
  1076. menuBtn: false,
  1077. disabled: true,
  1078. span: 8,
  1079. column: [{
  1080. label: '公司名称',
  1081. formslot: true,
  1082. prop: 'corpId',
  1083. rules: [{
  1084. required: true,
  1085. message: " ",
  1086. trigger: "change"
  1087. }],
  1088. }, {
  1089. label: '所属部门',
  1090. prop: 'salesmanDept',
  1091. type: "tree",
  1092. filter: false,
  1093. dicData: [],
  1094. props: {
  1095. label: "title"
  1096. }
  1097. }, {
  1098. label: '业务员',
  1099. prop: 'salesman',
  1100. type: "select",
  1101. dicUrl: "/api/blade-user/userList",
  1102. props: {
  1103. label: "realName",
  1104. value: "id"
  1105. },
  1106. rules: [{
  1107. required: true,
  1108. message: " ",
  1109. trigger: "blur"
  1110. }]
  1111. }, {
  1112. label: '物流运输',
  1113. prop: 'dispatchDept',
  1114. cascader: ['dispatcher'],
  1115. dicUrl: "/api/blade-system/dept/top-list?deptCategory=1",
  1116. type: "select",
  1117. props: {
  1118. label: "deptName",
  1119. value: "id"
  1120. },
  1121. rules: [{
  1122. required: true,
  1123. message: " ",
  1124. trigger: "blur"
  1125. }]
  1126. }, {
  1127. label: '运输调度',
  1128. prop: 'dispatcher',
  1129. type: "select",
  1130. dicUrl: "/api/blade-user/userList?deptPid={{key}}",
  1131. props: {
  1132. label: "realName",
  1133. value: "id"
  1134. }
  1135. }, {
  1136. label: '委托日期',
  1137. prop: 'bsDate',
  1138. type: "datetime",
  1139. format: 'yyyy-MM-dd HH:mm',
  1140. valueFormat: 'yyyy-MM-dd HH:mm:ss',
  1141. }, {
  1142. label: '票据号',
  1143. prop: 'receiptNo'
  1144. }, {
  1145. label: '联系电话',
  1146. prop: 'tel'
  1147. }, {
  1148. label: '提单号',
  1149. prop: 'billNo',
  1150. rules: [{
  1151. required: true,
  1152. message: " ",
  1153. trigger: "blur"
  1154. }],
  1155. }, {
  1156. label: '场站',
  1157. prop: 'station',
  1158. rules: [{
  1159. required: true,
  1160. message: " ",
  1161. trigger: "blur"
  1162. }],
  1163. },
  1164. // {
  1165. // label: '货运日期',
  1166. // type: "datetime",
  1167. // format: 'yyyy-MM-dd HH:mm:ss',
  1168. // valueFormat: 'yyyy-MM-dd HH:mm:ss',
  1169. // prop: 'arrivalTime',
  1170. // rules: [{
  1171. // required: true,
  1172. // message: " ",
  1173. // trigger: "blur"
  1174. // }],
  1175. // },
  1176. {
  1177. label: '备注',
  1178. span: 24,
  1179. minRows: 2,
  1180. prop: 'remarks',
  1181. type: 'textarea'
  1182. }]
  1183. },
  1184. goodsOptionFormTwo: {
  1185. menuBtn: false,
  1186. disabled: true,
  1187. span: 8,
  1188. column: [
  1189. // {
  1190. // label: '所属公司',
  1191. // formslot: true,
  1192. // prop: 'belongCompany',
  1193. // rules: [{
  1194. // required: false,
  1195. // message: " ",
  1196. // trigger: "blur"
  1197. // }],
  1198. // },
  1199. {
  1200. label: '船名航次',
  1201. prop: 'factory',
  1202. rules: [{
  1203. required: false,
  1204. message: " ",
  1205. trigger: "blur"
  1206. }],
  1207. }
  1208. // , {
  1209. // label: '货物名称',
  1210. // prop: 'goods',
  1211. // rules: [{
  1212. // required: false,
  1213. // message: " ",
  1214. // trigger: "blur"
  1215. // }],
  1216. // }
  1217. , {
  1218. label: '开船日期',
  1219. prop: 'etd',
  1220. type: 'date'
  1221. }, {
  1222. label: '预配箱量',
  1223. prop: 'expectCtnQty',
  1224. }, {
  1225. label: '起运港',
  1226. prop: 'polId'
  1227. }, {
  1228. label: '目的港',
  1229. prop: 'podId'
  1230. }, {
  1231. label: '截港日期',
  1232. prop: 'etc',
  1233. type: 'date'
  1234. }, {
  1235. label: '截单日期',
  1236. prop: 'siCutoffDate',
  1237. type: 'date'
  1238. }, {
  1239. label: '订舱代理',
  1240. prop: 'agentId'
  1241. }]
  1242. },
  1243. entrustOptionTwo: {
  1244. align: 'center',
  1245. menuAlign: 'center',
  1246. addBtnText: '录入箱信息',
  1247. index: true,
  1248. cellBtn: true,
  1249. addBtn: false,
  1250. addRowBtn: true,
  1251. showSummary: true,
  1252. summaryText: "合计",
  1253. sumColumnList: [
  1254. {
  1255. name: 'landWeight',
  1256. type: 'sum',
  1257. decimals: 2
  1258. }, {
  1259. name: 'landAmountD',
  1260. type: 'sum',
  1261. decimals: 2
  1262. }, {
  1263. name: 'ctnQuantity',
  1264. type: 'sum',
  1265. decimals: 7
  1266. }],
  1267. column: [{
  1268. label: '尺寸箱型',
  1269. cell: true,
  1270. prop: 'ctnType',
  1271. type: 'select',
  1272. width: 100,
  1273. dicUrl: "/api/blade-system/dict-biz/dictionary?code=boxType",
  1274. props: {
  1275. label: "dictValue",
  1276. value: "dictKey"
  1277. }
  1278. }, {
  1279. label: '箱量',
  1280. cell: true,
  1281. prop: 'ctnQuantity',
  1282. controls: false,
  1283. precision: 0,
  1284. width: 100,
  1285. type: 'number'
  1286. }, {
  1287. label: '总重量(吨)',
  1288. cell: true,
  1289. prop: 'landWeight',
  1290. controls: false,
  1291. width: 200,
  1292. precision: 2,
  1293. type: 'number'
  1294. }, {
  1295. label: '单柜运费',
  1296. cell: true,
  1297. prop: 'landAmountD',
  1298. controls: false,
  1299. width: 200,
  1300. precision: 2,
  1301. type: 'number'
  1302. }, {
  1303. label: '备注',
  1304. cell: true,
  1305. width: 200,
  1306. prop: 'remarks'
  1307. }
  1308. ]
  1309. },
  1310. collectionList: [],
  1311. collectionOption: {},
  1312. collectionOptionBackup: {
  1313. align: 'center',
  1314. menuAlign: 'center',
  1315. index: true,
  1316. cancelBtn: false,
  1317. editBtn: false,
  1318. delBtn: false,
  1319. cellBtn: false,
  1320. addBtn: false,
  1321. addRowBtn: false,
  1322. showSummary: true,
  1323. addBtnText: '录入明细',
  1324. summaryText: "合计",
  1325. sumColumnList: [{
  1326. name: 'price',
  1327. type: 'sum',
  1328. decimals: 2
  1329. }, {
  1330. name: 'amount',
  1331. type: 'sum',
  1332. decimals: 2
  1333. }, {
  1334. name: 'quantity',
  1335. type: 'sum',
  1336. decimals: 1
  1337. }],
  1338. column: [{
  1339. label: '客户名称',
  1340. slot: true,
  1341. width: 300,
  1342. prop: 'corpId'
  1343. }, {
  1344. label: '车号',
  1345. cell: true,
  1346. prop: 'plateNo',
  1347. type: "select",
  1348. props: {
  1349. label: "label",
  1350. value: "label"
  1351. },
  1352. }, {
  1353. label: '费用名称',
  1354. slot: true,
  1355. width: 200,
  1356. prop: 'feeId'
  1357. }, {
  1358. label: '计价单位',
  1359. cell: true,
  1360. prop: 'unit',
  1361. type: "select",
  1362. dicUrl: "/api/blade-system/dict-biz/dictionary?code=unit",
  1363. props: {
  1364. label: "dictValue",
  1365. value: "dictKey"
  1366. }
  1367. }, {
  1368. label: '单价',
  1369. cell: true,
  1370. type: 'number',
  1371. controls: false,
  1372. prop: 'price'
  1373. }, {
  1374. label: '数量',
  1375. cell: true,
  1376. controls: false,
  1377. type: 'number',
  1378. prop: 'quantity'
  1379. }, {
  1380. label: '金额',
  1381. cell: true,
  1382. type: 'number',
  1383. controls: false,
  1384. prop: 'amount'
  1385. }, {
  1386. label: '税率',
  1387. cell: true,
  1388. prop: 'taxRate'
  1389. }, {
  1390. label: '币别',
  1391. cell: true,
  1392. prop: 'currency',
  1393. type: "select",
  1394. dicUrl: "/api/blade-system/dict-biz/dictionary?code=currency",
  1395. props: {
  1396. label: "dictValue",
  1397. value: "dictKey"
  1398. },
  1399. }
  1400. ]
  1401. },
  1402. paymentList: [],
  1403. paymentOption: {},
  1404. paymentOptionBackup: {
  1405. align: 'center',
  1406. menuAlign: 'center',
  1407. index: true,
  1408. cancelBtn: false,
  1409. editBtn: false,
  1410. delBtn: false,
  1411. cellBtn: false,
  1412. addBtn: false,
  1413. addRowBtn: false,
  1414. showSummary: true,
  1415. addBtnText: '录入明细',
  1416. summaryText: "合计",
  1417. sumColumnList: [{
  1418. name: 'price',
  1419. type: 'sum',
  1420. decimals: 2
  1421. }, {
  1422. name: 'amount',
  1423. type: 'sum',
  1424. decimals: 2
  1425. }, {
  1426. name: 'quantity',
  1427. type: 'sum',
  1428. decimals: 1
  1429. }],
  1430. column: [{
  1431. label: '客户名称',
  1432. cell: true,
  1433. width: 300,
  1434. prop: 'fleetId',
  1435. type: "select",
  1436. cascader: ['plateNo'],
  1437. props: {
  1438. label: "fleetName",
  1439. value: "fleetId"
  1440. },
  1441. change:(data)=>{
  1442. data.row.plateNo = ''
  1443. }
  1444. },
  1445. // {
  1446. // label: '客户名称',
  1447. // slot: true,
  1448. // width: 300,
  1449. // prop: 'corpId'
  1450. // },
  1451. {
  1452. label: '车号',
  1453. cell: true,
  1454. prop: 'plateNo',
  1455. type: "select",
  1456. props: {
  1457. label: "label",
  1458. value: "label"
  1459. }
  1460. }, {
  1461. label: '费用名称',
  1462. slot: true,
  1463. width: 200,
  1464. prop: 'feeId'
  1465. }, {
  1466. label: '计价单位',
  1467. cell: true,
  1468. prop: 'unit',
  1469. type: "select",
  1470. dicUrl: "/api/blade-system/dict-biz/dictionary?code=unit",
  1471. props: {
  1472. label: "dictValue",
  1473. value: "dictKey"
  1474. }
  1475. }, {
  1476. label: '单价',
  1477. cell: true,
  1478. controls: false,
  1479. type: 'number',
  1480. prop: 'price',
  1481. }, {
  1482. label: '数量',
  1483. cell: true,
  1484. controls: false,
  1485. type: 'number',
  1486. prop: 'quantity'
  1487. }, {
  1488. label: '金额',
  1489. cell: true,
  1490. controls: false,
  1491. type: 'number',
  1492. prop: 'amount'
  1493. }, {
  1494. label: '税率',
  1495. cell: true,
  1496. prop: 'taxRate'
  1497. }, {
  1498. label: '币别',
  1499. cell: true,
  1500. prop: 'currency',
  1501. type: "select",
  1502. dicUrl: "/api/blade-system/dict-biz/dictionary?code=currency",
  1503. props: {
  1504. label: "dictValue",
  1505. value: "dictKey"
  1506. },
  1507. },
  1508. ]
  1509. }
  1510. };
  1511. },
  1512. async created() {
  1513. this.entrustOptionTwoT = await this.getColumnData(this.getColumnName(86.1), this.entrustOptionTwoTBackup);
  1514. this.collectionOption = await this.getColumnData(this.getColumnName(86.4), this.collectionOptionBackup);
  1515. this.paymentOption = await this.getColumnData(this.getColumnName(86.5), this.paymentOptionBackup);
  1516. this.findObject(this.paymentOption.column, "fleetId").dicUrl = "/api/blade-land/order-fee/fleet?orderId=" + this.id
  1517. this.findObject(this.paymentOption.column, "plateNo").dicUrl = "api/blade-land/order-fee/plate-no?orderId=" + this.id + '&fleetId={{key}}'
  1518. this.findObject(this.paymentOption.column, "plateNo").dicFormatter = (data)=>{
  1519. let list = []
  1520. data.data.forEach(ele=>{
  1521. list.push({label:ele})
  1522. })
  1523. return list
  1524. }
  1525. this.findObject(this.collectionOption.column, "price").change = (data) => {
  1526. if (data.row.price && data.row.quantity) {
  1527. data.row.amount = Number(data.row.price) * Number(data.row.quantity)
  1528. }
  1529. }
  1530. this.findObject(this.collectionOption.column, "quantity").change = (data) => {
  1531. if (data.row.price && data.row.quantity) {
  1532. data.row.amount = Number(data.row.price) * Number(data.row.quantity)
  1533. }
  1534. }
  1535. this.findObject(this.paymentOption.column, "price").change = (data) => {
  1536. if (data.row.price && data.row.quantity) {
  1537. data.row.amount = Number(data.row.price) * Number(data.row.quantity)
  1538. }
  1539. }
  1540. this.findObject(this.paymentOption.column, "quantity").change = (data) => {
  1541. if (data.row.price && data.row.quantity) {
  1542. data.row.amount = Number(data.row.price) * Number(data.row.quantity)
  1543. }
  1544. }
  1545. this.KeyBoxTwo++
  1546. if (this.id) {
  1547. detailDelegationList({id: this.id, kind: '2'}).then(res => {
  1548. this.goodsForm = res.data.data
  1549. this.tableData = res.data.data.orderAddressList
  1550. this.entrustList = res.data.data.orderItemList
  1551. this.goodsList = res.data.data.orderItemList
  1552. this.orderFilesList = res.data.data.fileList
  1553. if (res.data.data.orderFeeList.length > 0) {
  1554. res.data.data.orderFeeList.forEach(item => {
  1555. if (item.type == 1) {
  1556. this.collectionList.push(item)
  1557. } else {
  1558. this.paymentList.push(item)
  1559. }
  1560. })
  1561. }
  1562. delete this.goodsForm.orderAddressList
  1563. delete this.goodsForm.orderItemList
  1564. delete this.goodsForm.orderFeeList
  1565. // this.tableData.forEach(item => {
  1566. // if (item.region) item.region = item.region.split(',')
  1567. // })
  1568. if (this.roleNameTwo.indexOf('总调度') !== -1){
  1569. this.entrustOptionTwoT.menu = false
  1570. this.collectionOption.menu = false
  1571. this.paymentOption.menu = false
  1572. }
  1573. })
  1574. }
  1575. queryVehicle({orderId: this.id}).then(res => {
  1576. const column = this.findObject(this.collectionOption.column, "plateNo");
  1577. column.dicData = []
  1578. res.data.data.forEach(item => {
  1579. column.dicData.push({label: item})
  1580. })
  1581. this.key++
  1582. });
  1583. // this.findObject(this.paymentOption.column, "plateNo").change = (data) => {
  1584. // const columnTwo = this.findObject(this.paymentOption.column, "plateNo");
  1585. // columnTwo.dicData = []
  1586. // queryVehicle({orderId: this.id,fleetId:data.row.fleetId}).then(res => {
  1587. // res.data.data.forEach(item => {
  1588. // columnTwo.dicData.push({label: item})
  1589. // })
  1590. // });
  1591. // this.key++
  1592. // }
  1593. this.$refs.other.show = false
  1594. // 非租户模式默认加载管理组数据
  1595. if (!website.tenantMode) {
  1596. this.initData(website.tenantId);
  1597. } else {
  1598. this.initData();
  1599. }
  1600. },
  1601. methods: {
  1602. schedulingFileSaving(){
  1603. this.c_button = true
  1604. conserveDispatch({
  1605. fileList:this.orderFilesList,
  1606. id:this.goodsForm.id
  1607. }).then(res=>{
  1608. checkAttachment({id:this.goodsForm.id}).then(res=>{
  1609. this.orderFilesList = res.data.data
  1610. this.c_button = false
  1611. })
  1612. })
  1613. },
  1614. openTrack(row){
  1615. gaude({itemId: row.id,plateNo:row.plateNo,tenantId:'234557',color:'2'}).then(res => {
  1616. this.lineArr = res.data.data.trackArray
  1617. this.dialogVisibleTwo = true
  1618. let this_=this
  1619. setTimeout(function(){
  1620. this_.$refs.playback.initMap();
  1621. },100)
  1622. })
  1623. // location({itemId: row.id,plateNo:'陕YH0008'}).then(res => {
  1624. // // console.log(res.data.data)
  1625. // // console.log(this.lineArr[this.lineArr.length - 1])
  1626. // })
  1627. },
  1628. //自定义列保存
  1629. async saveColumnBoxTwo() {
  1630. /**
  1631. * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
  1632. * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
  1633. * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
  1634. */
  1635. const inSave = await this.saveColumnData(this.getColumnName(86.1), this.entrustOptionTwoT);
  1636. if (inSave) {
  1637. this.$message.success("保存成功");
  1638. //关闭窗口
  1639. this.$refs.crudBoxTwo.$refs.dialogColumn.columnBox = false;
  1640. }
  1641. },
  1642. //自定义列重置
  1643. async resetColumnBoxTwo() {
  1644. this.entrustOptionTwoT = this.entrustOptionTwoTBackup;
  1645. const inSave = await this.delColumnData(this.getColumnName(86.1), this.entrustOptionTwoTBackup);
  1646. if (inSave) {
  1647. this.$message.success("重置成功");
  1648. this.$refs.crudBoxTwo.$refs.dialogColumn.columnBox = false;
  1649. }
  1650. if (this.roleNameTwo.indexOf('总调度') !== -1){
  1651. this.entrustOptionTwoT.menu = false
  1652. this.collectionOption.menu = false
  1653. this.paymentOption.menu = false
  1654. }
  1655. },
  1656. //自定义列保存
  1657. async saveColumnCollection() {
  1658. /**
  1659. * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
  1660. * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
  1661. * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
  1662. */
  1663. const inSave = await this.saveColumnData(this.getColumnName(86.4), this.collectionOption);
  1664. if (inSave) {
  1665. this.$message.success("保存成功");
  1666. //关闭窗口
  1667. this.$refs.collection.$refs.dialogColumn.columnBox = false;
  1668. }
  1669. },
  1670. //自定义列重置
  1671. async resetColumnCollection() {
  1672. this.collectionOption = this.collectionOptionBackup;
  1673. const inSave = await this.delColumnData(this.getColumnName(86.4), this.collectionOptionBackup);
  1674. if (inSave) {
  1675. this.$message.success("重置成功");
  1676. this.$refs.collection.$refs.dialogColumn.columnBox = false;
  1677. }
  1678. },
  1679. //自定义列保存
  1680. async saveColumnPayment() {
  1681. /**
  1682. * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
  1683. * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
  1684. * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
  1685. */
  1686. const inSave = await this.saveColumnData(this.getColumnName(86.5), this.paymentOption);
  1687. if (inSave) {
  1688. this.findObject(this.paymentOption.column, "fleetId").dicUrl = "/api/blade-land/order-fee/fleet?orderId=" + this.id
  1689. this.findObject(this.paymentOption.column, "plateNo").dicUrl = "api/blade-land/order-fee/plate-no?orderId=" + this.id + '&fleetId={{key}}'
  1690. this.$message.success("保存成功");
  1691. //关闭窗口
  1692. this.$refs.payment.$refs.dialogColumn.columnBox = false;
  1693. }
  1694. },
  1695. //自定义列重置
  1696. async resetColumnPayment() {
  1697. this.paymentOption = this.paymentOptionBackup;
  1698. const inSave = await this.delColumnData(this.getColumnName(86.5), this.paymentOptionBackup);
  1699. if (inSave) {
  1700. this.$message.success("重置成功");
  1701. this.findObject(this.paymentOption.column, "fleetId").dicUrl = "/api/blade-land/order-fee/fleet?orderId=" + this.id
  1702. this.findObject(this.paymentOption.column, "plateNo").dicUrl = "api/blade-land/order-fee/plate-no?orderId=" + this.id + '&fleetId={{key}}'
  1703. this.$refs.payment.$refs.dialogColumn.columnBox = false;
  1704. }
  1705. },
  1706. //打开附件
  1707. annexOpen(row, index) {
  1708. this.enclosure = true
  1709. this.formAnnex = row
  1710. getFee({id: row.id}).then(res => {
  1711. this.orderList = res.data.data
  1712. })
  1713. },
  1714. //保存
  1715. saveAnnex() {
  1716. saveFile({
  1717. id: this.formAnnex.id,
  1718. fileList: this.orderList
  1719. }).then(res => {
  1720. this.$message.success("保存成功");
  1721. this.annexOpen(this.formAnnex)
  1722. })
  1723. },
  1724. getCorpData(val) {
  1725. this.formData.fleetName = val.cname
  1726. },
  1727. confirmChange() {
  1728. changeFleet({
  1729. ...this.formData,
  1730. id: this.formDataList.id,
  1731. orderId: this.goodsForm.id,
  1732. originalFleetName: this.formDataList.fleetName
  1733. }).then(res => {
  1734. this.$refs.saveForm.resetForm()
  1735. this.entrustList = res.data.data
  1736. this.dialogChange = false
  1737. this.$message.success("变更成功");
  1738. })
  1739. },
  1740. //查询业务部门
  1741. initData(tenantId) {
  1742. getDeptTree(tenantId).then(res => {
  1743. const column = this.findObject(this.goodsOptionForm.column, "salesmanDept");
  1744. column.dicData = res.data.data;
  1745. });
  1746. },
  1747. //多选触发
  1748. selectionChange(list) {
  1749. this.selectionList = list
  1750. },
  1751. //批量调度
  1752. batchScheduling() {
  1753. this.form = {}
  1754. this.dialogVisible = true
  1755. },
  1756. //提交调度
  1757. saveScheduling() {
  1758. this.$refs['form'].validate((valid, done) => {
  1759. done()
  1760. if (valid) {
  1761. let data = []
  1762. this.$confirm('是否确认调度?', '提示', {
  1763. confirmButtonText: '确定',
  1764. cancelButtonText: '取消',
  1765. type: 'warning'
  1766. }).then(() => {
  1767. this.selectionList.forEach(item => data.push(item.id))
  1768. dispatchBatch({
  1769. ...this.form,
  1770. idList: data,
  1771. orderId: this.goodsForm.id
  1772. }).then(res => {
  1773. this.entrustList = res.data.data
  1774. this.dialogVisible = false
  1775. })
  1776. }).catch(() => {
  1777. this.$message({
  1778. type: 'info',
  1779. message: '已取消'
  1780. });
  1781. });
  1782. } else {
  1783. return false
  1784. }
  1785. })
  1786. },
  1787. //刷新数据
  1788. refreshData() {
  1789. detailDelegationList({id: this.id, kind: '2'}).then(res => {
  1790. this.goodsForm = res.data.data
  1791. this.tableData = res.data.data.orderAddressList
  1792. this.entrustList = res.data.data.orderItemList
  1793. this.goodsList = res.data.data.orderItemList
  1794. this.orderFilesList = res.data.data.fileList
  1795. if (res.data.data.orderFeeList.length > 0) {
  1796. res.data.data.orderFeeList.forEach(item => {
  1797. if (item.type == 1) {
  1798. this.collectionList.push(item)
  1799. } else {
  1800. this.paymentList.push(item)
  1801. }
  1802. })
  1803. }
  1804. delete this.goodsForm.orderAddressList
  1805. delete this.goodsForm.orderItemList
  1806. delete this.goodsForm.orderFeeList
  1807. // this.tableData.forEach(item => {
  1808. // if (item.region) item.region = item.region.split(',')
  1809. // })
  1810. })
  1811. },
  1812. //切换收付费
  1813. handleSelect(tab, event) {
  1814. this.activeIndex = tab.name
  1815. },
  1816. //箱信息保存
  1817. rowSaveT(row, index, done, loading) {
  1818. if (row.$cellEdit) {
  1819. fleetDriverSave(row).then(res => {
  1820. this.$message.success("保存成功");
  1821. })
  1822. }
  1823. this.$refs.crudBoxTwo.rowCell(row, index)
  1824. },
  1825. //调度并且派车
  1826. rowSaveThree(row, index, done, loading) {
  1827. if (row.$cellEdit) {
  1828. if (!row.plateNo) {
  1829. return this.$message.warning('未选择车号,请选择');
  1830. }
  1831. if (!row.fleetId){
  1832. return this.$message.warning('请选择车队');
  1833. }
  1834. this.$confirm('是否确定调度派车', '提示', {
  1835. confirmButtonText: '确定',
  1836. cancelButtonText: '取消',
  1837. type: 'warning'
  1838. }).then(() => {
  1839. sendACarCollection(row).then(res => {
  1840. this.$message.success('操作成功');
  1841. this.$refs.crudBoxTwo.rowCell(row, index)
  1842. this.refreshData()
  1843. })
  1844. }).catch(() => {
  1845. this.$message({
  1846. type: 'info',
  1847. message: '已取消'
  1848. });
  1849. this.$refs.crudBoxTwo.rowCell(row, index)
  1850. });
  1851. }else {
  1852. this.entrustOptionTwoT.column.forEach(item=>{
  1853. if (item.prop === 'plateNo'){
  1854. item.cell = true
  1855. }
  1856. })
  1857. this.$refs.crudBoxTwo.rowCell(row, index)
  1858. }
  1859. },
  1860. rowSaveWell(row, index, done, loading) {
  1861. done()
  1862. },
  1863. //箱信息调度
  1864. designate(row, index) {
  1865. if (row.fleetId) {
  1866. this.$confirm('是否确定调度', '提示', {
  1867. confirmButtonText: '确定',
  1868. cancelButtonText: '取消',
  1869. type: 'warning'
  1870. }).then(() => {
  1871. dispatchCollection(row).then(res => {
  1872. this.$message.success('操作成功');
  1873. this.entrustList[index].status = res.data.data.status
  1874. })
  1875. }).catch(() => {
  1876. this.$message({
  1877. type: 'info',
  1878. message: '已取消'
  1879. });
  1880. });
  1881. } else {
  1882. this.$message.warning('请选择车队');
  1883. }
  1884. },
  1885. //变更车队
  1886. changeFleetT(row, index) {
  1887. this.formDataList = row
  1888. this.dialogChange = true
  1889. this.formData = row
  1890. },
  1891. //打开变更记录
  1892. recordsOfChanges(row, index) {
  1893. this.dialogRecord = true
  1894. recordingDetails({itemId: row.id, kind: 2}).then(res => {
  1895. this.dataRecord = res.data.data
  1896. })
  1897. },
  1898. //取消调度
  1899. cancelDesignate(row, index) {
  1900. this.$confirm('是否确定取消调度', '提示', {
  1901. confirmButtonText: '确定',
  1902. cancelButtonText: '取消',
  1903. type: 'warning'
  1904. }).then(() => {
  1905. cancelDispatchCollection({id: row.id}).then(res => {
  1906. this.$message.success('操作成功');
  1907. this.entrustList[index].status = res.data.data.status
  1908. })
  1909. }).catch(() => {
  1910. this.$message({
  1911. type: 'info',
  1912. message: '已取消'
  1913. });
  1914. });
  1915. },
  1916. //箱信息选择车队
  1917. getfleetIdT(data, row) {
  1918. this.$set(row, 'fleetName', data.cname)
  1919. console.log(this.$refs.crudBoxTwo)
  1920. // this.$refs.crudBoxTwo.handleChange({
  1921. // label: '车队',
  1922. // width: 200,
  1923. // index: 5,
  1924. // prop: 'fleetId',
  1925. // cascader: ['plateNo'],
  1926. // },row)
  1927. },
  1928. //地址新增
  1929. addAddress() {
  1930. this.tableData.splice(this.tableData.length - 1, 0, {leas: 1111})
  1931. },
  1932. //返回主列表
  1933. backToList(value) {
  1934. if (value === 0) {
  1935. this.$emit('backToList')
  1936. } else if (value === 1) {
  1937. this.$emit('backToList', true)
  1938. } else if (value === 2) {
  1939. this.$router.push({
  1940. path: '/landTransportation/reportAnalysis/index'
  1941. });
  1942. }
  1943. },
  1944. //删除途径地址
  1945. deleteAddress(scope) {
  1946. this.tableData.splice(scope.$index, 1);
  1947. },
  1948. //箱信息保存
  1949. rowSave(row, index, done, loading) {
  1950. row.$cellEdit = false
  1951. done()
  1952. },
  1953. rowCell(row, index) {
  1954. if (row.$cellEdit) {
  1955. if (row.plateNo) {
  1956. if (row.feeId){
  1957. incidentalSubmit(row).then(res => {
  1958. this.$refs.collection.rowCell(row, index)
  1959. row = res.data.data
  1960. this.$message.success("保存成功");
  1961. })
  1962. }else {
  1963. this.$message.error("请选择费用名称");
  1964. }
  1965. } else {
  1966. this.$message.error("请选择车号");
  1967. }
  1968. } else {
  1969. this.$refs.collection.rowCell(row, index)
  1970. }
  1971. },
  1972. paymentRowCell(row, index) {
  1973. if (row.$cellEdit) {
  1974. if (row.plateNo) {
  1975. if (row.feeId){
  1976. incidentalSubmit(row).then(res => {
  1977. row = res.data.data
  1978. this.$message.success("保存成功");
  1979. })
  1980. }else {
  1981. this.$message.error("请选择费用名称");
  1982. }
  1983. } else {
  1984. this.$message.error("请选择车号");
  1985. }
  1986. } else {
  1987. this.$refs.payment.rowCell(row, index)
  1988. }
  1989. },
  1990. //箱信息移除
  1991. rowDel(row, index) {
  1992. this.$confirm('此操作将永久删除该单据, 是否继续?', '提示', {
  1993. confirmButtonText: '确定',
  1994. cancelButtonText: '取消',
  1995. type: 'warning'
  1996. }).then(() => {
  1997. this.entrustList.splice(index, 1);
  1998. }).catch(() => {
  1999. this.$message({
  2000. type: 'info',
  2001. message: '已取消删除'
  2002. });
  2003. });
  2004. },
  2005. //保存
  2006. editCustomer() {
  2007. let data = JSON.parse(JSON.stringify(this.tableData))
  2008. // data.forEach(item => {
  2009. // if (item.region.length !== 0) item.region = item.region.join(',')
  2010. // })
  2011. saveDelegationList({
  2012. ...this.goodsForm,
  2013. kind: '2',
  2014. orderAddressList: data,
  2015. orderItemList: this.entrustList,
  2016. orderFeeList: this.collectionList.concat(this.paymentList)
  2017. }).then(res => {
  2018. this.$message.success('保存成功');
  2019. })
  2020. },
  2021. //收费新增
  2022. addRowCollection() {
  2023. customerList({size: 10, current: 1}).then(res => {
  2024. this.$refs.collection.rowCellAdd({
  2025. currency: '1',
  2026. type: '1',
  2027. feeId: res.data.data.records.length > 0 ? res.data.data.records[0].id : '',
  2028. unit: '件数',
  2029. corpId: this.goodsForm.corpId,
  2030. quantity: 1,
  2031. orderId: this.id,
  2032. $cellEdit: true
  2033. });
  2034. })
  2035. },
  2036. //付费新增
  2037. addRowPayment() {
  2038. customerList({size: 10, current: 1}).then(res => {
  2039. this.$refs.payment.rowCellAdd({
  2040. currency: '1',
  2041. type: '2',
  2042. feeId: res.data.data.records.length > 0 ? res.data.data.records[0].id : '',
  2043. unit: '件数',
  2044. quantity: 1,
  2045. // corpId: '1526835847238901762',
  2046. orderId: this.id,
  2047. $cellEdit: true
  2048. });
  2049. })
  2050. },
  2051. //选择费用
  2052. selectValue(value, row) {
  2053. this.$set(row, 'feeName', value.cname)
  2054. },
  2055. //选择客户信息触发
  2056. getfleetId(data, row) {
  2057. this.$set(row, 'corpName', data.cname)
  2058. },
  2059. //收款信息移除
  2060. makeDel(row, index) {
  2061. this.$confirm('此操作将永久删除该单据, 是否继续?', '提示', {
  2062. confirmButtonText: '确定',
  2063. cancelButtonText: '取消',
  2064. type: 'warning'
  2065. }).then(() => {
  2066. if (row.id) removeCollection(row.id)
  2067. this.collectionList.splice(index, 1);
  2068. }).catch(() => {
  2069. this.$message({
  2070. type: 'info',
  2071. message: '已取消删除'
  2072. });
  2073. });
  2074. },
  2075. //付款信息移除
  2076. feeDel(row, index) {
  2077. this.$confirm('此操作将永久删除该单据, 是否继续?', '提示', {
  2078. confirmButtonText: '确定',
  2079. cancelButtonText: '取消',
  2080. type: 'warning'
  2081. }).then(() => {
  2082. if (row.id) removeCollection(row.id)
  2083. this.paymentList.splice(index, 1);
  2084. }).catch(() => {
  2085. this.$message({
  2086. type: 'info',
  2087. message: '已取消删除'
  2088. });
  2089. });
  2090. },
  2091. //自定义表头
  2092. renderHeader(h) {
  2093. return (
  2094. <div>
  2095. <el-tooltip className="item" effect="dark" content="增加途径地址" placement="top">
  2096. <el-button type="primary" icon="el-icon-plus" size="mini" circle onClick={() => this.addAddress()}
  2097. style="margin-right: 1.25rem;"></el-button>
  2098. </el-tooltip>
  2099. </div>
  2100. )
  2101. }
  2102. }
  2103. }
  2104. </script>
  2105. <style scoped lang="scss">
  2106. ::v-deep .el-form-item {
  2107. margin-bottom: 8px;
  2108. }
  2109. ::v-deep .el-form-item__content {
  2110. line-height: 32px;
  2111. }
  2112. ::v-deep .el-card__body {
  2113. padding: 10px 15px;
  2114. font-size: 14px;
  2115. }
  2116. </style>