AddOrUpdate.vue 93 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919
  1. <template>
  2. <div>
  3. <el-breadcrumb separator="/">
  4. <el-breadcrumb-item
  5. ><span style="font-weight: 700">入库</span></el-breadcrumb-item
  6. >
  7. <el-breadcrumb-item
  8. ><span style="font-weight: 700">入库详情页</span></el-breadcrumb-item
  9. >
  10. </el-breadcrumb>
  11. <br />
  12. <div>
  13. <el-popconfirm title="是否确认离开此页面?" @confirm="changeShow">
  14. <el-button slot="reference" size="mini" icon="el-icon-arrow-left"
  15. >返回列表</el-button
  16. >
  17. </el-popconfirm>
  18. </div>
  19. <br />
  20. <el-form ref="form" :model="form" :rules="rules" label-width="120px">
  21. <el-row>
  22. <el-col :span="8">
  23. <el-form-item label="货权方" prop="fCorpid">
  24. <el-select
  25. v-model="form.fCorpid"
  26. clearable
  27. filterable
  28. remote
  29. reserve-keyword
  30. placeholder="请输入关键词"
  31. :remote-method="corpremoteMethod"
  32. :loading="selectloading"
  33. @clear="clear('fCorpid')"
  34. style="width: 80%"
  35. >
  36. <el-option
  37. v-for="(item, index) in fMblnoOptions"
  38. :key="index.fId"
  39. :label="item.fName"
  40. :value="item.fId"
  41. ></el-option>
  42. </el-select>
  43. </el-form-item>
  44. </el-col>
  45. <el-col :span="8">
  46. <el-form-item label="结算方式" prop="fStltypeid">
  47. <el-select
  48. v-model="form.fStltypeid"
  49. placeholder="请选择结算方式"
  50. clearable
  51. :disabled="browseStatus || formBrowseStatus"
  52. style="width: 80%"
  53. >
  54. <el-option
  55. v-for="(item, index) in fStltypeOptions"
  56. :key="index.dictValue"
  57. :label="item.dictLabel"
  58. :value="item.dictValue"
  59. />
  60. </el-select>
  61. </el-form-item>
  62. </el-col>
  63. <el-col :span="8">
  64. <el-form-item label="提单号" prop="fMblno">
  65. <el-input
  66. v-model="form.fMblno"
  67. :disabled="browseStatus || formBrowseStatus"
  68. style="width: 80%"
  69. placeholder="手工输入"
  70. />
  71. </el-form-item>
  72. </el-col>
  73. </el-row>
  74. <el-row>
  75. <el-col :span="8">
  76. <el-form-item label="入库日期" prop="fBsdate">
  77. <el-date-picker
  78. v-model="form.fBsdate"
  79. style="width: 80%"
  80. type="date"
  81. :disabled="browseStatus || formBrowseStatus"
  82. value-format="timestamp"
  83. placeholder="入库日期"
  84. @change="changeDate"
  85. >
  86. </el-date-picker>
  87. </el-form-item>
  88. </el-col>
  89. <el-col :span="8">
  90. <el-form-item label="入库时间" prop="fBstime">
  91. <el-time-picker
  92. style="width: 80%"
  93. :disabled="browseStatus || formBrowseStatus"
  94. v-model="form.fBstime"
  95. :picker-options="{
  96. selectableRange: '00:00:00 - 23:59:59',
  97. }"
  98. value-format="timestamp"
  99. placeholder="任意时间点"
  100. >
  101. </el-time-picker>
  102. </el-form-item>
  103. </el-col>
  104. <el-col :span="8">
  105. <el-form-item prop="fChargedate" label="仓储费计算日期">
  106. <el-date-picker
  107. v-model="form.fChargedate"
  108. type="date"
  109. style="width: 80%"
  110. value-format="timestamp"
  111. :disabled="browseStatus || formBrowseStatus"
  112. placeholder="仓储费计算日期"
  113. >
  114. </el-date-picker>
  115. </el-form-item>
  116. </el-col>
  117. <el-col :span="8">
  118. <el-form-item prop="fGoodsid" label="品名">
  119. <el-select
  120. filterable
  121. v-model="form.fGoodsid"
  122. style="width: 80%"
  123. :disabled="browseStatus || formBrowseStatus"
  124. placeholder="请选择品名"
  125. >
  126. <el-option
  127. v-for="(item, index) in goodsOptions"
  128. :key="index.fId"
  129. :label="item.fName"
  130. :value="item.fId"
  131. ></el-option>
  132. </el-select>
  133. </el-form-item>
  134. </el-col>
  135. <el-col :span="8">
  136. <el-form-item label="仓库" prop="fWarehouseid">
  137. <el-select
  138. v-model="form.fWarehouseid"
  139. filterable
  140. :disabled="browseStatus || formBrowseStatus"
  141. style="width: 80%"
  142. @keyup.enter.native="handleQuery"
  143. placeholder="请选择"
  144. >
  145. <el-option
  146. v-for="(item, index) in warehouseOptions"
  147. :key="index.fId"
  148. :label="item.fName"
  149. :value="item.fId"
  150. ></el-option>
  151. </el-select>
  152. </el-form-item>
  153. </el-col>
  154. <el-col :span="8">
  155. <el-form-item label="仓管员" prop="fStorekeeper">
  156. <el-select
  157. v-model="form.fStorekeeper"
  158. filterable
  159. remote
  160. clearable
  161. reserve-keyword
  162. :disabled="browseStatus || formBrowseStatus"
  163. style="width: 80%"
  164. :remote-method="userRemoteMethod"
  165. placeholder="请输入模糊查找"
  166. :loading="selectloading"
  167. @clear="clear('fStorekeeper')"
  168. >
  169. <el-option
  170. v-for="(item, index) in userOptions"
  171. :key="index.userName"
  172. :label="item.nickName"
  173. :value="item.userName"
  174. ></el-option>
  175. </el-select>
  176. </el-form-item>
  177. </el-col>
  178. </el-row>
  179. <el-row>
  180. <el-col :span="8">
  181. <el-form-item label="计划件数" prop="fPlanqty">
  182. <el-input
  183. v-model.number="form.fPlanqty"
  184. style="width: 80%"
  185. maxlength="9"
  186. laceholder="计划件数"
  187. :disabled="browseStatus || current !== before"
  188. />
  189. </el-form-item>
  190. </el-col>
  191. <el-col :span="8">
  192. <el-form-item label="计划净重(kg)" prop="fPlannetweight">
  193. <el-input
  194. v-model.number="form.fPlannetweight"
  195. style="width: 80%"
  196. maxlength="9"
  197. v-input-limit="0"
  198. laceholder="计划净重"
  199. :disabled="browseStatus || current !== before"
  200. />
  201. </el-form-item>
  202. </el-col>
  203. <el-col :span="8">
  204. <el-form-item label="计划毛重(kg)" prop="fPlangrossweight">
  205. <el-input
  206. v-model.number="form.fPlangrossweight"
  207. v-input-limit="0"
  208. style="width: 80%"
  209. laceholder="计划毛重"
  210. maxlength="9"
  211. :disabled="browseStatus || current !== before"
  212. />
  213. </el-form-item>
  214. </el-col>
  215. </el-row>
  216. <el-row>
  217. <el-col :span="8">
  218. <el-form-item label="作业类型" prop="fBusinessType">
  219. <el-select
  220. style="width: 80%"
  221. v-model="form.fBusinessType"
  222. filterable
  223. :disabled="contrOl || browseStatus"
  224. >
  225. <el-option
  226. v-for="(item, index) in businessTypeOption"
  227. :key="index.dictValue"
  228. :label="item.dictLabel"
  229. :value="item.dictValue"
  230. ></el-option>
  231. </el-select>
  232. </el-form-item>
  233. </el-col>
  234. <el-col :span="8">
  235. <el-form-item label="劳务公司" prop="fLabour">
  236. <el-select
  237. style="width: 80%"
  238. v-model="form.fLabour"
  239. clearable
  240. filterable
  241. remote
  242. reserve-keyword
  243. placeholder="请输入关键词"
  244. :remote-method="flabourRemoteMethod"
  245. :loading="selectloading"
  246. @clear="clear('fLabour')"
  247. >
  248. <el-option
  249. v-for="(item, index) in fCompanyOptIons"
  250. :key="index.fId"
  251. :label="item.fName"
  252. :value="item.fId"
  253. ></el-option>
  254. </el-select>
  255. </el-form-item>
  256. </el-col>
  257. <el-col :span="8">
  258. <el-form-item
  259. label="车队"
  260. prop="fFleet"
  261. :rules="{
  262. required: isrequired === 1 ? true : false,
  263. message: '请选择',
  264. trigger: ['blur', 'change'],
  265. }"
  266. >
  267. <el-select
  268. style="width: 80%"
  269. v-model="form.fFleet"
  270. clearable
  271. filterable
  272. remote
  273. reserve-keyword
  274. placeholder="请输入关键词"
  275. :remote-method="fleetRemoteMethod"
  276. :disabled="contrOl || browseStatus"
  277. :loading="selectloading"
  278. @clear="clear('fFleet')"
  279. >
  280. <el-option
  281. v-for="(item, index) in fleetOptions"
  282. :key="index.fId"
  283. :label="item.fName"
  284. :value="item.fId"
  285. ></el-option>
  286. </el-select>
  287. </el-form-item>
  288. </el-col>
  289. </el-row>
  290. <el-row>
  291. <el-col :span="8">
  292. <el-form-item label="计费单位" prop="fFeetunit">
  293. <el-select
  294. v-model="form.fFeetunit"
  295. placeholder="请选择计费单位"
  296. clearable
  297. :disabled="browseStatus || formBrowseStatus"
  298. style="width: 80%"
  299. >
  300. <el-option
  301. v-for="(item, index) in fFeetunitOptions"
  302. :key="index.dictValue"
  303. :label="item.dictLabel"
  304. :value="item.dictValue"
  305. />
  306. </el-select>
  307. </el-form-item>
  308. </el-col>
  309. <el-col :span="8">
  310. <el-form-item
  311. label="车号"
  312. prop="fTruckno"
  313. :rules="{
  314. required: isrequired_s === 1 ? true : false,
  315. message: '请选择',
  316. trigger: ['blur', 'change'],
  317. }"
  318. >
  319. <el-input
  320. v-model="form.fTruckno"
  321. style="width: 80%"
  322. :disabled="browseStatus || formBrowseStatus"
  323. placeholder="车号"
  324. />
  325. </el-form-item>
  326. </el-col>
  327. <el-col :span="8">
  328. <el-form-item
  329. label="司机姓名"
  330. prop="fDriverName"
  331. :rules="{
  332. required: isrequired_s === 1 ? true : false,
  333. message: '请选择',
  334. trigger: ['blur', 'change'],
  335. }"
  336. >
  337. <el-input
  338. v-model="form.fDriverName"
  339. style="width: 80%"
  340. :disabled="browseStatus || formBrowseStatus"
  341. placeholder="司机姓名"
  342. />
  343. </el-form-item>
  344. </el-col>
  345. </el-row>
  346. <el-row>
  347. <el-col :span="16">
  348. <el-row>
  349. <el-col :span="12">
  350. <el-form-item
  351. label="司机身份证"
  352. prop="fDriverIdCar"
  353. :rules="{
  354. required: isrequired_s === 1 ? true : false,
  355. message: '请选择',
  356. trigger: ['blur', 'change'],
  357. }"
  358. >
  359. <el-input
  360. v-model="form.fDriverIdCar"
  361. style="width: 80%"
  362. :disabled="browseStatus || formBrowseStatus"
  363. placeholder="司机身份证"
  364. />
  365. </el-form-item>
  366. </el-col>
  367. <el-col :span="12">
  368. <el-form-item
  369. label="司机电话"
  370. prop="fDriverTel"
  371. :rules="{
  372. required: isrequired_s === 1 ? true : false,
  373. message: '请选择',
  374. trigger: ['blur', 'change'],
  375. }"
  376. >
  377. <el-input
  378. v-model="form.fDriverTel"
  379. style="width: 80%"
  380. :disabled="browseStatus || formBrowseStatus"
  381. placeholder="司机电话"
  382. />
  383. </el-form-item>
  384. </el-col>
  385. </el-row>
  386. <el-row>
  387. <el-col :span="24">
  388. <el-form-item label="备注" prop="remark">
  389. <el-input
  390. style="width: 91.5%"
  391. v-model="form.remark"
  392. type="textarea"
  393. :disabled="browseStatus"
  394. placeholder="请输入内容"
  395. />
  396. </el-form-item>
  397. </el-col>
  398. </el-row>
  399. <el-row>
  400. <el-col :offset="16" :span="2">
  401. <el-form-item>
  402. <el-button
  403. @click="
  404. detailsHidden
  405. ? (detailsHidden = false)
  406. : (detailsHidden = true)
  407. "
  408. >{{ detailsHidden ? "隐藏" : "展开" }}
  409. </el-button>
  410. </el-form-item>
  411. </el-col>
  412. </el-row>
  413. </el-col>
  414. <el-col :span="8">
  415. <el-form-item>
  416. <el-table
  417. :data="CntrTable"
  418. style="width: 80%"
  419. :header-cell-style="{ lineHeight: '16px' }"
  420. height="139"
  421. >
  422. <el-table-column
  423. prop="fCntrid "
  424. label="箱型"
  425. header-align="center"
  426. align="center"
  427. >
  428. <template slot-scope="scope">
  429. <el-select
  430. placeholder="请选择箱型"
  431. v-model="scope.row.fCntrid"
  432. size="mini"
  433. >
  434. <el-option
  435. v-for="(item, index) in fCntridlist"
  436. :key="index.value"
  437. :label="item.label"
  438. :value="item.value"
  439. >
  440. </el-option>
  441. </el-select>
  442. </template>
  443. </el-table-column>
  444. <el-table-column
  445. prop="fCntrcount"
  446. label="箱量"
  447. header-align="center"
  448. align="center"
  449. >
  450. <template slot-scope="scope">
  451. <el-input
  452. placeholder="请输入箱量"
  453. v-model="scope.row.fCntrcount"
  454. size="mini"
  455. >
  456. </el-input>
  457. </template>
  458. </el-table-column>
  459. <el-table-column
  460. prop="fCntrcount"
  461. label="操作"
  462. header-align="center"
  463. align="center"
  464. width="50"
  465. >
  466. <template slot-scope="scope">
  467. <el-button
  468. size="mini"
  469. type="text"
  470. @click.native.prevent="deleteRow(scope.$index, CntrTable)"
  471. icon="el-icon-delete"
  472. ></el-button>
  473. </template>
  474. </el-table-column>
  475. </el-table>
  476. <div style="display: flex; justify-content: center; width: 80%">
  477. <el-tag class="tag-hover" @click="addRow"
  478. ><i class="el-icon-plus"></i
  479. ></el-tag>
  480. </div>
  481. </el-form-item>
  482. </el-col>
  483. </el-row>
  484. <div v-if="detailsHidden">
  485. <el-row style="margin-top: 30px">
  486. <el-col :span="8">
  487. <el-form-item label="仓库联系人" prop="fContacts">
  488. <el-input
  489. v-model="form.fContacts"
  490. style="width: 80%"
  491. :disabled="browseStatus || formBrowseStatus"
  492. placeholder="仓库联系人"
  493. />
  494. </el-form-item>
  495. </el-col>
  496. <el-col :span="8">
  497. <el-form-item label="仓库电话" prop="fTel">
  498. <el-input
  499. v-model="form.fTel"
  500. :disabled="browseStatus || formBrowseStatus"
  501. style="width: 80%"
  502. placeholder="请输仓库入电话"
  503. />
  504. </el-form-item>
  505. </el-col>
  506. <el-col :span="8">
  507. <el-form-item label="船名航次" prop="fVslvoy">
  508. <el-input
  509. v-model="form.fVslvoy"
  510. style="width: 80%"
  511. :disabled="browseStatus || formBrowseStatus"
  512. placeholder="船名航次"
  513. />
  514. </el-form-item>
  515. </el-col>
  516. </el-row>
  517. <el-row>
  518. <el-col :span="8">
  519. <el-form-item label="到港日期" prop="fEta">
  520. <el-date-picker
  521. v-model="form.fEta"
  522. style="width: 80%"
  523. type="date"
  524. :disabled="browseStatus || formBrowseStatus"
  525. value-format="timestamp"
  526. placeholder="到港日期"
  527. >
  528. </el-date-picker>
  529. </el-form-item>
  530. </el-col>
  531. <el-col :span="8">
  532. <el-form-item label="报关单号" prop="fCustomno">
  533. <el-input
  534. v-model="form.fCustomno"
  535. style="width: 80%"
  536. :disabled="browseStatus || formBrowseStatus"
  537. laceholder="报关单号"
  538. />
  539. </el-form-item>
  540. </el-col>
  541. <el-col :span="8">
  542. <el-form-item label="经营单位" prop="fSbu">
  543. <el-select
  544. v-model="form.fSbu"
  545. clearable
  546. filterable
  547. remote
  548. reserve-keyword
  549. placeholder="请输入关键词"
  550. :remote-method="fSbuRemoteMethod"
  551. :loading="selectloading"
  552. @clear="clear('fSbu')"
  553. >
  554. <el-option
  555. v-for="(item, index) in fSbuOptions"
  556. :key="index.fId"
  557. :label="item.fName"
  558. :value="item.fId"
  559. ></el-option>
  560. </el-select>
  561. </el-form-item>
  562. </el-col>
  563. </el-row>
  564. <el-row>
  565. <el-col :span="8">
  566. <el-form-item label="单据编号" prop="fBillno">
  567. <el-input
  568. v-model="form.fBillno"
  569. disabled
  570. style="width: 80%"
  571. placeholder="单据编号"
  572. />
  573. </el-form-item>
  574. </el-col>
  575. <el-col :span="8">
  576. <el-form-item label="贸易方式" prop="fTrademodeid">
  577. <el-select
  578. v-model="form.fTrademodeid"
  579. placeholder="请选择贸易方式"
  580. :disabled="browseStatus || formBrowseStatus"
  581. clearable
  582. style="width: 80%"
  583. >
  584. <el-option
  585. v-for="(item, index) in fTrademodeidOptions"
  586. :key="index.dictValue"
  587. :label="item.dictLabel"
  588. :value="item.dictValue"
  589. />
  590. </el-select>
  591. </el-form-item>
  592. </el-col>
  593. <el-col :span="8">
  594. <el-form-item label="制单人" prop="createBy">
  595. <el-input
  596. disabled
  597. v-model="form.createBy"
  598. style="width: 80%"
  599. placeholder="制单人"
  600. />
  601. </el-form-item>
  602. </el-col>
  603. </el-row>
  604. <el-row>
  605. <el-col :span="8">
  606. <el-form-item label="制单部门" prop="fDeptid">
  607. <el-select
  608. v-model="form.fDeptid"
  609. filterable
  610. disabled
  611. style="width: 80%"
  612. remote
  613. >
  614. <el-option
  615. v-for="(item, index) in deptOptions"
  616. :key="index.deptId"
  617. :label="item.deptName"
  618. :value="item.deptId"
  619. ></el-option>
  620. </el-select>
  621. </el-form-item>
  622. </el-col>
  623. <el-col :span="8">
  624. <el-form-item disabled label="制单日期" prop="fbilldate">
  625. <el-date-picker
  626. v-model="form.createTime"
  627. size="large"
  628. type="date"
  629. disabled
  630. style="width: 80%"
  631. value-format="timestamp"
  632. placeholder="制单日期"
  633. >
  634. </el-date-picker>
  635. </el-form-item>
  636. </el-col>
  637. <el-col :span="8">
  638. <el-form-item label="过磅" prop="fIfweigh">
  639. <el-select
  640. v-model="form.fIfweigh"
  641. placeholder="请选择是否过磅"
  642. clearable
  643. :disabled="browseStatus || formBrowseStatus"
  644. style="width: 80%"
  645. >
  646. <el-option
  647. v-for="(item, index) in fIfweighOptions"
  648. :key="index.dictValue"
  649. :label="item.dictLabel"
  650. :value="item.dictValue"
  651. />
  652. </el-select>
  653. </el-form-item>
  654. </el-col>
  655. </el-row>
  656. <el-row>
  657. <el-col :span="8">
  658. <el-form-item label="品名" prop="fProductName">
  659. <el-input
  660. v-model="form.fProductName"
  661. style="width: 80%"
  662. disabled
  663. placeholder="品名"
  664. />
  665. </el-form-item>
  666. </el-col>
  667. <el-col :span="8">
  668. <el-form-item label="品牌">
  669. <el-input
  670. v-model="form.fMarks"
  671. style="width: 80%"
  672. disabled
  673. placeholder="品牌"
  674. />
  675. </el-form-item>
  676. </el-col>
  677. <el-col :span="8">
  678. <el-form-item label="存货编号" prop="fBscorpno">
  679. <el-input
  680. disabled
  681. v-model="form.fBscorpno"
  682. style="width: 80%"
  683. laceholder="存货编号"
  684. />
  685. </el-form-item>
  686. </el-col>
  687. </el-row>
  688. <el-row>
  689. <el-col :span="8">
  690. <el-form-item label="质押" prop="fIfpledge">
  691. <el-select
  692. v-model="form.fIfpledge"
  693. placeholder="请选择是否质押"
  694. clearable
  695. :disabled="browseStatus || formBrowseStatus"
  696. style="width: 80%"
  697. >
  698. <el-option
  699. v-for="(item, index) in fIfpledgeOptions"
  700. :key="index.dictValue"
  701. :label="item.dictLabel"
  702. :value="item.dictValue"
  703. />
  704. </el-select>
  705. </el-form-item>
  706. </el-col>
  707. <el-col :span="8">
  708. <el-form-item label="质押银行" prop="fBankcorpid">
  709. <el-select
  710. v-model="form.fBankcorpid"
  711. filterable
  712. remote
  713. clearable
  714. style="width: 80%"
  715. :disabled="browseStatus || formBrowseStatus"
  716. @keyup.enter.native="handleQuery"
  717. :remote-method="corpsRemoteMethodd"
  718. placeholder="请输入关键词"
  719. @clear="clear('fBankcorpid')"
  720. >
  721. <el-option
  722. v-for="(item, index) in Pledgebank"
  723. :key="index.fId"
  724. :label="item.fName"
  725. :value="item.fId"
  726. ></el-option>
  727. </el-select>
  728. </el-form-item>
  729. </el-col>
  730. </el-row>
  731. </div>
  732. </el-form>
  733. <el-collapse v-model="collapselist">
  734. <el-collapse-item name="1">
  735. <template slot="title">
  736. <i class="el-icon-s-home" style="font-size: 16px"></i>
  737. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  738. >入库明细</span
  739. >
  740. </template>
  741. <div>
  742. <el-row
  743. type="flex"
  744. justify="space-between"
  745. style="margin-bottom: 10px"
  746. >
  747. <el-col>
  748. <el-button
  749. type="primary"
  750. :disabled="browseStatus"
  751. size="small"
  752. @click="addRelevant"
  753. >新行
  754. </el-button>
  755. <el-button
  756. :disabled="browseStatus"
  757. type="primary"
  758. size="small"
  759. @click="saveForm"
  760. >保 存</el-button
  761. >
  762. </el-col>
  763. <el-col style="display: flex; justify-content: flex-end">
  764. <el-button
  765. size="small"
  766. type="info"
  767. :disabled="browseStatus"
  768. prop="打印"
  769. @click="printZyd"
  770. >作业单
  771. </el-button>
  772. <el-button
  773. size="small"
  774. :disabled="browseStatus"
  775. @click="discharge"
  776. >叫车进场</el-button
  777. >
  778. <el-button
  779. size="small"
  780. :disabled="dataListSelection.length <= 0 || browseStatus"
  781. @click="creditClick"
  782. >入库确认
  783. </el-button>
  784. <el-button
  785. size="small"
  786. :disabled="dataWithdrawList.length <= 0 || browseStatus"
  787. @click.prevent="withdrawClick"
  788. >撤回入库
  789. </el-button>
  790. <el-dropdown @command="handleCommand" style="margin-left: 10px">
  791. <el-button :disabled="browseStatus" size="small" type="success">
  792. 打印单据<i class="el-icon-arrow-down el-icon--right"></i>
  793. </el-button>
  794. <el-dropdown-menu slot="dropdown">
  795. <el-dropdown-item command="a">收货单</el-dropdown-item>
  796. <el-dropdown-item command="b">入库单</el-dropdown-item>
  797. <el-dropdown-item command="c">理货单</el-dropdown-item>
  798. <el-dropdown-item command="d">货物确认</el-dropdown-item>
  799. <el-dropdown-item command="e">劳务确认</el-dropdown-item>
  800. <el-dropdown-item command="f">吊牌信息</el-dropdown-item>
  801. </el-dropdown-menu>
  802. </el-dropdown>
  803. </el-col>
  804. </el-row>
  805. <el-table
  806. :data="detailList"
  807. tooltip-effect="dark"
  808. stripe
  809. :summary-method="getSummaries"
  810. @selection-change="Selectinventory"
  811. show-summary
  812. >
  813. <el-table-column type="selection" width="55" align="center" fixed />
  814. <el-table-column label="序号" type="index" width="80" fixed />
  815. <el-table-column
  816. prop="fBillstatus"
  817. header-align="center"
  818. width="150px"
  819. align="center"
  820. fixed
  821. label="状态"
  822. >
  823. <template slot-scope="scope">
  824. <span v-if="scope.row.fBillstatus === 10">计划</span>
  825. <span v-if="scope.row.fBillstatus === 20">待入库</span>
  826. <span v-if="scope.row.fBillstatus === 30">入库中</span>
  827. <span v-if="scope.row.fBillstatus === 40">已入库</span>
  828. </template>
  829. </el-table-column>
  830. <el-table-column
  831. fixed
  832. prop="fBsdate"
  833. header-align="center"
  834. align="center"
  835. width="150px"
  836. label="入库日期"
  837. :formatter="fBsdateFormat"
  838. />
  839. <el-table-column
  840. prop="fMblno"
  841. header-align="center"
  842. align="center"
  843. width="140px"
  844. label="提单号"
  845. />
  846. <el-table-column
  847. prop="fGoodsid"
  848. header-align="center"
  849. align="center"
  850. width="140px"
  851. label="*品名"
  852. :formatter="goodsFormat"
  853. />
  854. <el-table-column
  855. prop="fBusinessType"
  856. header-align="center"
  857. width="140px"
  858. align="center"
  859. label="*货物属性"
  860. :formatter="fStorageTypeFormat"
  861. />
  862. <el-table-column
  863. prop="fMarks"
  864. header-align="center"
  865. align="center"
  866. width="140px"
  867. label="*属性详情"
  868. />
  869. <el-table-column
  870. prop="fWarehouseInformation"
  871. header-align="center"
  872. width="240px"
  873. align="center"
  874. label="*库区"
  875. />
  876. <el-table-column
  877. prop="fCntrtype"
  878. header-align="center"
  879. align="center"
  880. width="140px"
  881. label="箱型"
  882. />
  883. <el-table-column
  884. prop="fCntqty"
  885. header-align="center"
  886. align="center"
  887. width="140px"
  888. label="箱量"
  889. />
  890. <el-table-column
  891. prop="fQty"
  892. header-align="center"
  893. width="150px"
  894. align="center"
  895. label="*入库件数"
  896. />
  897. <el-table-column
  898. prop="fGrossweight"
  899. header-align="center"
  900. width="180px"
  901. align="center"
  902. label="*入库毛重(kg)"
  903. />
  904. <el-table-column
  905. prop="fNetweight"
  906. header-align="center"
  907. width="180px"
  908. align="center"
  909. label="*入库净重(kg)"
  910. />
  911. <el-table-column
  912. prop="fPackagespecs"
  913. header-align="center"
  914. width="150px"
  915. align="center"
  916. label="*包装规格"
  917. />
  918. <el-table-column
  919. prop="fTruckno"
  920. header-align="center"
  921. width="130px"
  922. align="center"
  923. label="*车号"
  924. />
  925. <el-table-column
  926. prop="fDriverName"
  927. header-align="center"
  928. width="130px"
  929. align="center"
  930. label="司机名"
  931. />
  932. <el-table-column
  933. prop="fDriverTel"
  934. header-align="center"
  935. width="200px"
  936. align="center"
  937. label="司机电话"
  938. />
  939. <el-table-column
  940. prop="fDriverIdCar"
  941. header-align="center"
  942. width="200px"
  943. align="center"
  944. label="司机身份证"
  945. />
  946. <el-table-column
  947. prop="fSerialNumber"
  948. header-align="center"
  949. width="160px"
  950. align="center"
  951. label="流水号"
  952. />
  953. <el-table-column
  954. prop="fCntrno"
  955. header-align="center"
  956. width="130px"
  957. align="center"
  958. label="箱号"
  959. />
  960. <el-table-column
  961. prop="fGoodsval"
  962. header-align="center"
  963. width="130px"
  964. align="center"
  965. label="货值"
  966. />
  967. <el-table-column
  968. prop="remark"
  969. header-align="center"
  970. width="130px"
  971. align="center"
  972. label="备注"
  973. />
  974. <el-table-column
  975. header-align="center"
  976. align="center"
  977. label="操作"
  978. width="130PX"
  979. >
  980. <template slot-scope="scope">
  981. <el-button
  982. :disabled="
  983. browseStatus ||
  984. scope.row.fBillstatus === 20 ||
  985. scope.row.fBillstatus === 30 ||
  986. scope.row.fBillstatus === 40
  987. "
  988. type="text"
  989. @click.native.prevent="fixRow(scope.row, scope.$index)"
  990. size="small"
  991. >修改</el-button
  992. >
  993. <el-button
  994. :disabled="
  995. browseStatus ||
  996. scope.row.fBillstatus === 20 ||
  997. scope.row.fBillstatus === 30 ||
  998. scope.row.fBillstatus === 40
  999. "
  1000. type="text"
  1001. @click.native.prevent="wDeleteRow(scope.$index, detailList)"
  1002. size="small"
  1003. >移除</el-button
  1004. >
  1005. </template>
  1006. </el-table-column>
  1007. </el-table>
  1008. </div>
  1009. </el-collapse-item>
  1010. <el-collapse-item>
  1011. <template slot="title">
  1012. <i class="el-icon-s-order" style="font-size: 16px"></i>
  1013. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  1014. >附件明细</span
  1015. >
  1016. </template>
  1017. </el-collapse-item>
  1018. <el-collapse-item>
  1019. <template slot="title">
  1020. <i class="el-icon-circle-plus" style="font-size: 16px"></i>
  1021. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  1022. >收款信息</span
  1023. >
  1024. </template>
  1025. </el-collapse-item>
  1026. <el-collapse-item>
  1027. <template slot="title">
  1028. <i class="el-icon-remove" style="font-size: 16px"></i>
  1029. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  1030. >付款信息</span
  1031. >
  1032. </template>
  1033. </el-collapse-item>
  1034. </el-collapse>
  1035. <el-dialog
  1036. :title="title"
  1037. :visible.sync="weightList"
  1038. width="80%"
  1039. :close-on-click-modal="false"
  1040. >
  1041. <div>
  1042. <el-form
  1043. ref="importList"
  1044. :model="importList"
  1045. :rules="imporRules"
  1046. label-width="120px"
  1047. >
  1048. <el-row>
  1049. <el-col :span="8">
  1050. <el-form-item label="入库日期" prop="fBsdate">
  1051. <el-date-picker
  1052. v-model="importList.fBsdate"
  1053. type="date"
  1054. style="width: 80%"
  1055. value-format="timestamp"
  1056. placeholder="入库日期"
  1057. >
  1058. </el-date-picker>
  1059. </el-form-item>
  1060. </el-col>
  1061. <el-col :span="8">
  1062. <el-form-item label="品名" prop="fGoodsid">
  1063. <el-select
  1064. filterable
  1065. v-model="importList.fGoodsid"
  1066. style="width: 80%"
  1067. placeholder="请选择品名"
  1068. >
  1069. <el-option
  1070. v-for="(item, index) in goodsOptions"
  1071. :key="index.fId"
  1072. :label="item.fName"
  1073. :value="item.fId"
  1074. ></el-option>
  1075. </el-select>
  1076. </el-form-item>
  1077. </el-col>
  1078. <el-col :span="8">
  1079. <el-form-item label="货物属性" prop="fBusinessType">
  1080. <el-select
  1081. filterable
  1082. v-model="importList.fBusinessType"
  1083. style="width: 80%"
  1084. placeholder="请选择商品属性"
  1085. >
  1086. <el-option
  1087. v-for="(item, index) in fStorageTypeOptions"
  1088. :key="index.dictValue"
  1089. :label="item.dictLabel"
  1090. :value="item.dictValue"
  1091. />
  1092. </el-select>
  1093. </el-form-item>
  1094. </el-col>
  1095. </el-row>
  1096. <el-row>
  1097. <el-col :span="8">
  1098. <el-form-item label="属性详情" prop="fMarks">
  1099. <el-input
  1100. v-model="importList.fMarks"
  1101. style="width: 80%"
  1102. placeholder="请填写属性描述"
  1103. />
  1104. </el-form-item>
  1105. </el-col>
  1106. <el-col :span="8">
  1107. <el-form-item label="库区" prop="fWarehouseInformation">
  1108. <el-select
  1109. filterable
  1110. v-model="importList.fWarehouseInformation"
  1111. style="width: 80%"
  1112. placeholder="请选择库区"
  1113. >
  1114. <el-option
  1115. v-for="(item, index) in fWarehouseidOptions"
  1116. :key="index.id"
  1117. :label="item.label"
  1118. :value="item.fWarehouseInformation"
  1119. ></el-option>
  1120. </el-select>
  1121. </el-form-item>
  1122. </el-col>
  1123. <el-col :span="8">
  1124. <el-form-item label="箱型" prop="fCntrtype">
  1125. <el-input
  1126. v-model="importList.fCntrtype"
  1127. style="width: 80%"
  1128. maxlength="4"
  1129. placeholder="箱型"
  1130. />
  1131. </el-form-item>
  1132. </el-col>
  1133. </el-row>
  1134. <el-row>
  1135. <el-col :span="8">
  1136. <el-form-item label="计划件数" prop="fQty">
  1137. <el-input
  1138. v-input-limit="0"
  1139. v-model.number="importList.fQty"
  1140. style="width: 80%"
  1141. placeholder="计划件数"
  1142. @input="imporComputer"
  1143. />
  1144. </el-form-item>
  1145. </el-col>
  1146. <el-col :span="8">
  1147. <el-form-item label="计划净重(kg)" prop="fNetweight">
  1148. <el-input
  1149. v-model.number="importList.fNetweight"
  1150. v-input-limit="2"
  1151. style="width: 80%"
  1152. disabled
  1153. placeholder="计划毛重"
  1154. />
  1155. </el-form-item>
  1156. </el-col>
  1157. <el-col :span="8">
  1158. <el-form-item label="计划毛重(kg)" prop="fGrossweight">
  1159. <el-input
  1160. v-model.number="importList.fGrossweight"
  1161. v-input-limit="2"
  1162. style="width: 80%"
  1163. disabled
  1164. placeholder="计划毛重"
  1165. />
  1166. </el-form-item>
  1167. </el-col>
  1168. </el-row>
  1169. <el-row>
  1170. <el-col :span="8">
  1171. <el-form-item label="箱量" prop="fCntqty">
  1172. <el-input
  1173. v-model="importList.fCntqty"
  1174. style="width: 80%"
  1175. placeholder="箱量"
  1176. />
  1177. </el-form-item>
  1178. </el-col>
  1179. <el-col :span="8">
  1180. <el-form-item label="包装规格" prop="fPackagespecs">
  1181. <el-input
  1182. v-model="importList.fPackagespecs"
  1183. style="width: 80%"
  1184. placeholder="包装规格"
  1185. />
  1186. </el-form-item>
  1187. </el-col>
  1188. <el-col :span="8">
  1189. <el-form-item label="车号" prop="fTruckno">
  1190. <el-input
  1191. v-model="importList.fTruckno"
  1192. style="width: 80%"
  1193. placeholder="车号"
  1194. />
  1195. </el-form-item>
  1196. </el-col>
  1197. </el-row>
  1198. <el-row>
  1199. <el-col :span="8">
  1200. <el-form-item label="司机名" prop="fDriverName">
  1201. <el-input
  1202. v-model="importList.fDriverName"
  1203. style="width: 80%"
  1204. placeholder="司机名"
  1205. />
  1206. </el-form-item>
  1207. </el-col>
  1208. <el-col :span="8">
  1209. <el-form-item label="司机电话" prop="fDriverTel">
  1210. <el-input
  1211. v-model="importList.fDriverTel"
  1212. style="width: 80%"
  1213. placeholder="司机电话"
  1214. />
  1215. </el-form-item>
  1216. </el-col>
  1217. <el-col :span="8">
  1218. <el-form-item label="司机身份证" prop="fDriverIdCar">
  1219. <el-input
  1220. v-model="importList.fDriverIdCar"
  1221. style="width: 80%"
  1222. placeholder="司机身份证"
  1223. />
  1224. </el-form-item>
  1225. </el-col>
  1226. </el-row>
  1227. <el-row>
  1228. <el-col :span="8">
  1229. <el-form-item label="流水号" prop="fSerialNumber">
  1230. <el-input
  1231. v-model="importList.fSerialNumber"
  1232. style="width: 80%"
  1233. placeholder="流水号"
  1234. />
  1235. </el-form-item>
  1236. </el-col>
  1237. <el-col :span="8">
  1238. <el-form-item label="箱号" prop="fCntrno">
  1239. <el-input
  1240. v-model="importList.fCntrno"
  1241. style="width: 80%"
  1242. placeholder="箱号"
  1243. />
  1244. </el-form-item>
  1245. </el-col>
  1246. <el-col :span="8">
  1247. <el-form-item label="货值" prop="fGoodsval">
  1248. <el-input
  1249. v-model="importList.fGoodsval"
  1250. style="width: 80%"
  1251. placeholder="货值"
  1252. />
  1253. </el-form-item>
  1254. </el-col>
  1255. </el-row>
  1256. <el-row>
  1257. <el-col>
  1258. <el-form-item label="备注" prop="remark">
  1259. <el-input
  1260. v-model="importList.remark"
  1261. style="width: 95%"
  1262. type="textarea"
  1263. placeholder="备注"
  1264. />
  1265. </el-form-item>
  1266. </el-col>
  1267. </el-row>
  1268. </el-form>
  1269. </div>
  1270. <span slot="footer" class="dialog-footer">
  1271. <el-button v-if="fixdetaiNum == null" type="info" @click="imporTable"
  1272. >导入库存明细</el-button
  1273. >
  1274. <el-button v-else type="info" @click="fiximporTable"
  1275. >确认修改</el-button
  1276. >
  1277. <el-button @click="weightList = false">取 消</el-button>
  1278. </span>
  1279. </el-dialog>
  1280. <el-dialog
  1281. :visible.sync="print_zyd"
  1282. width="70%"
  1283. :close-on-click-modal="false"
  1284. :modal="false"
  1285. >
  1286. <div id="print_area1" class="print-div">
  1287. <div
  1288. class="print-title"
  1289. style="
  1290. display: flex;
  1291. justify-content: center;
  1292. font-size: 24px;
  1293. margin-bottom: 5px;
  1294. "
  1295. >
  1296. {{ company }}有限公司作业单
  1297. </div>
  1298. <div
  1299. style="
  1300. display: flex;
  1301. justify-content: center;
  1302. font-size: 18px;
  1303. margin-bottom: 5px;
  1304. "
  1305. ></div>
  1306. <div class="print_table" style="display: flex">
  1307. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  1308. <tr>
  1309. <td>作业类型</td>
  1310. <td colspan="2">
  1311. {{ form.fBusinessType | fBusinessTypeFormat }}
  1312. </td>
  1313. <td>入库时间</td>
  1314. <td colspan="2"></td>
  1315. </tr>
  1316. <tr>
  1317. <td>车号</td>
  1318. <td>物品名称</td>
  1319. <td>提单号</td>
  1320. <td>品牌/规格/产地</td>
  1321. <td>净重(KG)</td>
  1322. <td>件数/规格</td>
  1323. </tr>
  1324. <tr v-for="(item, index) in Printinglist" :key="index">
  1325. <td>{{ item.fTruckno }}</td>
  1326. <td>{{ item.fGoodsids }}</td>
  1327. <td>{{ item.fMblno }}</td>
  1328. <td>
  1329. {{ item.fBusinessType | fStorageFormat }}/{{ item.fMarks }}
  1330. </td>
  1331. <td>{{ item.fNetweight }}</td>
  1332. <td>{{ item.fQty }}/{{ item.fPackagespecs }}</td>
  1333. </tr>
  1334. <tr>
  1335. <td>备注</td>
  1336. <td colspan="5"></td>
  1337. </tr>
  1338. <tr v-for="(item, index) in Collectionoptionss" :key="index">
  1339. <td>收费</td>
  1340. <td colspan="2">{{ item.fFeeids }}</td>
  1341. <td colspan="3">{{ item.fAmount }} 元</td>
  1342. </tr>
  1343. <tr>
  1344. <td>司机签字</td>
  1345. <td></td>
  1346. <td>电话</td>
  1347. <td>{{ fDriverTel }}</td>
  1348. <td colspan="2" rowspan="2">
  1349. 确认货物数量无误,包装于货物完好!<br />出库盖好篷布,如有违背责任自负<br />装卸工是否收小费
  1350. </td>
  1351. </tr>
  1352. <tr>
  1353. <td>制表</td>
  1354. <td>{{ form.createBy }}</td>
  1355. <td>机械/人工</td>
  1356. <td></td>
  1357. </tr>
  1358. <tr>
  1359. <td>地址</td>
  1360. <td colspan="2">{{ stockaddr }}</td>
  1361. <td>电话</td>
  1362. <td colspan="2">{{ form.fTel }}</td>
  1363. </tr>
  1364. </table>
  1365. </div>
  1366. </div>
  1367. <span lot="footer" class="dialog-footer">
  1368. <el-button
  1369. type="primary"
  1370. size="mini"
  1371. :disabled="browseStatus"
  1372. @click="addprint('zyd')"
  1373. >打印
  1374. </el-button>
  1375. <el-button @click="print_zyd = false" size="mini">取消 </el-button>
  1376. </span>
  1377. </el-dialog>
  1378. <el-dialog
  1379. :visible.sync="print_shd"
  1380. width="70%"
  1381. :close-on-click-modal="false"
  1382. :modal="false"
  1383. >
  1384. <div id="print_area1" class="print-div">
  1385. <div
  1386. class="print-title"
  1387. style="
  1388. display: flex;
  1389. justify-content: center;
  1390. font-size: 24px;
  1391. margin-bottom: 5px;
  1392. "
  1393. >
  1394. {{ company }}有限公司收货单
  1395. </div>
  1396. <div class="print_table" style="display: flex">
  1397. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  1398. <tr>
  1399. <td>车号</td>
  1400. <td>{{ fTruckno }}</td>
  1401. <td>日期</td>
  1402. <td>{{ fBsdate }}</td>
  1403. </tr>
  1404. <tr v-for="(item, index) in Printinglist" :key="index">
  1405. <td>货物品名</td>
  1406. <td>{{ item.fGoodsids }}</td>
  1407. <td>件数</td>
  1408. <td>{{ item.fQty }}件</td>
  1409. </tr>
  1410. <tr>
  1411. <td>备注</td>
  1412. <td colspan="3"></td>
  1413. </tr>
  1414. <tr>
  1415. <td>司机签字</td>
  1416. <td></td>
  1417. <td>司机电话</td>
  1418. <td>{{ fDriverTel }}</td>
  1419. </tr>
  1420. <tr>
  1421. <td>制单人</td>
  1422. <td>{{ form.createBy }}</td>
  1423. <td>收货人</td>
  1424. <td>{{ form.fContacts }}</td>
  1425. </tr>
  1426. <tr>
  1427. <td>地址</td>
  1428. <td>{{ stockaddr }}</td>
  1429. <td>电话</td>
  1430. <td>{{ form.fTel }}</td>
  1431. </tr>
  1432. </table>
  1433. </div>
  1434. </div>
  1435. <span slot="footer" class="dialog-footer">
  1436. <el-button type="primary" :disabled="browseStatus" @click="addprint"
  1437. >打印
  1438. </el-button>
  1439. <el-button @click="print_shd = false">取消 </el-button>
  1440. </span>
  1441. </el-dialog>
  1442. <el-dialog
  1443. :visible.sync="print_rkd"
  1444. width="70%"
  1445. :close-on-click-modal="false"
  1446. :modal="false"
  1447. >
  1448. <div id="print_area1" class="print-div">
  1449. <div
  1450. class="print-title"
  1451. style="
  1452. display: flex;
  1453. justify-content: center;
  1454. font-size: 24px;
  1455. margin-bottom: 5px;
  1456. "
  1457. >
  1458. {{ company }}有限公司进仓单
  1459. </div>
  1460. <div class="print_table" style="display: flex">
  1461. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  1462. <tr>
  1463. <td>货权方</td>
  1464. <td>{{ form.fCorpidName }}</td>
  1465. <td>仓库</td>
  1466. <td>{{ form.fWarehouseids }}</td>
  1467. <td>地址</td>
  1468. <td colspan="2">{{ stockaddr }}</td>
  1469. </tr>
  1470. <tr>
  1471. <td>保管方</td>
  1472. <td width="200">{{ company }}有限公司</td>
  1473. <td>联系人</td>
  1474. <td>{{ form.fContacts }}</td>
  1475. <td>电话</td>
  1476. <td colspan="2">{{ form.fTel }}</td>
  1477. </tr>
  1478. <tr>
  1479. <td>提单号</td>
  1480. <td>品名</td>
  1481. <td>箱型</td>
  1482. <td>品牌</td>
  1483. <td>件数</td>
  1484. <td>重量</td>
  1485. <td>包装规格</td>
  1486. </tr>
  1487. <tr>
  1488. <td></td>
  1489. <td></td>
  1490. <td></td>
  1491. <td></td>
  1492. <td></td>
  1493. <td></td>
  1494. <td></td>
  1495. </tr>
  1496. <tr>
  1497. <td>序号</td>
  1498. <td>入货日期</td>
  1499. <td>箱量(20GP)</td>
  1500. <td>重量</td>
  1501. <td>件数</td>
  1502. <td>入库重量</td>
  1503. <td>入库件数</td>
  1504. </tr>
  1505. <tr v-for="(item, index) in Printinglist" :key="index">
  1506. <td>{{ index + 1 }}</td>
  1507. <td>{{ item.fBsdate }}</td>
  1508. <td>{{ item.fCntqty }}</td>
  1509. <td v-if="item.fGrossweight">
  1510. {{ (item.fGrossweight / 1000).toFixed(2) }}
  1511. </td>
  1512. <td v-else></td>
  1513. <td>{{ item.fPlanqty }}</td>
  1514. <td v-if="item.fNetweight">
  1515. {{ (item.fNetweight / 1000).toFixed(2) }}
  1516. </td>
  1517. <td v-else></td>
  1518. <td>{{ item.fQty }}</td>
  1519. </tr>
  1520. <tr>
  1521. <td colspan="2">合计</td>
  1522. <td>{{ allfCntqty }}</td>
  1523. <td>{{ (allfGrossweight / 1000).toFixed(2) }}</td>
  1524. <td>{{ allfPlanqty }}</td>
  1525. <td>{{ (allfNetweight / 1000).toFixed(2) }}</td>
  1526. <td>{{ allfQty }}</td>
  1527. </tr>
  1528. <tr>
  1529. <td>备注</td>
  1530. <td colspan="6"></td>
  1531. </tr>
  1532. <tr>
  1533. <td colspan="7">
  1534. 本进仓单经仓管员签字并经保管方盖章后即专项作为货物所有人的货权证明,本单据不得转让。
  1535. </td>
  1536. </tr>
  1537. </table>
  1538. </div>
  1539. <div
  1540. style="display: flex; justify-content: space-between; font-size: 12px"
  1541. >
  1542. <div>开单员:</div>
  1543. <div style="width: 150px">仓管员:</div>
  1544. </div>
  1545. <div
  1546. style="display: flex; justify-content: space-between; font-size: 12px"
  1547. >
  1548. <div>开单时间:</div>
  1549. <div style="width: 150px">(盖章)</div>
  1550. </div>
  1551. </div>
  1552. <span slot="footer" class="dialog-footer">
  1553. <el-button type="primary" :disabled="browseStatus" @click="addprint"
  1554. >打印
  1555. </el-button>
  1556. <el-button @click="print_rkd = false">取消 </el-button>
  1557. </span>
  1558. </el-dialog>
  1559. <el-dialog
  1560. :visible.sync="print_lhd"
  1561. width="70%"
  1562. :close-on-click-modal="false"
  1563. :modal="false"
  1564. >
  1565. <div id="print_area1" class="print-div">
  1566. <div
  1567. class="print-title"
  1568. style="
  1569. display: flex;
  1570. justify-content: center;
  1571. font-size: 24px;
  1572. margin-bottom: 5px;
  1573. "
  1574. >
  1575. {{ company }}有限公司
  1576. </div>
  1577. <div
  1578. style="
  1579. display: flex;
  1580. justify-content: center;
  1581. font-size: 18px;
  1582. margin-bottom: 5px;
  1583. "
  1584. >
  1585. <div>入&nbsp;库&nbsp;计&nbsp;划&nbsp;单</div>
  1586. </div>
  1587. <div
  1588. style="
  1589. display: flex;
  1590. justify-content: space-between;
  1591. margin-bottom: 5px;
  1592. "
  1593. class="print_form"
  1594. >
  1595. <div>
  1596. <div>提单号:{{ form.fMblno }}</div>
  1597. <div>客户名称:{{ form.fCorpidName }}</div>
  1598. <div>货物名称:{{ form.fProductName }}</div>
  1599. <div>预计净重:{{ form.fPlannetweight }}</div>
  1600. </div>
  1601. <div>
  1602. <div>入库计划单号:{{ form.fBillno }}</div>
  1603. <div>计划入库日期:{{ form.fBstime }}</div>
  1604. <div>制单日期:{{ form.createTime }}</div>
  1605. <div>实际毛重:</div>
  1606. </div>
  1607. <div>
  1608. <div>清单号:{{ form.fCustomno }}</div>
  1609. <div>存放仓库:{{ stockName }}</div>
  1610. <div>预计毛重:{{ form.fPlangrossweight }}</div>
  1611. <div>实际净重:</div>
  1612. </div>
  1613. </div>
  1614. <div class="print_table" style="display: flex">
  1615. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  1616. <tr>
  1617. <td>箱号</td>
  1618. <td>铅封号</td>
  1619. <td>预计件数</td>
  1620. <td>实际件数</td>
  1621. <td>垛位</td>
  1622. <td>实际入库日期</td>
  1623. <td>送货车号</td>
  1624. <td>送货司机</td>
  1625. <td>备注</td>
  1626. </tr>
  1627. <tr v-for="(item, index) in Printinglist" :key="index">
  1628. <td>{{ item.fCntrno }}</td>
  1629. <td></td>
  1630. <td>{{ item.fQty }}</td>
  1631. <td></td>
  1632. <td>{{ item.fWarehouseInformation }}</td>
  1633. <td>{{ item.fChargedate }}</td>
  1634. <td>{{ item.fTruckno }}</td>
  1635. <td>{{ item.fDriverName }}</td>
  1636. <td>{{ item.remark }}</td>
  1637. </tr>
  1638. <tr>
  1639. <td colspan="2">合计:</td>
  1640. <td>{{ allfQty }}</td>
  1641. <td></td>
  1642. <td></td>
  1643. <td></td>
  1644. <td></td>
  1645. <td></td>
  1646. <td></td>
  1647. </tr>
  1648. </table>
  1649. </div>
  1650. <div
  1651. style="display: flex; justify-content: space-between; font-size: 12px"
  1652. >
  1653. <div>操作:{{ form.createBy }}</div>
  1654. <div>库管:{{ form.fContacts }}</div>
  1655. <div style="width: 100px">叉车:</div>
  1656. </div>
  1657. </div>
  1658. <span slot="footer" class="dialog-footer">
  1659. <el-button type="primary" :disabled="browseStatus" @click="addprint"
  1660. >打印
  1661. </el-button>
  1662. <el-button @click="print_lhd = false">取消 </el-button>
  1663. </span>
  1664. </el-dialog>
  1665. <el-dialog
  1666. :visible.sync="print_hwqr"
  1667. width="70%"
  1668. :close-on-click-modal="false"
  1669. :modal="false"
  1670. >
  1671. <div id="print_area1" class="print-div">
  1672. <div
  1673. class="print-title"
  1674. style="
  1675. display: flex;
  1676. justify-content: center;
  1677. font-size: 24px;
  1678. margin-bottom: 5px;
  1679. "
  1680. >
  1681. {{ company }}有限公司
  1682. </div>
  1683. <div
  1684. style="
  1685. display: flex;
  1686. justify-content: center;
  1687. font-size: 18px;
  1688. margin-bottom: 5px;
  1689. "
  1690. >
  1691. <div>入&nbsp;库&nbsp;单</div>
  1692. </div>
  1693. <div style="margin-bottom: 5px" class="print_form">
  1694. <div>客户名称:{{ form.fCorpidName }}</div>
  1695. </div>
  1696. <div class="print_table" style="display: flex">
  1697. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  1698. <tr>
  1699. <td>序号</td>
  1700. <td>实际入库日期</td>
  1701. <td>商品名称</td>
  1702. <td>提单号</td>
  1703. <td>箱号</td>
  1704. <td>件数</td>
  1705. <td>毛重</td>
  1706. <td>净重</td>
  1707. <td>备注</td>
  1708. </tr>
  1709. <tr v-for="(item, index) in Printinglist" :key="index">
  1710. <td>{{ index + 1 }}</td>
  1711. <td>{{ item.fChargedate }}</td>
  1712. <td>{{ item.fGoodsids }}</td>
  1713. <td>{{ item.fMblno }}</td>
  1714. <td>{{ item.fCntrno }}</td>
  1715. <td>{{ item.fQty }}</td>
  1716. <td>{{ item.fGrossweight }}</td>
  1717. <td>{{ item.fNetweight }}</td>
  1718. <td>{{ item.remark }}</td>
  1719. </tr>
  1720. <tr>
  1721. <td colspan="5">合计:</td>
  1722. <td>{{ allfQty }}</td>
  1723. <td>{{ allfGrossweight }}</td>
  1724. <td>{{ allfNetweight }}</td>
  1725. <td></td>
  1726. </tr>
  1727. </table>
  1728. </div>
  1729. <div
  1730. style="display: flex; justify-content: space-between; font-size: 12px"
  1731. >
  1732. <div>制单人:{{ form.createBy }}</div>
  1733. <div style="width: 100px">审核人:</div>
  1734. </div>
  1735. </div>
  1736. <span slot="footer" class="dialog-footer">
  1737. <el-button type="primary" :disabled="browseStatus" @click="addprint"
  1738. >打印
  1739. </el-button>
  1740. <el-button @click="print_hwqr = false">取消 </el-button>
  1741. </span>
  1742. </el-dialog>
  1743. <el-dialog
  1744. :visible.sync="print_lwqr"
  1745. width="70%"
  1746. :close-on-click-modal="false"
  1747. :modal="false"
  1748. >
  1749. <div id="print_area1" class="print-div">
  1750. <div
  1751. class="print-title"
  1752. style="
  1753. display: flex;
  1754. justify-content: center;
  1755. font-size: 24px;
  1756. margin-bottom: 5px;
  1757. "
  1758. >
  1759. {{ company }}有限公司
  1760. </div>
  1761. <div
  1762. style="
  1763. display: flex;
  1764. justify-content: center;
  1765. font-size: 18px;
  1766. margin-bottom: 5px;
  1767. "
  1768. >
  1769. <div>入&nbsp;库&nbsp;单</div>
  1770. </div>
  1771. <div style="display: flex; margin-bottom: 5px">
  1772. <div>
  1773. <div>报关单号:{{ form.fCustomno }}</div>
  1774. <div>存货地点:</div>
  1775. </div>
  1776. </div>
  1777. <div class="print_table" style="display: flex">
  1778. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  1779. <tr>
  1780. <td>品名</td>
  1781. <td colspan="3">{{ form.fProductName }}</td>
  1782. <td colspan="3">清单号</td>
  1783. <td colspan="2">{{ form.fCustomno }}</td>
  1784. </tr>
  1785. <tr>
  1786. <td>提单号</td>
  1787. <td colspan="8">{{ form.fMblno }}</td>
  1788. </tr>
  1789. <tr>
  1790. <td>入库日期</td>
  1791. <td>箱号</td>
  1792. <td>铅封号</td>
  1793. <td>预计件数</td>
  1794. <td>垛位</td>
  1795. <td>实收件数</td>
  1796. <td>实收净重(吨)</td>
  1797. <td>毛重(吨)</td>
  1798. <td>备注</td>
  1799. </tr>
  1800. <tr v-for="(item, index) in Printinglist" :key="index">
  1801. <td>{{ item.fChargedate }}</td>
  1802. <td>{{ item.fCntrno }}</td>
  1803. <td></td>
  1804. <td>{{ item.fQty }}</td>
  1805. <td>{{ item.fWarehouseInformation }}</td>
  1806. <td></td>
  1807. <td></td>
  1808. <td></td>
  1809. <td>{{ item.remark }}</td>
  1810. </tr>
  1811. </table>
  1812. </div>
  1813. <div
  1814. style="display: flex; justify-content: space-between; font-size: 12px"
  1815. >
  1816. <div>库管:{{ form.fContacts }}</div>
  1817. <div style="width: 100px">叉车:</div>
  1818. </div>
  1819. </div>
  1820. <span slot="footer" class="dialog-footer">
  1821. <el-button type="primary" :disabled="browseStatus" @click="addprint"
  1822. >打印
  1823. </el-button>
  1824. <el-button @click="print_lwqr = false">取消 </el-button>
  1825. </span>
  1826. </el-dialog>
  1827. <el-dialog
  1828. :visible.sync="print_dpxx"
  1829. width="70%"
  1830. :close-on-click-modal="false"
  1831. :modal="false"
  1832. >
  1833. <div id="print_area1" class="print-div">
  1834. <div
  1835. class="print-title"
  1836. style="
  1837. display: flex;
  1838. justify-content: center;
  1839. font-size: 24px;
  1840. margin-bottom: 5px;
  1841. "
  1842. >
  1843. {{ company }}有限公司货物标识卡
  1844. </div>
  1845. <div
  1846. style="
  1847. display: flex;
  1848. justify-content: center;
  1849. font-size: 18px;
  1850. margin-bottom: 5px;
  1851. "
  1852. >
  1853. <div>入&nbsp;库&nbsp;计&nbsp;划&nbsp;单</div>
  1854. </div>
  1855. <div class="print_table" style="display: flex">
  1856. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  1857. <tr>
  1858. <td>货物名称</td>
  1859. <td colspan="2">{{ form.fProductName }}</td>
  1860. <td>库位</td>
  1861. <td colspan="2">{{ stockName }}</td>
  1862. </tr>
  1863. <tr>
  1864. <td>提单号</td>
  1865. <td colspan="2">{{ form.fMblno }}</td>
  1866. <td>清单号</td>
  1867. <td colspan="2">{{ form.fCustomno }}</td>
  1868. </tr>
  1869. <tr>
  1870. <td>箱号</td>
  1871. <td colspan="2"></td>
  1872. <td>总箱量</td>
  1873. <td colspan="2"></td>
  1874. </tr>
  1875. <tr>
  1876. <td>总件数</td>
  1877. <td colspan="2">{{ form.fPlanqty }}</td>
  1878. <td>总净重</td>
  1879. <td colspan="2">{{ form.fPlannetweight }}</td>
  1880. </tr>
  1881. <tr>
  1882. <td>总毛重</td>
  1883. <td colspan="2">{{ form.fPlangrossweight }}</td>
  1884. <td>本垛件数</td>
  1885. <td colspan="2">{{ allfQty }}</td>
  1886. </tr>
  1887. <tr>
  1888. <td>本垛净重</td>
  1889. <td colspan="2">{{ allfGrossweight }}</td>
  1890. <td>本垛毛重</td>
  1891. <td colspan="2">{{ allfNetweight }}</td>
  1892. </tr>
  1893. <tr>
  1894. <td>入库日期</td>
  1895. <td colspan="2">{{ form.fBstime }}</td>
  1896. <td>仓管员</td>
  1897. <td colspan="2">{{ form.fContacts }}</td>
  1898. </tr>
  1899. <tr>
  1900. <td>出库日期</td>
  1901. <td>出库件数</td>
  1902. <td>剩余件数</td>
  1903. <td>出库仓管员</td>
  1904. <td>盘点日期</td>
  1905. <td>盘点人</td>
  1906. </tr>
  1907. <tr style="height: 17.8px" v-for="(item, index) in 10" :key="index">
  1908. <td></td>
  1909. <td></td>
  1910. <td></td>
  1911. <td></td>
  1912. <td></td>
  1913. <td></td>
  1914. </tr>
  1915. <tr style="height: 50px">
  1916. <td>备注</td>
  1917. <td colspan="5"></td>
  1918. </tr>
  1919. </table>
  1920. </div>
  1921. </div>
  1922. <span slot="footer" class="dialog-footer">
  1923. <el-button type="primary" :disabled="browseStatus" @click="addprint"
  1924. >打印
  1925. </el-button>
  1926. <el-button @click="print_dpxx = false">取消 </el-button>
  1927. </span>
  1928. </el-dialog>
  1929. </div>
  1930. </template>
  1931. <script>
  1932. import print from "print-js";
  1933. import {
  1934. addWhgenleg,
  1935. addJoblist,
  1936. disChargelist,
  1937. updateCredit,
  1938. listWarehousebills,
  1939. getWarehousebills,
  1940. delWarehousebills,
  1941. addWarehousebills,
  1942. addWarehouse,
  1943. exportWarehousebills,
  1944. revoke,
  1945. revokeTwo,
  1946. delinStock_s,
  1947. } from "@/api/warehouseBusiness/warehouseInStock";
  1948. import { operationAgreement } from "@/api/agreement/agreement";
  1949. import { listCorps } from "@/api/basicdata/corps";
  1950. import { listFees, getFees } from "@/api/basicdata/fees";
  1951. import {
  1952. listWarehouse,
  1953. treeselect,
  1954. listWarehousesss,
  1955. } from "@/api/basicdata/warehouse";
  1956. import { listGoods } from "@/api/basicdata/goods";
  1957. import { listUser, queryUserVal } from "@/api/system/user";
  1958. import ApprovalComments from "@/views/startApproval";
  1959. import AddOrUpdate from "@/views/viewApproval";
  1960. import Global from "@/layout/components/global";
  1961. import Treeselect from "@riophae/vue-treeselect";
  1962. import "@riophae/vue-treeselect/dist/vue-treeselect.css";
  1963. import UploadFile from "@/components/Uploadfile";
  1964. import Cookies from "js-cookie";
  1965. import { getToken } from "@/utils/auth";
  1966. export default {
  1967. name: "inStock",
  1968. props: {
  1969. chiId: {
  1970. type: Number,
  1971. required: null,
  1972. },
  1973. },
  1974. components: {
  1975. UploadFile,
  1976. },
  1977. data() {
  1978. return {
  1979. mblnoStatus: "",
  1980. selectloading: false,
  1981. fMblnoOptions: [],
  1982. warehouseDrList: [],
  1983. relevantAttachments: [],
  1984. warehouseCrList: [],
  1985. fStltypeOptions: [],
  1986. form: {},
  1987. rules: {
  1988. fDeptid: [{ required: true, message: " ", trigger: "blur" }],
  1989. fMblno: [{ required: true, message: " ", trigger: "blur" }],
  1990. fBsdeptid: [{ required: true, message: " ", trigger: "blur" }],
  1991. fCorpid: [{ required: true, message: " ", trigger: "blur" }],
  1992. fFeetunit: [{ required: true, message: " ", trigger: "blur" }],
  1993. fPlanqty: [{ required: true, message: " ", trigger: "blur" }],
  1994. fPlangrossweight: [{ required: true, message: " ", trigger: "blur" }],
  1995. fPlannetweight: [{ required: true, message: " ", trigger: "blur" }],
  1996. fChargedate: [{ required: true, message: " ", trigger: "blur" }],
  1997. fMarks: [{ required: true, message: " ", trigger: "blur" }],
  1998. fBsdate: [{ required: true, message: " ", trigger: "blur" }],
  1999. fTrademodeid: [{ required: true, message: " ", trigger: "blur" }],
  2000. fSbu: [{ required: true, message: " ", trigger: "blur" }],
  2001. fBusinessType: [{ required: true, message: " ", trigger: "blur" }],
  2002. fStorekeeper: { required: true, message: " ", trigger: "blur" },
  2003. fWarehouseid: [{ required: true, message: " ", trigger: "blur" }],
  2004. fbillingway: [{ required: true, message: " ", trigger: "blur" }],
  2005. fTocorpid: [{ required: true, message: " ", trigger: "blur" }],
  2006. fGoodsid: [{ required: true, message: " ", trigger: "blur" }],
  2007. },
  2008. imporRules: {
  2009. fQty: [{ required: true, message: " ", trigger: "blur" }],
  2010. fGoodsid: [{ required: true, message: " ", trigger: "blur" }],
  2011. fBusinessType: [{ required: true, message: " ", trigger: "blur" }],
  2012. fMarks: [{ required: true, message: " ", trigger: "blur" }],
  2013. fWarehouseInformation: [
  2014. { required: true, message: " ", trigger: "blur" },
  2015. ],
  2016. fPackagespecs: [{ required: true, message: " ", trigger: "blur" }],
  2017. fTruckno: [{ required: true, message: " ", trigger: "blur" }],
  2018. fDriverName: [{ required: true, message: " ", trigger: "blur" }],
  2019. fDriverTel: [{ required: true, message: " ", trigger: "blur" }],
  2020. fDriverIdCar: [{ required: true, message: " ", trigger: "blur" }],
  2021. fCntrno: [{ required: true, message: " ", trigger: "blur" }],
  2022. },
  2023. browseStatus: false,
  2024. formBrowseStatus: false,
  2025. goodsOptions: [],
  2026. warehouseOptions: [],
  2027. userOptions: [],
  2028. businessTypeOption: [],
  2029. fCompanyOptIons: [],
  2030. fleetOptions: [],
  2031. fFeetunitOptions: [],
  2032. current: "",
  2033. before: "",
  2034. contrOl: false,
  2035. isrequired: 2,
  2036. isrequired_s: 2,
  2037. detailsHidden: false,
  2038. CntrTable: [{}],
  2039. fCntridlist: [],
  2040. fTrademodeidOptions: [],
  2041. fIfweighOptions: [],
  2042. fIfpledgeOptions: [],
  2043. fSbuOptions: [],
  2044. Pledgebank: [],
  2045. collapselist: ["1"],
  2046. fStorageTypeOptions: [],
  2047. weightList: false,
  2048. importList: {},
  2049. headers: {
  2050. Authorization: "Bearer " + getToken(),
  2051. },
  2052. sumMum: 0,
  2053. allfPlanqty: 0,
  2054. detailList: [],
  2055. fWarehouseidOptions: [],
  2056. print_zyd: false,
  2057. print_shd: false,
  2058. print_rkd: false,
  2059. print_lhd: false,
  2060. print_hwqr: false,
  2061. print_lwqr: false,
  2062. print_dpxx: false,
  2063. company: "",
  2064. Printinglist: [],
  2065. //库位
  2066. stockName: "",
  2067. //库位地址
  2068. stockaddr: "",
  2069. Collectionoptionss: [],
  2070. fDriverTel: "",
  2071. fBsdate: "",
  2072. fTruckno: "",
  2073. allfCntqty: 0,
  2074. allfGrossweight: 0,
  2075. allfPlanqty: 0,
  2076. allfNetweight: 0,
  2077. allfQty: 0,
  2078. fixdetaiNum: null,
  2079. dataListSelection: [],
  2080. dataWithdrawList: [],
  2081. };
  2082. },
  2083. created() {
  2084. this.getDicts("data_stltype_type").then((response) => {
  2085. this.fStltypeOptions = response.data;
  2086. });
  2087. this.getDicts("st_in_type").then((response) => {
  2088. this.businessTypeOption = response.data;
  2089. localStorage.setItem("businessTypeList", JSON.stringify(response.data));
  2090. });
  2091. this.getDicts("data_unitfees").then((response) => {
  2092. this.fFeetunitOptions = response.data;
  2093. });
  2094. this.getDicts("data_trademodes").then((response) => {
  2095. this.fTrademodeidOptions = response.data;
  2096. });
  2097. this.getDicts("data_ifweigh_status").then((response) => {
  2098. this.fIfweighOptions = response.data;
  2099. });
  2100. listGoods({ fStatus: 0, delFlag: 0 }).then((response) => {
  2101. this.goodsOptions = response.rows;
  2102. });
  2103. this.getDicts("data_ifpledge_status").then((response) => {
  2104. this.fIfpledgeOptions = response.data;
  2105. });
  2106. this.getDicts("storage_type").then((response) => {
  2107. this.fStorageTypeOptions = response.data;
  2108. localStorage.setItem("fStorageTypeList", JSON.stringify(response.data));
  2109. });
  2110. listWarehousesss({ fStatus: 0, delFlag: 0 }).then((response) => {
  2111. this.warehouseOptions = response.rows;
  2112. });
  2113. this.company = localStorage.getItem("companyName");
  2114. this.queryUser();
  2115. },
  2116. filters: {
  2117. fStorageFormat(row) {
  2118. let name;
  2119. for (const item of JSON.parse(localStorage.getItem("fStorageTypeList"))) {
  2120. if (row == item.dictValue) {
  2121. name = item.dictLabel;
  2122. }
  2123. }
  2124. return name;
  2125. },
  2126. fBusinessTypeFormat(row) {
  2127. let name;
  2128. for (const item of JSON.parse(localStorage.getItem("businessTypeList"))) {
  2129. if (row == item.dictValue) {
  2130. name = item.dictLabel;
  2131. }
  2132. }
  2133. return name;
  2134. },
  2135. },
  2136. methods: {
  2137. init() {
  2138. this.resetForm("form");
  2139. this.resetForm("importList");
  2140. this.detailList = [];
  2141. this.getForm();
  2142. },
  2143. reset() {
  2144. this.importList = {
  2145. fBillstatus: null,
  2146. fMblno: null,
  2147. fQty: null,
  2148. fNetweight: null,
  2149. fGrossweight: null,
  2150. fBsdate: null,
  2151. fGoodsid: null,
  2152. fBusinessType: null,
  2153. fMarks: null,
  2154. fWarehouseInformation: null,
  2155. fCntrtype: null,
  2156. fCntqty: null,
  2157. fPackagespecs: null,
  2158. fTruckno: null,
  2159. fDriverName: null,
  2160. fDriverTel: null,
  2161. fDriverIdCar: null,
  2162. fSerialNumber: null,
  2163. fCntrno: null,
  2164. fGoodsval: null,
  2165. remark: null,
  2166. title:""
  2167. };
  2168. },
  2169. discharge() {
  2170. if (this.Printinglist.length > 0) {
  2171. for (let item in this.Printinglist) {
  2172. if (this.Printinglist[item].fBillstatus === 10) {
  2173. return this.$message.error("请先打印作业单");
  2174. }
  2175. if (this.Printinglist[item].fBillstatus >= 30) {
  2176. return this.$message.error("请勿重复卸货");
  2177. }
  2178. if (
  2179. this.Printinglist[item].ifCntrno == 1 &&
  2180. !this.Printinglist[item].fCntrno
  2181. ) {
  2182. return this.$message.error(
  2183. "请输入第" + (Number(item) + 1) + "行的箱号"
  2184. );
  2185. }
  2186. }
  2187. let formData = new window.FormData();
  2188. formData.append("warehouseBills", JSON.stringify(this.form));
  2189. formData.append("tEnclosure", JSON.stringify(this.relevantAttachments));
  2190. formData.append(
  2191. "warehousebillsitems",
  2192. JSON.stringify(this.Printinglist)
  2193. );
  2194. formData.append(
  2195. "warehousebillsfeesDr",
  2196. JSON.stringify(this.warehouseDrList)
  2197. );
  2198. formData.append(
  2199. "warehousebillsfeesCr",
  2200. JSON.stringify(this.warehouseCrList)
  2201. );
  2202. disChargelist(formData).then((response) => {
  2203. if ((response.code = 200)) {
  2204. this.detailList.map((e, index) => {
  2205. response.data.warehousebillsitems.map((item) => {
  2206. if (e.fId == item.fId) {
  2207. e = item;
  2208. this.$set(this.detailList, index, e);
  2209. }
  2210. });
  2211. });
  2212. this.msgSuccess("卸货成功");
  2213. }
  2214. });
  2215. } else {
  2216. this.$message.error("请选择需要卸货的明细!");
  2217. }
  2218. },
  2219. creditClick() {
  2220. for (let item in this.Printinglist) {
  2221. if (!this.Printinglist[item].fId) {
  2222. return this.$message.error("请存在未保存的数据");
  2223. }
  2224. if (this.Printinglist[item].fBillstatus == 10) {
  2225. return this.$message.error("请存在未打印的作业单");
  2226. }
  2227. if (this.Printinglist[item].fBillstatus == 20) {
  2228. return this.$message.error("请存在未卸货的数据");
  2229. }
  2230. }
  2231. let formData = new window.FormData();
  2232. formData.append("warehouseBills", JSON.stringify(this.form));
  2233. formData.append("warehousebillsitems", JSON.stringify(this.Printinglist));
  2234. formData.append(
  2235. "warehousebillsfeesDr",
  2236. JSON.stringify(this.warehouseDrList)
  2237. );
  2238. formData.append(
  2239. "warehousebillsfeesCr",
  2240. JSON.stringify(this.warehouseCrList)
  2241. );
  2242. formData.append("tEnclosure", JSON.stringify(this.relevantAttachments));
  2243. formData.append("whgenleg", JSON.stringify(this.relevantAttachments));
  2244. addWhgenleg(formData).then((response) => {
  2245. if ((response.code = 200)) {
  2246. this.detailList.map((e, index) => {
  2247. response.data.warehousebillsitems.map((item) => {
  2248. if (e.fId == item.fId) {
  2249. e = item;
  2250. this.$set(this.detailList, index, e);
  2251. }
  2252. });
  2253. });
  2254. this.msgSuccess("入库成功");
  2255. }
  2256. });
  2257. },
  2258. // 撤回入账
  2259. withdrawClick() {
  2260. for (let item in this.Printinglist) {
  2261. if (!this.Printinglist[item].fId) {
  2262. return this.$message.error("请存在未保存的数据");
  2263. }
  2264. if (this.Printinglist[item].fBillstatus == 10) {
  2265. return this.$message.error("请存在未打印的作业单");
  2266. }
  2267. if (this.Printinglist[item].fBillstatus == 20) {
  2268. return this.$message.error("请存在未卸货的数据");
  2269. }
  2270. if (this.Printinglist[item].fBillstatus == 30) {
  2271. return this.$message.error("请存在未入库的数据");
  2272. }
  2273. }
  2274. // 撤回入库
  2275. let formData = new window.FormData();
  2276. formData.append("warehouseBills", JSON.stringify(this.form));
  2277. formData.append("warehousebillsitems", JSON.stringify(this.Printinglist));
  2278. formData.append(
  2279. "warehousebillsfeesDr",
  2280. JSON.stringify(this.warehouseDrList)
  2281. );
  2282. formData.append(
  2283. "warehousebillsfeesCr",
  2284. JSON.stringify(this.warehouseCrList)
  2285. );
  2286. formData.append("tEnclosure", JSON.stringify(this.relevantAttachments));
  2287. updateCredit(formData).then((response) => {
  2288. this.detailList.map((e, index) => {
  2289. response.data.warehousebillsitems.map((item) => {
  2290. if (e.fId == item.fId) {
  2291. e = item;
  2292. this.$set(this.detailList, index, e);
  2293. }
  2294. });
  2295. });
  2296. this.msgSuccess("撤回成功");
  2297. });
  2298. },
  2299. fStorageTypeFormat(row) {
  2300. let fStorageType;
  2301. this.fStorageTypeOptions.map((e) => {
  2302. if (row.fBusinessType == e.dictValue) {
  2303. fStorageType = e.dictLabel;
  2304. }
  2305. });
  2306. return fStorageType;
  2307. },
  2308. goodsFormat(row) {
  2309. let goods;
  2310. this.goodsOptions.map((e) => {
  2311. if (row.fGoodsid == e.fId) {
  2312. goods = e.fName;
  2313. }
  2314. });
  2315. return goods;
  2316. },
  2317. fBsdateFormat(row) {
  2318. const dateMat = new Date(row.fBsdate);
  2319. const year = dateMat.getFullYear();
  2320. const month = dateMat.getMonth() + 1;
  2321. const day = dateMat.getDate();
  2322. const timeFormat = year + "-" + month + "-" + day;
  2323. return timeFormat;
  2324. },
  2325. getForm() {
  2326. getWarehousebills(this.chiId).then((response) => {
  2327. this.form = response.data.warehousebills;
  2328. this.$set(this.form, "fEta", Date.parse(this.form.fEta));
  2329. this.$set(this.form, "fBsdate", Date.parse(this.form.fBsdate));
  2330. this.$set(this.form, "createTime", Date.parse(this.form.createTime));
  2331. this.$set(this.form, "fChargedate", Date.parse(this.form.fChargedate));
  2332. if (this.form.fTrademodeid) {
  2333. this.$set(
  2334. this.form,
  2335. "fTrademodeid",
  2336. this.form.fTrademodeid.toString()
  2337. );
  2338. }
  2339. if (this.form.fStltypeid) {
  2340. this.$set(this.form, "fStltypeid", this.form.fStltypeid.toString());
  2341. }
  2342. if (response.data.corps) {
  2343. this.fMblnoOptions = response.data.corps;
  2344. this.KHblnoOptions = response.data.corps;
  2345. this.fCompanyOptIons = response.data.corps;
  2346. this.fSbuOptions = response.data.corps;
  2347. }
  2348. this.detailList = response.data.warehouseBillsItem;
  2349. });
  2350. },
  2351. saveForm() {
  2352. this.$refs["form"].validate((valid) => {
  2353. if (valid) {
  2354. if (this.detailList.length > 0) {
  2355. let formDatae = new window.FormData();
  2356. // 附件数据
  2357. this.form.fBillingway = this.form.fFeetunit;
  2358. // this.form.fBstime = JSON.stringify(this.form.fBstime)
  2359. formDatae.append("tWarehouseBills", JSON.stringify(this.form));
  2360. // 库存明细
  2361. formDatae.append(
  2362. "tWarehousebillsitems",
  2363. JSON.stringify(this.detailList)
  2364. );
  2365. // 附件数据
  2366. formDatae.append(
  2367. "tEnclosure",
  2368. JSON.stringify(this.relevantAttachments)
  2369. );
  2370. // 费用明细付款
  2371. formDatae.append(
  2372. "tWarehousebillsfeesCr",
  2373. JSON.stringify(this.warehouseCrList)
  2374. );
  2375. // 收款
  2376. formDatae.append(
  2377. "tWarehousebillsfeesDr",
  2378. JSON.stringify(this.warehouseDrList)
  2379. );
  2380. formDatae.append("mblnoStatus", this.mblnoStatus);
  2381. addWarehousebills(formDatae).then((response) => {
  2382. if (response.data == false) {
  2383. this.$confirm(response.msg, "提示", {
  2384. confirmButtonText: "确定",
  2385. cancelButtonText: "取消",
  2386. type: "warning",
  2387. })
  2388. .then(() => {
  2389. this.mblnoStatus = true;
  2390. this.saveForm();
  2391. })
  2392. .catch(() => {
  2393. this.$message({
  2394. type: "info",
  2395. message: "已取消",
  2396. });
  2397. });
  2398. } else {
  2399. this.mblnoStatus = "";
  2400. this.form = response.data.warehouseBills;
  2401. this.detailList = response.data.warehousebillsitems;
  2402. this.msgSuccess("保存成功");
  2403. }
  2404. });
  2405. } else {
  2406. this.$message.error("至少添加一条入库明细");
  2407. }
  2408. }
  2409. });
  2410. },
  2411. imporTable() {
  2412. this.$refs["importList"].validate((valid) => {
  2413. if (valid) {
  2414. let obj = {};
  2415. this.detailList.push({
  2416. fBillstatus: 10,
  2417. fMblno: this.form.fMblno,
  2418. fQty: this.importList.fQty,
  2419. fNetweight: this.importList.fNetweight,
  2420. fGrossweight: this.importList.fGrossweight,
  2421. fBsdate: this.importList.fBsdate,
  2422. fGoodsid: this.importList.fGoodsid,
  2423. fBusinessType: this.importList.fBusinessType,
  2424. fMarks: this.importList.fMarks,
  2425. fWarehouseInformation: this.importList.fWarehouseInformation,
  2426. fCntrtype: this.importList.fCntrtype,
  2427. fCntqty: this.importList.fCntqty,
  2428. fPackagespecs: this.importList.fPackagespecs,
  2429. fTruckno: this.importList.fTruckno,
  2430. fDriverName: this.importList.fDriverName,
  2431. fDriverTel: this.importList.fDriverTel,
  2432. fDriverIdCar: this.importList.fDriverIdCar,
  2433. fSerialNumber: this.importList.fSerialNumber,
  2434. fCntrno: this.importList.fCntrno,
  2435. fGoodsval: this.importList.fGoodsval,
  2436. remark: this.importList.remark,
  2437. });
  2438. this.weightList = false;
  2439. }
  2440. });
  2441. },
  2442. fiximporTable() {
  2443. this.detailList[this.fixdetaiNum] = this.importList;
  2444. this.weightList = false;
  2445. },
  2446. // 库存明细多选
  2447. Selectinventory(selection) {
  2448. this.Printinglist = selection;
  2449. //允许确认入库list
  2450. this.dataListSelection = [];
  2451. this.dataListSelection = selection.filter((e) => e.fBillstatus == 30);
  2452. //允许撤销入库list
  2453. this.dataWithdrawList = [];
  2454. this.dataWithdrawList = selection.filter((e) => e.fBillstatus == 40);
  2455. console.log("ruku");
  2456. console.log(this.dataListSelection);
  2457. console.log("chexiao");
  2458. console.log(this.dataWithdrawList);
  2459. },
  2460. // 合计
  2461. getSummaries(param) {
  2462. const { columns, data } = param;
  2463. const sums = [];
  2464. var values = [];
  2465. columns.forEach((column, index) => {
  2466. if (index === 0) {
  2467. sums[index] = "";
  2468. return;
  2469. }
  2470. if (column.property === "fGrossweight") {
  2471. values = data.map((item) => Number(item["fGrossweight"]));
  2472. }
  2473. if (column.property === "fNetweight") {
  2474. values = data.map((item) => Number(item["fNetweight"]));
  2475. }
  2476. if (column.property === "fQty") {
  2477. values = data.map((item) => Number(item["fQty"]));
  2478. }
  2479. if (
  2480. column.property === "fGrossweight" ||
  2481. column.property === "fNetweight" ||
  2482. column.property === "fQty"
  2483. ) {
  2484. sums[index] = values.reduce((prev, curr) => {
  2485. const value = Number(curr);
  2486. if (!isNaN(value)) {
  2487. if (column.property === "fQty") {
  2488. this.sumMum = prev + curr;
  2489. }
  2490. return prev + curr;
  2491. } else {
  2492. return prev;
  2493. }
  2494. }, 0);
  2495. sums[index] = sums[index].toFixed(2);
  2496. }
  2497. });
  2498. this.sums = sums;
  2499. return sums;
  2500. },
  2501. playcomputer() {
  2502. let Num1 = this.form.fPlannetweight / this.form.fPlanqty;
  2503. let Num2 = this.form.fPlangrossweight / this.form.fPlanqty;
  2504. this.importList.fNetweight = Number(
  2505. (this.importList.fQty * Num1).toFixed(2)
  2506. );
  2507. this.importList.fGrossweight = Number(
  2508. (this.importList.fQty * Num2).toFixed(2)
  2509. );
  2510. },
  2511. imporComputer() {
  2512. if (this.importList.fQty > this.allfPlanqty) {
  2513. return this.$alert("计划件数不能超过" + this.allfPlanqty, "提示", {
  2514. confirmButtonText: "确定",
  2515. type: "warning",
  2516. callback: (action) => {
  2517. this.importList.fQty = this.allfPlanqty;
  2518. this.playcomputer();
  2519. },
  2520. });
  2521. } else {
  2522. this.playcomputer();
  2523. }
  2524. },
  2525. // 入库明细新增list
  2526. addRelevant() {
  2527. this.$refs["form"].validate((valid) => {
  2528. if (valid) {
  2529. this.title="新增"
  2530. this.reset();
  2531. this.fixdetaiNum = null;
  2532. if (
  2533. !this.form.fPlannetweight ||
  2534. !this.form.fPlangrossweight ||
  2535. !this.form.fPlanqty
  2536. ) {
  2537. return this.$message({
  2538. message: "请维护计划净重(kg),计划毛重(kg),计划件数",
  2539. type: "warning",
  2540. });
  2541. }
  2542. this.importList.fQty = Number(
  2543. (this.form.fPlanqty - this.sumMum).toFixed(2)
  2544. );
  2545. if (this.form.fTruckno) {
  2546. this.importList.fTruckno = this.form.fTruckno;
  2547. }
  2548. if (this.form.fDriverTel) {
  2549. this.importList.fDriverTel = this.form.fDriverTel;
  2550. }
  2551. if (this.form.fDriverName) {
  2552. this.importList.fDriverName = this.form.fDriverName;
  2553. }
  2554. if (this.form.fDriverIdCar) {
  2555. this.importList.fDriverIdCar = this.form.fDriverIdCar;
  2556. }
  2557. this.allfPlanqty = this.importList.fQty;
  2558. this.importList.fBsdate = this.form.fBsdate;
  2559. this.importList.fGoodsid = this.form.fGoodsid;
  2560. this.playcomputer();
  2561. treeselect(this.form.fWarehouseid).then((response) => {
  2562. this.fWarehouseidOptions = response.data;
  2563. });
  2564. this.weightList = true;
  2565. }
  2566. });
  2567. },
  2568. printZyd() {
  2569. if (this.Printinglist.length > 0) {
  2570. for (let item in this.Printinglist) {
  2571. if (!this.Printinglist[item].fId) {
  2572. return this.$message.error("请先保存!");
  2573. }
  2574. if (
  2575. this.Printinglist[item].fTruckno !== this.Printinglist[0].fTruckno
  2576. ) {
  2577. return this.$message.error("请选择车相同车号");
  2578. }
  2579. }
  2580. this.print_zyd = true;
  2581. this.warehouseOptions.map((e) => {
  2582. if (e.fId == this.form.fWarehouseid) {
  2583. this.stockaddr = e.fAddr;
  2584. }
  2585. });
  2586. this.fDriverTel = this.Printinglist[0].fDriverTel;
  2587. } else {
  2588. this.$message.error("请选择需要打印的明细!");
  2589. }
  2590. },
  2591. handleCommand(command) {
  2592. if (this.Printinglist.length > 0) {
  2593. this.$refs["form"].validate((valid) => {
  2594. if (valid) {
  2595. for (let corp in this.fMblnoOptions) {
  2596. if (this.form.fCorpid === this.fMblnoOptions[corp].fId) {
  2597. this.$set(
  2598. this.form,
  2599. "fCorpidName",
  2600. this.fMblnoOptions[corp].fName
  2601. );
  2602. }
  2603. }
  2604. this.warehouseOptions.map((e) => {
  2605. if (e.fId == this.form.fWarehouseid) {
  2606. this.stockName = e.fName;
  2607. this.stockaddr = e.fAddr;
  2608. }
  2609. });
  2610. this.fDriverTel = this.Printinglist[0].fDriverTel;
  2611. this.fBsdate = this.Printinglist[0].fBsdate;
  2612. this.fTruckno = this.Printinglist[0].fTruckno;
  2613. this.allfCntqty = 0;
  2614. this.allfGrossweight = 0;
  2615. this.allfPlanqty = 0;
  2616. this.allfNetweight = 0;
  2617. this.allfQty = 0;
  2618. this.Printinglist.map((e) => {
  2619. if (e.fCntqty) {
  2620. this.allfCntqty += e.fCntqty;
  2621. }
  2622. if (e.fGrossweight) {
  2623. this.allfGrossweight += e.fGrossweight;
  2624. }
  2625. if (e.fPlanqty) {
  2626. this.allfPlanqty += e.fPlanqty;
  2627. }
  2628. if (e.fNetweight) {
  2629. this.allfNetweight += e.fNetweight;
  2630. }
  2631. if (e.fQty) {
  2632. this.allfQty += e.fQty;
  2633. }
  2634. });
  2635. if (command == "a") {
  2636. this.print_shd = true;
  2637. } else if (command == "b") {
  2638. this.print_rkd = true;
  2639. } else if (command == "c") {
  2640. this.print_lhd = true;
  2641. } else if (command == "d") {
  2642. this.print_hwqr = true;
  2643. } else if (command == "e") {
  2644. this.print_lwqr = true;
  2645. } else if (command == "f") {
  2646. this.print_dpxx = true;
  2647. }
  2648. }
  2649. });
  2650. } else {
  2651. this.$message.error("请选择需要打印的明细!");
  2652. }
  2653. },
  2654. //计算仓储费日期变更
  2655. changeDate() {
  2656. this.$set(this.form, "fChargedate", this.form.fBsdate);
  2657. },
  2658. addRow() {
  2659. var obj = {};
  2660. this.CntrTable.push(obj);
  2661. },
  2662. fixRow(row, index) {
  2663. this.title="修改"
  2664. this.reset();
  2665. this.fixdetaiNum=null;
  2666. this.fixdetaiNum = index;
  2667. row.fBsdate = new Date(row.fBsdate).getTime();
  2668. this.importList = row;
  2669. this.weightList = true;
  2670. },
  2671. deleteRow(index, rows) {
  2672. rows.splice(index, 1);
  2673. },
  2674. wDeleteRow(index, rows) {
  2675. rows.splice(index, 1);
  2676. this.sumMum = 0;
  2677. this.detailList.map((e) => {
  2678. if (e.fQty) {
  2679. this.sumMum += e.fQty;
  2680. }
  2681. });
  2682. },
  2683. //获取登陆人
  2684. queryUser() {
  2685. queryUserVal().then((response) => {
  2686. if (response.user !== null) {
  2687. this.userVal = response.user;
  2688. this.$set(this.form, "fDeptid", this.userVal.deptId);
  2689. this.$set(this.form, "createBy", this.userVal.userName);
  2690. this.$set(this.form, "fStorekeeper", this.userVal.nickName);
  2691. this.$set(this.form, "fIfdamage", "1");
  2692. this.$set(this.form, "fIfweigh", "1");
  2693. this.$set(this.form, "fTrademodeid", "1");
  2694. this.$set(this.form, "createTime", Date.parse(new Date()));
  2695. }
  2696. if (response.dept !== null) {
  2697. this.deptOptions = [];
  2698. this.deptOptions.push(response.dept);
  2699. }
  2700. });
  2701. },
  2702. //作业类型校验
  2703. educationChange() {
  2704. if (this.form.fBusinessType === "1" || this.form.fBusinessType === "2") {
  2705. this.isrequired = 1;
  2706. this.isrequired_s = 2;
  2707. } else if (
  2708. this.form.fBusinessType === "3" ||
  2709. this.form.fBusinessType === "4"
  2710. ) {
  2711. this.isrequired_s = 1;
  2712. this.isrequired = 2;
  2713. } else {
  2714. this.isrequired = 2;
  2715. this.isrequired_s = 2;
  2716. }
  2717. },
  2718. userRemoteMethod(query) {
  2719. if (query !== "") {
  2720. this.selectloading = true;
  2721. setTimeout(() => {
  2722. listUser({ userName: query }).then((response) => {
  2723. this.selectloading = false;
  2724. this.userOptions = response.rows;
  2725. });
  2726. }, 200);
  2727. } else {
  2728. this.userOptions = [];
  2729. }
  2730. },
  2731. corpremoteMethod(query) {
  2732. if (query !== "") {
  2733. this.selectloading = true;
  2734. setTimeout(() => {
  2735. listCorps({ fName: query, type: 1 }).then((response) => {
  2736. this.selectloading = false;
  2737. this.fMblnoOptions = response.rows;
  2738. });
  2739. }, 200);
  2740. } else {
  2741. this.fMblnoOptions = [];
  2742. }
  2743. },
  2744. flabourRemoteMethod(query) {
  2745. if (query !== "") {
  2746. this.selectloading = true;
  2747. setTimeout(() => {
  2748. listCorps({ fName: query, fTypeid: 6 }).then((response) => {
  2749. this.selectloading = false;
  2750. this.fCompanyOptIons = response.rows;
  2751. });
  2752. }, 200);
  2753. } else {
  2754. this.fCompanyOptIons = [];
  2755. }
  2756. },
  2757. fleetRemoteMethod(query) {
  2758. if (query !== "") {
  2759. this.selectloading = true;
  2760. setTimeout(() => {
  2761. listCorps({ fName: query, fTypeid: 2 }).then((response) => {
  2762. this.selectloading = false;
  2763. this.fleetOptions = response.rows;
  2764. });
  2765. }, 200);
  2766. } else {
  2767. this.fleetOptions = [];
  2768. }
  2769. },
  2770. corpsRemoteMethodd(query) {
  2771. if (query !== "") {
  2772. this.selectloading = true;
  2773. setTimeout(() => {
  2774. listCorps({ fName: query, type: 5 }).then((response) => {
  2775. this.selectloading = false;
  2776. this.Pledgebank = response.rows;
  2777. });
  2778. }, 200);
  2779. } else {
  2780. this.Pledgebank = [];
  2781. }
  2782. },
  2783. fSbuRemoteMethod(query) {
  2784. if (query !== "") {
  2785. this.selectloading = true;
  2786. setTimeout(() => {
  2787. listCorps({ fName: query }).then((response) => {
  2788. this.selectloading = false;
  2789. this.fSbuOptions = response.rows;
  2790. });
  2791. }, 200);
  2792. } else {
  2793. this.fSbuOptions = [];
  2794. }
  2795. },
  2796. clear(e) {
  2797. if (e == "fCorpid") {
  2798. this.fMblnoOptions = [];
  2799. }
  2800. if (e == "fStorekeeper") {
  2801. this.userOptions = [];
  2802. }
  2803. if (e == "fLabour") {
  2804. this.fCompanyOptIons = [];
  2805. }
  2806. if (e == "fFleet") {
  2807. this.fleetOptions = [];
  2808. }
  2809. if (e == "fBankcorpid") {
  2810. this.Pledgebank = [];
  2811. }
  2812. if (e == "fSbu") {
  2813. this.fSbuOptions = [];
  2814. }
  2815. },
  2816. //打印
  2817. addprint(status) {
  2818. if (status == "zyd") {
  2819. let formData = new window.FormData();
  2820. formData.append("warehouseBills", JSON.stringify(this.form));
  2821. formData.append(
  2822. "warehousebillsitems",
  2823. JSON.stringify(this.Printinglist)
  2824. );
  2825. formData.append(
  2826. "warehousebillsfeesDr",
  2827. JSON.stringify(this.warehouseDrList)
  2828. );
  2829. formData.append(
  2830. "warehousebillsfeesCr",
  2831. JSON.stringify(this.warehouseCrList)
  2832. );
  2833. formData.append("tEnclosure", JSON.stringify(this.relevantAttachments));
  2834. addJoblist(formData).then((response) => {
  2835. this.detailList.map((e, index) => {
  2836. response.data.warehousebillsitems.map((item) => {
  2837. if (e.fId == item.fId) {
  2838. e = item;
  2839. this.$set(this.detailList, index, e);
  2840. }
  2841. });
  2842. });
  2843. });
  2844. }
  2845. const style =
  2846. "@page { } " +
  2847. "@media print { .print-div{ padding:8px;background-color:#cccccc;} .print-title{display:flex;justify-content: center;font-size:24px} .print_form{font-size:12px} .print_table table {border-right: 1px solid #000;border-bottom: 1px solid #000;font-size:12px} .print_table table td {border-left: 1px solid #000;border-top: 1px solid #000;padding:2px;vertical-align:middle;text-align: center;}";
  2848. print({
  2849. printable: "print_area1",
  2850. type: "html",
  2851. style: style, // 亦可使用引入的外部css;
  2852. scanStyles: false,
  2853. });
  2854. },
  2855. changeShow(status) {
  2856. if (status == "save") {
  2857. this.saveForm();
  2858. }
  2859. this.resetForm("form");
  2860. this.resetForm("importList");
  2861. this.detailList = [];
  2862. this.$emit("changeShow", "true");
  2863. },
  2864. },
  2865. watch: {
  2866. // 监听 addOrUpdateVisible 改变
  2867. addOrUpdateVisible(oldVal, newVal) {
  2868. this.showDialog = this.addOrUpdateVisible;
  2869. },
  2870. },
  2871. };
  2872. </script>
  2873. <style lang="scss" scoped>
  2874. .tag-hover:hover {
  2875. background-color: #d9ebfb;
  2876. }
  2877. .tag-hover {
  2878. border-top-left-radius: 0;
  2879. border-top-right-radius: 0;
  2880. height: 15px;
  2881. padding: 0px 4px;
  2882. line-height: 12px;
  2883. }
  2884. .print-div {
  2885. color: #000;
  2886. }
  2887. .print_table {
  2888. table {
  2889. border-right: 1px solid #000;
  2890. border-bottom: 1px solid #000;
  2891. font-size: 12px;
  2892. margin-bottom: 5px;
  2893. }
  2894. table td {
  2895. border-left: 1px solid #000;
  2896. border-top: 1px solid #000;
  2897. vertical-align: middle;
  2898. padding: 2px;
  2899. text-align: center;
  2900. }
  2901. }
  2902. .print_form {
  2903. font-size: 12px;
  2904. }
  2905. </style>