AddOrUpdate.vue 160 KB

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