AddOrUpdate.vue 173 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556
  1. <template>
  2. <div>
  3. <div style="display: flex; justify-content: space-between">
  4. <div style="display: flex; align-items: center">
  5. <el-breadcrumb separator="/">
  6. <el-breadcrumb-item
  7. ><span style="font-weight: 700">入库</span></el-breadcrumb-item
  8. >
  9. <el-breadcrumb-item
  10. ><span style="font-weight: 700"
  11. >入库详情页</span
  12. ></el-breadcrumb-item
  13. >
  14. </el-breadcrumb>
  15. <el-button
  16. style="margin-left: 10px"
  17. size="mini"
  18. icon="el-icon-arrow-left"
  19. @click="goBack"
  20. >返回列表</el-button
  21. >
  22. </div>
  23. <!-- <el-button icon="el-icon-refresh" circle size="mini"></el-button> -->
  24. </div>
  25. <br />
  26. <el-form ref="form" :model="form" :rules="rules" label-width="120px">
  27. <el-row>
  28. <el-col :span="8">
  29. <el-form-item label="客户" prop="fCorpid">
  30. <el-select
  31. v-model="form.fCorpid"
  32. clearable
  33. filterable
  34. placeholder="请输入关键词"
  35. style="width: 80%"
  36. @change="changefStltype"
  37. :disabled="detailList.length > 0"
  38. >
  39. <el-option
  40. v-for="(item, index) in fMblnoOptions"
  41. :key="index.fId"
  42. :label="item.fName"
  43. :value="item.fId"
  44. ></el-option>
  45. </el-select>
  46. </el-form-item>
  47. </el-col>
  48. <el-col :span="8">
  49. <el-form-item
  50. v-if="dataShowcar == '0'"
  51. label="结算方式"
  52. prop="fStltypeid"
  53. >
  54. <el-select
  55. v-model="form.fStltypeid"
  56. placeholder="请选择结算方式"
  57. clearable
  58. :disabled="browseStatus"
  59. style="width: 80%"
  60. >
  61. <el-option
  62. v-for="(item, index) in fStltypeOptions"
  63. :key="index.dictValue"
  64. :label="item.dictLabel"
  65. :value="item.dictValue"
  66. />
  67. </el-select>
  68. </el-form-item>
  69. </el-col>
  70. <el-col :span="8">
  71. <el-form-item
  72. v-if="dataShowcar == '1'"
  73. label="计费单位"
  74. prop="fFeetUnit"
  75. >
  76. <el-select
  77. v-model="form.fFeetUnit"
  78. placeholder="请选择计费单位"
  79. clearable
  80. :disabled="browseStatus"
  81. style="width: 80%"
  82. >
  83. <el-option
  84. v-for="(item, index) in fFeetUnitOptions"
  85. :key="index.dictValue"
  86. :label="item.dictLabel"
  87. :value="item.dictValue"
  88. />
  89. </el-select>
  90. </el-form-item>
  91. </el-col>
  92. <el-col :span="8">
  93. <el-form-item label="提单号" prop="fMblno">
  94. <el-input
  95. v-model="form.fMblno"
  96. :disabled="browseStatus || detailList.length > 0"
  97. style="width: 80%"
  98. placeholder="请输入提单号"
  99. />
  100. </el-form-item>
  101. </el-col>
  102. </el-row>
  103. <el-row>
  104. <el-col :span="8">
  105. <el-form-item label="计划日期" prop="fBsdate">
  106. <el-date-picker
  107. v-model="form.fBsdate"
  108. style="width: 80%"
  109. type="date"
  110. :disabled="browseStatus"
  111. value-format="timestamp"
  112. placeholder="请选择计划日期"
  113. @change="changeDate"
  114. >
  115. </el-date-picker>
  116. </el-form-item>
  117. </el-col>
  118. <el-col :span="8">
  119. <el-form-item label="入库时间" prop="fBstime">
  120. <el-time-picker
  121. style="width: 80%"
  122. :disabled="browseStatus"
  123. v-model="form.fBstime"
  124. :picker-options="{
  125. selectableRange: '00:00:00 - 23:59:59',
  126. }"
  127. value-format="timestamp"
  128. placeholder="任意时间点"
  129. >
  130. </el-time-picker>
  131. </el-form-item>
  132. </el-col>
  133. <el-col :span="8">
  134. <el-form-item prop="fChargedate" label="仓储费计算日期">
  135. <el-date-picker
  136. v-model="form.fChargedate"
  137. type="date"
  138. style="width: 80%"
  139. value-format="timestamp"
  140. :disabled="browseStatus"
  141. placeholder="仓储费计算日期"
  142. >
  143. </el-date-picker>
  144. </el-form-item>
  145. </el-col>
  146. <el-col :span="8">
  147. <el-form-item prop="fGoodsid" label="品名">
  148. <el-select
  149. filterable
  150. v-model="form.fGoodsid"
  151. style="width: 80%"
  152. :disabled="browseStatus || detailList.length > 0"
  153. placeholder="请选择品名"
  154. >
  155. <el-option
  156. v-for="(item, index) in goodsOptions"
  157. :key="index.fId"
  158. :label="item.fName"
  159. :value="item.fId"
  160. ></el-option>
  161. </el-select>
  162. </el-form-item>
  163. </el-col>
  164. <el-col :span="8">
  165. <el-form-item label="仓库" prop="fWarehouseid">
  166. <el-select
  167. v-model="form.fWarehouseid"
  168. filterable
  169. :disabled="browseStatus || detailList.length > 0"
  170. style="width: 80%"
  171. placeholder="请选择"
  172. >
  173. <el-option
  174. v-for="(item, index) in warehouseOptions"
  175. :key="index.fId"
  176. :label="item.fName"
  177. :value="item.fId"
  178. ></el-option>
  179. </el-select>
  180. </el-form-item>
  181. </el-col>
  182. <el-col :span="8">
  183. <el-form-item label="仓管员" prop="fStorekeeper">
  184. <el-select
  185. v-model="form.fStorekeeper"
  186. filterable
  187. clearable
  188. :disabled="browseStatus"
  189. style="width: 80%"
  190. placeholder="请输入模糊查找"
  191. >
  192. <el-option
  193. v-for="(item, index) in userOptions"
  194. :key="index.userName"
  195. :label="item.nickName"
  196. :value="item.userName"
  197. ></el-option>
  198. </el-select>
  199. </el-form-item>
  200. </el-col>
  201. </el-row>
  202. {{ form.fPlanqty }}
  203. <el-row>
  204. <el-col :span="8">
  205. <el-form-item label="计划件数" prop="fPlanqty">
  206. <el-input
  207. v-model.number="form.fPlanqty"
  208. style="width: 80%"
  209. maxlength="9"
  210. laceholder="计划件数"
  211. :disabled="browseStatus || current !== before"
  212. @change="tfQty"
  213. >
  214. <template slot="append">{{ tfQtynum }}吨</template>
  215. </el-input>
  216. </el-form-item>
  217. </el-col>
  218. <el-col :span="8">
  219. <el-form-item label="计划净重(kg)" prop="fPlannetweight">
  220. <el-input
  221. v-model="form.fPlannetweight"
  222. style="width: 80%"
  223. maxlength="9"
  224. v-input-limit="2"
  225. laceholder="计划净重"
  226. :disabled="browseStatus || current !== before"
  227. @change="tfNetweight"
  228. >
  229. <template slot="append">{{ tfNetweightnum }}吨</template>
  230. </el-input>
  231. </el-form-item>
  232. </el-col>
  233. <el-col :span="8">
  234. <el-form-item label="计划毛重(kg)" prop="fPlangrossweight">
  235. <el-input
  236. v-model="form.fPlangrossweight"
  237. v-input-limit="2"
  238. style="width: 80%"
  239. laceholder="计划毛重"
  240. maxlength="9"
  241. :disabled="browseStatus || current !== before"
  242. @change="tfGrossweight"
  243. >
  244. <template slot="append">{{ tfGrossweightnum }}吨</template>
  245. </el-input>
  246. </el-form-item>
  247. </el-col>
  248. </el-row>
  249. <div v-if="detailsHidden2">
  250. <el-row>
  251. <el-col :span="8">
  252. <el-form-item label="作业类型" prop="fBusinessType">
  253. <el-select
  254. style="width: 80%"
  255. v-model="form.fBusinessType"
  256. filterable
  257. @change="educationChange"
  258. :disabled="
  259. contrOl ||
  260. browseStatus ||
  261. warehouseDrList.length > 0 ||
  262. warehouseCrList.length > 0
  263. "
  264. >
  265. <el-option
  266. v-for="(item, index) in businessTypeOption"
  267. :key="index.dictValue"
  268. :label="item.dictLabel"
  269. :value="item.dictValue"
  270. ></el-option>
  271. </el-select>
  272. </el-form-item>
  273. </el-col>
  274. <el-col :span="8">
  275. <el-form-item label="劳务公司" prop="fLabour">
  276. <el-select
  277. style="width: 80%"
  278. v-model="form.fLabour"
  279. clearable
  280. filterable
  281. placeholder="请输入关键词"
  282. :disabled="contrOl || browseStatus"
  283. >
  284. <el-option
  285. v-for="(item, index) in fCompanyOptIons"
  286. :key="index.fId"
  287. :label="item.fName"
  288. :value="item.fId"
  289. ></el-option>
  290. </el-select>
  291. </el-form-item>
  292. </el-col>
  293. <el-col :span="8">
  294. <el-form-item
  295. label="车队"
  296. prop="fFleet"
  297. :rules="{
  298. required: isrequired === 1 ? true : false,
  299. message: '请选择',
  300. trigger: ['blur', 'change'],
  301. }"
  302. >
  303. <el-select
  304. style="width: 80%"
  305. v-model="form.fFleet"
  306. clearable
  307. filterable
  308. placeholder="请输入关键词"
  309. :disabled="contrOl || browseStatus"
  310. >
  311. <el-option
  312. v-for="(item, index) in fleetOptions"
  313. :key="index.fId"
  314. :label="item.fName"
  315. :value="item.fId"
  316. ></el-option>
  317. </el-select>
  318. </el-form-item>
  319. </el-col>
  320. </el-row>
  321. <el-row>
  322. <el-col :span="8">
  323. <el-form-item
  324. v-if="dataShowcar == '0'"
  325. label="计费单位"
  326. prop="fFeetUnit"
  327. >
  328. <el-select
  329. v-model="form.fFeetUnit"
  330. placeholder="请选择计费单位"
  331. clearable
  332. :disabled="browseStatus"
  333. style="width: 80%"
  334. >
  335. <el-option
  336. v-for="(item, index) in fFeetUnitOptions"
  337. :key="index.dictValue"
  338. :label="item.dictLabel"
  339. :value="item.dictValue"
  340. />
  341. </el-select>
  342. </el-form-item>
  343. <el-form-item
  344. v-if="dataShowcar == '1'"
  345. label="结算方式"
  346. prop="fStltypeid"
  347. >
  348. <el-select
  349. v-model="form.fStltypeid"
  350. placeholder="请选择结算方式"
  351. clearable
  352. :disabled="browseStatus"
  353. style="width: 80%"
  354. >
  355. <el-option
  356. v-for="(item, index) in fStltypeOptions"
  357. :key="index.dictValue"
  358. :label="item.dictLabel"
  359. :value="item.dictValue"
  360. />
  361. </el-select>
  362. </el-form-item>
  363. </el-col>
  364. <el-col :span="8">
  365. <el-form-item
  366. label="车号"
  367. prop="fTruckno"
  368. :rules="{
  369. required: isrequired2 === 1 ? true : false,
  370. message: '请选择',
  371. trigger: ['blur', 'change'],
  372. }"
  373. >
  374. <el-input
  375. v-model="form.fTruckno"
  376. style="width: 80%"
  377. :disabled="browseStatus"
  378. placeholder="车号"
  379. />
  380. </el-form-item>
  381. </el-col>
  382. <el-col :span="8">
  383. <el-form-item
  384. label="司机姓名"
  385. prop="fDriverName"
  386. :rules="{
  387. required: isrequired2 === 1 ? true : false,
  388. message: '请选择',
  389. trigger: ['blur', 'change'],
  390. }"
  391. >
  392. <el-input
  393. v-model="form.fDriverName"
  394. style="width: 80%"
  395. :disabled="browseStatus"
  396. placeholder="司机姓名"
  397. />
  398. </el-form-item>
  399. </el-col>
  400. </el-row>
  401. </div>
  402. <el-row>
  403. <el-col :span="16">
  404. <div v-if="detailsHidden2">
  405. <el-row>
  406. <el-col :span="12">
  407. <el-form-item
  408. label="司机身份证"
  409. prop="fDriverIdCar"
  410. :rules="{
  411. required: isrequired2 === 1 ? true : false,
  412. message: '请选择',
  413. trigger: ['blur', 'change'],
  414. }"
  415. >
  416. <el-input
  417. v-model="form.fDriverIdCar"
  418. style="width: 80%"
  419. :disabled="browseStatus"
  420. placeholder="司机身份证"
  421. />
  422. </el-form-item>
  423. </el-col>
  424. <el-col :span="12">
  425. <el-form-item
  426. label="司机电话"
  427. prop="fDriverTel"
  428. :rules="{
  429. required: isrequired2 === 1 ? true : false,
  430. message: '请选择',
  431. trigger: ['blur', 'change'],
  432. }"
  433. >
  434. <el-input
  435. v-model="form.fDriverTel"
  436. style="width: 80%"
  437. :disabled="browseStatus"
  438. placeholder="司机电话"
  439. />
  440. </el-form-item>
  441. </el-col>
  442. </el-row>
  443. </div>
  444. <el-row>
  445. <el-col :span="24">
  446. <el-form-item label="备注" prop="remark">
  447. <el-input
  448. style="width: 91.5%"
  449. v-model="form.remark"
  450. type="textarea"
  451. :disabled="browseStatus"
  452. placeholder="请输入内容"
  453. />
  454. </el-form-item>
  455. </el-col>
  456. </el-row>
  457. <el-row>
  458. <el-col :offset="16" :span="6">
  459. <el-button
  460. @click="
  461. detailsHidden2
  462. ? (detailsHidden2 = false)
  463. : (detailsHidden2 = true)
  464. "
  465. v-if="this.dataShowcar == 1"
  466. >{{ detailsHidden2 ? "隐藏" : "更多" }}
  467. </el-button>
  468. <el-button
  469. @click="
  470. detailsHidden
  471. ? (detailsHidden = false)
  472. : (detailsHidden = true)
  473. "
  474. >{{ detailsHidden ? "隐藏" : "展开" }}
  475. </el-button>
  476. </el-col>
  477. </el-row>
  478. </el-col>
  479. <el-col :span="8">
  480. <el-form-item>
  481. <div style="display: flex; align-items: center">
  482. <el-table
  483. :data="CntrTable"
  484. style="width: 80%"
  485. :header-cell-style="{ lineHeight: '16px' }"
  486. >
  487. <el-table-column
  488. prop="fCntrid "
  489. label="箱型"
  490. header-align="center"
  491. align="center"
  492. >
  493. <template slot-scope="scope">
  494. <el-select
  495. placeholder="请选择箱型"
  496. v-model="scope.row.fCntrid"
  497. size="mini"
  498. >
  499. <el-option
  500. v-for="(item, index) in cntrList"
  501. :key="index.fId"
  502. :label="item.fName"
  503. :value="item.fId"
  504. >
  505. </el-option>
  506. </el-select>
  507. </template>
  508. </el-table-column>
  509. <el-table-column
  510. prop="fCntrcount"
  511. label="箱量"
  512. header-align="center"
  513. align="center"
  514. >
  515. <template slot-scope="scope">
  516. <el-input
  517. placeholder="请输入箱量"
  518. v-model="scope.row.fCntrcount"
  519. size="mini"
  520. >
  521. </el-input>
  522. </template>
  523. </el-table-column>
  524. <el-table-column
  525. prop="fCntrcount"
  526. label="操作"
  527. header-align="center"
  528. align="center"
  529. width="50"
  530. >
  531. <template slot-scope="scope">
  532. <el-button
  533. size="mini"
  534. type="text"
  535. @click.native.prevent="deleteRow(scope.$index, CntrTable)"
  536. icon="el-icon-delete"
  537. ></el-button>
  538. </template>
  539. </el-table-column>
  540. </el-table>
  541. <el-tag class="tag-hover" @click="addRow"
  542. ><i class="el-icon-plus"></i
  543. ></el-tag>
  544. </div>
  545. </el-form-item>
  546. </el-col>
  547. </el-row>
  548. <div v-if="detailsHidden">
  549. <el-row style="margin-top: 30px">
  550. <el-col :span="8">
  551. <el-form-item label="仓库联系人" prop="fContacts">
  552. <el-input
  553. v-model="form.fContacts"
  554. style="width: 80%"
  555. :disabled="browseStatus"
  556. placeholder="仓库联系人"
  557. />
  558. </el-form-item>
  559. </el-col>
  560. <el-col :span="8">
  561. <el-form-item label="仓库电话" prop="fTel">
  562. <el-input
  563. v-model="form.fTel"
  564. :disabled="browseStatus"
  565. style="width: 80%"
  566. placeholder="请输仓库入电话"
  567. />
  568. </el-form-item>
  569. </el-col>
  570. <el-col :span="8">
  571. <el-form-item label="船名航次" prop="fVslvoy">
  572. <el-input
  573. v-model="form.fVslvoy"
  574. style="width: 80%"
  575. :disabled="browseStatus"
  576. placeholder="船名航次"
  577. />
  578. </el-form-item>
  579. </el-col>
  580. </el-row>
  581. <el-row>
  582. <el-col :span="8">
  583. <el-form-item label="到港日期" prop="fEta">
  584. <el-date-picker
  585. v-model="form.fEta"
  586. style="width: 80%"
  587. type="date"
  588. :disabled="browseStatus"
  589. value-format="timestamp"
  590. placeholder="到港日期"
  591. >
  592. </el-date-picker>
  593. </el-form-item>
  594. </el-col>
  595. <el-col :span="8">
  596. <el-form-item label="报关单号" prop="fCustomno">
  597. <el-input
  598. v-model="form.fCustomno"
  599. style="width: 80%"
  600. :disabled="browseStatus"
  601. laceholder="报关单号"
  602. />
  603. </el-form-item>
  604. </el-col>
  605. <el-col :span="8">
  606. <el-form-item label="经营单位" prop="fSbu">
  607. <el-select
  608. v-model="form.fSbu"
  609. clearable
  610. filterable
  611. placeholder="请输入关键词"
  612. >
  613. <el-option
  614. v-for="(item, index) in fSbuOptions"
  615. :key="index.fId"
  616. :label="item.fName"
  617. :value="item.fId"
  618. ></el-option>
  619. </el-select>
  620. </el-form-item>
  621. </el-col>
  622. </el-row>
  623. <el-row>
  624. <el-col :span="8">
  625. <el-form-item label="单据编号" prop="fBillno">
  626. <el-input
  627. v-model="form.fBillno"
  628. disabled
  629. style="width: 80%"
  630. placeholder="单据编号"
  631. />
  632. </el-form-item>
  633. </el-col>
  634. <el-col :span="8">
  635. <el-form-item label="贸易方式" prop="fTrademodeid">
  636. <el-select
  637. v-model="form.fTrademodeid"
  638. placeholder="请选择贸易方式"
  639. :disabled="browseStatus"
  640. clearable
  641. style="width: 80%"
  642. >
  643. <el-option
  644. v-for="(item, index) in fTrademodeidOptions"
  645. :key="index.dictValue"
  646. :label="item.dictLabel"
  647. :value="item.dictValue"
  648. />
  649. </el-select>
  650. </el-form-item>
  651. </el-col>
  652. <el-col :span="8">
  653. <el-form-item label="制单人" prop="createBy">
  654. <el-input
  655. disabled
  656. v-model="form.createBy"
  657. style="width: 80%"
  658. placeholder="制单人"
  659. />
  660. </el-form-item>
  661. </el-col>
  662. </el-row>
  663. <el-row>
  664. <el-col :span="8">
  665. <el-form-item label="制单部门" prop="fDeptid">
  666. <el-select
  667. v-model="form.fDeptid"
  668. filterable
  669. disabled
  670. style="width: 80%"
  671. remote
  672. >
  673. <el-option
  674. v-for="(item, index) in deptOptions"
  675. :key="index.deptId"
  676. :label="item.deptName"
  677. :value="item.deptId"
  678. ></el-option>
  679. </el-select>
  680. </el-form-item>
  681. </el-col>
  682. <el-col :span="8">
  683. <el-form-item disabled label="制单日期" prop="createTime">
  684. <el-date-picker
  685. v-model="form.createTime"
  686. size="large"
  687. type="date"
  688. disabled
  689. style="width: 80%"
  690. value-format="timestamp"
  691. placeholder="制单日期"
  692. >
  693. </el-date-picker>
  694. </el-form-item>
  695. </el-col>
  696. <el-col :span="8">
  697. <el-form-item label="过磅" prop="fIfweigh">
  698. <el-select
  699. v-model="form.fIfweigh"
  700. placeholder="请选择是否过磅"
  701. clearable
  702. :disabled="browseStatus"
  703. style="width: 80%"
  704. >
  705. <el-option
  706. v-for="(item, index) in fIfweighOptions"
  707. :key="index.dictValue"
  708. :label="item.dictLabel"
  709. :value="item.dictValue"
  710. />
  711. </el-select>
  712. </el-form-item>
  713. </el-col>
  714. </el-row>
  715. <el-row>
  716. <el-col :span="8">
  717. <el-form-item label="品名" prop="fProductName">
  718. <el-input
  719. v-model="form.fProductName"
  720. style="width: 80%"
  721. disabled
  722. placeholder="品名"
  723. />
  724. </el-form-item>
  725. </el-col>
  726. <el-col :span="8">
  727. <el-form-item label="品牌">
  728. <el-input
  729. v-model="form.fMarks"
  730. style="width: 80%"
  731. disabled
  732. placeholder="品牌"
  733. />
  734. </el-form-item>
  735. </el-col>
  736. <el-col :span="8">
  737. <el-form-item label="存货编号" prop="fBscorpno">
  738. <el-input
  739. disabled
  740. v-model="form.fBscorpno"
  741. style="width: 80%"
  742. laceholder="存货编号"
  743. />
  744. </el-form-item>
  745. </el-col>
  746. </el-row>
  747. <el-row>
  748. <el-col :span="8">
  749. <el-form-item label="质押" prop="fIfpledge">
  750. <el-select
  751. v-model="form.fIfpledge"
  752. placeholder="请选择是否质押"
  753. clearable
  754. :disabled="browseStatus"
  755. style="width: 80%"
  756. >
  757. <el-option
  758. v-for="(item, index) in fIfpledgeOptions"
  759. :key="index.dictValue"
  760. :label="item.dictLabel"
  761. :value="item.dictValue"
  762. />
  763. </el-select>
  764. </el-form-item>
  765. </el-col>
  766. <el-col :span="8">
  767. <el-form-item label="质押银行" prop="fBankcorpid">
  768. <el-select
  769. v-model="form.fBankcorpid"
  770. filterable
  771. clearable
  772. style="width: 80%"
  773. :disabled="browseStatus"
  774. placeholder="请输入关键词"
  775. >
  776. <el-option
  777. v-for="(item, index) in Pledgebank"
  778. :key="index.fId"
  779. :label="item.fName"
  780. :value="item.fId"
  781. ></el-option>
  782. </el-select>
  783. </el-form-item>
  784. </el-col>
  785. </el-row>
  786. </div>
  787. </el-form>
  788. <el-dialog
  789. title="自定义列显示"
  790. :visible.sync="showSetting"
  791. width="700px"
  792. v-dialogDrag
  793. :close-on-click-modal="false"
  794. >
  795. <template slot="title">
  796. <div class="avue-crud__dialog__header">
  797. <span class="el-dialog__title">
  798. <span
  799. style="
  800. display: inline-block;
  801. width: 3px;
  802. height: 20px;
  803. margin-right: 5px;
  804. float: left;
  805. margin-top: 2px;
  806. "
  807. ></span>
  808. </span>
  809. </div>
  810. </template>
  811. <div>配置排序列数据(拖动调整顺序)</div>
  812. <div style="margin-left: 17px">
  813. <el-checkbox
  814. v-model="allCheck"
  815. label="全选"
  816. @change="allChecked"
  817. ></el-checkbox>
  818. </div>
  819. <div style="padding: 4px; display: flex; justify-content: center">
  820. <draggable
  821. v-model="setRowList"
  822. group="site"
  823. animation="300"
  824. @start="onStart"
  825. @end="onEnd"
  826. handle=".indraggable"
  827. >
  828. <transition-group>
  829. <div
  830. v-for="item in setRowList"
  831. :key="item.surface"
  832. class="listStyle"
  833. >
  834. <div style="width: 500px" class="indraggable">
  835. <div class="progress" :style="{ width: item.width + 'px' }">
  836. <el-checkbox
  837. :label="item.name"
  838. v-model="item.checked"
  839. :true-label="0"
  840. :false-label="1"
  841. >{{ item.name }}
  842. </el-checkbox>
  843. </div>
  844. </div>
  845. <el-input-number
  846. v-model.number="item.width"
  847. controls-position="right"
  848. :min="1"
  849. :max="500"
  850. size="mini"
  851. ></el-input-number>
  852. </div>
  853. </transition-group>
  854. </draggable>
  855. </div>
  856. <span slot="footer" class="dialog-footer">
  857. <el-button @click="showSetting = false">取 消</el-button>
  858. <el-button @click="delRow" type="danger">重 置</el-button>
  859. <el-button type="primary" @click="save()">确 定</el-button>
  860. </span>
  861. </el-dialog>
  862. <el-collapse v-model="collapselist">
  863. <el-collapse-item name="1">
  864. <template slot="title">
  865. <i class="el-icon-s-home" style="font-size: 16px"></i>
  866. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  867. >入库明细</span
  868. >
  869. </template>
  870. <div>
  871. <el-row
  872. type="flex"
  873. justify="space-between"
  874. style="margin-bottom: 10px"
  875. >
  876. <el-col>
  877. <el-button
  878. type="primary"
  879. :disabled="browseStatus"
  880. size="small"
  881. @click="addRelevant"
  882. >录 入
  883. </el-button>
  884. <el-button
  885. :disabled="browseStatus"
  886. type="primary"
  887. size="small"
  888. @click="saveForm"
  889. >保 存</el-button
  890. >
  891. <el-button
  892. :disabled="browseStatus || Printinglist.length != 1"
  893. type="primary"
  894. size="small"
  895. @click="addRelevant('copy')"
  896. >复制录入</el-button
  897. >
  898. <el-button
  899. :disabled="browseStatus"
  900. type="primary"
  901. size="small"
  902. @click="tishi"
  903. >导入模板</el-button
  904. >
  905. <el-button
  906. :disabled="browseStatus"
  907. type="primary"
  908. size="small"
  909. @click="tishi"
  910. >导入接口</el-button
  911. >
  912. </el-col>
  913. <el-col style="display: flex; justify-content: flex-end">
  914. <el-button
  915. size="small"
  916. type="info"
  917. :disabled="browseStatus"
  918. prop="打印"
  919. @click="printZyd"
  920. >作业单
  921. </el-button>
  922. <el-button
  923. size="small"
  924. :disabled="browseStatus"
  925. @click="discharge"
  926. >叫车进场</el-button
  927. >
  928. <el-button
  929. size="small"
  930. :disabled="dataListSelection.length <= 0 || browseStatus"
  931. @click="creditClick"
  932. >入库确认
  933. </el-button>
  934. <el-button
  935. size="small"
  936. :disabled="dataWithdrawList.length <= 0 || browseStatus"
  937. @click.prevent="withdrawClick"
  938. >撤回入库
  939. </el-button>
  940. <el-dropdown @command="handleCommand" style="margin-left: 10px">
  941. <el-button :disabled="browseStatus" size="small" type="success">
  942. 打印单据<i class="el-icon-arrow-down el-icon--right"></i>
  943. </el-button>
  944. <el-dropdown-menu slot="dropdown">
  945. <el-dropdown-item command="a">收货单</el-dropdown-item>
  946. <el-dropdown-item command="g">标准入库单</el-dropdown-item>
  947. <el-dropdown-item command="b">入库单</el-dropdown-item>
  948. <el-dropdown-item command="c">理货单</el-dropdown-item>
  949. <el-dropdown-item command="d">货物确认</el-dropdown-item>
  950. <el-dropdown-item command="e">劳务确认</el-dropdown-item>
  951. <el-dropdown-item command="f">吊牌信息</el-dropdown-item>
  952. <el-dropdown-item command="h">入库垛卡</el-dropdown-item>
  953. </el-dropdown-menu>
  954. </el-dropdown>
  955. <div style="margin: 0 10px">
  956. <el-button
  957. icon="el-icon-setting"
  958. size="mini"
  959. circle
  960. @click="showSetting = !showSetting"
  961. ></el-button>
  962. </div>
  963. </el-col>
  964. </el-row>
  965. <el-table
  966. :data="detailList"
  967. tooltip-effect="dark"
  968. stripe
  969. :summary-method="getSummaries"
  970. @selection-change="Selectinventory"
  971. show-summary
  972. >
  973. <el-table-column type="selection" width="50" align="center" fixed />
  974. <el-table-column
  975. label="序号"
  976. type="index"
  977. width="50"
  978. fixed
  979. align="center"
  980. />
  981. <el-table-column
  982. v-for="(item, index) in getRowList"
  983. :key="index"
  984. :label="item.name"
  985. :width="item.width"
  986. :prop="item.label"
  987. align="center"
  988. :fixed="item.fixed"
  989. :show-overflow-tooltip="true"
  990. sortable
  991. >
  992. <template slot-scope="scope">
  993. <span v-if="item.label == 'fBillstatus'">
  994. {{ scope.row.fBillstatus | fBillstatusFormat }}
  995. </span>
  996. <span v-else-if="item.label == 'fBsdate'">
  997. {{ scope.row.fBsdate | fBsdateFormat }}
  998. </span>
  999. <span v-else-if="item.label == 'fGoodsid'">
  1000. {{ scope.row.fGoodsid | goodsFormat(goodsOptions) }}
  1001. </span>
  1002. <span v-else-if="item.label == 'fBusinessType'">
  1003. {{
  1004. scope.row.fBusinessType
  1005. | fStorageTypeFormat(fStorageTypeOptions)
  1006. }}
  1007. </span>
  1008. <span v-else-if="item.label == 'fCntrtype'">
  1009. {{ scope.row.fCntrtype | fCntrtypeFormat(cntrList) }}
  1010. </span>
  1011. <span v-else-if="item.label == 'fLntype'">
  1012. {{ scope.row.fLntype | fLntypeFormat(unloadModes) }}
  1013. </span>
  1014. <span v-else-if="item.label == 'fFleet'">
  1015. {{ scope.row.fFleet | fFleetFormat(fleetOptions) }}
  1016. </span>
  1017. <span v-else>{{ scope.row[item.label] }}</span>
  1018. </template>
  1019. </el-table-column>
  1020. <el-table-column
  1021. header-align="center"
  1022. align="center"
  1023. label="操作"
  1024. width="130px"
  1025. fixed="right"
  1026. >
  1027. <template slot-scope="scope">
  1028. <el-button
  1029. :disabled="browseStatus || scope.row.fBillstatus > 30"
  1030. type="text"
  1031. @click.native.prevent="fixRow(scope.row, scope.$index)"
  1032. size="small"
  1033. >修改</el-button
  1034. >
  1035. <el-button
  1036. :disabled="
  1037. browseStatus ||
  1038. scope.row.fBillstatus === 20 ||
  1039. scope.row.fBillstatus === 30 ||
  1040. scope.row.fBillstatus === 40
  1041. "
  1042. type="text"
  1043. @click.native.prevent="wDeleteRow(scope.$index, detailList)"
  1044. size="small"
  1045. >移除</el-button
  1046. >
  1047. </template>
  1048. </el-table-column>
  1049. </el-table>
  1050. </div>
  1051. </el-collapse-item>
  1052. <el-collapse-item>
  1053. <template slot="title">
  1054. <i class="el-icon-s-order" style="font-size: 16px"></i>
  1055. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  1056. >附件明细</span
  1057. >
  1058. </template>
  1059. <div
  1060. class="dialogTableTitle flex a-center jlr"
  1061. style="
  1062. display: flex;
  1063. justify-content: space-between;
  1064. align-items: center;
  1065. margin: 10px 0;
  1066. "
  1067. >
  1068. <div>
  1069. <el-button
  1070. size="small"
  1071. type="primary"
  1072. :disabled="browseStatus"
  1073. @click.prevent="addRelevt()"
  1074. >新行
  1075. </el-button>
  1076. </div>
  1077. </div>
  1078. <el-table
  1079. :data="relevantAttachments"
  1080. ref="table"
  1081. tooltip-effect="dark"
  1082. border
  1083. stripe
  1084. style="width: 100%"
  1085. height="150"
  1086. >
  1087. <el-table-column label="序号" type="index" width="80">
  1088. </el-table-column>
  1089. <el-table-column
  1090. prop="fName"
  1091. header-align="center"
  1092. align="center"
  1093. width="250px"
  1094. label="附件名称"
  1095. >
  1096. <template slot-scope="scope">
  1097. <el-input
  1098. v-model="scope.row.fName"
  1099. :disabled="browseStatus"
  1100. placeholder="附件名称"
  1101. show-word-limit
  1102. />
  1103. </template>
  1104. </el-table-column>
  1105. <el-table-column
  1106. prop="createBy"
  1107. header-align="center"
  1108. align="center"
  1109. width="250px"
  1110. label="上传人"
  1111. >
  1112. <template slot-scope="scope">
  1113. <el-input
  1114. v-model="scope.row.createBy"
  1115. disabled
  1116. placeholder="上传人"
  1117. show-word-limit
  1118. />
  1119. </template>
  1120. </el-table-column>
  1121. <el-table-column
  1122. prop="createTime"
  1123. header-align="center"
  1124. align="center"
  1125. label="上传时间"
  1126. >
  1127. <template slot-scope="scope">
  1128. <el-date-picker
  1129. v-model="scope.row.createTime"
  1130. type="date"
  1131. disabled
  1132. placeholder="上传时间"
  1133. format="yyyy-MM-dd HH:mm"
  1134. value-format="timestamp"
  1135. ></el-date-picker>
  1136. </template>
  1137. </el-table-column>
  1138. <el-table-column
  1139. prop="fUrl"
  1140. header-align="center"
  1141. align="center"
  1142. width="300px"
  1143. label="上传附件"
  1144. >
  1145. <template slot-scope="scope">
  1146. <div style="display: flex; justify-content: center">
  1147. <el-upload
  1148. class="upload-demo"
  1149. :action="uploadImgUrl"
  1150. :on-success="
  1151. (res, file) => {
  1152. handleSucces(scope, res, file);
  1153. }
  1154. "
  1155. :headers="headers"
  1156. :disabled="browseStatus"
  1157. :show-file-list="false"
  1158. :limit="1"
  1159. >
  1160. <el-button size="small" type="text" :disabled="browseStatus"
  1161. >点击上传</el-button
  1162. >
  1163. </el-upload>
  1164. <el-button size="small" type="text" @click="checkFile(scope)"
  1165. >查看</el-button
  1166. >
  1167. <el-button
  1168. size="small"
  1169. type="text"
  1170. :disabled="browseStatus"
  1171. @click="deleteFile(scope)"
  1172. >删除</el-button
  1173. >
  1174. </div>
  1175. </template>
  1176. </el-table-column>
  1177. <el-table-column
  1178. header-align="center"
  1179. align="center"
  1180. label="操作"
  1181. width="130PX"
  1182. >
  1183. <template slot-scope="scope">
  1184. <el-button
  1185. @click.native.prevent="
  1186. deleteRow(scope.$index, relevantAttachments)
  1187. "
  1188. :disabled="browseStatus"
  1189. size="small"
  1190. type="text"
  1191. >删除
  1192. </el-button>
  1193. </template>
  1194. </el-table-column>
  1195. </el-table>
  1196. </el-collapse-item>
  1197. <el-collapse-item>
  1198. <template slot="title">
  1199. <i class="el-icon-circle-plus" style="font-size: 16px"></i>
  1200. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  1201. >收款信息</span
  1202. >
  1203. </template>
  1204. <div
  1205. class="dialogTableTitle flex a-center jlr"
  1206. style="
  1207. display: flex;
  1208. justify-content: space-between;
  1209. align-items: center;
  1210. margin: 10px 0;
  1211. "
  1212. >
  1213. <div>
  1214. <el-button
  1215. size="small"
  1216. type="primary"
  1217. :disabled="browseStatus"
  1218. @click.prevent="addCollection()"
  1219. >新行
  1220. </el-button>
  1221. <!-- <el-button :disabled="browseStatus" @click.prevent="deleteRow(warehouseDrList)"
  1222. >删除
  1223. </el-button> -->
  1224. <el-button
  1225. type="primary"
  1226. size="small"
  1227. :disabled="browseStatus"
  1228. @click="saveForm"
  1229. >保 存</el-button
  1230. >
  1231. <!-- <el-button @click.prevent="addAgreement()" type="warning">仓储费协议</el-button> -->
  1232. <el-button
  1233. size="small"
  1234. @click.prevent="handleSelect(3)"
  1235. :disabled="browseStatus"
  1236. type="danger"
  1237. >作业费协议</el-button
  1238. >
  1239. </div>
  1240. </div>
  1241. <el-table
  1242. :data="warehouseDrList"
  1243. ref="table"
  1244. tooltip-effect="dark"
  1245. border
  1246. stripe
  1247. show-summary
  1248. @selection-change="Collectionoptions"
  1249. :summary-method="warehouseDrSummaries"
  1250. >
  1251. <el-table-column type="selection" width="55" align="center" />
  1252. <el-table-column label="序号" type="index" width="80">
  1253. </el-table-column>
  1254. <el-table-column
  1255. prop="fCorpid"
  1256. header-align="center"
  1257. align="center"
  1258. width="180px"
  1259. label="客户名称"
  1260. >
  1261. <template slot-scope="scope">
  1262. <el-select
  1263. v-model="scope.row.fCorpid"
  1264. filterable
  1265. clearable
  1266. placeholder="客户名称"
  1267. :disabled="browseStatus"
  1268. >
  1269. <el-option
  1270. v-for="(item, index) in fMblnoOptions"
  1271. :key="index.fId"
  1272. :label="item.fName"
  1273. :value="item.fId"
  1274. ></el-option>
  1275. </el-select>
  1276. </template>
  1277. </el-table-column>
  1278. <el-table-column
  1279. prop="fFeeid"
  1280. header-align="center"
  1281. align="center"
  1282. width="180px"
  1283. label="费用名称"
  1284. >
  1285. <template slot-scope="scope">
  1286. <el-select
  1287. v-model="scope.row.fFeeid"
  1288. clearable
  1289. placeholder="费用名称"
  1290. :disabled="browseStatus"
  1291. >
  1292. <el-option
  1293. v-for="(item, index) in fDNameOptions"
  1294. :key="index.fId"
  1295. :label="item.fName"
  1296. :value="item.fId"
  1297. ></el-option>
  1298. </el-select>
  1299. </template>
  1300. </el-table-column>
  1301. <el-table-column
  1302. prop="fBusinessType"
  1303. header-align="center"
  1304. align="center"
  1305. width="180px"
  1306. label="作业类型"
  1307. >
  1308. <template slot-scope="scope">
  1309. <el-select
  1310. style="width: 80%"
  1311. v-model="scope.row.fBusinessType"
  1312. filterable
  1313. disabled
  1314. >
  1315. <el-option
  1316. v-for="(item, index) in businessTypeOption"
  1317. :key="index.dictValue"
  1318. :label="item.dictLabel"
  1319. :value="item.dictValue"
  1320. ></el-option>
  1321. </el-select>
  1322. </template>
  1323. </el-table-column>
  1324. <el-table-column
  1325. prop="fFeeUnitid"
  1326. header-align="center"
  1327. align="center"
  1328. width="180px"
  1329. label="计价单位"
  1330. >
  1331. <template slot-scope="scope">
  1332. <el-select
  1333. v-model="scope.row.fFeeUnitid"
  1334. placeholder="请选择计价单位"
  1335. clearable
  1336. :disabled="browseStatus"
  1337. @change="changeFeeUnit(scope.row)"
  1338. >
  1339. <el-option
  1340. v-for="(item, index) in fFeetUnitOptions"
  1341. :key="index.dictValue"
  1342. :label="item.dictLabel"
  1343. :value="item.dictValue"
  1344. />
  1345. </el-select>
  1346. </template>
  1347. </el-table-column>
  1348. <el-table-column
  1349. prop="fQty"
  1350. header-align="center"
  1351. align="center"
  1352. width="130px"
  1353. label="数量"
  1354. >
  1355. <template slot-scope="scope">
  1356. <el-input
  1357. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1358. v-model="scope.row.fQty"
  1359. placeholder="数量"
  1360. :disabled="browseStatus"
  1361. @change="changeContractAmt(scope.row)"
  1362. show-word-limit
  1363. />
  1364. </template>
  1365. </el-table-column>
  1366. <el-table-column
  1367. prop="fUnitprice"
  1368. header-align="center"
  1369. align="center"
  1370. width="130px"
  1371. label="单价"
  1372. >
  1373. <template slot-scope="scope">
  1374. <el-input
  1375. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1376. v-model="scope.row.fUnitprice"
  1377. placeholder="单价"
  1378. :disabled="browseStatus || scope.row.fSrcTypeId !== 0"
  1379. @change="changeContractAmt(scope.row)"
  1380. show-word-limit
  1381. />
  1382. </template>
  1383. </el-table-column>
  1384. <el-table-column
  1385. prop="fAmount"
  1386. header-align="center"
  1387. align="center"
  1388. width="130px"
  1389. label="金额"
  1390. >
  1391. <template slot-scope="scope">
  1392. <el-input
  1393. disabled
  1394. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1395. v-model="scope.row.fAmount"
  1396. placeholder="金额"
  1397. show-word-limit
  1398. />
  1399. </template>
  1400. </el-table-column>
  1401. <el-table-column
  1402. prop="fStltypeid"
  1403. header-align="center"
  1404. align="center"
  1405. width="130px"
  1406. label="结算方式"
  1407. >
  1408. <template slot-scope="scope">
  1409. <el-select
  1410. v-model="scope.row.fStltypeid"
  1411. placeholder="请选择结算表票结、月结"
  1412. :disabled="browseStatus"
  1413. >
  1414. <el-option
  1415. v-for="(item, index) in fStltypeOptions"
  1416. :key="index.dictValue"
  1417. :label="item.dictLabel"
  1418. :value="item.dictValue"
  1419. ></el-option>
  1420. </el-select>
  1421. </template>
  1422. </el-table-column>
  1423. <el-table-column
  1424. prop="fCurrency"
  1425. header-align="center"
  1426. align="center"
  1427. width="130px"
  1428. label="币别"
  1429. >
  1430. <template slot-scope="scope">
  1431. <el-input
  1432. v-model="scope.row.fCurrency"
  1433. :disabled="browseStatus"
  1434. placeholder="币别"
  1435. show-word-limit
  1436. />
  1437. </template>
  1438. </el-table-column>
  1439. <el-table-column
  1440. prop="fExrate"
  1441. header-align="center"
  1442. align="center"
  1443. width="130px"
  1444. label="汇率"
  1445. >
  1446. <template slot-scope="scope">
  1447. <el-input
  1448. v-model="scope.row.fExrate"
  1449. :disabled="browseStatus"
  1450. placeholder="汇率"
  1451. show-word-limit
  1452. />
  1453. </template>
  1454. </el-table-column>
  1455. <el-table-column
  1456. prop="fTaxrate"
  1457. header-align="center"
  1458. align="center"
  1459. width="130px"
  1460. label="税率"
  1461. >
  1462. <template slot-scope="scope">
  1463. <el-input
  1464. v-model="scope.row.fTaxrate"
  1465. :disabled="browseStatus"
  1466. placeholder="税率"
  1467. show-word-limit
  1468. />
  1469. </template>
  1470. </el-table-column>
  1471. <el-table-column
  1472. prop="fMblno"
  1473. header-align="center"
  1474. align="center"
  1475. width="130px"
  1476. label="提单号"
  1477. >
  1478. <template slot-scope="scope">
  1479. <el-input
  1480. v-model="scope.row.fMblno"
  1481. :disabled="browseStatus"
  1482. placeholder="提单号"
  1483. show-word-limit
  1484. />
  1485. </template>
  1486. </el-table-column>
  1487. <el-table-column
  1488. prop="fProductName"
  1489. header-align="center"
  1490. align="center"
  1491. width="140px"
  1492. label="品名"
  1493. >
  1494. <template slot-scope="scope">
  1495. <el-input
  1496. v-model="scope.row.fProductName"
  1497. :disabled="browseStatus"
  1498. placeholder="品名"
  1499. show-word-limit
  1500. />
  1501. </template>
  1502. </el-table-column>
  1503. <el-table-column
  1504. prop="fMarks"
  1505. header-align="center"
  1506. align="center"
  1507. width="130px"
  1508. label="品牌"
  1509. >
  1510. <template slot-scope="scope">
  1511. <el-input
  1512. v-model="scope.row.fMarks"
  1513. :disabled="browseStatus"
  1514. placeholder="品牌"
  1515. show-word-limit
  1516. />
  1517. </template>
  1518. </el-table-column>
  1519. <el-table-column
  1520. prop="fSrcTypeId"
  1521. header-align="center"
  1522. align="center"
  1523. width="130px"
  1524. label="来源"
  1525. >
  1526. <template slot-scope="scope">
  1527. <span v-if="scope.row.fSrcTypeId === 0">录入</span>
  1528. <span v-if="scope.row.fSrcTypeId !== 0">协议</span>
  1529. </template>
  1530. </el-table-column>
  1531. <el-table-column
  1532. prop="remarks"
  1533. header-align="center"
  1534. align="center"
  1535. width="150px"
  1536. label="备注"
  1537. >
  1538. <template slot-scope="scope">
  1539. <el-input
  1540. v-model="scope.row.Remarks"
  1541. :disabled="browseStatus"
  1542. placeholder="备注"
  1543. show-word-limit
  1544. />
  1545. </template>
  1546. </el-table-column>
  1547. <el-table-column
  1548. header-align="center"
  1549. align="center"
  1550. label="操作"
  1551. width="200px"
  1552. >
  1553. <template slot-scope="scope">
  1554. <el-button
  1555. @click.native.prevent="deleteRow(scope.$index, warehouseDrList)"
  1556. size="small"
  1557. :disabled="browseStatus"
  1558. >移除</el-button
  1559. >
  1560. </template>
  1561. </el-table-column>
  1562. </el-table>
  1563. </el-collapse-item>
  1564. <el-collapse-item>
  1565. <template slot="title">
  1566. <i class="el-icon-remove" style="font-size: 16px"></i>
  1567. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  1568. >付款信息</span
  1569. >
  1570. </template>
  1571. <div
  1572. class="dialogTableTitle flex a-center jlr"
  1573. style="
  1574. display: flex;
  1575. justify-content: space-between;
  1576. align-items: center;
  1577. margin: 10px 0;
  1578. "
  1579. >
  1580. <div>
  1581. <el-button
  1582. type="primary"
  1583. :disabled="browseStatus"
  1584. @click.prevent="addpayment()"
  1585. size="small"
  1586. >新行
  1587. </el-button>
  1588. <el-button
  1589. type="primary"
  1590. size="small"
  1591. @click="saveForm"
  1592. :disabled="browseStatus"
  1593. >保 存</el-button
  1594. >
  1595. <el-button
  1596. type="danger"
  1597. size="small"
  1598. @click.prevent="handleSelect(1)"
  1599. :disabled="browseStatus"
  1600. >作业费协议</el-button
  1601. >
  1602. </div>
  1603. </div>
  1604. <el-table
  1605. :data="warehouseCrList"
  1606. ref="table"
  1607. tooltip-effect="dark"
  1608. border
  1609. stripe
  1610. show-summary
  1611. :summary-method="warehouseDrSummaries"
  1612. >
  1613. <el-table-column type="selection" width="55" align="center" />
  1614. <el-table-column label="序号" type="index" width="80">
  1615. </el-table-column>
  1616. <el-table-column
  1617. prop="fCorpid"
  1618. header-align="center"
  1619. align="center"
  1620. width="180px"
  1621. label="客户名称"
  1622. >
  1623. <template slot-scope="scope">
  1624. <el-select
  1625. v-model="scope.row.fCorpid"
  1626. filterable
  1627. clearable
  1628. placeholder="客户名称"
  1629. :disabled="browseStatus"
  1630. >
  1631. <el-option
  1632. v-for="(item, index) in fMblnoOptions"
  1633. :key="index.fId"
  1634. :label="item.fName"
  1635. :value="item.fId"
  1636. ></el-option>
  1637. </el-select>
  1638. </template>
  1639. </el-table-column>
  1640. <el-table-column
  1641. prop="fFeeid"
  1642. header-align="center"
  1643. align="center"
  1644. width="180px"
  1645. label="费用名称"
  1646. >
  1647. <template slot-scope="scope">
  1648. <el-select
  1649. v-model="scope.row.fFeeid"
  1650. clearable
  1651. placeholder="费用名称"
  1652. :disabled="browseStatus"
  1653. >
  1654. <el-option
  1655. v-for="(item, index) in fCNameOptions"
  1656. :key="index.fId"
  1657. :label="item.fName"
  1658. :value="item.fId"
  1659. ></el-option>
  1660. </el-select>
  1661. </template>
  1662. </el-table-column>
  1663. <el-table-column
  1664. prop="fBusinessType"
  1665. header-align="center"
  1666. align="center"
  1667. width="180px"
  1668. label="作业类型"
  1669. >
  1670. <template slot-scope="scope">
  1671. <el-select
  1672. style="width: 80%"
  1673. v-model="scope.row.fBusinessType"
  1674. filterable
  1675. disabled
  1676. >
  1677. <el-option
  1678. v-for="(item, index) in businessTypeOption"
  1679. :key="index.dictValue"
  1680. :label="item.dictLabel"
  1681. :value="item.dictValue"
  1682. ></el-option>
  1683. </el-select>
  1684. </template>
  1685. </el-table-column>
  1686. <el-table-column
  1687. prop="fFeeUnitid"
  1688. header-align="center"
  1689. align="center"
  1690. width="180px"
  1691. label="计价单位"
  1692. >
  1693. <template slot-scope="scope">
  1694. <el-select
  1695. v-model="scope.row.fFeeUnitid"
  1696. placeholder="请选择计价单位"
  1697. clearable
  1698. :disabled="browseStatus"
  1699. @change="changeFeeUnit(scope.row)"
  1700. >
  1701. <el-option
  1702. v-for="(item, index) in fFeetUnitOptions"
  1703. :key="index.dictValue"
  1704. :label="item.dictLabel"
  1705. :value="item.dictValue"
  1706. />
  1707. </el-select>
  1708. </template>
  1709. </el-table-column>
  1710. <el-table-column
  1711. prop="fQty"
  1712. header-align="center"
  1713. align="center"
  1714. width="150px"
  1715. label="数量"
  1716. >
  1717. <template slot-scope="scope">
  1718. <el-input
  1719. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d\d\d).*$/, "$1$2.$3")'
  1720. v-model="scope.row.fQty"
  1721. :disabled="browseStatus"
  1722. @change="changeContractAmt(scope.row)"
  1723. placeholder="数量"
  1724. show-word-limit
  1725. />
  1726. </template>
  1727. </el-table-column>
  1728. <el-table-column
  1729. prop="fUnitprice"
  1730. header-align="center"
  1731. align="center"
  1732. width="150px"
  1733. label="单价"
  1734. >
  1735. <template slot-scope="scope">
  1736. <el-input
  1737. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1738. v-model="scope.row.fUnitprice"
  1739. :disabled="browseStatus || scope.row.fSrcTypeId !== 0"
  1740. @change="changeContractAmt(scope.row)"
  1741. placeholder="单价"
  1742. show-word-limit
  1743. />
  1744. </template>
  1745. </el-table-column>
  1746. <el-table-column
  1747. prop="fAmount"
  1748. header-align="center"
  1749. align="center"
  1750. width="150px"
  1751. label="金额"
  1752. >
  1753. <template slot-scope="scope">
  1754. <el-input
  1755. disabled
  1756. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1757. v-model="scope.row.fAmount"
  1758. placeholder="金额"
  1759. show-word-limit
  1760. />
  1761. </template>
  1762. </el-table-column>
  1763. <el-table-column
  1764. prop="fStltypeid"
  1765. header-align="center"
  1766. align="center"
  1767. width="130px"
  1768. label="结算方式"
  1769. >
  1770. <template slot-scope="scope">
  1771. <el-select
  1772. v-model="scope.row.fStltypeid"
  1773. placeholder="请选择结算表票结、月结"
  1774. :disabled="browseStatus"
  1775. >
  1776. <el-option
  1777. v-for="(item, index) in fStltypeOptions"
  1778. :key="index.dictValue"
  1779. :label="item.dictLabel"
  1780. :value="item.dictValue"
  1781. ></el-option>
  1782. </el-select>
  1783. </template>
  1784. </el-table-column>
  1785. <el-table-column
  1786. prop="fCurrency"
  1787. header-align="center"
  1788. align="center"
  1789. width="150px"
  1790. label="币别"
  1791. >
  1792. <template slot-scope="scope">
  1793. <el-input
  1794. v-model="scope.row.fCurrency"
  1795. :disabled="browseStatus"
  1796. placeholder="币别"
  1797. show-word-limit
  1798. />
  1799. </template>
  1800. </el-table-column>
  1801. <el-table-column
  1802. prop="fExrate"
  1803. header-align="center"
  1804. align="center"
  1805. width="150px"
  1806. label="汇率"
  1807. >
  1808. <template slot-scope="scope">
  1809. <el-input
  1810. v-model="scope.row.fExrate"
  1811. :disabled="browseStatus"
  1812. placeholder="汇率"
  1813. show-word-limit
  1814. />
  1815. </template>
  1816. </el-table-column>
  1817. <el-table-column
  1818. prop="fTaxrate"
  1819. header-align="center"
  1820. align="center"
  1821. width="150px"
  1822. label="税率"
  1823. >
  1824. <template slot-scope="scope">
  1825. <el-input
  1826. v-model="scope.row.fTaxrate"
  1827. :disabled="browseStatus"
  1828. placeholder="税率"
  1829. show-word-limit
  1830. />
  1831. </template>
  1832. </el-table-column>
  1833. <el-table-column
  1834. prop="fMblno"
  1835. header-align="center"
  1836. align="center"
  1837. width="130px"
  1838. label="提单号"
  1839. >
  1840. <template slot-scope="scope">
  1841. <el-input
  1842. v-model="scope.row.fMblno"
  1843. :disabled="browseStatus"
  1844. placeholder="提单号"
  1845. show-word-limit
  1846. />
  1847. </template>
  1848. </el-table-column>
  1849. <el-table-column
  1850. prop="fProductName"
  1851. header-align="center"
  1852. align="center"
  1853. width="140px"
  1854. label="品名"
  1855. >
  1856. <template slot-scope="scope">
  1857. <el-input
  1858. v-model="scope.row.fProductName"
  1859. :disabled="browseStatus"
  1860. placeholder="品名"
  1861. show-word-limit
  1862. />
  1863. </template>
  1864. </el-table-column>
  1865. <el-table-column
  1866. prop="fMarks"
  1867. header-align="center"
  1868. align="center"
  1869. width="130px"
  1870. label="品牌"
  1871. >
  1872. <template slot-scope="scope">
  1873. <el-input
  1874. v-model="scope.row.fMarks"
  1875. :disabled="browseStatus"
  1876. placeholder="品牌"
  1877. show-word-limit
  1878. />
  1879. </template>
  1880. </el-table-column>
  1881. <el-table-column
  1882. prop="fSrcTypeId"
  1883. header-align="center"
  1884. align="center"
  1885. width="130px"
  1886. label="来源"
  1887. >
  1888. <template slot-scope="scope">
  1889. <span v-if="scope.row.fSrcTypeId === 0">录入</span>
  1890. <span v-if="scope.row.fSrcTypeId !== 0">协议</span>
  1891. </template>
  1892. </el-table-column>
  1893. <el-table-column
  1894. prop="remarks"
  1895. header-align="center"
  1896. align="center"
  1897. width="150px"
  1898. label="备注"
  1899. >
  1900. <template slot-scope="scope">
  1901. <el-input
  1902. v-model="scope.row.remarks"
  1903. :disabled="browseStatus"
  1904. placeholder="备注"
  1905. show-word-limit
  1906. />
  1907. </template>
  1908. </el-table-column>
  1909. <el-table-column
  1910. header-align="center"
  1911. align="center"
  1912. width="200px"
  1913. label="操作"
  1914. >
  1915. <template slot-scope="scope">
  1916. <!-- <el-button size="small">审核费用</el-button> -->
  1917. <el-button
  1918. @click.native.prevent="
  1919. deleteRoww(scope.$index, warehouseCrList)
  1920. "
  1921. size="small"
  1922. :disabled="browseStatus"
  1923. >移除</el-button
  1924. >
  1925. </template>
  1926. </el-table-column>
  1927. </el-table>
  1928. </el-collapse-item>
  1929. </el-collapse>
  1930. <el-dialog
  1931. v-dialogDrag
  1932. :title="title"
  1933. :visible.sync="weightList"
  1934. width="80%"
  1935. :close-on-click-modal="false"
  1936. >
  1937. <div>
  1938. <el-form
  1939. ref="importList"
  1940. :model="importList"
  1941. :rules="imporRules"
  1942. label-width="120px"
  1943. >
  1944. <el-row>
  1945. <el-col :span="6">
  1946. <el-form-item label="入库日期" prop="fBsdate">
  1947. <el-date-picker
  1948. v-model="importList.fBsdate"
  1949. type="date"
  1950. style="width: 100%"
  1951. value-format="timestamp"
  1952. placeholder="入库日期"
  1953. >
  1954. </el-date-picker>
  1955. </el-form-item>
  1956. </el-col>
  1957. <el-col :span="6">
  1958. <el-form-item label="品名" prop="fGoodsid">
  1959. <el-select
  1960. filterable
  1961. v-model="importList.fGoodsid"
  1962. style="width: 100%"
  1963. placeholder="请选择品名"
  1964. @change="changeGoods"
  1965. >
  1966. <el-option
  1967. v-for="(item, index) in goodsOptions"
  1968. :key="index.fId"
  1969. :label="item.fName"
  1970. :value="item.fId"
  1971. ></el-option>
  1972. </el-select>
  1973. </el-form-item>
  1974. </el-col>
  1975. <el-col :span="6">
  1976. <el-form-item label="货物属性" prop="fBusinessType">
  1977. <el-select
  1978. filterable
  1979. v-model="importList.fBusinessType"
  1980. style="width: 100%"
  1981. placeholder="请选择商品属性"
  1982. >
  1983. <el-option
  1984. v-for="(item, index) in fStorageTypeOptions"
  1985. :key="index.dictValue"
  1986. :label="item.dictLabel"
  1987. :value="item.dictValue"
  1988. />
  1989. </el-select>
  1990. </el-form-item>
  1991. </el-col>
  1992. <el-col :span="6">
  1993. <el-form-item label="属性详情" prop="fMarks">
  1994. <el-input
  1995. v-model="importList.fMarks"
  1996. style="width: 100%"
  1997. placeholder="请填写属性描述"
  1998. />
  1999. </el-form-item>
  2000. </el-col>
  2001. </el-row>
  2002. <el-row>
  2003. <el-col :span="6">
  2004. <el-form-item label="库区" prop="fWarehouselocid">
  2005. <treeselect
  2006. v-model="importList.fWarehouselocid"
  2007. @select="getAlltree"
  2008. :options="fWarehouseidOptions"
  2009. :show-count="true"
  2010. :disable-branch-nodes="true"
  2011. placeholder="请选择库区"
  2012. />
  2013. </el-form-item>
  2014. </el-col>
  2015. <el-col :span="6">
  2016. <el-form-item label="件数" prop="fQty">
  2017. <el-input
  2018. v-input-limit="0"
  2019. v-model.number="importList.fQty"
  2020. style="width: 100%"
  2021. placeholder="件数"
  2022. @input="imporComputer"
  2023. />
  2024. </el-form-item>
  2025. </el-col>
  2026. <el-col :span="6">
  2027. <el-form-item label="毛重(kg)" prop="fGrossweight">
  2028. <el-input
  2029. v-model.number="importList.fGrossweight"
  2030. v-input-limit="2"
  2031. style="width: 100%"
  2032. placeholder="毛重"
  2033. />
  2034. </el-form-item>
  2035. </el-col>
  2036. <el-col :span="6">
  2037. <el-form-item label="净重(kg)" prop="fNetweight">
  2038. <el-input
  2039. v-model.number="importList.fNetweight"
  2040. v-input-limit="2"
  2041. style="width: 100%"
  2042. placeholder="毛重"
  2043. />
  2044. </el-form-item>
  2045. </el-col>
  2046. </el-row>
  2047. <el-row>
  2048. <el-col :span="6">
  2049. <el-form-item label="包装规格" prop="fPackagespecs">
  2050. <el-input
  2051. v-model="importList.fPackagespecs"
  2052. style="width: 100%"
  2053. placeholder="包装规格"
  2054. />
  2055. </el-form-item>
  2056. </el-col>
  2057. <el-col :span="6">
  2058. <el-form-item label="箱型" prop="fCntrtype">
  2059. <el-select
  2060. placeholder="请选择箱型"
  2061. v-model="importList.fCntrtype"
  2062. >
  2063. <el-option
  2064. v-for="(item, index) in cntrList"
  2065. :key="index.fId"
  2066. :label="item.fName"
  2067. :value="item.fId"
  2068. >
  2069. </el-option>
  2070. </el-select>
  2071. </el-form-item>
  2072. </el-col>
  2073. <el-col :span="6">
  2074. <el-form-item label="箱量" prop="fCntqty">
  2075. <el-input
  2076. v-model="importList.fCntqty"
  2077. style="width: 100%"
  2078. placeholder="箱量"
  2079. />
  2080. </el-form-item>
  2081. </el-col>
  2082. <el-col :span="6">
  2083. <el-form-item
  2084. label="箱号"
  2085. prop="fCntrno"
  2086. :rules="{
  2087. required: ifCntrnoStatus == 1 ? true : false,
  2088. message: '',
  2089. trigger: ['blur', 'change'],
  2090. }"
  2091. >
  2092. <el-input
  2093. v-model="importList.fCntrno"
  2094. style="width: 100%"
  2095. placeholder="箱号"
  2096. v-Alphabet
  2097. />
  2098. </el-form-item>
  2099. </el-col>
  2100. </el-row>
  2101. <el-row>
  2102. <el-col :span="6">
  2103. <el-form-item label="车队" prop="fFleet">
  2104. <el-select
  2105. style="width: 80%"
  2106. v-model="importList.fFleet"
  2107. clearable
  2108. filterable
  2109. placeholder="请输入关键词"
  2110. >
  2111. <el-option
  2112. v-for="(item, index) in fleetOptions"
  2113. :key="index.fId"
  2114. :label="item.fName"
  2115. :value="item.fId"
  2116. ></el-option>
  2117. </el-select>
  2118. </el-form-item>
  2119. </el-col>
  2120. <el-col :span="6">
  2121. <el-form-item label="车号" prop="fTruckno">
  2122. <el-input
  2123. v-model="importList.fTruckno"
  2124. style="width: 100%"
  2125. placeholder="车号"
  2126. />
  2127. </el-form-item>
  2128. </el-col>
  2129. <el-col :span="6">
  2130. <el-form-item label="司机名" prop="fDriverName">
  2131. <el-input
  2132. v-model="importList.fDriverName"
  2133. style="width: 100%"
  2134. placeholder="司机名"
  2135. />
  2136. </el-form-item>
  2137. </el-col>
  2138. <el-col :span="6">
  2139. <el-form-item label="司机电话" prop="fDriverTel">
  2140. <el-input
  2141. v-model="importList.fDriverTel"
  2142. style="width: 100%"
  2143. placeholder="司机电话"
  2144. />
  2145. </el-form-item>
  2146. </el-col>
  2147. </el-row>
  2148. <el-row>
  2149. <el-col :span="6">
  2150. <el-form-item label="司机身份证" prop="fDriverIdCar">
  2151. <el-input
  2152. v-model="importList.fDriverIdCar"
  2153. style="width: 100%"
  2154. placeholder="司机身份证"
  2155. />
  2156. </el-form-item>
  2157. </el-col>
  2158. <el-col :span="6">
  2159. <el-form-item label="流水号" prop="fSerialNumber">
  2160. <el-input
  2161. v-model="importList.fSerialNumber"
  2162. style="width: 100%"
  2163. placeholder="流水号"
  2164. disabled
  2165. />
  2166. </el-form-item>
  2167. </el-col>
  2168. <el-col :span="6">
  2169. <el-form-item label="货值" prop="fGoodsval">
  2170. <el-input
  2171. v-model="importList.fGoodsval"
  2172. style="width: 100%"
  2173. placeholder="货值"
  2174. />
  2175. </el-form-item>
  2176. </el-col>
  2177. <el-col :span="6">
  2178. <el-form-item label="装卸方式" prop="fLntype">
  2179. <el-select
  2180. v-model="importList.fLntype"
  2181. placeholder="装卸方式"
  2182. style="width: 100%"
  2183. >
  2184. <el-option
  2185. v-for="(item, index) in unloadModes"
  2186. :key="index.dictValue"
  2187. :label="item.dictLabel"
  2188. :value="item.dictValue"
  2189. />
  2190. </el-select>
  2191. </el-form-item>
  2192. </el-col>
  2193. </el-row>
  2194. <el-row>
  2195. <el-col :span="6">
  2196. <el-form-item label="叉车工" prop="fForkliftman">
  2197. <el-input
  2198. v-model="importList.fForkliftman"
  2199. style="width: 100%"
  2200. placeholder="叉车工"
  2201. />
  2202. </el-form-item>
  2203. </el-col>
  2204. <el-col :span="6">
  2205. <el-form-item label="装卸工" prop="fStevedore">
  2206. <el-input
  2207. v-model="importList.fStevedore"
  2208. style="width: 100%"
  2209. placeholder="装卸工"
  2210. />
  2211. </el-form-item>
  2212. </el-col>
  2213. <el-col :span="6">
  2214. <el-form-item label="库内箱号" prop="fLocalcntrno">
  2215. <el-input
  2216. v-model="importList.fLocalcntrno"
  2217. style="width: 100%"
  2218. placeholder="库内箱号"
  2219. v-Alphabet
  2220. />
  2221. </el-form-item>
  2222. </el-col>
  2223. <el-col :span="6">
  2224. <el-form-item label="封号" prop="fSealno">
  2225. <el-input
  2226. v-model="importList.fSealno"
  2227. style="width: 100%"
  2228. placeholder="封号"
  2229. />
  2230. </el-form-item>
  2231. </el-col>
  2232. </el-row>
  2233. <el-row>
  2234. <el-col>
  2235. <el-form-item label="备注" prop="remark">
  2236. <el-input
  2237. v-model="importList.remark"
  2238. style="width: 100%"
  2239. type="textarea"
  2240. placeholder="备注"
  2241. />
  2242. </el-form-item>
  2243. </el-col>
  2244. </el-row>
  2245. </el-form>
  2246. </div>
  2247. <span slot="footer" class="dialog-footer">
  2248. <el-button v-if="fixdetaiNum == null" type="info" @click="imporTable"
  2249. >保 存</el-button
  2250. >
  2251. <el-button v-else type="info" @click="fiximporTable"
  2252. >确认修改</el-button
  2253. >
  2254. <el-button @click="weightList = false">取 消</el-button>
  2255. </span>
  2256. </el-dialog>
  2257. <el-dialog
  2258. :visible.sync="print_zyd"
  2259. width="70%"
  2260. :close-on-click-modal="false"
  2261. :modal="false"
  2262. >
  2263. <div id="print_area1" class="print-div">
  2264. <div
  2265. class="print-title"
  2266. style="
  2267. display: flex;
  2268. justify-content: center;
  2269. font-size: 24px;
  2270. margin-bottom: 5px;
  2271. "
  2272. >
  2273. {{ company }}有限公司作业单
  2274. </div>
  2275. <div
  2276. style="
  2277. display: flex;
  2278. justify-content: center;
  2279. font-size: 18px;
  2280. margin-bottom: 5px;
  2281. "
  2282. ></div>
  2283. <div class="print_table" style="display: flex">
  2284. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  2285. <tr>
  2286. <td>作业类型</td>
  2287. <td colspan="2">
  2288. {{ form.fBusinessType | fBusinessTypeFormat }}
  2289. </td>
  2290. <td>入库时间</td>
  2291. <td colspan="2"></td>
  2292. </tr>
  2293. <tr>
  2294. <td>车号</td>
  2295. <td>物品名称</td>
  2296. <td>提单号</td>
  2297. <td>品牌/规格/产地</td>
  2298. <td>净重(KG)</td>
  2299. <td>件数/规格</td>
  2300. </tr>
  2301. <tr v-for="(item, index) in Printinglist" :key="index">
  2302. <td>{{ item.fTruckno }}</td>
  2303. <td>{{ item.fGoodsids }}</td>
  2304. <td>{{ item.fMblno }}</td>
  2305. <td>
  2306. {{ item.fBusinessType | fStorageFormat }}/{{ item.fMarks }}
  2307. </td>
  2308. <td>{{ item.fNetweight }}</td>
  2309. <td>{{ item.fQty }}/{{ item.fPackagespecs }}</td>
  2310. </tr>
  2311. <tr>
  2312. <td>备注</td>
  2313. <td colspan="5"></td>
  2314. </tr>
  2315. <tr v-for="(item, index) in Collectionoptionss" :key="index">
  2316. <td>收费</td>
  2317. <td colspan="2">{{ item.fFeeids }}</td>
  2318. <td colspan="3">{{ item.fAmount }} 元</td>
  2319. </tr>
  2320. <tr>
  2321. <td>司机签字</td>
  2322. <td></td>
  2323. <td>电话</td>
  2324. <td>{{ fDriverTel }}</td>
  2325. <td colspan="2" rowspan="2">
  2326. 确认货物数量无误,包装于货物完好!<br />出库盖好篷布,如有违背责任自负<br />装卸工是否收小费
  2327. </td>
  2328. </tr>
  2329. <tr>
  2330. <td>制表</td>
  2331. <td>{{ form.createBy }}</td>
  2332. <td>机械/人工</td>
  2333. <td></td>
  2334. </tr>
  2335. <tr>
  2336. <td>地址</td>
  2337. <td colspan="2">{{ stockaddr }}</td>
  2338. <td>电话</td>
  2339. <td colspan="2">{{ form.fTel }}</td>
  2340. </tr>
  2341. </table>
  2342. </div>
  2343. </div>
  2344. <span lot="footer" class="dialog-footer">
  2345. <el-button
  2346. type="primary"
  2347. size="mini"
  2348. :disabled="browseStatus"
  2349. @click="
  2350. print_zyd = false;
  2351. addprint('zyd');
  2352. "
  2353. >打印
  2354. </el-button>
  2355. <el-button @click="print_zyd = false" size="mini">取消 </el-button>
  2356. </span>
  2357. </el-dialog>
  2358. <el-dialog
  2359. :visible.sync="print_shd"
  2360. width="70%"
  2361. :close-on-click-modal="false"
  2362. :modal="false"
  2363. >
  2364. <div id="print_area1" class="print-div">
  2365. <div
  2366. class="print-title"
  2367. style="
  2368. display: flex;
  2369. justify-content: center;
  2370. font-size: 24px;
  2371. margin-bottom: 5px;
  2372. "
  2373. >
  2374. {{ company }}有限公司收货单
  2375. </div>
  2376. <div class="print_table" style="display: flex">
  2377. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  2378. <tr>
  2379. <td>车号</td>
  2380. <td>{{ fTruckno }}</td>
  2381. <td>日期</td>
  2382. <td>{{ fBsdate }}</td>
  2383. </tr>
  2384. <tr v-for="(item, index) in Printinglist" :key="index">
  2385. <td>货物品名</td>
  2386. <td>{{ item.fGoodsids }}</td>
  2387. <td>件数</td>
  2388. <td>{{ item.fQty }}件</td>
  2389. </tr>
  2390. <tr>
  2391. <td>备注</td>
  2392. <td colspan="3"></td>
  2393. </tr>
  2394. <tr>
  2395. <td>司机签字</td>
  2396. <td></td>
  2397. <td>司机电话</td>
  2398. <td>{{ fDriverTel }}</td>
  2399. </tr>
  2400. <tr>
  2401. <td>制单人</td>
  2402. <td>{{ form.createBy }}</td>
  2403. <td>收货人</td>
  2404. <td>{{ form.fContacts }}</td>
  2405. </tr>
  2406. <tr>
  2407. <td>地址</td>
  2408. <td>{{ stockaddr }}</td>
  2409. <td>电话</td>
  2410. <td>{{ form.fTel }}</td>
  2411. </tr>
  2412. </table>
  2413. </div>
  2414. </div>
  2415. <span slot="footer" class="dialog-footer">
  2416. <el-button
  2417. type="primary"
  2418. :disabled="browseStatus"
  2419. @click="
  2420. addprint();
  2421. print_shd = false;
  2422. "
  2423. >打印
  2424. </el-button>
  2425. <el-button @click="print_shd = false">取消 </el-button>
  2426. </span>
  2427. </el-dialog>
  2428. <el-dialog
  2429. :visible.sync="print_rkd"
  2430. width="70%"
  2431. :close-on-click-modal="false"
  2432. :modal="false"
  2433. >
  2434. <div id="print_area1" class="print-div">
  2435. <div
  2436. class="print-title"
  2437. style="
  2438. display: flex;
  2439. justify-content: center;
  2440. font-size: 24px;
  2441. margin-bottom: 5px;
  2442. "
  2443. >
  2444. {{ company }}有限公司进仓单
  2445. </div>
  2446. <div class="print_table" style="display: flex">
  2447. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  2448. <tr>
  2449. <td>客户</td>
  2450. <td>{{ form.fCorpidName }}</td>
  2451. <td>仓库</td>
  2452. <td>{{ form.fWarehouseids }}</td>
  2453. <td>地址</td>
  2454. <td colspan="2">{{ stockaddr }}</td>
  2455. </tr>
  2456. <tr>
  2457. <td>保管方</td>
  2458. <td width="200">{{ company }}有限公司</td>
  2459. <td>联系人</td>
  2460. <td>{{ form.fContacts }}</td>
  2461. <td>电话</td>
  2462. <td colspan="2">{{ form.fTel }}</td>
  2463. </tr>
  2464. <tr>
  2465. <td>提单号</td>
  2466. <td>品名</td>
  2467. <td>箱型</td>
  2468. <td>品牌</td>
  2469. <td>件数</td>
  2470. <td>重量</td>
  2471. <td>包装规格</td>
  2472. </tr>
  2473. <tr>
  2474. <td></td>
  2475. <td></td>
  2476. <td></td>
  2477. <td></td>
  2478. <td></td>
  2479. <td></td>
  2480. <td></td>
  2481. </tr>
  2482. <tr>
  2483. <td>序号</td>
  2484. <td>入货日期</td>
  2485. <td>箱量(20GP)</td>
  2486. <td>重量</td>
  2487. <td>件数</td>
  2488. <td>入库重量</td>
  2489. <td>入库件数</td>
  2490. </tr>
  2491. <tr v-for="(item, index) in Printinglist" :key="index">
  2492. <td>{{ index + 1 }}</td>
  2493. <td>{{ item.fBsdate }}</td>
  2494. <td>{{ item.fCntqty }}</td>
  2495. <td v-if="item.fGrossweight">
  2496. {{ (item.fGrossweight / 1000).toFixed(2) }}
  2497. </td>
  2498. <td v-else></td>
  2499. <td>{{ item.fPlanqty }}</td>
  2500. <td v-if="item.fNetweight">
  2501. {{ (item.fNetweight / 1000).toFixed(2) }}
  2502. </td>
  2503. <td v-else></td>
  2504. <td>{{ item.fQty }}</td>
  2505. </tr>
  2506. <tr>
  2507. <td colspan="2">合计</td>
  2508. <td>{{ allfCntqty }}</td>
  2509. <td>{{ (allfGrossweight / 1000).toFixed(2) }}</td>
  2510. <td>{{ allfPlanqty }}</td>
  2511. <td>{{ (allfNetweight / 1000).toFixed(2) }}</td>
  2512. <td>{{ allfQty }}</td>
  2513. </tr>
  2514. <tr>
  2515. <td>备注</td>
  2516. <td colspan="6"></td>
  2517. </tr>
  2518. <tr>
  2519. <td colspan="7">
  2520. 本进仓单经仓管员签字并经保管方盖章后即专项作为货物所有人的货权证明,本单据不得转让。
  2521. </td>
  2522. </tr>
  2523. </table>
  2524. </div>
  2525. <div
  2526. style="display: flex; justify-content: space-between; font-size: 12px"
  2527. >
  2528. <div>开单员:</div>
  2529. <div style="width: 150px">仓管员:</div>
  2530. </div>
  2531. <div
  2532. style="display: flex; justify-content: space-between; font-size: 12px"
  2533. >
  2534. <div>开单时间:</div>
  2535. <div style="width: 150px">(盖章)</div>
  2536. </div>
  2537. </div>
  2538. <span slot="footer" class="dialog-footer">
  2539. <el-button
  2540. type="primary"
  2541. :disabled="browseStatus"
  2542. @click="
  2543. addprint();
  2544. print_rkd = false;
  2545. "
  2546. >打印
  2547. </el-button>
  2548. <el-button @click="print_rkd = false">取消 </el-button>
  2549. </span>
  2550. </el-dialog>
  2551. <el-dialog
  2552. :visible.sync="print_bzrkd"
  2553. width="70%"
  2554. :close-on-click-modal="false"
  2555. :modal="false"
  2556. >
  2557. <div id="print_area1" class="print-div">
  2558. <div
  2559. class="print-title"
  2560. style="
  2561. display: flex;
  2562. justify-content: center;
  2563. font-size: 24px;
  2564. margin-bottom: 5px;
  2565. "
  2566. >
  2567. {{ company }}有限公司(入库单-标准)
  2568. </div>
  2569. <div class="print_table" style="display: flex">
  2570. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  2571. <tr>
  2572. <td>客户名称</td>
  2573. <td>{{ form.fCorpidName }}</td>
  2574. <td>入库日期</td>
  2575. <td>{{ form.fBsdate | fBsdateFormat }}</td>
  2576. <td>流水号</td>
  2577. <td colspan="2">{{ form.fBillno }}</td>
  2578. </tr>
  2579. <tr>
  2580. <td>车号</td>
  2581. <td>{{ form.fTruckno }}</td>
  2582. <td>提单号</td>
  2583. <td>{{ form.fMblno }}</td>
  2584. <td>箱号</td>
  2585. <td colspan="2" v-if="Printinglist.length">
  2586. {{ Printinglist[0].fCntrno }}
  2587. </td>
  2588. <td colspan="2" v-else></td>
  2589. </tr>
  2590. <tr>
  2591. <td>货名</td>
  2592. <td>箱量</td>
  2593. <td>件数</td>
  2594. <td>毛重</td>
  2595. <td>规格</td>
  2596. <td>区位</td>
  2597. <td>备注</td>
  2598. </tr>
  2599. <tr v-for="(item, index) in Printinglist" :key="index">
  2600. <td>{{ item.fGoodsids }}</td>
  2601. <td>{{ item.fCntqty }}</td>
  2602. <td>{{ item.fQty }}</td>
  2603. <td v-if="item.fGrossweight">
  2604. {{ (item.fGrossweight / 1000).toFixed(2) }}
  2605. </td>
  2606. <td v-else></td>
  2607. <td>{{ item.fPackagespecs }}</td>
  2608. <td>{{ item.fWarehouseInformation }}</td>
  2609. <td>{{ item.remark }}</td>
  2610. </tr>
  2611. <tr>
  2612. <td>备注</td>
  2613. <td colspan="4">不贴标签不卸货</td>
  2614. <td>总件数</td>
  2615. <td>{{ allfQty }}</td>
  2616. </tr>
  2617. </table>
  2618. </div>
  2619. <div
  2620. style="display: flex; justify-content: space-between; font-size: 12px"
  2621. >
  2622. <div>操作:{{ form.createBy }}</div>
  2623. <div>理货:</div>
  2624. <div>叉车:</div>
  2625. <div>司机:</div>
  2626. <div style="width: 150px">电话:</div>
  2627. </div>
  2628. </div>
  2629. <span slot="footer" class="dialog-footer">
  2630. <el-button
  2631. type="primary"
  2632. :disabled="browseStatus"
  2633. @click="
  2634. addprint();
  2635. print_bzrkd = false;
  2636. "
  2637. >打印
  2638. </el-button>
  2639. <el-button @click="print_bzrkd = false">取消 </el-button>
  2640. </span>
  2641. </el-dialog>
  2642. <el-dialog
  2643. :visible.sync="print_lhd"
  2644. width="70%"
  2645. :close-on-click-modal="false"
  2646. :modal="false"
  2647. >
  2648. <div id="print_area1" class="print-div">
  2649. <div
  2650. class="print-title"
  2651. style="
  2652. display: flex;
  2653. justify-content: center;
  2654. font-size: 24px;
  2655. margin-bottom: 5px;
  2656. "
  2657. >
  2658. {{ company }}有限公司
  2659. </div>
  2660. <div
  2661. style="
  2662. display: flex;
  2663. justify-content: center;
  2664. font-size: 18px;
  2665. margin-bottom: 5px;
  2666. "
  2667. >
  2668. <div>入&nbsp;库&nbsp;计&nbsp;划&nbsp;单</div>
  2669. </div>
  2670. <div
  2671. style="
  2672. display: flex;
  2673. justify-content: space-between;
  2674. margin-bottom: 5px;
  2675. "
  2676. class="print_form"
  2677. >
  2678. <div>
  2679. <div>提单号:{{ form.fMblno }}</div>
  2680. <div>客户名称:{{ form.fCorpidName }}</div>
  2681. <div>货物名称:{{ form.fProductName }}</div>
  2682. <div>预计净重:{{ form.fPlannetweight }}</div>
  2683. </div>
  2684. <div>
  2685. <div>入库计划单号:{{ form.fBillno }}</div>
  2686. <div>计划入库日期:{{ form.fBstime }}</div>
  2687. <div>制单日期:{{ form.createTime }}</div>
  2688. <div>实际毛重:</div>
  2689. </div>
  2690. <div>
  2691. <div>清单号:{{ form.fCustomno }}</div>
  2692. <div>存放仓库:{{ stockName }}</div>
  2693. <div>预计毛重:{{ form.fPlangrossweight }}</div>
  2694. <div>实际净重:</div>
  2695. </div>
  2696. </div>
  2697. <div class="print_table" style="display: flex">
  2698. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  2699. <tr>
  2700. <td>箱号</td>
  2701. <td>铅封号</td>
  2702. <td>预计件数</td>
  2703. <td>实际件数</td>
  2704. <td>垛位</td>
  2705. <td>实际入库日期</td>
  2706. <td>送货车号</td>
  2707. <td>送货司机</td>
  2708. <td>备注</td>
  2709. </tr>
  2710. <tr v-for="(item, index) in Printinglist" :key="index">
  2711. <td>{{ item.fCntrno }}</td>
  2712. <td></td>
  2713. <td>{{ item.fQty }}</td>
  2714. <td></td>
  2715. <td>{{ item.fWarehouseInformation }}</td>
  2716. <td>{{ item.fChargedate }}</td>
  2717. <td>{{ item.fTruckno }}</td>
  2718. <td>{{ item.fDriverName }}</td>
  2719. <td>{{ item.remark }}</td>
  2720. </tr>
  2721. <tr>
  2722. <td colspan="2">合计:</td>
  2723. <td>{{ allfQty }}</td>
  2724. <td></td>
  2725. <td></td>
  2726. <td></td>
  2727. <td></td>
  2728. <td></td>
  2729. <td></td>
  2730. </tr>
  2731. </table>
  2732. </div>
  2733. <div
  2734. style="display: flex; justify-content: space-between; font-size: 12px"
  2735. >
  2736. <div>操作:{{ form.createBy }}</div>
  2737. <div>库管:{{ form.fContacts }}</div>
  2738. <div style="width: 100px">叉车:</div>
  2739. </div>
  2740. </div>
  2741. <span slot="footer" class="dialog-footer">
  2742. <el-button
  2743. type="primary"
  2744. :disabled="browseStatus"
  2745. @click="
  2746. addprint();
  2747. print_lhd = false;
  2748. "
  2749. >打印
  2750. </el-button>
  2751. <el-button @click="print_lhd = false">取消 </el-button>
  2752. </span>
  2753. </el-dialog>
  2754. <el-dialog
  2755. :visible.sync="print_hwqr"
  2756. width="70%"
  2757. :close-on-click-modal="false"
  2758. :modal="false"
  2759. >
  2760. <div id="print_area1" class="print-div">
  2761. <div
  2762. class="print-title"
  2763. style="
  2764. display: flex;
  2765. justify-content: center;
  2766. font-size: 24px;
  2767. margin-bottom: 5px;
  2768. "
  2769. >
  2770. {{ company }}有限公司
  2771. </div>
  2772. <div
  2773. style="
  2774. display: flex;
  2775. justify-content: center;
  2776. font-size: 18px;
  2777. margin-bottom: 5px;
  2778. "
  2779. >
  2780. <div>入&nbsp;库&nbsp;单</div>
  2781. </div>
  2782. <div style="margin-bottom: 5px" class="print_form">
  2783. <div>客户名称:{{ form.fCorpidName }}</div>
  2784. </div>
  2785. <div class="print_table" style="display: flex">
  2786. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  2787. <tr>
  2788. <td>序号</td>
  2789. <td>实际入库日期</td>
  2790. <td>商品名称</td>
  2791. <td>提单号</td>
  2792. <td>箱号</td>
  2793. <td>件数</td>
  2794. <td>毛重</td>
  2795. <td>净重</td>
  2796. <td>备注</td>
  2797. </tr>
  2798. <tr v-for="(item, index) in Printinglist" :key="index">
  2799. <td>{{ index + 1 }}</td>
  2800. <td>{{ item.fChargedate }}</td>
  2801. <td>{{ item.fGoodsids }}</td>
  2802. <td>{{ item.fMblno }}</td>
  2803. <td>{{ item.fCntrno }}</td>
  2804. <td>{{ item.fQty }}</td>
  2805. <td>{{ item.fGrossweight }}</td>
  2806. <td>{{ item.fNetweight }}</td>
  2807. <td>{{ item.remark }}</td>
  2808. </tr>
  2809. <tr>
  2810. <td colspan="5">合计:</td>
  2811. <td>{{ allfQty }}</td>
  2812. <td>{{ allfGrossweight }}</td>
  2813. <td>{{ allfNetweight }}</td>
  2814. <td></td>
  2815. </tr>
  2816. </table>
  2817. </div>
  2818. <div
  2819. style="display: flex; justify-content: space-between; font-size: 12px"
  2820. >
  2821. <div>制单人:{{ form.createBy }}</div>
  2822. <div style="width: 100px">审核人:</div>
  2823. </div>
  2824. </div>
  2825. <span slot="footer" class="dialog-footer">
  2826. <el-button
  2827. type="primary"
  2828. :disabled="browseStatus"
  2829. @click="
  2830. addprint();
  2831. print_hwqr = false;
  2832. "
  2833. >打印
  2834. </el-button>
  2835. <el-button @click="print_hwqr = false">取消 </el-button>
  2836. </span>
  2837. </el-dialog>
  2838. <el-dialog
  2839. :visible.sync="print_lwqr"
  2840. width="70%"
  2841. :close-on-click-modal="false"
  2842. :modal="false"
  2843. >
  2844. <div id="print_area1" class="print-div">
  2845. <div
  2846. class="print-title"
  2847. style="
  2848. display: flex;
  2849. justify-content: center;
  2850. font-size: 24px;
  2851. margin-bottom: 5px;
  2852. "
  2853. >
  2854. {{ company }}有限公司
  2855. </div>
  2856. <div
  2857. style="
  2858. display: flex;
  2859. justify-content: center;
  2860. font-size: 18px;
  2861. margin-bottom: 5px;
  2862. "
  2863. >
  2864. <div>入&nbsp;库&nbsp;单</div>
  2865. </div>
  2866. <div style="display: flex; margin-bottom: 5px">
  2867. <div>
  2868. <div>报关单号:{{ form.fCustomno }}</div>
  2869. <div>存货地点:</div>
  2870. </div>
  2871. </div>
  2872. <div class="print_table" style="display: flex">
  2873. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  2874. <tr>
  2875. <td>品名</td>
  2876. <td colspan="3">{{ form.fProductName }}</td>
  2877. <td colspan="3">清单号</td>
  2878. <td colspan="2">{{ form.fCustomno }}</td>
  2879. </tr>
  2880. <tr>
  2881. <td>提单号</td>
  2882. <td colspan="8">{{ form.fMblno }}</td>
  2883. </tr>
  2884. <tr>
  2885. <td>入库日期</td>
  2886. <td>箱号</td>
  2887. <td>铅封号</td>
  2888. <td>预计件数</td>
  2889. <td>垛位</td>
  2890. <td>实收件数</td>
  2891. <td>实收净重(吨)</td>
  2892. <td>毛重(吨)</td>
  2893. <td>备注</td>
  2894. </tr>
  2895. <tr v-for="(item, index) in Printinglist" :key="index">
  2896. <td>{{ item.fChargedate }}</td>
  2897. <td>{{ item.fCntrno }}</td>
  2898. <td></td>
  2899. <td>{{ item.fQty }}</td>
  2900. <td>{{ item.fWarehouseInformation }}</td>
  2901. <td></td>
  2902. <td></td>
  2903. <td></td>
  2904. <td>{{ item.remark }}</td>
  2905. </tr>
  2906. </table>
  2907. </div>
  2908. <div
  2909. style="display: flex; justify-content: space-between; font-size: 12px"
  2910. >
  2911. <div>库管:{{ form.fContacts }}</div>
  2912. <div style="width: 100px">叉车:</div>
  2913. </div>
  2914. </div>
  2915. <span slot="footer" class="dialog-footer">
  2916. <el-button
  2917. type="primary"
  2918. :disabled="browseStatus"
  2919. @click="
  2920. addprint();
  2921. print_lwqr = false;
  2922. "
  2923. >打印
  2924. </el-button>
  2925. <el-button @click="print_lwqr = false">取消 </el-button>
  2926. </span>
  2927. </el-dialog>
  2928. <el-dialog
  2929. :visible.sync="print_dpxx"
  2930. width="70%"
  2931. :close-on-click-modal="false"
  2932. :modal="false"
  2933. >
  2934. <div id="print_area1" class="print-div">
  2935. <div
  2936. class="print-title"
  2937. style="
  2938. display: flex;
  2939. justify-content: center;
  2940. font-size: 24px;
  2941. margin-bottom: 5px;
  2942. "
  2943. >
  2944. {{ company }}有限公司货物标识卡
  2945. </div>
  2946. <div
  2947. style="
  2948. display: flex;
  2949. justify-content: center;
  2950. font-size: 18px;
  2951. margin-bottom: 5px;
  2952. "
  2953. >
  2954. <div>入&nbsp;库&nbsp;计&nbsp;划&nbsp;单</div>
  2955. </div>
  2956. <div class="print_table" style="display: flex">
  2957. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  2958. <tr>
  2959. <td>货物名称</td>
  2960. <td colspan="2">{{ form.fProductName }}</td>
  2961. <td>库位</td>
  2962. <td colspan="2">{{ stockName }}</td>
  2963. </tr>
  2964. <tr>
  2965. <td>提单号</td>
  2966. <td colspan="2">{{ form.fMblno }}</td>
  2967. <td>清单号</td>
  2968. <td colspan="2">{{ form.fCustomno }}</td>
  2969. </tr>
  2970. <tr>
  2971. <td>箱号</td>
  2972. <td colspan="2"></td>
  2973. <td>总箱量</td>
  2974. <td colspan="2"></td>
  2975. </tr>
  2976. <tr>
  2977. <td>总件数</td>
  2978. <td colspan="2">{{ form.fPlanqty }}</td>
  2979. <td>总净重</td>
  2980. <td colspan="2">{{ form.fPlannetweight }}</td>
  2981. </tr>
  2982. <tr>
  2983. <td>总毛重</td>
  2984. <td colspan="2">{{ form.fPlangrossweight }}</td>
  2985. <td>本垛件数</td>
  2986. <td colspan="2">{{ allfQty }}</td>
  2987. </tr>
  2988. <tr>
  2989. <td>本垛净重</td>
  2990. <td colspan="2">{{ allfGrossweight }}</td>
  2991. <td>本垛毛重</td>
  2992. <td colspan="2">{{ allfNetweight }}</td>
  2993. </tr>
  2994. <tr>
  2995. <td>入库日期</td>
  2996. <td colspan="2">{{ form.fBstime }}</td>
  2997. <td>仓管员</td>
  2998. <td colspan="2">{{ form.fContacts }}</td>
  2999. </tr>
  3000. <tr>
  3001. <td>出库日期</td>
  3002. <td>出库件数</td>
  3003. <td>剩余件数</td>
  3004. <td>出库仓管员</td>
  3005. <td>盘点日期</td>
  3006. <td>盘点人</td>
  3007. </tr>
  3008. <tr style="height: 17.8px" v-for="(item, index) in 10" :key="index">
  3009. <td></td>
  3010. <td></td>
  3011. <td></td>
  3012. <td></td>
  3013. <td></td>
  3014. <td></td>
  3015. </tr>
  3016. <tr style="height: 50px">
  3017. <td>备注</td>
  3018. <td colspan="5"></td>
  3019. </tr>
  3020. </table>
  3021. </div>
  3022. </div>
  3023. <span slot="footer" class="dialog-footer">
  3024. <el-button
  3025. type="primary"
  3026. :disabled="browseStatus"
  3027. @click="
  3028. addprint();
  3029. print_dpxx = false;
  3030. "
  3031. >打印
  3032. </el-button>
  3033. <el-button @click="print_dpxx = false">取消 </el-button>
  3034. </span>
  3035. </el-dialog>
  3036. <el-dialog
  3037. :visible.sync="print_dk"
  3038. width="70%"
  3039. :close-on-click-modal="false"
  3040. :modal="false"
  3041. >
  3042. <div id="print_area1" class="print-div">
  3043. <div
  3044. class="print-title"
  3045. style="
  3046. display: flex;
  3047. justify-content: center;
  3048. font-size: 24px;
  3049. margin-bottom: 5px;
  3050. "
  3051. >
  3052. 垛卡
  3053. </div>
  3054. <div class="print_table" style="display: flex">
  3055. <table border="0" cellspacing="0" cellpadding="0" style="width: 100%">
  3056. <tr>
  3057. <td>客户</td>
  3058. <td colspan="2">{{ form.fCorpidName }}</td>
  3059. <td>箱量</td>
  3060. <td v-if="Printinglist.length">{{ Printinglist[0].fCntqty }}</td>
  3061. <td v-else></td>
  3062. <td>车号</td>
  3063. <td>{{ form.fTruckno }}</td>
  3064. </tr>
  3065. <tr>
  3066. <td>提单号</td>
  3067. <td colspan="2">{{ form.fMblno }}</td>
  3068. <td>品名</td>
  3069. <td colspan="3">
  3070. {{ form.fGoodsid | goodsFormat(goodsOptions) }}
  3071. </td>
  3072. </tr>
  3073. <tr>
  3074. <td>箱号</td>
  3075. <td colspan="2" v-if="Printinglist.length">
  3076. {{ Printinglist[0].fCntrno }}
  3077. </td>
  3078. <td colspan="2" v-else></td>
  3079. <td>报关号</td>
  3080. <td colspan="3"></td>
  3081. </tr>
  3082. <tr>
  3083. <td>入库日期</td>
  3084. <td>入库件数</td>
  3085. <td>出库日期</td>
  3086. <td>出库件数</td>
  3087. <td>结余件数</td>
  3088. <td>区位</td>
  3089. <td>备注</td>
  3090. </tr>
  3091. <tr v-for="(item, index) in Printinglist" :key="index">
  3092. <td>{{ item.fBsdate }}</td>
  3093. <td>{{ item.fQty }}</td>
  3094. <td></td>
  3095. <td></td>
  3096. <td></td>
  3097. <td>{{ item.fWarehouseInformation }}</td>
  3098. <td>{{ item.remark }}</td>
  3099. </tr>
  3100. </table>
  3101. </div>
  3102. <div
  3103. style="
  3104. display: flex;
  3105. justify-content: space-between;
  3106. font-size: 12px;
  3107. "
  3108. >
  3109. <div>操作:{{ form.createBy }}</div>
  3110. <div>司机:</div>
  3111. <div>理货:</div>
  3112. <div>掏箱叉车:</div>
  3113. <div style="width: 150px">码垛叉车:</div>
  3114. </div>
  3115. </div>
  3116. <span slot="footer" class="dialog-footer">
  3117. <el-button
  3118. type="primary"
  3119. :disabled="browseStatus"
  3120. @click="
  3121. addprint();
  3122. print_dk = false;
  3123. "
  3124. >打印
  3125. </el-button>
  3126. <el-button @click="print_dk = false">取消 </el-button>
  3127. </span>
  3128. </el-dialog>
  3129. <!-- 选择作业费协议数据 -->
  3130. <el-dialog
  3131. v-dialogDrag
  3132. title="作业费协议"
  3133. :close-on-click-modal="false"
  3134. :modal="false"
  3135. style="box-shadow: 0 1px 3px rgba(0, 0, 0, 0) !important"
  3136. :visible.sync="warehousingagreements"
  3137. width="70%"
  3138. >
  3139. <template slot="作业费协议">
  3140. <div class="avue-crud__dialog__header">
  3141. <span class="el-dialog__title">
  3142. <span
  3143. style="
  3144. display: inline-block;
  3145. width: 3px;
  3146. height: 20px;
  3147. margin-right: 5px;
  3148. float: left;
  3149. margin-top: 2px;
  3150. "
  3151. ></span>
  3152. </span>
  3153. </div>
  3154. </template>
  3155. <el-menu
  3156. :default-active="activeIndex"
  3157. v-if="Navigation === true"
  3158. class="el-menu-demo"
  3159. mode="horizontal"
  3160. @select="handleSelect"
  3161. >
  3162. <el-menu-item index="1">车队作业费</el-menu-item>
  3163. <el-menu-item index="2">劳务作业费</el-menu-item>
  3164. </el-menu>
  3165. <el-table
  3166. :data="tasklegList"
  3167. ref="table"
  3168. tooltip-effect="dark"
  3169. width="100%"
  3170. border
  3171. stripe
  3172. @selection-change="whgenlegSelectionChange"
  3173. >
  3174. <el-table-column type="selection" width="55"> </el-table-column>
  3175. <el-table-column label="行号" type="index" width="80">
  3176. </el-table-column>
  3177. <el-table-column
  3178. prop="fCorpname"
  3179. header-align="center"
  3180. align="center"
  3181. label="客户名称"
  3182. />
  3183. <el-table-column
  3184. prop="fName"
  3185. header-align="center"
  3186. align="center"
  3187. label="费用名称"
  3188. />
  3189. <el-table-column
  3190. prop="fFeeUnitid"
  3191. header-align="center"
  3192. align="center"
  3193. width="180px"
  3194. label="计价单位"
  3195. >
  3196. <template slot-scope="scope">
  3197. <el-select
  3198. v-model="scope.row.fFeeUnitid"
  3199. placeholder="请选择计价单位"
  3200. @change="changeFeeUnit(scope.row)"
  3201. disabled
  3202. clearable
  3203. >
  3204. <el-option
  3205. v-for="(dict, index) in fFeetUnitOptions"
  3206. :key="index.dictValue"
  3207. :label="dict.dictLabel"
  3208. :value="dict.dictValue"
  3209. />
  3210. </el-select>
  3211. </template>
  3212. </el-table-column>
  3213. <el-table-column
  3214. prop="fPrice"
  3215. header-align="center"
  3216. align="center"
  3217. label="单价"
  3218. />
  3219. </el-table>
  3220. <pagination
  3221. v-show="whgenlegTotal > 0"
  3222. :total="whgenlegTotal"
  3223. :page.sync="pageNum"
  3224. :limit.sync="pageSize"
  3225. @pagination="getWhgenlegList"
  3226. />
  3227. <div slot="footer" class="dialog-footer">
  3228. <el-button type="primary" @click="zhgenlegData">导 入</el-button>
  3229. <el-button
  3230. @click="
  3231. warehousingagreements = false;
  3232. Navigation = false;
  3233. "
  3234. >取 消</el-button
  3235. >
  3236. </div>
  3237. </el-dialog>
  3238. <div style="display: flex; justify-content: flex-end; margin-top: 10px">
  3239. <!-- 弹窗, 新增 / 修改 -->
  3240. <add-or-update
  3241. v-if="addOrUpdateVisible"
  3242. ref="addOrUpdate"
  3243. @refreshDataList="getDataList"
  3244. ></add-or-update>
  3245. <approval-comments
  3246. v-if="addOrUpdateVisib"
  3247. ref="ApprovalComments"
  3248. @refreshDataList="returnData"
  3249. ></approval-comments>
  3250. <el-button
  3251. type="primary"
  3252. :disabled="approvalStatus"
  3253. v-if="form.fBillstatus > 3"
  3254. @click="addOrUpdateHandle(form)"
  3255. >查看审批</el-button
  3256. >
  3257. <el-button
  3258. type="primary"
  3259. v-if="approVal === true"
  3260. @click="addOrUpdateHand(form)"
  3261. >审批</el-button
  3262. >
  3263. <el-button
  3264. :disabled="browseStatus"
  3265. type="success"
  3266. prop="打印"
  3267. @click="print_shd = true"
  3268. >收货单
  3269. </el-button>
  3270. <el-button
  3271. :disabled="browseStatus"
  3272. type="warning"
  3273. prop="打印"
  3274. @click="print_rkd = true"
  3275. >入库单
  3276. </el-button>
  3277. <el-button @click="discharge" :disabled="browseStatus">卸货</el-button>
  3278. <el-button
  3279. type="info"
  3280. :disabled="browseStatus"
  3281. prop="打印"
  3282. @click="print_zyd = true"
  3283. >作业单
  3284. </el-button>
  3285. <el-button :disabled="browseStatus" type="primary" @click="saveForm()"
  3286. >保 存</el-button
  3287. >
  3288. <el-button
  3289. :disabled="browseStatus"
  3290. style="background-color: #008000; color: #fff"
  3291. @click="submitForm()"
  3292. >请核</el-button
  3293. >
  3294. <el-button type="danger" v-if="form.fBillstatus === 6" @click="revoke"
  3295. >撤销请核</el-button
  3296. >
  3297. <el-button
  3298. type="danger"
  3299. v-if="form.fBillstatus === 4 && current == before"
  3300. :disabled="doNot"
  3301. @click="revokeTwo"
  3302. >撤销审批</el-button
  3303. >
  3304. <el-button @click="cancel">取 消</el-button>
  3305. </div>
  3306. </div>
  3307. </template>
  3308. <script>
  3309. import print from "print-js";
  3310. import {
  3311. addWhgenleg,
  3312. addJoblist,
  3313. disChargelist,
  3314. updateCredit,
  3315. listWarehousebills,
  3316. getWarehousebills,
  3317. delWarehousebills,
  3318. addWarehousebills,
  3319. addWarehouse,
  3320. exportWarehousebills,
  3321. revoke,
  3322. revokeTwo,
  3323. delinStock_s,
  3324. } from "@/api/warehouseBusiness/warehouseInStock";
  3325. import { operationAgreement } from "@/api/agreement/agreement";
  3326. import { listCorps } from "@/api/basicdata/corps";
  3327. import { listFees, getFees } from "@/api/basicdata/fees";
  3328. import {
  3329. listWarehouse,
  3330. treeselect,
  3331. listWarehousesss,
  3332. } from "@/api/basicdata/warehouse";
  3333. import { listGoods } from "@/api/basicdata/goods";
  3334. import { listCntrs } from "@/api/basicdata/cntr";
  3335. import { listUser, queryUserVal } from "@/api/system/user";
  3336. import ApprovalComments from "@/views/startApproval";
  3337. import AddOrUpdate from "@/views/viewApproval";
  3338. import Global from "@/layout/components/global";
  3339. import Treeselect from "@riophae/vue-treeselect";
  3340. import "@riophae/vue-treeselect/dist/vue-treeselect.css";
  3341. import UploadFile from "@/components/Uploadfile";
  3342. import Cookies from "js-cookie";
  3343. import { getToken } from "@/utils/auth";
  3344. import { addSet, select, resetModule } from "@/api/system/set";
  3345. import draggable from "vuedraggable";
  3346. export default {
  3347. name: "inStock",
  3348. props: {
  3349. chiId: {
  3350. type: Number,
  3351. required: null,
  3352. },
  3353. copyStatus: {
  3354. type: Number,
  3355. required: null,
  3356. },
  3357. },
  3358. components: {
  3359. UploadFile,
  3360. Treeselect,
  3361. AddOrUpdate,
  3362. ApprovalComments,
  3363. draggable,
  3364. },
  3365. data() {
  3366. return {
  3367. pageNum: 1,
  3368. pageSize: 10,
  3369. dialogWhgenlegList: [],
  3370. tasklegList: [],
  3371. Navigation: false,
  3372. key_id: "",
  3373. warehousingagreements: false,
  3374. mblnoStatus: "",
  3375. selectloading: false,
  3376. fMblnoOptions: [],
  3377. warehouseDrList: [],
  3378. relevantAttachments: [],
  3379. warehouseCrList: [],
  3380. fStltypeOptions: [],
  3381. form: {},
  3382. rules: {
  3383. fDeptid: [{ required: true, message: " ", trigger: "blur" }],
  3384. fMblno: [{ required: true, message: " ", trigger: "blur" }],
  3385. fBsdeptid: [{ required: true, message: " ", trigger: "blur" }],
  3386. fCorpid: [{ required: true, message: " ", trigger: "blur" }],
  3387. fFeetUnit: [{ required: true, message: " ", trigger: "blur" }],
  3388. fPlanqty: [{ required: true, message: " ", trigger: "blur" }],
  3389. fPlangrossweight: [{ required: true, message: " ", trigger: "blur" }],
  3390. fPlannetweight: [{ required: true, message: " ", trigger: "blur" }],
  3391. fChargedate: [{ required: true, message: " ", trigger: "blur" }],
  3392. fMarks: [{ required: true, message: " ", trigger: "blur" }],
  3393. fBsdate: [{ required: true, message: " ", trigger: "blur" }],
  3394. fTrademodeid: [{ required: true, message: " ", trigger: "blur" }],
  3395. fSbu: [{ required: true, message: " ", trigger: "blur" }],
  3396. fBusinessType: [{ required: true, message: " ", trigger: "blur" }],
  3397. fStorekeeper: { required: true, message: " ", trigger: "blur" },
  3398. fWarehouseid: [{ required: true, message: " ", trigger: "blur" }],
  3399. fbillingway: [{ required: true, message: " ", trigger: "blur" }],
  3400. fTocorpid: [{ required: true, message: " ", trigger: "blur" }],
  3401. fGoodsid: [{ required: true, message: " ", trigger: "blur" }],
  3402. },
  3403. imporRules: {
  3404. fBsdate: [{ required: true, message: " ", trigger: "blur" }],
  3405. fQty: [{ required: true, message: " ", trigger: "blur" }],
  3406. fGoodsid: [{ required: true, message: " ", trigger: "blur" }],
  3407. fBusinessType: [{ required: true, message: " ", trigger: "blur" }],
  3408. fMarks: [{ required: true, message: " ", trigger: "blur" }],
  3409. fPackagespecs: [{ required: true, message: " ", trigger: "blur" }],
  3410. fTruckno: [{ required: true, message: " ", trigger: "blur" }],
  3411. },
  3412. browseStatus: false,
  3413. goodsOptions: [],
  3414. warehouseOptions: [],
  3415. userOptions: [],
  3416. businessTypeOption: [],
  3417. fCompanyOptIons: [],
  3418. fleetOptions: [],
  3419. fFeetUnitOptions: [],
  3420. current: "",
  3421. before: "",
  3422. contrOl: false,
  3423. isrequired: 2,
  3424. isrequired2: 2,
  3425. detailsHidden: false,
  3426. detailsHidden2: true,
  3427. CntrTable: [],
  3428. cntrList: [],
  3429. fTrademodeidOptions: [],
  3430. fIfweighOptions: [],
  3431. fIfpledgeOptions: [],
  3432. fSbuOptions: [],
  3433. Pledgebank: [],
  3434. collapselist: ["1"],
  3435. fStorageTypeOptions: [],
  3436. weightList: false,
  3437. importList: {},
  3438. headers: {
  3439. Authorization: "Bearer " + getToken(),
  3440. },
  3441. uploadImgUrl: process.env.VUE_APP_BASE_API + "/common/upload", // 上传的图片服务器地址
  3442. sumMum: 0,
  3443. allfPlanqty: 0,
  3444. detailList: [],
  3445. fWarehouseidOptions: [],
  3446. print_zyd: false,
  3447. print_shd: false,
  3448. print_rkd: false,
  3449. print_lhd: false,
  3450. print_hwqr: false,
  3451. print_lwqr: false,
  3452. print_dpxx: false,
  3453. print_bzrkd: false,
  3454. print_dk: false,
  3455. company: "",
  3456. Printinglist: [],
  3457. //库位
  3458. stockName: "",
  3459. //库位地址
  3460. stockaddr: "",
  3461. Collectionoptionss: [],
  3462. fDriverTel: "",
  3463. fBsdate: "",
  3464. fTruckno: "",
  3465. allfCntqty: 0,
  3466. allfGrossweight: 0,
  3467. allfPlanqty: 0,
  3468. allfNetweight: 0,
  3469. allfQty: 0,
  3470. fixdetaiNum: null,
  3471. dataListSelection: [],
  3472. dataWithdrawList: [],
  3473. title: "",
  3474. fCNameOptions: [],
  3475. fDNameOptions: [],
  3476. whgenlegTotal: 0,
  3477. fGrossweight: 0,
  3478. fQty: 0,
  3479. fNetweight: 0,
  3480. fCntqty: 0,
  3481. activeIndex: "1",
  3482. ifCntrnoStatus: null,
  3483. addOrUpdateVisible: false,
  3484. addOrUpdateVisib: false,
  3485. approVal: false,
  3486. approvalStatus: false,
  3487. doNot: false,
  3488. stockoi: null,
  3489. unloadModes: [],
  3490. dataShowcar: null,
  3491. drag: false,
  3492. tableDate: [
  3493. {
  3494. surface: "0",
  3495. label: "fBillstatus",
  3496. name: "状态",
  3497. checked: 0,
  3498. width: 100,
  3499. },
  3500. {
  3501. surface: "1",
  3502. label: "fBsdate",
  3503. name: "入库日期",
  3504. checked: 0,
  3505. width: 100,
  3506. },
  3507. {
  3508. surface: "2",
  3509. label: "fMblno",
  3510. name: "提单号",
  3511. checked: 0,
  3512. width: 100,
  3513. },
  3514. {
  3515. surface: "3",
  3516. label: "fGoodsid",
  3517. name: "品名",
  3518. checked: 0,
  3519. width: 100,
  3520. },
  3521. {
  3522. surface: "4",
  3523. label: "fBusinessType",
  3524. name: "货物属性",
  3525. checked: 0,
  3526. width: 100,
  3527. },
  3528. {
  3529. surface: "5",
  3530. label: "fMarks",
  3531. name: "属性详情",
  3532. checked: 0,
  3533. width: 100,
  3534. },
  3535. {
  3536. surface: "6",
  3537. label: "fWarehouseInformation",
  3538. name: "库区",
  3539. checked: 0,
  3540. width: 100,
  3541. },
  3542. {
  3543. surface: "7",
  3544. label: "fCntrtype",
  3545. name: "箱型",
  3546. checked: 0,
  3547. width: 100,
  3548. },
  3549. {
  3550. surface: "8",
  3551. label: "fCntqty",
  3552. name: "箱量",
  3553. checked: 0,
  3554. width: 100,
  3555. },
  3556. {
  3557. surface: "9",
  3558. label: "fQty",
  3559. name: "入库件数",
  3560. checked: 0,
  3561. width: 100,
  3562. },
  3563. {
  3564. surface: "10",
  3565. label: "fGrossweight",
  3566. name: "入库毛重(kg)",
  3567. checked: 0,
  3568. width: 100,
  3569. },
  3570. {
  3571. surface: "11",
  3572. label: "fNetweight",
  3573. name: "入库净重(kg)",
  3574. checked: 0,
  3575. width: 100,
  3576. },
  3577. {
  3578. surface: "12",
  3579. label: "fPackagespecs",
  3580. name: "包装规格",
  3581. checked: 0,
  3582. width: 100,
  3583. },
  3584. {
  3585. surface: "13",
  3586. label: "fFleet",
  3587. name: "车队",
  3588. checked: 0,
  3589. width: 100,
  3590. },
  3591. {
  3592. surface: "13",
  3593. label: "fTruckno",
  3594. name: "车号",
  3595. checked: 0,
  3596. width: 100,
  3597. },
  3598. {
  3599. surface: "14",
  3600. label: "fDriverName",
  3601. name: "司机名称",
  3602. checked: 0,
  3603. width: 100,
  3604. },
  3605. {
  3606. surface: "15",
  3607. label: "fDriverTel",
  3608. name: "司机电话",
  3609. checked: 0,
  3610. width: 100,
  3611. },
  3612. {
  3613. surface: "16",
  3614. label: "fDriverIdCar",
  3615. name: "司机身份证",
  3616. checked: 0,
  3617. width: 100,
  3618. },
  3619. {
  3620. surface: "17",
  3621. label: "fSerialNumber",
  3622. name: "流水号",
  3623. checked: 0,
  3624. width: 100,
  3625. },
  3626. {
  3627. surface: "18",
  3628. label: "fCntrno",
  3629. name: "箱号",
  3630. checked: 0,
  3631. width: 100,
  3632. },
  3633. {
  3634. surface: "19",
  3635. label: "fLntype",
  3636. name: "装卸方式",
  3637. checked: 0,
  3638. width: 100,
  3639. },
  3640. {
  3641. surface: "20",
  3642. label: "fForkliftman",
  3643. name: "叉车工",
  3644. checked: 0,
  3645. width: 100,
  3646. },
  3647. {
  3648. surface: "21",
  3649. label: "fStevedore",
  3650. name: "装卸工",
  3651. checked: 0,
  3652. width: 100,
  3653. },
  3654. {
  3655. surface: "22",
  3656. label: "fLocalcntrno",
  3657. name: "库内箱号",
  3658. checked: 0,
  3659. width: 100,
  3660. },
  3661. {
  3662. surface: "23",
  3663. label: "fSealno",
  3664. name: "封号",
  3665. checked: 0,
  3666. width: 100,
  3667. },
  3668. {
  3669. surface: "24",
  3670. label: "fGoodsval",
  3671. name: "货值",
  3672. checked: 0,
  3673. width: 100,
  3674. },
  3675. {
  3676. surface: "25",
  3677. label: "remark",
  3678. name: "备注",
  3679. checked: 0,
  3680. width: 100,
  3681. },
  3682. ],
  3683. setRowList: [],
  3684. getRowList: [],
  3685. allCheck: false,
  3686. showSetting: false,
  3687. tfQtynum: 0,
  3688. tfNetweightnum: 0,
  3689. tfGrossweightnum: 0,
  3690. };
  3691. },
  3692. created() {
  3693. this.setRowList = this.tableDate;
  3694. this.getRowList = this.tableDate;
  3695. this.getDicts("data_stltype_type").then((response) => {
  3696. this.fStltypeOptions = response.data;
  3697. });
  3698. this.getDicts("st_in_type").then((response) => {
  3699. this.businessTypeOption = response.data;
  3700. localStorage.setItem("businessTypeList", JSON.stringify(response.data));
  3701. });
  3702. this.getDicts("data_unitfees").then((response) => {
  3703. this.fFeetUnitOptions = response.data;
  3704. });
  3705. this.getDicts("data_trademodes").then((response) => {
  3706. this.fTrademodeidOptions = response.data;
  3707. });
  3708. this.getDicts("data_ifweigh_status").then((response) => {
  3709. this.fIfweighOptions = response.data;
  3710. });
  3711. this.getDicts("data_ifpledge_status").then((response) => {
  3712. this.fIfpledgeOptions = response.data;
  3713. });
  3714. this.getDicts("storage_type").then((response) => {
  3715. this.fStorageTypeOptions = response.data;
  3716. localStorage.setItem("fStorageTypeList", JSON.stringify(response.data));
  3717. });
  3718. this.getDicts("unload_mode").then((response) => {
  3719. this.unloadModes = response.data;
  3720. });
  3721. this.getConfigKey("stockoi").then((response) => {
  3722. this.stockoi = response.msg;
  3723. });
  3724. this.getConfigKey("data_showcar").then((response) => {
  3725. this.dataShowcar = response.msg;
  3726. if (this.dataShowcar == "1") {
  3727. this.detailsHidden2 = false;
  3728. this.form.fBusinessType = "0";
  3729. }
  3730. });
  3731. listWarehousesss({ fStatus: 0, delFlag: 0 }).then((response) => {
  3732. this.warehouseOptions = response.rows;
  3733. });
  3734. listFees({ fDc: "C" }).then((response) => {
  3735. this.fCNameOptions = response.rows;
  3736. });
  3737. listFees({ fDc: "D" }).then((response) => {
  3738. this.fDNameOptions = response.rows;
  3739. });
  3740. listCorps({ type: 1 }).then((response) => {
  3741. this.fMblnoOptions = response.rows;
  3742. });
  3743. listCorps().then((response) => {
  3744. this.fSbuOptions = response.rows;
  3745. });
  3746. listCorps({ type: 5 }).then((response) => {
  3747. this.Pledgebank = response.rows;
  3748. });
  3749. listUser().then((response) => {
  3750. this.userOptions = response.rows;
  3751. });
  3752. listGoods({ fStatus: 0, delFlag: 0 }).then((response) => {
  3753. this.goodsOptions = response.rows;
  3754. });
  3755. listCntrs({ fStatus: "T" }).then((response) => {
  3756. this.cntrList = response.rows;
  3757. });
  3758. listCorps({ fTypeid: 6 }).then((response) => {
  3759. this.fCompanyOptIons = response.rows;
  3760. });
  3761. listCorps({ fTypeid: 2 }).then((response) => {
  3762. this.fleetOptions = response.rows;
  3763. });
  3764. this.company = localStorage.getItem("companyName");
  3765. this.queryUser();
  3766. this.getRow();
  3767. },
  3768. filters: {
  3769. fStorageFormat(row) {
  3770. let name;
  3771. for (const item of JSON.parse(localStorage.getItem("fStorageTypeList"))) {
  3772. if (row == item.dictValue) {
  3773. name = item.dictLabel;
  3774. }
  3775. }
  3776. return name;
  3777. },
  3778. fBusinessTypeFormat(row) {
  3779. let name;
  3780. for (const item of JSON.parse(localStorage.getItem("businessTypeList"))) {
  3781. if (row == item.dictValue) {
  3782. name = item.dictLabel;
  3783. }
  3784. }
  3785. return name;
  3786. },
  3787. fStorageTypeFormat(row, fStorageTypeOptions) {
  3788. let fStorageType;
  3789. fStorageTypeOptions.map((e) => {
  3790. if (row == e.dictValue) {
  3791. fStorageType = e.dictLabel;
  3792. }
  3793. });
  3794. return fStorageType;
  3795. },
  3796. fCntrtypeFormat(row, cntrList) {
  3797. let fCntrtype;
  3798. cntrList.map((e) => {
  3799. if (row == e.fId) {
  3800. fCntrtype = e.fName;
  3801. }
  3802. });
  3803. return fCntrtype;
  3804. },
  3805. goodsFormat(row, goodsOptions) {
  3806. let goods;
  3807. goodsOptions.map((e) => {
  3808. if (row == e.fId) {
  3809. goods = e.fName;
  3810. }
  3811. });
  3812. return goods;
  3813. },
  3814. fLntypeFormat(row, unloadModes) {
  3815. let name;
  3816. unloadModes.map((e) => {
  3817. if (row == e.dictValue) {
  3818. name = e.dictLabel;
  3819. }
  3820. });
  3821. return name;
  3822. },
  3823. fFleetFormat(row, fleetOptions) {
  3824. let name;
  3825. fleetOptions.map((e) => {
  3826. if (row == e.fId) {
  3827. name = e.fName;
  3828. }
  3829. });
  3830. return name;
  3831. },
  3832. fBsdateFormat(row) {
  3833. if (row) {
  3834. const dateMat = new Date(row);
  3835. const year = dateMat.getFullYear();
  3836. const month = dateMat.getMonth() + 1;
  3837. const day = dateMat.getDate();
  3838. const timeFormat = year + "-" + month + "-" + day;
  3839. return timeFormat;
  3840. }
  3841. },
  3842. fBillstatusFormat(row) {
  3843. let Name;
  3844. switch (row) {
  3845. case 10:
  3846. Name = "计划";
  3847. break;
  3848. case 20:
  3849. Name = "待入库";
  3850. break;
  3851. case 30:
  3852. Name = "入库中";
  3853. break;
  3854. default:
  3855. Name = "已入库";
  3856. }
  3857. return Name;
  3858. },
  3859. },
  3860. methods: {
  3861. init() {
  3862. this.resetForm("form");
  3863. this.resetForm("importList");
  3864. this.detailList = [];
  3865. this.relevantAttachments = [];
  3866. this.warehouseCrList = [];
  3867. this.warehouseDrList = [];
  3868. this.CntrTable = [];
  3869. this.sumMum = 0;
  3870. if (this.dataShowcar == "1") {
  3871. this.detailsHidden2 = false;
  3872. }
  3873. this.getForm();
  3874. },
  3875. reset() {
  3876. this.importList = {
  3877. fBillstatus: null,
  3878. fMblno: null,
  3879. fQty: null,
  3880. fNetweight: null,
  3881. fGrossweight: null,
  3882. fBsdate: null,
  3883. fGoodsid: null,
  3884. fBusinessType: null,
  3885. fMarks: null,
  3886. fWarehouselocid: null,
  3887. fWarehouseInformation: null,
  3888. fCntrtype: null,
  3889. fCntqty: null,
  3890. fPackagespecs: null,
  3891. fTruckno: null,
  3892. fDriverName: null,
  3893. fDriverTel: null,
  3894. fDriverIdCar: null,
  3895. fSerialNumber: null,
  3896. fCntrno: null,
  3897. fGoodsval: null,
  3898. remark: null,
  3899. };
  3900. },
  3901. tfQty(row) {
  3902. this.tfQtynum = (row / 1000).toFixed(2);
  3903. },
  3904. tfNetweight(row) {
  3905. this.tfNetweightnum = (row / 1000).toFixed(2);
  3906. },
  3907. tfGrossweight(row) {
  3908. this.tfGrossweightnum = (row / 1000).toFixed(2);
  3909. },
  3910. //列设置全选
  3911. allChecked() {
  3912. if (this.allCheck == true) {
  3913. this.setRowList.map((e) => {
  3914. return (e.checked = 0);
  3915. });
  3916. } else {
  3917. this.setRowList.map((e) => {
  3918. return (e.checked = 1);
  3919. });
  3920. }
  3921. },
  3922. tishi() {
  3923. return this.$message.error("正在开发中");
  3924. },
  3925. //查询列数据
  3926. getRow() {
  3927. let that = this;
  3928. this.data = {
  3929. tableName: "入库明细",
  3930. userId: Cookies.get("userName"),
  3931. };
  3932. select(this.data).then((res) => {
  3933. if (res.data.length != 0) {
  3934. this.getRowList = res.data.filter((e) => e.checked == 0);
  3935. this.setRowList = res.data;
  3936. this.setRowList = this.setRowList.reduce((res, item) => {
  3937. res.push({
  3938. surface: item.surface,
  3939. label: item.label,
  3940. name: item.name,
  3941. checked: item.checked,
  3942. width: item.width,
  3943. fixed: item.fixed,
  3944. });
  3945. return res;
  3946. }, []);
  3947. }
  3948. });
  3949. },
  3950. //重置列表
  3951. delRow() {
  3952. this.data = {
  3953. tableName: "入库明细",
  3954. userId: Cookies.get("userName"),
  3955. };
  3956. resetModule(this.data).then((res) => {
  3957. if (res.code == 200) {
  3958. this.showSetting = false;
  3959. this.setRowList = this.$options.data().tableDate;
  3960. this.getRowList = this.$options.data().tableDate;
  3961. }
  3962. });
  3963. },
  3964. //保存列设置
  3965. save() {
  3966. this.showSetting = false;
  3967. this.data = {
  3968. tableName: "入库明细",
  3969. userId: Cookies.get("userName"),
  3970. sysTableSetList: this.setRowList,
  3971. };
  3972. addSet(this.data).then((res) => {
  3973. if (res.code == 200) {
  3974. this.showSetting = false;
  3975. this.getRowList = this.setRowList.filter((e) => e.checked == 0);
  3976. console.log(this.tableDate);
  3977. }
  3978. });
  3979. },
  3980. //开始拖拽事件
  3981. onStart() {
  3982. this.drag = true;
  3983. },
  3984. //拖拽结束事件
  3985. onEnd() {
  3986. this.drag = false;
  3987. },
  3988. //撤销审批
  3989. revokeTwo() {
  3990. let data = {
  3991. actId: 110,
  3992. billId: this.form.fId,
  3993. id: this.form.fId,
  3994. };
  3995. revokeTwo(data).then((data) => {
  3996. if (data.code === 200) {
  3997. this.browseStatus = false;
  3998. this.msgSuccess("撤销成功");
  3999. }
  4000. });
  4001. },
  4002. // 查看审批流
  4003. getDataList() {
  4004. this.addOrUpdateVisible = false;
  4005. },
  4006. returnData() {
  4007. this.addOrUpdateVisib = false;
  4008. this.open = false;
  4009. this.cancelTwo();
  4010. },
  4011. addOrUpdateHandle(form) {
  4012. this.addOrUpdateVisible = true;
  4013. let actId = "110";
  4014. this.$nextTick(() => {
  4015. this.$refs.addOrUpdate.init(form.fId, actId);
  4016. });
  4017. },
  4018. addOrUpdateHand(form) {
  4019. this.addOrUpdateVisib = true;
  4020. this.$nextTick(() => {
  4021. this.$refs.ApprovalComments.init(form.fId, 110);
  4022. });
  4023. },
  4024. changefStltype(row) {
  4025. this.fMblnoOptions.map((e) => {
  4026. if (row == e.fId) {
  4027. this.$set(
  4028. this.form,
  4029. "fStltypeid",
  4030. e.fStltypeid ? e.fStltypeid.toString() : null
  4031. );
  4032. }
  4033. });
  4034. },
  4035. changeGoods(row) {
  4036. this.goodsOptions.map((e) => {
  4037. if (row == e.fId) {
  4038. if (e.ifCntrno == "1") {
  4039. this.ifCntrnoStatus = 1;
  4040. } else {
  4041. this.ifCntrnoStatus = null;
  4042. }
  4043. }
  4044. });
  4045. },
  4046. discharge() {
  4047. if (this.Printinglist.length > 0) {
  4048. for (let item in this.Printinglist) {
  4049. if (this.Printinglist[item].fBillstatus === 10) {
  4050. return this.$message.error("请先打印作业单");
  4051. }
  4052. if (
  4053. this.Printinglist[item].fBillstatus >= 30 &&
  4054. this.stockoi == "0"
  4055. ) {
  4056. return this.$message.error("请勿重复卸货");
  4057. }
  4058. }
  4059. if (this.CntrTable.length > 0) {
  4060. let arr = [];
  4061. this.CntrTable.map((e) => {
  4062. this.cntrList.map((item) => {
  4063. if (item.fId == e.fCntrid) {
  4064. arr.push(item.fName + "X" + e.fCntrcount);
  4065. }
  4066. });
  4067. });
  4068. arr = [...new Set(arr)];
  4069. this.form.fCntval = arr.join(",");
  4070. } else {
  4071. this.form.fCntval = null;
  4072. }
  4073. if (this.detailList.length > 0) {
  4074. let arr = [];
  4075. this.detailList.map((e) => {
  4076. this.goodsOptions.map((item) => {
  4077. if (e.fGoodsid == item.fId) {
  4078. arr.push(item.fName);
  4079. }
  4080. });
  4081. });
  4082. arr = [...new Set(arr)];
  4083. this.form.fProductName = arr.join(",");
  4084. } else {
  4085. this.form.fProductName = "";
  4086. }
  4087. if (this.detailList.length > 0) {
  4088. let arr = [];
  4089. this.detailList.map((e) => {
  4090. arr.push(e.fMarks);
  4091. });
  4092. arr = [...new Set(arr)];
  4093. this.form.fMarks = arr.join(",");
  4094. } else {
  4095. this.form.fMarks = "";
  4096. }
  4097. if (this.detailList.length == 0) {
  4098. this.form.fNetweight = 0;
  4099. this.form.fPlanvolumn = 0;
  4100. this.form.fGrossweight = 0;
  4101. } else {
  4102. this.form.fNetweight = this.fNetweight;
  4103. this.form.fPlanvolumn = this.fPlanvolumn;
  4104. this.form.fGrossweight = this.fGrossweight;
  4105. }
  4106. let formData = new window.FormData();
  4107. formData.append("warehouseBills", JSON.stringify(this.form));
  4108. formData.append("tEnclosure", JSON.stringify(this.relevantAttachments));
  4109. formData.append(
  4110. "warehousebillsitems",
  4111. JSON.stringify(this.Printinglist)
  4112. );
  4113. formData.append(
  4114. "warehousebillsfeesDr",
  4115. JSON.stringify(this.warehouseDrList)
  4116. );
  4117. formData.append(
  4118. "warehousebillsfeesCr",
  4119. JSON.stringify(this.warehouseCrList)
  4120. );
  4121. formData.append("tCntr", JSON.stringify(this.CntrTable));
  4122. disChargelist(formData).then((response) => {
  4123. if ((response.code = 200)) {
  4124. this.detailList.map((e, index) => {
  4125. response.data.warehousebillsitems.map((item) => {
  4126. if (e.fId == item.fId) {
  4127. e = item;
  4128. this.$set(this.detailList, index, e);
  4129. }
  4130. });
  4131. });
  4132. this.msgSuccess("卸货成功");
  4133. this.$set(this.form, "fItemsStatus", 3);
  4134. }
  4135. });
  4136. } else {
  4137. this.$message.error("请选择需要卸货的明细!");
  4138. }
  4139. },
  4140. creditClick() {
  4141. for (let item in this.Printinglist) {
  4142. if (!this.Printinglist[item].fId) {
  4143. return this.$message.error("请存在未保存的数据");
  4144. }
  4145. if (this.Printinglist[item].fBillstatus == 10 && this.stockoi == "0") {
  4146. return this.$message.error("请存在未打印的作业单");
  4147. }
  4148. if (this.Printinglist[item].fBillstatus == 20 && this.stockoi == "0") {
  4149. return this.$message.error("请存在未卸货的数据");
  4150. }
  4151. }
  4152. if (this.CntrTable.length > 0) {
  4153. let arr = [];
  4154. this.CntrTable.map((e) => {
  4155. this.cntrList.map((item) => {
  4156. if (item.fId == e.fCntrid) {
  4157. arr.push(item.fName + "X" + e.fCntrcount);
  4158. }
  4159. });
  4160. });
  4161. arr = [...new Set(arr)];
  4162. this.form.fCntval = arr.join(",");
  4163. } else {
  4164. this.form.fCntval = null;
  4165. }
  4166. if (this.detailList.length > 0) {
  4167. let arr = [];
  4168. this.detailList.map((e) => {
  4169. this.goodsOptions.map((item) => {
  4170. if (e.fGoodsid == item.fId) {
  4171. arr.push(item.fName);
  4172. }
  4173. });
  4174. });
  4175. arr = [...new Set(arr)];
  4176. this.form.fProductName = arr.join(",");
  4177. } else {
  4178. this.form.fProductName = "";
  4179. }
  4180. if (this.detailList.length > 0) {
  4181. let arr = [];
  4182. this.detailList.map((e) => {
  4183. arr.push(e.fMarks);
  4184. });
  4185. arr = [...new Set(arr)];
  4186. this.form.fMarks = arr.join(",");
  4187. } else {
  4188. this.form.fMarks = "";
  4189. }
  4190. if (this.detailList.length == 0) {
  4191. this.form.fNetweight = 0;
  4192. this.form.fPlanvolumn = 0;
  4193. this.form.fGrossweight = 0;
  4194. } else {
  4195. this.form.fNetweight = this.fNetweight;
  4196. this.form.fPlanvolumn = this.fPlanvolumn;
  4197. this.form.fGrossweight = this.fGrossweight;
  4198. }
  4199. let formData = new window.FormData();
  4200. formData.append("warehouseBills", JSON.stringify(this.form));
  4201. formData.append("warehousebillsitems", JSON.stringify(this.Printinglist));
  4202. formData.append(
  4203. "warehousebillsfeesDr",
  4204. JSON.stringify(this.warehouseDrList)
  4205. );
  4206. formData.append(
  4207. "warehousebillsfeesCr",
  4208. JSON.stringify(this.warehouseCrList)
  4209. );
  4210. formData.append("tEnclosure", JSON.stringify(this.relevantAttachments));
  4211. formData.append("whgenleg", JSON.stringify(this.relevantAttachments));
  4212. formData.append("tCntr", JSON.stringify(this.CntrTable));
  4213. addWhgenleg(formData).then((response) => {
  4214. if ((response.code = 200)) {
  4215. this.detailList.map((e, index) => {
  4216. response.data.warehousebillsitems.map((item) => {
  4217. if (e.fId == item.fId) {
  4218. e = item;
  4219. this.$set(this.detailList, index, e);
  4220. }
  4221. });
  4222. });
  4223. this.msgSuccess("入库成功");
  4224. this.$set(this.form, "fItemsStatus", 4);
  4225. }
  4226. });
  4227. },
  4228. // 撤回入账
  4229. withdrawClick() {
  4230. for (let item in this.Printinglist) {
  4231. if (!this.Printinglist[item].fId) {
  4232. return this.$message.error("请存在未保存的数据");
  4233. }
  4234. if (this.Printinglist[item].fBillstatus == 10) {
  4235. return this.$message.error("请存在未打印的作业单");
  4236. }
  4237. if (this.Printinglist[item].fBillstatus == 20) {
  4238. return this.$message.error("请存在未卸货的数据");
  4239. }
  4240. if (this.Printinglist[item].fBillstatus == 30) {
  4241. return this.$message.error("请存在未入库的数据");
  4242. }
  4243. }
  4244. if (this.CntrTable.length > 0) {
  4245. let arr = [];
  4246. this.CntrTable.map((e) => {
  4247. this.cntrList.map((item) => {
  4248. if (item.fId == e.fCntrid) {
  4249. arr.push(item.fName + "X" + e.fCntrcount);
  4250. }
  4251. });
  4252. });
  4253. arr = [...new Set(arr)];
  4254. this.form.fCntval = arr.join(",");
  4255. } else {
  4256. this.form.fCntval = null;
  4257. }
  4258. if (this.detailList.length > 0) {
  4259. let arr = [];
  4260. this.detailList.map((e) => {
  4261. this.goodsOptions.map((item) => {
  4262. if (e.fGoodsid == item.fId) {
  4263. arr.push(item.fName);
  4264. }
  4265. });
  4266. });
  4267. arr = [...new Set(arr)];
  4268. this.form.fProductName = arr.join(",");
  4269. } else {
  4270. this.form.fProductName = "";
  4271. }
  4272. if (this.detailList.length > 0) {
  4273. let arr = [];
  4274. this.detailList.map((e) => {
  4275. arr.push(e.fMarks);
  4276. });
  4277. arr = [...new Set(arr)];
  4278. this.form.fMarks = arr.join(",");
  4279. } else {
  4280. this.form.fMarks = "";
  4281. }
  4282. if (this.detailList.length == 0) {
  4283. this.form.fNetweight = 0;
  4284. this.form.fPlanvolumn = 0;
  4285. this.form.fGrossweight = 0;
  4286. } else {
  4287. this.form.fNetweight = this.fNetweight;
  4288. this.form.fPlanvolumn = this.fPlanvolumn;
  4289. this.form.fGrossweight = this.fGrossweight;
  4290. }
  4291. // 撤回入库
  4292. let formData = new window.FormData();
  4293. formData.append("warehouseBills", JSON.stringify(this.form));
  4294. formData.append("warehousebillsitems", JSON.stringify(this.Printinglist));
  4295. formData.append(
  4296. "warehousebillsfeesDr",
  4297. JSON.stringify(this.warehouseDrList)
  4298. );
  4299. formData.append(
  4300. "warehousebillsfeesCr",
  4301. JSON.stringify(this.warehouseCrList)
  4302. );
  4303. formData.append("tEnclosure", JSON.stringify(this.relevantAttachments));
  4304. formData.append("tCntr", JSON.stringify(this.CntrTable));
  4305. updateCredit(formData).then((response) => {
  4306. this.Printinglist.map((e) => {
  4307. this.detailList.map((item, index) => {
  4308. if (e.fId == item.fId) {
  4309. this.$set(this.detailList[index], "fBillstatus", 10);
  4310. }
  4311. });
  4312. });
  4313. this.msgSuccess("撤回成功");
  4314. this.$set(this.form, "fItemsStatus", 1);
  4315. });
  4316. },
  4317. getForm() {
  4318. getWarehousebills(this.chiId).then((response) => {
  4319. this.form = response.data.warehousebills;
  4320. if (this.form.fBillstatus > 2) {
  4321. this.approvalStatus = false;
  4322. this.browseStatus = true;
  4323. } else {
  4324. this.approvalStatus = true;
  4325. this.browseStatus = false;
  4326. }
  4327. this.$set(this.form, "fEta", Date.parse(this.form.fEta));
  4328. this.$set(this.form, "fBsdate", Date.parse(this.form.fBsdate));
  4329. this.$set(this.form, "fBstime", Date.parse(this.form.fBstime));
  4330. this.$set(this.form, "createTime", Date.parse(this.form.createTime));
  4331. this.$set(this.form, "fChargedate", Date.parse(this.form.fChargedate));
  4332. this.$set(this.form, "fFeetUnit", this.form.fFeetunit);
  4333. this.tfQtynum = (this.form.fPlanqty / 1000).toFixed(2);
  4334. this.tfNetweightnum = (this.form.fPlannetweight / 1000).toFixed(2);
  4335. this.tfGrossweightnum = (this.form.fPlangrossweight / 1000).toFixed(2);
  4336. if (this.form.fTrademodeid) {
  4337. this.$set(
  4338. this.form,
  4339. "fTrademodeid",
  4340. this.form.fTrademodeid.toString()
  4341. );
  4342. }
  4343. if (this.form.fStltypeid || this.form.fStltypeid == 0) {
  4344. this.$set(this.form, "fStltypeid", this.form.fStltypeid.toString());
  4345. }
  4346. if (!this.copyStatus) {
  4347. if (response.data.warehouseBillsItem) {
  4348. response.data.warehouseBillsItem.map((e) => {
  4349. e.fLntype = e.fLntype ? e.fLntype.toString() : null;
  4350. });
  4351. this.detailList = response.data.warehouseBillsItem;
  4352. } else {
  4353. this.detailList = [];
  4354. }
  4355. response.data.warehousebillsfeesCr.map((e) => {
  4356. if (e.fFeeunitid) {
  4357. e.fFeeUnitid = e.fFeeunitid.toString();
  4358. }
  4359. if (e.fStltypeid || e.fStltypeid == 0) {
  4360. e.fStltypeid = e.fStltypeid.toString();
  4361. }
  4362. });
  4363. this.warehouseCrList = response.data.warehousebillsfeesCr;
  4364. response.data.warehousebillsfeesDr.map((e) => {
  4365. if (e.fFeeunitid) {
  4366. e.fFeeUnitid = e.fFeeunitid.toString();
  4367. }
  4368. if (e.fStltypeid || e.fStltypeid == 0) {
  4369. e.fStltypeid = e.fStltypeid.toString();
  4370. }
  4371. });
  4372. this.warehouseDrList = response.data.warehousebillsfeesDr;
  4373. if (response.data.tCntrList) {
  4374. this.CntrTable = response.data.tCntrList;
  4375. } else {
  4376. this.CntrTable = [];
  4377. }
  4378. if (response.data.enclosures) {
  4379. this.relevantAttachments = response.data.enclosures;
  4380. }
  4381. } else {
  4382. this.$set(this.form, "fId", null);
  4383. this.$set(this.form, "fMblno", null);
  4384. this.$set(this.form, "fMarks", null);
  4385. this.$set(this.form, "fProductName", null);
  4386. this.$set(this.form, "fNetweight", 0);
  4387. this.$set(this.form, "fPlanvolumn", 0);
  4388. this.$set(this.form, "fGrossweight", 0);
  4389. }
  4390. });
  4391. },
  4392. //从表库位弹窗下拉树状事件
  4393. getAlltree(tree) {
  4394. this.importList.fWarehouseInformation = tree.fWarehouseInformation;
  4395. },
  4396. submitForm() {
  4397. this.$refs["form"].validate((valid) => {
  4398. if (valid) {
  4399. if (this.detailList.length === 0) {
  4400. return this.$message.error("请新增库存明细!");
  4401. }
  4402. for (let item in this.warehouseDrList) {
  4403. if (!this.warehouseDrList[item].fCorpid) {
  4404. if (item === "fBusinessType") {
  4405. } else {
  4406. this.$message.error(
  4407. "请维护收款信息第" + (Number(item) + 1) + "行客户名称"
  4408. );
  4409. return false;
  4410. }
  4411. }
  4412. if (!this.warehouseDrList[item].fFeeid) {
  4413. if (item === "fBusinessType") {
  4414. } else {
  4415. this.$message.error(
  4416. "请维护收款信息第" + (Number(item) + 1) + "行费用名称"
  4417. );
  4418. return false;
  4419. }
  4420. }
  4421. if (!this.warehouseDrList[item].fFeeUnitid) {
  4422. if (item === "fBusinessType") {
  4423. } else {
  4424. this.$message.error(
  4425. "请维护收款信息第" + (Number(item) + 1) + "行计价单位"
  4426. );
  4427. return false;
  4428. }
  4429. }
  4430. }
  4431. for (let item in this.warehouseCrList) {
  4432. if (!this.warehouseCrList[item].fCorpid) {
  4433. if (item === "fBusinessType") {
  4434. } else {
  4435. this.$message.error(
  4436. "请维护付款信息第" + (Number(item) + 1) + "行客户名称"
  4437. );
  4438. return false;
  4439. }
  4440. }
  4441. if (!this.warehouseCrList[item].fFeeid) {
  4442. if (item === "fBusinessType") {
  4443. } else {
  4444. this.$message.error(
  4445. "请维护付款信息第" + (Number(item) + 1) + "行费用名称"
  4446. );
  4447. return false;
  4448. }
  4449. }
  4450. if (!this.warehouseCrList[item].fFeeUnitid) {
  4451. if (item === "fBusinessType") {
  4452. } else {
  4453. this.$message.error(
  4454. "请维护付款信息第" + (Number(item) + 1) + "行计价单位"
  4455. );
  4456. return false;
  4457. }
  4458. }
  4459. }
  4460. // 附件数据
  4461. this.form.fBillingway = this.form.fFeetUnit;
  4462. if (this.detailList.length == 0) {
  4463. this.form.fNetweight = 0;
  4464. this.form.fPlanvolumn = 0;
  4465. this.form.fGrossweight = 0;
  4466. } else {
  4467. this.form.fNetweight = this.fNetweight;
  4468. this.form.fPlanvolumn = this.fPlanvolumn;
  4469. this.form.fGrossweight = this.fGrossweight;
  4470. }
  4471. if (this.CntrTable.length > 0) {
  4472. let arr = [];
  4473. this.CntrTable.map((e) => {
  4474. this.cntrList.map((item) => {
  4475. if (item.fId == e.fCntrid) {
  4476. arr.push(item.fName + "X" + e.fCntrcount);
  4477. }
  4478. });
  4479. });
  4480. arr = [...new Set(arr)];
  4481. this.form.fCntval = arr.join(",");
  4482. } else {
  4483. this.form.fCntval = null;
  4484. }
  4485. if (this.detailList.length > 0) {
  4486. let arr = [];
  4487. this.detailList.map((e) => {
  4488. this.goodsOptions.map((item) => {
  4489. if (e.fGoodsid == item.fId) {
  4490. arr.push(item.fName);
  4491. }
  4492. });
  4493. });
  4494. arr = [...new Set(arr)];
  4495. this.form.fProductName = arr.join(",");
  4496. } else {
  4497. this.form.fProductName = "";
  4498. }
  4499. if (this.detailList.length > 0) {
  4500. let arr = [];
  4501. this.detailList.map((e) => {
  4502. arr.push(e.fMarks);
  4503. });
  4504. arr = [...new Set(arr)];
  4505. this.form.fMarks = arr.join(",");
  4506. } else {
  4507. this.form.fMarks = "";
  4508. }
  4509. let formData = new window.FormData();
  4510. formData.append("tWarehouseBills", JSON.stringify(this.form));
  4511. // 库存明细
  4512. formData.append(
  4513. "tWarehousebillsitems",
  4514. JSON.stringify(this.detailList)
  4515. );
  4516. // 附件数据
  4517. formData.append(
  4518. "tEnclosure",
  4519. JSON.stringify(this.relevantAttachments)
  4520. );
  4521. // 费用明细付款
  4522. formData.append(
  4523. "tWarehousebillsfeesCr",
  4524. JSON.stringify(this.warehouseCrList)
  4525. );
  4526. // 收款
  4527. formData.append(
  4528. "tWarehousebillsfeesDr",
  4529. JSON.stringify(this.warehouseDrList)
  4530. );
  4531. formData.append("mblnoStatus", JSON.stringify(this.mblnoStatus));
  4532. formData.append("tCntr", JSON.stringify(this.CntrTable));
  4533. addWarehouse(formData).then((response) => {
  4534. if (response.code == 200) {
  4535. this.msgSuccess("提交成功");
  4536. setTimeout(() => {
  4537. this.cancel();
  4538. }, 200);
  4539. }
  4540. });
  4541. }
  4542. });
  4543. },
  4544. saveForm(status) {
  4545. this.$refs["form"].validate((valid) => {
  4546. if (valid) {
  4547. this.form.fBillingway = this.form.fFeetUnit;
  4548. if (this.detailList.length == 0) {
  4549. this.form.fNetweight = 0;
  4550. this.form.fPlanvolumn = 0;
  4551. this.form.fGrossweight = 0;
  4552. } else {
  4553. this.form.fNetweight = this.fNetweight;
  4554. this.form.fPlanvolumn = this.fPlanvolumn;
  4555. this.form.fGrossweight = this.fGrossweight;
  4556. }
  4557. let formData = new window.FormData();
  4558. // 附件数据
  4559. this.form.fQty = this.fQty;
  4560. if (this.CntrTable.length > 0) {
  4561. let arr = [];
  4562. this.CntrTable.map((e) => {
  4563. this.cntrList.map((item) => {
  4564. if (item.fId == e.fCntrid) {
  4565. arr.push(item.fName + "X" + e.fCntrcount);
  4566. }
  4567. });
  4568. });
  4569. arr = [...new Set(arr)];
  4570. this.form.fCntval = arr.join(",");
  4571. } else {
  4572. this.form.fCntval = null;
  4573. }
  4574. if (this.detailList.length > 0) {
  4575. let arr = [];
  4576. this.detailList.map((e) => {
  4577. this.goodsOptions.map((item) => {
  4578. if (e.fGoodsid == item.fId) {
  4579. arr.push(item.fName);
  4580. }
  4581. });
  4582. });
  4583. arr = [...new Set(arr)];
  4584. this.form.fProductName = arr.join(",");
  4585. } else {
  4586. this.form.fProductName = "";
  4587. }
  4588. if (this.detailList.length > 0) {
  4589. let arr = [];
  4590. this.detailList.map((e) => {
  4591. arr.push(e.fMarks);
  4592. });
  4593. arr = [...new Set(arr)];
  4594. this.form.fMarks = arr.join(",");
  4595. } else {
  4596. this.form.fMarks = "";
  4597. }
  4598. formData.append("tWarehouseBills", JSON.stringify(this.form));
  4599. // 库存明细
  4600. formData.append(
  4601. "tWarehousebillsitems",
  4602. JSON.stringify(this.detailList)
  4603. );
  4604. // 附件数据
  4605. formData.append(
  4606. "tEnclosure",
  4607. JSON.stringify(this.relevantAttachments)
  4608. );
  4609. // 费用明细付款
  4610. formData.append(
  4611. "tWarehousebillsfeesCr",
  4612. JSON.stringify(this.warehouseCrList)
  4613. );
  4614. // 收款
  4615. formData.append(
  4616. "tWarehousebillsfeesDr",
  4617. JSON.stringify(this.warehouseDrList)
  4618. );
  4619. formData.append("mblnoStatus", JSON.stringify(this.mblnoStatus));
  4620. formData.append("tCntr", JSON.stringify(this.CntrTable));
  4621. addWarehousebills(formData).then((response) => {
  4622. if (response.data == false) {
  4623. this.$confirm(response.msg, "提示", {
  4624. confirmButtonText: "确定",
  4625. cancelButtonText: "取消",
  4626. type: "warning",
  4627. })
  4628. .then(() => {
  4629. this.mblnoStatus = true;
  4630. this.saveForm();
  4631. })
  4632. .catch(() => {
  4633. this.$message({
  4634. type: "info",
  4635. message: "已取消",
  4636. });
  4637. });
  4638. } else {
  4639. if ((response.code = 200)) {
  4640. this.mblnoStatus = "";
  4641. this.form = response.data.warehouseBills;
  4642. this.$set(this.form, "fEta", Date.parse(this.form.fEta));
  4643. this.$set(this.form, "fBsdate", Date.parse(this.form.fBsdate));
  4644. this.$set(this.form, "fBstime", Date.parse(this.form.fBstime));
  4645. this.$set(this.form, "fFeetUnit", this.form.fFeetunit);
  4646. this.$set(
  4647. this.form,
  4648. "createTime",
  4649. Date.parse(this.form.createTime)
  4650. );
  4651. this.$set(
  4652. this.form,
  4653. "fChargedate",
  4654. Date.parse(this.form.fChargedate)
  4655. );
  4656. if (this.form.fTrademodeid) {
  4657. this.$set(
  4658. this.form,
  4659. "fTrademodeid",
  4660. this.form.fTrademodeid.toString()
  4661. );
  4662. }
  4663. if (this.form.fStltypeid || this.form.fStltypeid == 0) {
  4664. this.$set(
  4665. this.form,
  4666. "fStltypeid",
  4667. this.form.fStltypeid.toString()
  4668. );
  4669. }
  4670. this.detailList = response.data.warehousebillsitems;
  4671. this.msgSuccess("保存成功");
  4672. if (status == "goBack") {
  4673. this.cancel();
  4674. }
  4675. }
  4676. }
  4677. });
  4678. }
  4679. });
  4680. },
  4681. imporTable() {
  4682. this.$refs["importList"].validate((valid) => {
  4683. if (valid) {
  4684. if (!this.importList.fWarehouselocid) {
  4685. return this.$message.error("库区不能为空");
  4686. }
  4687. for (let item in this.detailList) {
  4688. if (
  4689. this.importList.fCntrno == this.detailList[item].fCntrno &&
  4690. this.importList.fCntrno
  4691. ) {
  4692. return this.$message.error("箱号不能重复");
  4693. }
  4694. }
  4695. this.detailList.push({
  4696. fBillstatus: 10,
  4697. fMblno: this.form.fMblno,
  4698. fQty: this.importList.fQty,
  4699. fNetweight: this.importList.fNetweight,
  4700. fGrossweight: this.importList.fGrossweight,
  4701. fBsdate: this.importList.fBsdate,
  4702. fGoodsid: this.importList.fGoodsid,
  4703. fBusinessType: this.importList.fBusinessType,
  4704. fMarks: this.importList.fMarks,
  4705. fWarehouselocid: this.importList.fWarehouselocid,
  4706. fWarehouseInformation: this.importList.fWarehouseInformation,
  4707. fCntrtype: this.importList.fCntrtype,
  4708. fCntqty: this.importList.fCntqty,
  4709. fPackagespecs: this.importList.fPackagespecs,
  4710. fTruckno: this.importList.fTruckno,
  4711. fDriverName: this.importList.fDriverName,
  4712. fDriverTel: this.importList.fDriverTel,
  4713. fDriverIdCar: this.importList.fDriverIdCar,
  4714. fSerialNumber: this.importList.fSerialNumber,
  4715. fCntrno: this.importList.fCntrno,
  4716. fGoodsval: this.importList.fGoodsval,
  4717. fLntype: this.importList.fLntype,
  4718. fForkliftman: this.importList.fForkliftman,
  4719. fStevedore: this.importList.fStevedore,
  4720. fLocalcntrno: this.importList.fLocalcntrno,
  4721. fSealno: this.importList.fSealno,
  4722. fFleet: this.importList.fFleet,
  4723. remark: this.importList.remark,
  4724. });
  4725. if (this.detailList[0].fGoodsid) {
  4726. for (let item in this.goodsOptions) {
  4727. if (this.goodsOptions[item].fId == this.detailList[0].fGoodsid) {
  4728. this.form.fProductName = this.goodsOptions[item].fName;
  4729. }
  4730. }
  4731. }
  4732. this.weightList = false;
  4733. }
  4734. });
  4735. },
  4736. fiximporTable() {
  4737. this.$refs["importList"].validate((valid) => {
  4738. if (valid) {
  4739. for (let item in this.detailList) {
  4740. if (
  4741. this.importList.fCntrno == this.detailList[item].fCntrno &&
  4742. this.importList.fCntrno &&
  4743. item != this.fixdetaiNum
  4744. ) {
  4745. return this.$message.error("箱号不能重复");
  4746. }
  4747. }
  4748. this.$set(this.detailList, this.fixdetaiNum, this.importList);
  4749. this.weightList = false;
  4750. }
  4751. });
  4752. },
  4753. // 库存明细多选
  4754. Selectinventory(selection) {
  4755. this.Printinglist = selection;
  4756. //允许确认入库list
  4757. this.dataListSelection = [];
  4758. if (this.stockoi == "0") {
  4759. this.dataListSelection = selection.filter((e) => e.fBillstatus == 30);
  4760. } else {
  4761. this.dataListSelection = selection;
  4762. }
  4763. //允许撤销入库list
  4764. this.dataWithdrawList = [];
  4765. this.dataWithdrawList = selection.filter((e) => e.fBillstatus == 40);
  4766. },
  4767. // 合计
  4768. getSummaries(param) {
  4769. const { columns, data } = param;
  4770. const sums = [];
  4771. var values = [];
  4772. columns.forEach((column, index) => {
  4773. if (index === 0) {
  4774. sums[index] = "";
  4775. return;
  4776. }
  4777. if (column.property === "fGrossweight") {
  4778. values = data.map((item) => Number(item["fGrossweight"]));
  4779. }
  4780. if (column.property === "fNetweight") {
  4781. values = data.map((item) => Number(item["fNetweight"]));
  4782. }
  4783. if (column.property === "fQty") {
  4784. values = data.map((item) => Number(item["fQty"]));
  4785. }
  4786. if (column.property === "fCntqty") {
  4787. values = data.map((item) => Number(item["fCntqty"]));
  4788. }
  4789. if (
  4790. column.property === "fGrossweight" ||
  4791. column.property === "fNetweight" ||
  4792. column.property === "fQty" ||
  4793. column.property === "fCntqty"
  4794. ) {
  4795. sums[index] = values.reduce((prev, curr) => {
  4796. const value = Number(curr);
  4797. if (!isNaN(value)) {
  4798. if (column.property === "fGrossweight") {
  4799. this.fGrossweight = prev + curr;
  4800. }
  4801. if (column.property === "fNetweight") {
  4802. this.fNetweight = prev + curr;
  4803. }
  4804. if (column.property === "fQty") {
  4805. this.fQty = prev + curr;
  4806. this.sumMum = prev + curr;
  4807. }
  4808. if (column.property === "fCntqty") {
  4809. this.fCntqty = prev + curr;
  4810. }
  4811. return prev + curr;
  4812. } else {
  4813. return prev;
  4814. }
  4815. }, 0);
  4816. sums[index] = sums[index].toFixed(2);
  4817. }
  4818. });
  4819. this.sums = sums;
  4820. return sums;
  4821. },
  4822. // 付款合计
  4823. warehouseDrSummaries(param) {
  4824. const { columns, data } = param;
  4825. const sums = [];
  4826. columns.forEach((column, index) => {
  4827. if (index === 0) {
  4828. sums[index] = "合计";
  4829. return;
  4830. }
  4831. const values = data.map((item) => Number(item[column.property]));
  4832. if (
  4833. column.property === "fUnitprice" ||
  4834. column.property === "fAmount" ||
  4835. column.property === "fQty" ||
  4836. column.property === "fQty"
  4837. ) {
  4838. sums[index] = values.reduce((prev, curr) => {
  4839. const value = Number(curr);
  4840. if (!isNaN(value)) {
  4841. return prev + curr;
  4842. } else {
  4843. return prev;
  4844. }
  4845. }, 0);
  4846. sums[index] = sums[index].toFixed(2);
  4847. }
  4848. });
  4849. return sums;
  4850. },
  4851. playcomputer() {
  4852. let Num1 = Number(this.form.fPlannetweight) / Number(this.form.fPlanqty);
  4853. let Num2 =
  4854. Number(this.form.fPlangrossweight) / Number(this.form.fPlanqty);
  4855. this.importList.fNetweight = Number(
  4856. (this.importList.fQty * Num1).toFixed(2)
  4857. );
  4858. this.importList.fGrossweight = Number(
  4859. (this.importList.fQty * Num2).toFixed(2)
  4860. );
  4861. },
  4862. imporComputer() {
  4863. this.playcomputer();
  4864. },
  4865. // 库存总账多选框
  4866. whgenlegSelectionChange(selection) {
  4867. this.dialogWhgenlegList = selection;
  4868. },
  4869. handleSelect(key) {
  4870. if (!this.form.fCorpid) {
  4871. this.$message({
  4872. message: "请维护客户",
  4873. type: "warning",
  4874. });
  4875. } else if (this.form.fProductName == undefined) {
  4876. this.$message({
  4877. message: "请维护入库明细品名",
  4878. type: "warning",
  4879. });
  4880. } else {
  4881. this.dialogWhgenlegList = [];
  4882. this.whgenlegTotal = 0;
  4883. this.warehousingagreements = true;
  4884. this.getWhgenlegList(key);
  4885. }
  4886. },
  4887. // 查询作业费信息
  4888. getWhgenlegList(key) {
  4889. let data = {};
  4890. if (key == 2) {
  4891. this.key_id = key;
  4892. this.Navigation = true;
  4893. data = {
  4894. pageNum: 1,
  4895. pageSize: 10,
  4896. fTaskType: key,
  4897. fLabour: this.form.fLabour,
  4898. };
  4899. } else if (key == 1) {
  4900. this.key_id = key;
  4901. this.Navigation = true;
  4902. data = {
  4903. pageNum: 1,
  4904. pageSize: 10,
  4905. fTaskType: key,
  4906. fFleet: this.form.fFleet,
  4907. };
  4908. } else {
  4909. this.Navigation = false;
  4910. this.key_id = key;
  4911. data = {
  4912. pageNum: 1,
  4913. pageSize: 10,
  4914. fCorpid: this.form.fCorpid,
  4915. };
  4916. }
  4917. operationAgreement(data).then((response) => {
  4918. response.rows.map((e) => {
  4919. if (e.fFeeUnitid) {
  4920. e.fFeeUnitid = e.fFeeUnitid.toString();
  4921. }
  4922. });
  4923. this.tasklegList = response.rows;
  4924. this.whgenlegTotal = response.total;
  4925. });
  4926. },
  4927. // 入库明细新增list
  4928. addRelevant(status) {
  4929. this.$refs["form"].validate((valid) => {
  4930. if (valid) {
  4931. this.title = "新增";
  4932. this.reset();
  4933. this.fixdetaiNum = null;
  4934. if (
  4935. !this.form.fPlannetweight ||
  4936. !this.form.fPlangrossweight ||
  4937. !this.form.fPlanqty
  4938. ) {
  4939. return this.$message({
  4940. message: "请维护计划净重(kg),计划毛重(kg),计划件数",
  4941. type: "warning",
  4942. });
  4943. }
  4944. this.importList.fQty = Number(
  4945. (this.form.fPlanqty - this.sumMum).toFixed(2)
  4946. );
  4947. if (this.importList.fQty < 0) {
  4948. this.importList.fQty = 0;
  4949. }
  4950. if (this.form.fTruckno) {
  4951. this.importList.fTruckno = this.form.fTruckno;
  4952. }
  4953. if (this.form.fDriverTel) {
  4954. this.importList.fDriverTel = this.form.fDriverTel;
  4955. }
  4956. if (this.form.fDriverName) {
  4957. this.importList.fDriverName = this.form.fDriverName;
  4958. }
  4959. if (this.form.fDriverIdCar) {
  4960. this.importList.fDriverIdCar = this.form.fDriverIdCar;
  4961. }
  4962. this.allfPlanqty = this.importList.fQty;
  4963. this.importList.fBsdate = this.form.fBsdate;
  4964. this.importList.fGoodsid = this.form.fGoodsid;
  4965. this.goodsOptions.map((e) => {
  4966. if (this.importList.fGoodsid == e.fId) {
  4967. if (e.ifCntrno == "1") {
  4968. this.ifCntrnoStatus = 1;
  4969. } else {
  4970. this.ifCntrnoStatus = null;
  4971. }
  4972. }
  4973. });
  4974. this.playcomputer();
  4975. treeselect(this.form.fWarehouseid).then((response) => {
  4976. this.fWarehouseidOptions = response.data;
  4977. });
  4978. if (status == "copy") {
  4979. this.importList.fBsdate = Date.parse(this.Printinglist[0].fBsdate);
  4980. if (!this.importList.fBsdate) {
  4981. this.importList.fBsdate = this.Printinglist[0].fBsdate;
  4982. }
  4983. this.importList.fGoodsid = this.Printinglist[0].fGoodsid;
  4984. this.importList.fBusinessType = this.Printinglist[0].fBusinessType.toString();
  4985. this.importList.fMarks = this.Printinglist[0].fMarks;
  4986. this.importList.fWarehouselocid = this.Printinglist[0].fWarehouselocid;
  4987. this.importList.fWarehouseInformation = this.Printinglist[0].fWarehouseInformation;
  4988. this.importList.fPackagespecs = this.Printinglist[0].fPackagespecs;
  4989. this.importList.fCntrtype = Number(this.Printinglist[0].fCntrtype);
  4990. this.importList.fCntqty = this.Printinglist[0].fCntqty;
  4991. this.importList.fTruckno = this.Printinglist[0].fTruckno;
  4992. this.importList.fDriverName = this.Printinglist[0].fDriverName;
  4993. this.importList.fDriverTel = this.Printinglist[0].fDriverTel;
  4994. this.importList.fDriverIdCar = this.Printinglist[0].fDriverIdCar;
  4995. this.importList.fSerialNumber = this.Printinglist[0].fSerialNumber;
  4996. this.importList.fGoodsval = this.Printinglist[0].fGoodsval;
  4997. this.importList.remark = this.Printinglist[0].remark;
  4998. this.importList.fQty = this.Printinglist[0].fQty;
  4999. this.importList.fGrossweight = this.Printinglist[0].fGrossweight;
  5000. this.importList.fNetweight = this.Printinglist[0].fNetweight;
  5001. }
  5002. console.log(this.importList);
  5003. this.weightList = true;
  5004. }
  5005. });
  5006. },
  5007. printZyd() {
  5008. if (this.Printinglist.length > 0) {
  5009. for (let item in this.Printinglist) {
  5010. if (!this.Printinglist[item].fId) {
  5011. return this.$message.error("请先保存!");
  5012. }
  5013. if (
  5014. this.Printinglist[item].fTruckno !== this.Printinglist[0].fTruckno
  5015. ) {
  5016. return this.$message.error("请选择车相同车号");
  5017. }
  5018. }
  5019. this.print_zyd = true;
  5020. this.warehouseOptions.map((e) => {
  5021. if (e.fId == this.form.fWarehouseid) {
  5022. this.stockaddr = e.fAddr;
  5023. }
  5024. });
  5025. this.fDriverTel = this.Printinglist[0].fDriverTel;
  5026. } else {
  5027. this.$message.error("请选择需要打印的明细!");
  5028. }
  5029. },
  5030. handleCommand(command) {
  5031. if (this.Printinglist.length > 0) {
  5032. this.$refs["form"].validate((valid) => {
  5033. if (valid) {
  5034. for (let corp in this.fMblnoOptions) {
  5035. if (this.form.fCorpid === this.fMblnoOptions[corp].fId) {
  5036. this.$set(
  5037. this.form,
  5038. "fCorpidName",
  5039. this.fMblnoOptions[corp].fName
  5040. );
  5041. }
  5042. }
  5043. this.warehouseOptions.map((e) => {
  5044. if (e.fId == this.form.fWarehouseid) {
  5045. this.stockName = e.fName;
  5046. this.stockaddr = e.fAddr;
  5047. }
  5048. });
  5049. this.fDriverTel = this.Printinglist[0].fDriverTel;
  5050. this.fBsdate = this.Printinglist[0].fBsdate;
  5051. this.fTruckno = this.Printinglist[0].fTruckno;
  5052. this.allfCntqty = 0;
  5053. this.allfGrossweight = 0;
  5054. this.allfPlanqty = 0;
  5055. this.allfNetweight = 0;
  5056. this.allfQty = 0;
  5057. this.Printinglist.map((e) => {
  5058. if (e.fCntqty) {
  5059. this.allfCntqty += e.fCntqty;
  5060. }
  5061. if (e.fGrossweight) {
  5062. this.allfGrossweight += e.fGrossweight;
  5063. }
  5064. if (e.fPlanqty) {
  5065. this.allfPlanqty += e.fPlanqty;
  5066. }
  5067. if (e.fNetweight) {
  5068. this.allfNetweight += e.fNetweight;
  5069. }
  5070. if (e.fQty) {
  5071. this.allfQty += e.fQty;
  5072. }
  5073. });
  5074. if (command == "a") {
  5075. this.print_shd = true;
  5076. } else if (command == "b") {
  5077. this.print_rkd = true;
  5078. } else if (command == "c") {
  5079. this.print_lhd = true;
  5080. } else if (command == "d") {
  5081. this.print_hwqr = true;
  5082. } else if (command == "e") {
  5083. this.print_lwqr = true;
  5084. } else if (command == "f") {
  5085. this.print_dpxx = true;
  5086. } else if (command == "g") {
  5087. this.print_bzrkd = true;
  5088. } else if (command == "h") {
  5089. this.print_dk = true;
  5090. }
  5091. }
  5092. });
  5093. } else {
  5094. this.$message.error("请选择需要打印的明细!");
  5095. }
  5096. },
  5097. //计算仓储费日期变更
  5098. changeDate() {
  5099. this.$set(this.form, "fChargedate", this.form.fBsdate);
  5100. },
  5101. addRow() {
  5102. var obj = {};
  5103. this.CntrTable.push(obj);
  5104. },
  5105. fixRow(row, index) {
  5106. this.title = "修改";
  5107. this.reset();
  5108. this.fixdetaiNum = null;
  5109. this.fixdetaiNum = index;
  5110. treeselect(this.form.fWarehouseid).then((response) => {
  5111. this.fWarehouseidOptions = response.data;
  5112. });
  5113. this.allfPlanqty += row.fQty;
  5114. row.fBsdate = new Date(row.fBsdate).getTime();
  5115. row.fBusinessType = row.fBusinessType.toString();
  5116. row.fCntrtype = Number(row.fCntrtype);
  5117. this.importList = JSON.parse(JSON.stringify(row));
  5118. this.weightList = true;
  5119. },
  5120. deleteRow(index, rows) {
  5121. rows.splice(index, 1);
  5122. },
  5123. wDeleteRow(index, rows) {
  5124. rows.splice(index, 1);
  5125. this.sumMum = 0;
  5126. this.detailList.map((e) => {
  5127. if (e.fQty) {
  5128. this.sumMum += e.fQty;
  5129. }
  5130. });
  5131. if (this.detailList.length == 0) {
  5132. this.form.fProductName = "";
  5133. this.form.fMarks = "";
  5134. this.form.fNetweight = 0;
  5135. this.form.fPlanvolumn = 0;
  5136. this.form.fGrossweight = 0;
  5137. }
  5138. },
  5139. // 新增附件上传
  5140. addRelevt() {
  5141. this.relevantAttachments.push({
  5142. fUrl: null,
  5143. fName: null,
  5144. createBy: this.form.createBy,
  5145. createTime: Date.parse(new Date()),
  5146. });
  5147. },
  5148. // 收款信息新行
  5149. addCollection() {
  5150. this.$refs["form"].validate((valid) => {
  5151. if (valid) {
  5152. if (this.form.fBusinessType == null) {
  5153. this.$message.error("请维护作业类型");
  5154. return false;
  5155. } else {
  5156. this.warehouseDrList.push({
  5157. fCorpid: null,
  5158. fFeeid: null,
  5159. fFeeUnitid: "",
  5160. fQty: null,
  5161. fUnitprice: null,
  5162. fAmount: null,
  5163. fCurrency: "RMB",
  5164. fExrate: "1",
  5165. fTaxrate: this.fTaxrate,
  5166. fCxrate: null,
  5167. fRate: null,
  5168. remarks: null,
  5169. fMblno: this.form.fMblno,
  5170. fProductName: this.form.fProductName,
  5171. fMarks: this.form.fMarks,
  5172. fBusinessType: this.form.fBusinessType,
  5173. fSrcTypeId: 0,
  5174. });
  5175. this.fWbuOptions = [];
  5176. let queryParams = { pageNum: 1, fDc: "D" };
  5177. listFees(queryParams).then((response) => {
  5178. this.fDNameOptions = response.rows;
  5179. });
  5180. }
  5181. }
  5182. });
  5183. },
  5184. //付款信息新行
  5185. addpayment() {
  5186. this.$refs["form"].validate((valid) => {
  5187. if (valid) {
  5188. if (this.form.fBusinessType == null) {
  5189. return this.$message.error("请维护作业类型");
  5190. } else {
  5191. this.warehouseCrList.push({
  5192. fCorpid: null,
  5193. fFeeid: null,
  5194. fFeeUnitid: "",
  5195. fQty: null,
  5196. fUnitprice: null,
  5197. fAmount: null,
  5198. fCurrency: "RMB",
  5199. fExrate: "1",
  5200. fTaxrate: this.fTaxrate,
  5201. fCxrate: null,
  5202. fRate: null,
  5203. remarks: null,
  5204. fMblno: this.form.fMblno,
  5205. fProductName: this.form.fProductName,
  5206. fMarks: this.form.fMarks,
  5207. fBusinessType: this.form.fBusinessType,
  5208. fSrcTypeId: 0,
  5209. });
  5210. this.fWbuOptions = [];
  5211. let queryParams = { pageNum: 1, fDc: "C" };
  5212. listFees(queryParams).then((response) => {
  5213. this.fCNameOptions = response.rows;
  5214. });
  5215. }
  5216. }
  5217. });
  5218. },
  5219. //导入收付款信息明细
  5220. zhgenlegData() {
  5221. if (this.dialogWhgenlegList.length === 0) {
  5222. this.$message({
  5223. message: "请选择需要导入的数据",
  5224. type: "warning",
  5225. });
  5226. } else {
  5227. this.dialogWhgenlegList.map((e) => {
  5228. let qty = 1;
  5229. if (e.fFeeUnitid == 1) {
  5230. qty = this.fQty;
  5231. } else if (e.fFeeUnitid == 2) {
  5232. qty = (this.fGrossweight / 1000).toFixed(2);
  5233. } else if (e.fFeeUnitid == 3) {
  5234. qty = (this.fNetweight / 1000).toFixed(2);
  5235. } else if (e.fFeeUnitid == 7) {
  5236. qty = this.fCntqty;
  5237. }
  5238. let fAmount = 0;
  5239. fAmount = e.fPrice * qty;
  5240. console.log(this.key_id);
  5241. if (this.key_id == 3) {
  5242. this.warehouseDrList.push({
  5243. fQty: qty,
  5244. fCorpid: e.fCorpid,
  5245. fFeeid: e.feeFId,
  5246. fFeeUnitid: e.fFeeUnitid,
  5247. fUnitprice: e.fPrice,
  5248. fCurrency: "RMB",
  5249. fExrate: 1,
  5250. fAmount: fAmount,
  5251. fTaxrate: this.fTaxrate,
  5252. fMblno: this.form.fMblno,
  5253. fProductName: this.form.fProductName,
  5254. fMarks: this.form.fMarks,
  5255. fBusinessType: this.form.fBusinessType,
  5256. fSrcTypeId: e.fId,
  5257. });
  5258. } else {
  5259. this.warehouseCrList.push({
  5260. fQty: qty,
  5261. fCorpid: e.fCorpid,
  5262. fFeeid: e.feeId,
  5263. fFeeUnitid: e.fFeeUnitid,
  5264. fUnitprice: e.fPrice,
  5265. fCurrency: "RMB",
  5266. fExrate: 1,
  5267. fAmount: fAmount,
  5268. fTaxrate: this.fTaxrate,
  5269. fMblno: this.form.fMblno,
  5270. fProductName: this.form.fProductName,
  5271. fMarks: this.form.fMarks,
  5272. fBusinessType: this.form.fBusinessType,
  5273. fSrcTypeId: e.fId,
  5274. });
  5275. }
  5276. });
  5277. this.warehousingagreements = false;
  5278. }
  5279. },
  5280. // 收款选
  5281. Collectionoptions(selection) {
  5282. this.Collectionoptionss = selection;
  5283. for (let item in this.fWbuOptions) {
  5284. for (let li in this.Collectionoptionss) {
  5285. if (
  5286. this.fWbuOptions[item].fId === this.Collectionoptionss[li].fFeeid
  5287. ) {
  5288. this.$set(
  5289. this.Collectionoptionss[li],
  5290. "fFeeids",
  5291. this.fWbuOptions[item].fName
  5292. );
  5293. }
  5294. }
  5295. }
  5296. },
  5297. //附件上传
  5298. handleSucces(scope, res, file) {
  5299. this.relevantAttachments[scope.$index].fName = res.fileName;
  5300. this.relevantAttachments[scope.$index].fUrl = res.url;
  5301. if (this.relevantAttachments[scope.$index].fUrl === "") {
  5302. this.$message.error("上传失败");
  5303. } else {
  5304. this.$message.success("上传成功");
  5305. }
  5306. },
  5307. //获取登陆人
  5308. queryUser() {
  5309. queryUserVal().then((response) => {
  5310. if (response.user !== null) {
  5311. this.userVal = response.user;
  5312. this.$set(this.form, "fDeptid", this.userVal.deptId);
  5313. this.$set(this.form, "createBy", this.userVal.userName);
  5314. this.$set(this.form, "fStorekeeper", this.userVal.nickName);
  5315. this.$set(this.form, "fIfdamage", "1");
  5316. this.$set(this.form, "fIfweigh", "1");
  5317. this.$set(this.form, "fTrademodeid", "1");
  5318. this.$set(this.form, "createTime", Date.parse(new Date()));
  5319. this.$set(this.form, "fBstime", Date.parse(new Date()));
  5320. }
  5321. if (response.dept !== null) {
  5322. this.deptOptions = [];
  5323. this.deptOptions.push(response.dept);
  5324. }
  5325. });
  5326. },
  5327. //作业类型校验
  5328. educationChange() {
  5329. if (this.form.fBusinessType === "1" || this.form.fBusinessType === "2") {
  5330. this.isrequired = 1;
  5331. this.isrequired2 = 2;
  5332. } else if (
  5333. this.form.fBusinessType === "3" ||
  5334. this.form.fBusinessType === "4"
  5335. ) {
  5336. this.isrequired2 = 1;
  5337. this.isrequired = 2;
  5338. } else {
  5339. this.isrequired = 2;
  5340. this.isrequired2 = 2;
  5341. }
  5342. },
  5343. // 数量计算
  5344. changeContractAmt(row) {
  5345. let fQty = 0;
  5346. let fUnitprice = 0;
  5347. if (row.fUnitprice) {
  5348. fUnitprice = row.fUnitprice;
  5349. }
  5350. if (row.fQty) {
  5351. fQty = row.fQty;
  5352. }
  5353. this.$set(row, "fAmount", Number(fUnitprice) * Number(fQty)).toFixed(2);
  5354. },
  5355. // 变更计价单位
  5356. changeFeeUnit(row) {
  5357. if (!row.fFeeUnitid) {
  5358. return false;
  5359. }
  5360. if (row.fFeeUnitid === "2") {
  5361. this.$set(row, "fQty", (this.fGrossweight / 1000).toFixed(2));
  5362. } else if (row.fFeeUnitid === "1") {
  5363. this.$set(row, "fQty", this.fQty.toFixed(2));
  5364. } else if (row.fFeeUnitid === "3") {
  5365. this.$set(row, "fQty", (this.fNetweight / 1000).toFixed(2));
  5366. } else if (row.fFeeUnitid === "7") {
  5367. this.$set(row, "fQty", this.fCntqty);
  5368. } else {
  5369. this.$set(row, "fQty", 0);
  5370. }
  5371. if (row.fUnitprice) {
  5372. this.$set(
  5373. row,
  5374. "fAmount",
  5375. parseFloat(Number(row.fUnitprice) * Number(row.fQty)).toFixed(2)
  5376. );
  5377. }
  5378. },
  5379. //打印
  5380. addprint(status) {
  5381. if (status == "zyd") {
  5382. if (this.CntrTable.length > 0) {
  5383. let arr = [];
  5384. this.CntrTable.map((e) => {
  5385. this.cntrList.map((item) => {
  5386. if (item.fId == e.fCntrid) {
  5387. arr.push(item.fName + "X" + e.fCntrcount);
  5388. }
  5389. });
  5390. });
  5391. arr = [...new Set(arr)];
  5392. this.form.fCntval = arr.join(",");
  5393. } else {
  5394. this.form.fCntval = null;
  5395. }
  5396. if (this.detailList.length > 0) {
  5397. let arr = [];
  5398. this.detailList.map((e) => {
  5399. this.goodsOptions.map((item) => {
  5400. if (e.fGoodsid == item.fId) {
  5401. arr.push(item.fName);
  5402. }
  5403. });
  5404. });
  5405. arr = [...new Set(arr)];
  5406. this.form.fProductName = arr.join(",");
  5407. } else {
  5408. this.form.fProductName = "";
  5409. }
  5410. if (this.detailList.length > 0) {
  5411. let arr = [];
  5412. this.detailList.map((e) => {
  5413. arr.push(e.fMarks);
  5414. });
  5415. arr = [...new Set(arr)];
  5416. this.form.fMarks = arr.join(",");
  5417. } else {
  5418. this.form.fMarks = "";
  5419. }
  5420. this.form.fBillingway = this.form.fFeetUnit;
  5421. if (this.detailList.length == 0) {
  5422. this.form.fNetweight = 0;
  5423. this.form.fPlanvolumn = 0;
  5424. this.form.fGrossweight = 0;
  5425. } else {
  5426. this.form.fNetweight = this.fNetweight;
  5427. this.form.fPlanvolumn = this.fPlanvolumn;
  5428. this.form.fGrossweight = this.fGrossweight;
  5429. }
  5430. let formData = new window.FormData();
  5431. formData.append("warehouseBills", JSON.stringify(this.form));
  5432. formData.append(
  5433. "warehousebillsitems",
  5434. JSON.stringify(this.Printinglist)
  5435. );
  5436. formData.append(
  5437. "warehousebillsfeesDr",
  5438. JSON.stringify(this.warehouseDrList)
  5439. );
  5440. formData.append(
  5441. "warehousebillsfeesCr",
  5442. JSON.stringify(this.warehouseCrList)
  5443. );
  5444. formData.append("tEnclosure", JSON.stringify(this.relevantAttachments));
  5445. formData.append("tCntr", JSON.stringify(this.CntrTable));
  5446. addJoblist(formData).then((response) => {
  5447. if (response.code == 200) {
  5448. this.detailList.map((e, index) => {
  5449. response.data.warehousebillsitems.map((item) => {
  5450. if (e.fId == item.fId) {
  5451. e = item;
  5452. this.$set(this.detailList, index, e);
  5453. }
  5454. });
  5455. });
  5456. this.$set(this.form, "fItemsStatus", 2);
  5457. }
  5458. });
  5459. }
  5460. const style =
  5461. "@page { } " +
  5462. "@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;}";
  5463. print({
  5464. printable: "print_area1",
  5465. type: "html",
  5466. style: style, // 亦可使用引入的外部css;
  5467. scanStyles: false,
  5468. });
  5469. },
  5470. cancel() {
  5471. this.resetForm("form");
  5472. this.resetForm("importList");
  5473. this.detailList = [];
  5474. this.relevantAttachments = [];
  5475. this.warehouseCrList = [];
  5476. this.warehouseDrList = [];
  5477. this.CntrTable = [];
  5478. this.$emit("changeShow", "true");
  5479. },
  5480. goBack() {
  5481. this.$confirm("是否确定返回列表?", "提示", {
  5482. confirmButtonText: "保存",
  5483. cancelButtonText: "取消",
  5484. type: "warning",
  5485. })
  5486. .then(() => {
  5487. this.saveForm("goBack");
  5488. })
  5489. .catch(() => {
  5490. this.cancel();
  5491. });
  5492. },
  5493. },
  5494. watch: {
  5495. // 监听 addOrUpdateVisible 改变
  5496. addOrUpdateVisible(oldVal, newVal) {
  5497. this.showDialog = this.addOrUpdateVisible;
  5498. },
  5499. },
  5500. };
  5501. </script>
  5502. <style lang="scss" scoped>
  5503. .tag-hover:hover {
  5504. background-color: #d9ebfb;
  5505. }
  5506. .tag-hover {
  5507. border-top-left-radius: 0;
  5508. border-bottom-left-radius: 0;
  5509. height: 15px;
  5510. padding: 0px 1px;
  5511. line-height: 12px;
  5512. }
  5513. .print-div {
  5514. color: #000;
  5515. }
  5516. .print_table {
  5517. table {
  5518. border-right: 1px solid #000;
  5519. border-bottom: 1px solid #000;
  5520. font-size: 12px;
  5521. margin-bottom: 5px;
  5522. }
  5523. table td {
  5524. border-left: 1px solid #000;
  5525. border-top: 1px solid #000;
  5526. vertical-align: middle;
  5527. padding: 2px;
  5528. text-align: center;
  5529. }
  5530. }
  5531. .print_form {
  5532. font-size: 12px;
  5533. }
  5534. </style>