AddOrUpdate.vue 155 KB

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