AddOrUpdate.vue 249 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545554655475548554955505551555255535554555555565557555855595560556155625563556455655566556755685569557055715572557355745575557655775578557955805581558255835584558555865587558855895590559155925593559455955596559755985599560056015602560356045605560656075608560956105611561256135614561556165617561856195620562156225623562456255626562756285629563056315632563356345635563656375638563956405641564256435644564556465647564856495650565156525653565456555656565756585659566056615662566356645665566656675668566956705671567256735674567556765677567856795680568156825683568456855686568756885689569056915692569356945695569656975698569957005701570257035704570557065707570857095710571157125713571457155716571757185719572057215722572357245725572657275728572957305731573257335734573557365737573857395740574157425743574457455746574757485749575057515752575357545755575657575758575957605761576257635764576557665767576857695770577157725773577457755776577757785779578057815782578357845785578657875788578957905791579257935794579557965797579857995800580158025803580458055806580758085809581058115812581358145815581658175818581958205821582258235824582558265827582858295830583158325833583458355836583758385839584058415842584358445845584658475848584958505851585258535854585558565857585858595860586158625863586458655866586758685869587058715872587358745875587658775878587958805881588258835884588558865887588858895890589158925893589458955896589758985899590059015902590359045905590659075908590959105911591259135914591559165917591859195920592159225923592459255926592759285929593059315932593359345935593659375938593959405941594259435944594559465947594859495950595159525953595459555956595759585959596059615962596359645965596659675968596959705971597259735974597559765977597859795980598159825983598459855986598759885989599059915992599359945995599659975998599960006001600260036004600560066007600860096010601160126013601460156016601760186019602060216022602360246025602660276028602960306031603260336034603560366037603860396040604160426043604460456046604760486049605060516052605360546055605660576058605960606061606260636064606560666067606860696070607160726073607460756076607760786079608060816082608360846085608660876088608960906091609260936094609560966097609860996100610161026103610461056106610761086109611061116112611361146115611661176118611961206121612261236124612561266127612861296130613161326133613461356136613761386139614061416142614361446145614661476148614961506151615261536154615561566157615861596160616161626163616461656166616761686169617061716172617361746175617661776178617961806181618261836184618561866187618861896190619161926193619461956196619761986199620062016202620362046205620662076208620962106211621262136214621562166217621862196220622162226223622462256226622762286229623062316232623362346235623662376238623962406241624262436244624562466247624862496250625162526253625462556256625762586259626062616262626362646265626662676268626962706271627262736274627562766277627862796280628162826283628462856286628762886289629062916292629362946295629662976298629963006301630263036304630563066307630863096310631163126313631463156316631763186319632063216322632363246325632663276328632963306331633263336334633563366337633863396340634163426343634463456346634763486349635063516352635363546355635663576358635963606361636263636364636563666367636863696370637163726373637463756376637763786379638063816382638363846385638663876388638963906391639263936394639563966397639863996400640164026403640464056406640764086409641064116412641364146415641664176418641964206421642264236424642564266427642864296430643164326433643464356436643764386439644064416442644364446445644664476448644964506451645264536454645564566457645864596460646164626463646464656466646764686469647064716472647364746475647664776478647964806481648264836484648564866487648864896490649164926493649464956496649764986499650065016502650365046505650665076508650965106511651265136514651565166517651865196520652165226523652465256526652765286529653065316532653365346535653665376538653965406541654265436544654565466547654865496550655165526553655465556556655765586559656065616562656365646565656665676568656965706571657265736574657565766577657865796580658165826583658465856586658765886589659065916592659365946595659665976598659966006601660266036604660566066607660866096610661166126613661466156616661766186619662066216622662366246625662666276628662966306631663266336634663566366637663866396640664166426643664466456646664766486649665066516652665366546655665666576658665966606661666266636664666566666667666866696670667166726673667466756676667766786679668066816682668366846685668666876688668966906691669266936694669566966697669866996700670167026703670467056706670767086709671067116712671367146715671667176718671967206721672267236724672567266727672867296730673167326733673467356736673767386739674067416742674367446745674667476748674967506751675267536754675567566757675867596760676167626763676467656766676767686769677067716772677367746775677667776778677967806781678267836784678567866787678867896790679167926793679467956796679767986799680068016802680368046805680668076808680968106811681268136814681568166817681868196820682168226823682468256826682768286829683068316832683368346835683668376838683968406841684268436844684568466847684868496850685168526853685468556856685768586859686068616862686368646865686668676868686968706871687268736874687568766877687868796880688168826883688468856886688768886889689068916892689368946895689668976898689969006901690269036904690569066907690869096910691169126913691469156916691769186919692069216922692369246925692669276928692969306931693269336934693569366937693869396940694169426943694469456946694769486949695069516952695369546955695669576958695969606961696269636964696569666967696869696970697169726973697469756976697769786979698069816982698369846985698669876988698969906991699269936994699569966997699869997000700170027003700470057006700770087009701070117012701370147015701670177018701970207021702270237024702570267027702870297030703170327033703470357036703770387039704070417042704370447045704670477048704970507051705270537054705570567057705870597060706170627063706470657066706770687069707070717072707370747075707670777078707970807081708270837084708570867087708870897090709170927093709470957096709770987099710071017102710371047105710671077108710971107111711271137114711571167117711871197120712171227123712471257126712771287129713071317132713371347135713671377138713971407141714271437144714571467147714871497150715171527153715471557156715771587159716071617162716371647165716671677168716971707171717271737174717571767177717871797180718171827183718471857186718771887189719071917192719371947195719671977198719972007201720272037204720572067207720872097210721172127213721472157216721772187219722072217222722372247225722672277228722972307231723272337234723572367237723872397240724172427243724472457246724772487249725072517252725372547255725672577258725972607261726272637264726572667267726872697270727172727273727472757276727772787279728072817282728372847285728672877288728972907291729272937294729572967297729872997300730173027303730473057306730773087309731073117312731373147315731673177318731973207321732273237324732573267327732873297330733173327333733473357336733773387339734073417342734373447345734673477348734973507351735273537354735573567357735873597360736173627363736473657366736773687369737073717372737373747375737673777378737973807381738273837384738573867387738873897390739173927393739473957396739773987399740074017402740374047405740674077408740974107411741274137414741574167417741874197420742174227423742474257426742774287429743074317432743374347435743674377438743974407441744274437444744574467447744874497450745174527453745474557456745774587459746074617462
  1. <template>
  2. <div>
  3. <div style="display: flex; justify-content: space-between">
  4. <div style="display: flex; align-items: center">
  5. <el-breadcrumb separator="/">
  6. <el-breadcrumb-item
  7. ><span style="font-weight: 700">出库</span></el-breadcrumb-item
  8. >
  9. <el-breadcrumb-item
  10. ><span style="font-weight: 700"
  11. >出库详情页</span
  12. ></el-breadcrumb-item
  13. >
  14. </el-breadcrumb>
  15. <el-button
  16. style="margin-left: 10px"
  17. size="mini"
  18. icon="el-icon-arrow-left"
  19. @click="goBack"
  20. >返回列表
  21. </el-button
  22. >
  23. </div>
  24. <div v-if="showApproval == 0">
  25. <el-button
  26. type="info"
  27. size="small"
  28. @click="addOrUpdateHandle(form, 'warehouse_status')"
  29. v-if="form.warehouseStatus > 3"
  30. >查看接单审批
  31. </el-button>
  32. <el-button
  33. type="info"
  34. size="small"
  35. @click="addOrUpdateHand(form, 'warehouse_status')"
  36. v-if="form.warehouseStatus > 3 && approVal == true"
  37. >接单审批
  38. </el-button>
  39. <el-button
  40. type="info"
  41. :disabled="form.warehouseStatus >= 4"
  42. size="small"
  43. @click="verifyForm"
  44. v-if="form.fBillstatus"
  45. >接单请核
  46. </el-button>
  47. <el-button
  48. type="info"
  49. size="small"
  50. @click="ordersRevoke"
  51. v-if="form.warehouseStatus == 6"
  52. >撤销接单请核
  53. </el-button>
  54. <el-button
  55. type="info"
  56. size="small"
  57. @click="revokeTwo('warehouse_status')"
  58. v-if="form.warehouseStatus == 4"
  59. >撤销接单审批
  60. </el-button>
  61. </div>
  62. </div>
  63. <br/>
  64. <el-form ref="form" :model="form" :rules="rules" label-width="120px">
  65. <el-row>
  66. <el-col :span="8">
  67. <el-form-item label="客户" prop="fCorpid">
  68. <el-select
  69. v-model="form.fCorpid"
  70. clearable
  71. filterable
  72. placeholder="请输入关键词"
  73. style="width: 80%"
  74. @change="changefStltype"
  75. :disabled="detailList.length > 0 || form.warehouseStatus > 3"
  76. >
  77. <el-option
  78. v-for="(item, index) in fMblnoOptions"
  79. :key="index.fId"
  80. :label="item.fName"
  81. :value="item.fId"
  82. ></el-option>
  83. </el-select>
  84. </el-form-item>
  85. </el-col>
  86. <el-col :span="8">
  87. <el-form-item label="结算方式" prop="fStltypeid">
  88. <el-select
  89. v-model="form.fStltypeid"
  90. placeholder="请选择结算方式"
  91. clearable
  92. :disabled="browseStatus || form.warehouseStatus > 3"
  93. style="width: 80%"
  94. >
  95. <el-option
  96. v-for="(item, index) in fStltypeOptions"
  97. :key="index.dictValue"
  98. :label="item.dictLabel"
  99. :value="item.dictValue"
  100. />
  101. </el-select>
  102. </el-form-item>
  103. </el-col>
  104. <el-col :span="8">
  105. <el-form-item label="提单号" prop="fMblno">
  106. <el-input
  107. v-model="form.fMblno"
  108. style="width: 80%"
  109. placeholder="请输入提单号"
  110. @change="judgmentWarehouse"
  111. :disabled="detailList.length != 0"
  112. />
  113. </el-form-item>
  114. </el-col>
  115. </el-row>
  116. <el-row>
  117. <el-col :span="8">
  118. <el-form-item label="业务日期" prop="fBsdate">
  119. <el-date-picker
  120. v-model="form.fBsdate"
  121. style="width: 80%"
  122. type="date"
  123. :disabled="browseStatus || form.warehouseStatus > 3"
  124. value-format="timestamp"
  125. format="yyyy-MM-dd"
  126. placeholder="业务日期"
  127. @change="changeDate"
  128. >
  129. </el-date-picker>
  130. </el-form-item>
  131. </el-col>
  132. <el-col :span="8">
  133. <el-form-item label="业务时间" prop="fBstime">
  134. <el-time-picker
  135. style="width: 80%"
  136. :disabled="browseStatus || form.warehouseStatus > 3"
  137. v-model="form.fBstime"
  138. :picker-options="{
  139. selectableRange: '00:00:00 - 23:59:59',
  140. }"
  141. value-format="timestamp"
  142. placeholder="任意时间点"
  143. >
  144. </el-time-picker>
  145. </el-form-item>
  146. </el-col>
  147. <el-col :span="8">
  148. <el-form-item label="车辆类型" prop="fCartype">
  149. <el-select
  150. style="width: 80%"
  151. v-model="form.fCartype"
  152. :disabled="browseStatus || form.warehouseStatus > 3"
  153. >
  154. <el-option
  155. v-for="(dict, index) in fCartypeOptions"
  156. :key="index.dictValue"
  157. :label="dict.dictLabel"
  158. :value="dict.dictValue"
  159. ></el-option>
  160. </el-select>
  161. </el-form-item>
  162. </el-col>
  163. </el-row>
  164. <el-row>
  165. <el-col :span="8">
  166. <el-form-item label="仓管员" prop="fStorekeeper">
  167. <el-select
  168. v-model="form.fStorekeeper"
  169. filterable
  170. clearable
  171. :disabled="browseStatus || form.warehouseStatus > 3"
  172. style="width: 80%"
  173. placeholder="请输入模糊查找"
  174. >
  175. <el-option
  176. v-for="(item, index) in userOptions"
  177. :key="index.userName"
  178. :label="item.nickName"
  179. :value="item.userName"
  180. ></el-option>
  181. </el-select>
  182. </el-form-item>
  183. </el-col>
  184. <el-col :span="8">
  185. <el-form-item label="仓库" prop="fWarehouseid">
  186. <el-select
  187. v-model="form.fWarehouseid"
  188. filterable
  189. :disabled="
  190. browseStatus ||
  191. detailList.length > 0 ||
  192. form.warehouseStatus > 3
  193. "
  194. style="width: 80%"
  195. placeholder="请选择"
  196. @change="warehouseChange"
  197. >
  198. <el-option
  199. v-for="(item, index) in form.fMblno && form.fCorpid && !form.fId?warehouseSwitching:warehouseOptions"
  200. :key="index.fId"
  201. :label="item.fName"
  202. :value="item.fId"
  203. ></el-option>
  204. </el-select>
  205. </el-form-item>
  206. </el-col>
  207. <el-col :span="8">
  208. <el-form-item label="计费单位" prop="fFeetUnit">
  209. <el-select
  210. v-model="form.fFeetUnit"
  211. placeholder="请选择计费单位"
  212. clearable
  213. :disabled="browseStatus || form.warehouseStatus > 3"
  214. style="width: 80%"
  215. >
  216. <el-option
  217. v-for="(item, index) in fFeetUnitOptions"
  218. :key="index.dictValue"
  219. :label="item.dictLabel"
  220. :value="item.dictValue"
  221. />
  222. </el-select>
  223. </el-form-item>
  224. </el-col>
  225. </el-row>
  226. <el-row>
  227. <el-col :span="8">
  228. <el-form-item label="计划件数" prop="fPlanqty">
  229. <el-input
  230. v-model.number="form.fPlanqty"
  231. style="width: 80%"
  232. maxlength="9"
  233. laceholder="计划件数"
  234. :disabled="
  235. browseStatus || current !== before || form.warehouseStatus > 3
  236. "
  237. />
  238. </el-form-item>
  239. </el-col>
  240. <el-col :span="8">
  241. <el-form-item label="计划净重(kg)" prop="fPlannetweight">
  242. <el-input
  243. v-model="form.fPlannetweight"
  244. style="width: 80%"
  245. maxlength="16"
  246. v-input-limit="2"
  247. laceholder="计划净重"
  248. :disabled="
  249. browseStatus || current !== before || form.warehouseStatus > 3
  250. "
  251. @change="tfNetweight"
  252. >
  253. <template slot="append">{{ tfNetweightnum }}吨</template>
  254. </el-input>
  255. </el-form-item>
  256. </el-col>
  257. <el-col :span="8">
  258. <el-form-item label="计划毛重(kg)" prop="fPlangrossweight">
  259. <el-input
  260. v-model="form.fPlangrossweight"
  261. v-input-limit="2"
  262. style="width: 80%"
  263. laceholder="计划毛重"
  264. maxlength="16"
  265. :disabled="
  266. browseStatus || current !== before || form.warehouseStatus > 3
  267. "
  268. @change="tfGrossweight"
  269. >
  270. <template slot="append">{{ tfGrossweightnum }}吨</template>
  271. </el-input>
  272. </el-form-item>
  273. </el-col>
  274. </el-row>
  275. <div v-if="detailsHidden2">
  276. <el-row>
  277. <el-col :span="8">
  278. <el-form-item label="作业类型" prop="fBusinessType">
  279. <el-select
  280. style="width: 80%"
  281. v-model="form.fBusinessType"
  282. filterable
  283. @change="educationChange"
  284. :disabled="
  285. browseStatus ||
  286. warehouseDrList.length > 0 ||
  287. warehouseCrList.length > 0 ||
  288. form.warehouseStatus > 3
  289. "
  290. >
  291. <el-option
  292. v-for="(item, index) in businessTypeOption"
  293. :key="index.dictValue"
  294. :label="item.dictLabel"
  295. :value="item.dictValue"
  296. ></el-option>
  297. </el-select>
  298. </el-form-item>
  299. </el-col>
  300. <el-col :span="8">
  301. <el-form-item label="劳务公司" prop="fLabour">
  302. <el-select
  303. style="width: 80%"
  304. v-model="form.fLabour"
  305. clearable
  306. filterable
  307. placeholder="请输入关键词"
  308. :disabled="contrOl || browseStatus || form.warehouseStatus > 3"
  309. >
  310. <el-option
  311. v-for="(item, index) in fCompanyOptIons"
  312. :key="index.fId"
  313. :label="item.fName"
  314. :value="item.fId"
  315. ></el-option>
  316. </el-select>
  317. </el-form-item>
  318. </el-col>
  319. <el-col :span="8">
  320. <el-form-item
  321. label="车队"
  322. prop="fFleet"
  323. :rules="{
  324. required: isrequired === 1 ? true : false,
  325. message: '请选择',
  326. trigger: ['blur', 'change'],
  327. }"
  328. >
  329. <el-select
  330. style="width: 80%"
  331. v-model="form.fFleet"
  332. clearable
  333. filterable
  334. placeholder="请输入关键词"
  335. :disabled="contrOl || browseStatus || form.warehouseStatus > 3"
  336. >
  337. <el-option
  338. v-for="(item, index) in fleetOptions"
  339. :key="index.fId"
  340. :label="item.fName"
  341. :value="item.fId"
  342. ></el-option>
  343. </el-select>
  344. </el-form-item>
  345. </el-col>
  346. </el-row>
  347. <el-row>
  348. <el-col :span="8">
  349. <el-form-item
  350. label="车号"
  351. prop="fTruckno"
  352. :rules="{
  353. required: isrequired2 === 1 ? true : false,
  354. message: '请选择',
  355. trigger: ['blur', 'change'],
  356. }"
  357. >
  358. <el-input
  359. v-model="form.fTruckno"
  360. style="width: 80%"
  361. :disabled="browseStatus || form.warehouseStatus > 3"
  362. placeholder="车号"
  363. />
  364. </el-form-item>
  365. </el-col>
  366. <el-col :span="8">
  367. <el-form-item
  368. label="司机姓名"
  369. prop="fDriverName"
  370. :rules="{
  371. required: isrequired2 === 1 ? true : false,
  372. message: '请选择',
  373. trigger: ['blur', 'change'],
  374. }"
  375. >
  376. <el-input
  377. v-model="form.fDriverName"
  378. style="width: 80%"
  379. :disabled="browseStatus || form.warehouseStatus > 3"
  380. placeholder="司机姓名"
  381. />
  382. </el-form-item>
  383. </el-col>
  384. <el-col :span="8">
  385. <el-form-item
  386. label="司机电话"
  387. prop="fDriverTel"
  388. :rules="{
  389. required: isrequired2 === 1 ? true : false,
  390. message: '请选择',
  391. trigger: ['blur', 'change'],
  392. }"
  393. >
  394. <el-input
  395. v-model="form.fDriverTel"
  396. style="width: 80%"
  397. :disabled="browseStatus || form.warehouseStatus > 3"
  398. placeholder="司机电话"
  399. />
  400. </el-form-item>
  401. </el-col>
  402. </el-row>
  403. </div>
  404. <el-row>
  405. <el-col :span="16">
  406. <el-row v-if="detailsHidden2">
  407. <el-col :span="12">
  408. <el-form-item
  409. label="司机身份证"
  410. prop="fDriverIdCar"
  411. :rules="{
  412. required: isrequired2 === 1 ? true : false,
  413. message: '请选择',
  414. trigger: ['blur', 'change'],
  415. }"
  416. >
  417. <el-input
  418. v-model="form.fDriverIdCar"
  419. style="width: 80%"
  420. :disabled="browseStatus || form.warehouseStatus > 3"
  421. placeholder="司机身份证"
  422. />
  423. </el-form-item>
  424. </el-col>
  425. </el-row>
  426. <el-row>
  427. <el-col :span="12">
  428. <el-form-item label="备注" prop="remark">
  429. <el-input
  430. style="width: 80%"
  431. v-model="form.remark"
  432. type="textarea"
  433. :disabled="browseStatus || form.warehouseStatus > 3"
  434. placeholder="请输入内容"
  435. />
  436. </el-form-item>
  437. </el-col>
  438. <el-col :span="12">
  439. <el-form-item label="收费指示" prop="remark">
  440. <el-input
  441. style="width: 80%"
  442. v-model="form.fRemarksFees"
  443. type="textarea"
  444. :disabled="browseStatus || form.warehouseStatus > 3"
  445. placeholder="请输入内容"
  446. />
  447. </el-form-item>
  448. </el-col>
  449. </el-row>
  450. <el-row>
  451. <el-col :offset="16" :span="6">
  452. <el-button
  453. v-if="dataShowcar == '0'"
  454. @click="
  455. detailsHidden2
  456. ? (detailsHidden2 = false)
  457. : (detailsHidden2 = true)
  458. "
  459. >{{ detailsHidden2 ? "隐藏" : "更多" }}
  460. </el-button>
  461. <el-button
  462. @click="
  463. detailsHidden
  464. ? (detailsHidden = false)
  465. : (detailsHidden = true)
  466. "
  467. >{{ detailsHidden ? "隐藏" : "展开" }}
  468. </el-button>
  469. </el-col>
  470. </el-row>
  471. </el-col>
  472. <el-col :span="8">
  473. <el-form-item>
  474. <div style="display: flex; align-items: center">
  475. <el-table
  476. :data="CntrTable"
  477. style="width: 80%"
  478. :header-cell-style="{ lineHeight: '16px' }"
  479. >
  480. <el-table-column
  481. prop="fCntrid "
  482. label="箱型"
  483. header-align="center"
  484. align="center"
  485. >
  486. <template slot-scope="scope">
  487. <el-select
  488. placeholder="请选择箱型"
  489. v-model="scope.row.fCntrid"
  490. size="mini"
  491. >
  492. <el-option
  493. v-for="(item, index) in cntrList"
  494. :key="index.fId"
  495. :label="item.fName"
  496. :value="item.fId"
  497. >
  498. </el-option>
  499. </el-select>
  500. </template>
  501. </el-table-column>
  502. <el-table-column
  503. prop="fCntrcount"
  504. label="箱量"
  505. header-align="center"
  506. align="center"
  507. >
  508. <template slot-scope="scope">
  509. <el-input
  510. placeholder="请输入箱量"
  511. v-model="scope.row.fCntrcount"
  512. size="mini"
  513. >
  514. </el-input>
  515. </template>
  516. </el-table-column>
  517. <el-table-column
  518. prop="fCntrcount"
  519. label="操作"
  520. header-align="center"
  521. align="center"
  522. width="50"
  523. >
  524. <template slot-scope="scope">
  525. <el-button
  526. size="mini"
  527. type="text"
  528. @click.native.prevent="deleteRow(scope.$index, CntrTable)"
  529. icon="el-icon-delete"
  530. ></el-button>
  531. </template>
  532. </el-table-column>
  533. </el-table>
  534. <el-tag class="tag-hover" @click="addRow"
  535. ><i class="el-icon-plus"></i
  536. ></el-tag>
  537. </div>
  538. </el-form-item>
  539. </el-col>
  540. </el-row>
  541. <div v-if="detailsHidden">
  542. <el-row style="margin-top: 30px">
  543. <el-col :span="8">
  544. <el-form-item label="仓库联系人" prop="fContacts">
  545. <el-input
  546. v-model="form.fContacts"
  547. style="width: 80%"
  548. :disabled="browseStatus || form.warehouseStatus > 3"
  549. placeholder="仓库联系人"
  550. />
  551. </el-form-item>
  552. </el-col>
  553. <el-col :span="8">
  554. <el-form-item label="仓库电话" prop="fTel">
  555. <el-input
  556. v-model="form.fTel"
  557. :disabled="browseStatus || form.warehouseStatus > 3"
  558. style="width: 80%"
  559. placeholder="请输仓库入电话"
  560. />
  561. </el-form-item>
  562. </el-col>
  563. <el-col :span="8">
  564. <el-form-item label="贸易方式" prop="fTrademodeid">
  565. <el-select
  566. v-model="form.fTrademodeid"
  567. placeholder="请选择贸易方式"
  568. :disabled="browseStatus || form.warehouseStatus > 3"
  569. style="width: 80%"
  570. >
  571. <el-option
  572. v-for="(item, index) in fTrademodeidOptions"
  573. :key="index.dictValue"
  574. :label="item.dictLabel"
  575. :value="item.dictValue"
  576. />
  577. </el-select>
  578. </el-form-item>
  579. </el-col>
  580. </el-row>
  581. <el-row>
  582. <el-col :span="8">
  583. <el-form-item label="单据编号" prop="fBillno">
  584. <el-input
  585. v-model="form.fBillno"
  586. disabled
  587. style="width: 80%"
  588. placeholder="单据编号"
  589. />
  590. </el-form-item>
  591. </el-col>
  592. <el-col :span="8">
  593. <el-form-item label="破损" prop="fifdamage">
  594. <el-select
  595. v-model="form.fIfdamage"
  596. placeholder="请选择是否破损"
  597. :disabled="browseStatus || form.warehouseStatus > 3"
  598. clearable
  599. style="width: 80%"
  600. >
  601. <el-option
  602. v-for="(item, index) in fIfdamageOptions"
  603. :key="index.dictValue"
  604. :label="item.dictLabel"
  605. :value="item.dictValue"
  606. />
  607. </el-select>
  608. </el-form-item>
  609. </el-col>
  610. <el-col :span="8">
  611. <el-form-item label="过磅" prop="fIfweigh">
  612. <el-select
  613. v-model="form.fIfweigh"
  614. placeholder="请选择是否过磅"
  615. clearable
  616. :disabled="browseStatus || form.warehouseStatus > 3"
  617. style="width: 80%"
  618. >
  619. <el-option
  620. v-for="(item, index) in fIfweighOptions"
  621. :key="index.dictValue"
  622. :label="item.dictLabel"
  623. :value="item.dictValue"
  624. />
  625. </el-select>
  626. </el-form-item>
  627. </el-col>
  628. </el-row>
  629. <el-row>
  630. <el-col :span="8">
  631. <el-form-item label="制单人" prop="createBy">
  632. <el-input
  633. disabled
  634. v-model="form.createBy"
  635. style="width: 80%"
  636. placeholder="制单人"
  637. />
  638. </el-form-item>
  639. </el-col>
  640. <el-col :span="8">
  641. <el-form-item label="制单部门" prop="fDeptid">
  642. <el-select
  643. v-model="form.fDeptid"
  644. filterable
  645. disabled
  646. style="width: 80%"
  647. remote
  648. >
  649. <el-option
  650. v-for="(item, index) in deptOptions"
  651. :key="index.deptId"
  652. :label="item.deptName"
  653. :value="item.deptId"
  654. ></el-option>
  655. </el-select>
  656. </el-form-item>
  657. </el-col>
  658. <el-col :span="8">
  659. <el-form-item label="制单日期" prop="createTime">
  660. <el-date-picker
  661. v-model="form.createTime"
  662. size="large"
  663. type="date"
  664. disabled
  665. style="width: 80%"
  666. value-format="timestamp"
  667. placeholder="制单日期"
  668. >
  669. </el-date-picker>
  670. </el-form-item>
  671. </el-col>
  672. </el-row>
  673. <el-row>
  674. <el-col :span="8">
  675. <el-form-item label="品名" prop="fProductName">
  676. <el-input
  677. v-model="form.fProductName"
  678. style="width: 80%"
  679. disabled
  680. placeholder="品名"
  681. />
  682. </el-form-item>
  683. </el-col>
  684. <el-col :span="8">
  685. <el-form-item label="品牌">
  686. <el-input
  687. v-model="form.fMarks"
  688. style="width: 80%"
  689. disabled
  690. placeholder="品牌"
  691. />
  692. </el-form-item>
  693. </el-col>
  694. <el-col :span="8">
  695. <el-form-item label="业务员" prop="fSalesmanId">
  696. <el-select
  697. v-model="form.fSalesmanId"
  698. clearable
  699. filterable
  700. placeholder="请选择业务员"
  701. style="width: 80%"
  702. :disabled="browseStatus || form.warehouseStatus > 3"
  703. >
  704. <el-option
  705. v-for="(item, index) in fSalesmanId"
  706. :key="index.userId"
  707. :label="item.userName"
  708. :value="item.userId"
  709. ></el-option>
  710. </el-select>
  711. </el-form-item>
  712. </el-col>
  713. </el-row>
  714. <el-row>
  715. <el-col :span="8">
  716. <el-form-item label="预计到厂日期" prop="fPredictBranch">
  717. <el-date-picker
  718. v-model="form.fPredictBranch"
  719. style="width: 80%"
  720. type="date"
  721. :disabled="browseStatus || form.warehouseStatus > 3"
  722. value-format="timestamp"
  723. placeholder="预计到厂日期"
  724. >
  725. </el-date-picker>
  726. </el-form-item>
  727. </el-col>
  728. <el-col :span="8">
  729. <el-form-item label="等级" prop="fGrade">
  730. <el-input
  731. v-model="form.fGrade"
  732. :disabled="browseStatus || form.warehouseStatus > 3"
  733. style="width: 80%"
  734. placeholder="等级"
  735. />
  736. </el-form-item>
  737. </el-col>
  738. <el-col :span="8">
  739. <el-form-item label="送货详情" prop="fDeliveryDetails">
  740. <el-input
  741. v-model="form.fDeliveryDetails"
  742. :disabled="browseStatus || form.warehouseStatus > 3"
  743. style="width: 80%"
  744. placeholder="送货详情"
  745. />
  746. </el-form-item>
  747. </el-col>
  748. </el-row>
  749. </div>
  750. </el-form>
  751. <el-dialog
  752. title="自定义列显示"
  753. :visible.sync="showSetting"
  754. width="700px"
  755. v-dialogDrag
  756. :close-on-click-modal="false"
  757. >
  758. <template slot="title">
  759. <div class="avue-crud__dialog__header">
  760. <span class="el-dialog__title">
  761. <span
  762. style="
  763. display: inline-block;
  764. width: 3px;
  765. height: 20px;
  766. margin-right: 5px;
  767. float: left;
  768. margin-top: 2px;
  769. "
  770. ></span>
  771. </span>
  772. </div>
  773. </template>
  774. <div>配置排序列数据(拖动调整顺序)</div>
  775. <div style="margin-left: 17px">
  776. <el-checkbox
  777. v-model="allCheck"
  778. label="全选"
  779. @change="allChecked"
  780. ></el-checkbox>
  781. </div>
  782. <div style="padding: 4px; display: flex; justify-content: center">
  783. <draggable
  784. v-model="setRowList"
  785. group="site"
  786. animation="300"
  787. @start="onStart"
  788. @end="onEnd"
  789. handle=".indraggable"
  790. >
  791. <transition-group>
  792. <div
  793. v-for="item in setRowList"
  794. :key="item.surface"
  795. class="listStyle"
  796. >
  797. <div style="width: 500px" class="indraggable">
  798. <div class="progress" :style="{ width: item.width + 'px' }">
  799. <el-checkbox
  800. :label="item.name"
  801. v-model="item.checked"
  802. :true-label="0"
  803. :false-label="1"
  804. >{{ item.name }}
  805. </el-checkbox>
  806. </div>
  807. </div>
  808. <el-input-number
  809. v-model.number="item.width"
  810. controls-position="right"
  811. :min="1"
  812. :max="500"
  813. size="mini"
  814. ></el-input-number>
  815. </div>
  816. </transition-group>
  817. </draggable>
  818. </div>
  819. <span slot="footer" class="dialog-footer">
  820. <el-button @click="showSetting = false">取 消</el-button>
  821. <el-button @click="delRow" type="danger">重 置</el-button>
  822. <el-button type="primary" @click="save()">确 定</el-button>
  823. </span>
  824. </el-dialog>
  825. <el-collapse v-model="collapselist">
  826. <el-collapse-item name="1">
  827. <template slot="title">
  828. <i class="el-icon-s-home" style="font-size: 16px"></i>
  829. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  830. >出库明细</span
  831. >
  832. </template>
  833. <div>
  834. <el-row
  835. type="flex"
  836. justify="space-between"
  837. style="margin-bottom: 10px"
  838. >
  839. <el-col>
  840. <el-button
  841. type="primary"
  842. :disabled="browseStatus"
  843. size="small"
  844. @click="addRelevant"
  845. >导入库存
  846. </el-button>
  847. <el-button
  848. :disabled="browseStatus"
  849. type="primary"
  850. size="small"
  851. @click="saveForm"
  852. >保 存
  853. </el-button
  854. >
  855. </el-col>
  856. <el-col style="display: flex; justify-content: flex-end">
  857. <el-button size="small" type="info" prop="打印" @click="printZyd" v-if="entryPrinting == 0"
  858. >作业单
  859. </el-button>
  860. <el-button
  861. size="small"
  862. v-if="entryPrinting == 0"
  863. :disabled="browseStatus"
  864. @click="discharge"
  865. >叫车进场
  866. </el-button
  867. >
  868. <el-button
  869. size="small"
  870. :disabled="dataListSelection.length <= 0 || deliveryConfirmation"
  871. @click="creditClick"
  872. >出库确认
  873. </el-button>
  874. <el-button
  875. size="small"
  876. :disabled="dataWithdrawList.length <= 0 || cancelDelivery || form.fBillstatus > 3"
  877. @click.prevent="withdrawClick"
  878. >撤回出库
  879. </el-button>
  880. <el-dropdown @command="handleCommand" style="margin-left: 10px">
  881. <el-button size="small" type="success">
  882. 打印单据<i class="el-icon-arrow-down el-icon--right"></i>
  883. </el-button>
  884. <el-dropdown-menu slot="dropdown">
  885. <el-dropdown-item command="d">标准出库单</el-dropdown-item>
  886. <el-dropdown-item command="i">标准出库单(详情)</el-dropdown-item>
  887. <!-- <el-dropdown-item command="b">出库单</el-dropdown-item>-->
  888. <!-- <el-dropdown-item command="c">理货单</el-dropdown-item>-->
  889. <!-- <el-dropdown-item command="e">出库确认</el-dropdown-item>-->
  890. <!-- <el-dropdown-item command="e">劳务确认</el-dropdown-item>-->
  891. <el-dropdown-item command="f">叉车出库单</el-dropdown-item>
  892. <el-dropdown-item command="g">单车出库单</el-dropdown-item>
  893. <el-dropdown-item command="h">装车存档出库单</el-dropdown-item>
  894. <el-dropdown-item command="q">签收单</el-dropdown-item>
  895. </el-dropdown-menu>
  896. </el-dropdown>
  897. <el-dropdown @command="detailedApproval" style="margin-left: 10px" v-if="showApproval == 0">
  898. <el-button size="small" type="primary">
  899. 明细审批<i class="el-icon-arrow-down el-icon--right"></i>
  900. </el-button>
  901. <el-dropdown-menu slot="dropdown">
  902. <el-dropdown-item command="QH">明细请核</el-dropdown-item>
  903. <el-dropdown-item command="CK">查看明细审批</el-dropdown-item>
  904. <el-dropdown-item command="SP">明细审批</el-dropdown-item>
  905. <el-dropdown-item command="CX">撤销明细审批</el-dropdown-item>
  906. </el-dropdown-menu>
  907. </el-dropdown>
  908. <div style="margin: 0 10px">
  909. <el-button
  910. icon="el-icon-setting"
  911. size="mini"
  912. circle
  913. @click="showSetting = !showSetting"
  914. ></el-button>
  915. </div>
  916. </el-col>
  917. </el-row>
  918. <el-table
  919. :data="detailList"
  920. tooltip-effect="dark"
  921. stripe
  922. :summary-method="getSummaries"
  923. @selection-change="Selectinventory"
  924. show-summary
  925. ref="detailTable"
  926. >
  927. <el-table-column type="selection" width="55" align="center" fixed/>
  928. <el-table-column label="序号" type="index" width="80" fixed/>
  929. <el-table-column
  930. v-for="(item, index) in getRowList"
  931. :key="index"
  932. :label="item.name"
  933. :width="item.width"
  934. :prop="item.label"
  935. align="center"
  936. :fixed="item.fixed"
  937. sortable
  938. >
  939. <template slot-scope="scope">
  940. <span v-if="item.label == 'fBillstatus'">
  941. <span v-if="form.fBusinessType === '5'">
  942. <span v-if="scope.row.fBillstatus == 40">已装箱</span>
  943. <span v-if="scope.row.fBillstatus == 20">待装箱</span>
  944. <span v-if="scope.row.fBillstatus == 30">装箱中</span>
  945. <span v-if="scope.row.fBillstatus == 10">计划</span>
  946. </span>
  947. <span v-if="form.fBusinessType !== '5'">
  948. <span v-if="scope.row.fBillstatus == 40">已出库</span>
  949. <span v-if="scope.row.fBillstatus == 20">待出库</span>
  950. <span v-if="scope.row.fBillstatus == 30">出库中</span>
  951. <span v-if="scope.row.fBillstatus == 10">计划</span>
  952. </span>
  953. </span>
  954. <span v-else-if="item.label == 'fBsdate'">
  955. <!-- scope.row.fBillstatus >= 20"-->
  956. <el-date-picker
  957. v-model="scope.row.fBsdate"
  958. style="width: 138px"
  959. :disabled="browseStatus || scope.row.fBillstatus == 40"
  960. type="date"
  961. format="yyyy-MM-dd"
  962. value-format="timestamp"
  963. placeholder="业务日期"
  964. >
  965. </el-date-picker>
  966. </span>
  967. <span v-else-if="item.label == 'fGoodsid'">
  968. {{ scope.row.fGoodsid | goodsFormat(goodsOptions) }}
  969. </span>
  970. <span v-else-if="item.label == 'fBusinessType'">
  971. <el-select
  972. v-model="scope.row.fBusinessType"
  973. filterable
  974. disabled
  975. placeholder="请选择商品属性"
  976. >
  977. <el-option
  978. v-for="(item, index) in fStorageTypeOptions"
  979. :key="index.dictValue"
  980. :label="item.dictLabel"
  981. :value="item.dictValue"
  982. />
  983. </el-select>
  984. </span>
  985. <span v-else-if="item.label =='fNowCarton'">
  986. <el-input
  987. v-model="scope.row.fNowCarton"
  988. :disabled="browseStatus || scope.row.fBillstatus == 40"
  989. placeholder="现箱号"
  990. />
  991. </span>
  992. <span v-else-if="item.label =='fCartypeId'">
  993. <el-select
  994. style="width: 80%"
  995. v-model="scope.row.fCartypeId"
  996. :disabled="browseStatus || scope.row.fBillstatus == 40"
  997. >
  998. <el-option
  999. v-for="(dict, index) in cartypeId"
  1000. :key="index.dictValue"
  1001. :label="dict.dictLabel"
  1002. :value="dict.dictValue"
  1003. ></el-option>
  1004. </el-select>
  1005. </span>
  1006. <span v-else-if="item.label == 'fQty'">
  1007. <el-input
  1008. @change="qtyChange(scope.row)"
  1009. v-model="scope.row.fQty"
  1010. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1011. placeholder="出库件数"
  1012. />
  1013. </span>
  1014. <span v-else-if="item.label == 'fGrossweight'">
  1015. <el-input
  1016. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1017. v-model="scope.row.fGrossweight"
  1018. @change="changeOutStock(scope.row)"
  1019. placeholder="出库毛重"
  1020. />
  1021. </span>
  1022. <span v-else-if="item.label == 'fNetweight'">
  1023. <el-input
  1024. v-model="scope.row.fNetweight"
  1025. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1026. @change="changeOutStock(scope.row)"
  1027. placeholder="出库净重"
  1028. />
  1029. </span>
  1030. <span v-else-if="item.label == 'fPackagespecs'">
  1031. <el-input
  1032. v-model="scope.row.fPackagespecs"
  1033. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1034. placeholder="包装规格"
  1035. />
  1036. </span>
  1037. <span v-else-if="item.label == 'fCntrtype'">
  1038. <el-input
  1039. v-model="scope.row.fCntrtype"
  1040. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1041. placeholder="箱型"
  1042. />
  1043. </span>
  1044. <span v-else-if="item.label == 'fCntqty'">
  1045. <el-input
  1046. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1047. v-model="scope.row.fCntqty"
  1048. placeholder="箱量"
  1049. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1050. />
  1051. </span>
  1052. <span v-else-if="item.label == 'fGoodsval'">
  1053. <el-input
  1054. v-model="scope.row.fGoodsval"
  1055. placeholder="货值"
  1056. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1057. />
  1058. </span>
  1059. <span v-else-if="item.label == 'fTruckno'">
  1060. <el-input
  1061. v-model="scope.row.fTruckno"
  1062. placeholder="车号"
  1063. :disabled="browseStatus || scope.row.fBillstatus >= 40"
  1064. />
  1065. </span>
  1066. <span v-else-if="item.label == 'fDriverName'">
  1067. <el-input
  1068. v-model="scope.row.fDriverName"
  1069. placeholder="司机名"
  1070. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1071. />
  1072. </span>
  1073. <span v-else-if="item.label == 'fDriverTel'">
  1074. <el-input
  1075. v-model="scope.row.fDriverTel"
  1076. placeholder="司机电话"
  1077. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1078. />
  1079. </span>
  1080. <span v-else-if="item.label == 'fDriverIdCar'">
  1081. <el-input
  1082. v-model="scope.row.fDriverIdCar"
  1083. placeholder="司机身份证"
  1084. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1085. />
  1086. </span>
  1087. <span v-else-if="item.label == 'fIsPass'">
  1088. <el-select
  1089. v-model="scope.row.fIsPass"
  1090. placeholder="是否放行"
  1091. :disabled="browseStatus || scope.row.fBillstatus == 40"
  1092. style="width: 80%"
  1093. >
  1094. <el-option
  1095. v-for="(item, index) in releaseList"
  1096. :key="index.dictValue"
  1097. :label="item.dictLabel"
  1098. :value="item.dictValue"
  1099. />
  1100. </el-select>
  1101. </span>
  1102. <span v-else-if="item.label == 'fFleet'">
  1103. <el-select
  1104. v-model="scope.row.fFleet"
  1105. placeholder="车队"
  1106. :disabled="browseStatus || scope.row.fBillstatus >= 40"
  1107. style="width: 80%"
  1108. >
  1109. <el-option
  1110. v-for="(item, index) in fleetOptions"
  1111. :key="index.fId"
  1112. :label="item.fName"
  1113. :value="item.fId"
  1114. ></el-option>
  1115. </el-select>
  1116. </span>
  1117. <span v-else-if="item.label == 'fLntype'">
  1118. <el-select
  1119. v-model="scope.row.fLntype"
  1120. placeholder="装卸方式"
  1121. :disabled="browseStatus || scope.row.fBillstatus >= 40"
  1122. style="width: 80%"
  1123. >
  1124. <el-option
  1125. v-for="(item, index) in unloadModes"
  1126. :key="index.dictValue"
  1127. :label="item.dictLabel"
  1128. :value="item.dictValue"
  1129. />
  1130. </el-select>
  1131. </span>
  1132. <span v-else-if="item.label == 'fForkliftman'">
  1133. <el-input
  1134. v-model="scope.row.fForkliftman"
  1135. placeholder="叉车工"
  1136. :disabled="browseStatus || scope.row.fBillstatus >= 40"
  1137. />
  1138. </span>
  1139. <span v-else-if="item.label == 'fLocalcntrno'">
  1140. <el-input
  1141. v-model="scope.row.fLocalcntrno"
  1142. placeholder="库内箱号"
  1143. :disabled="browseStatus || scope.row.fBillstatus >= 40"
  1144. v-Alphabet
  1145. />
  1146. </span>
  1147. <span v-else-if="item.label == 'fSealno'">
  1148. <el-input
  1149. v-model="scope.row.fSealno"
  1150. placeholder="封号"
  1151. :disabled="browseStatus || scope.row.fBillstatus >= 40"
  1152. />
  1153. </span>
  1154. <span v-else-if="item.label == 'fSerialNumber'">
  1155. <el-input
  1156. v-model="scope.row.fSerialNumber"
  1157. placeholder="流水号"
  1158. :disabled="browseStatus || scope.row.fBillstatus >= 40"
  1159. />
  1160. </span>
  1161. <span v-else-if="item.label == 'remark'">
  1162. <el-input
  1163. v-model="scope.row.remark"
  1164. placeholder="备注"
  1165. :disabled="browseStatus"
  1166. show-word-limit
  1167. />
  1168. </span>
  1169. <span v-else>{{ scope.row[item.label] }}</span>
  1170. </template>
  1171. </el-table-column>
  1172. <el-table-column
  1173. header-align="center"
  1174. align="center"
  1175. label="操作"
  1176. width="130px"
  1177. fixed="right"
  1178. >
  1179. <template slot-scope="scope">
  1180. <el-button
  1181. :disabled="browseStatus || scope.row.fBillstatus >= 20"
  1182. type="text"
  1183. @click.native.prevent="wDeleteRow(scope.$index, detailList)"
  1184. size="small"
  1185. >移除
  1186. </el-button
  1187. >
  1188. </template>
  1189. </el-table-column>
  1190. </el-table>
  1191. </div>
  1192. </el-collapse-item>
  1193. <el-collapse-item>
  1194. <template slot="title">
  1195. <i class="el-icon-s-order" style="font-size: 16px"></i>
  1196. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  1197. >附件明细</span
  1198. >
  1199. </template>
  1200. <up-load
  1201. :relevantAttachments="relevantAttachments"
  1202. :createBy="form.createBy"
  1203. :browseStatus="browseStatus"
  1204. ></up-load>
  1205. </el-collapse-item>
  1206. <el-collapse-item>
  1207. <template slot="title">
  1208. <i class="el-icon-circle-plus" style="font-size: 16px"></i>
  1209. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  1210. >收款信息</span
  1211. >
  1212. </template>
  1213. <div
  1214. class="dialogTableTitle flex a-center jlr"
  1215. style="
  1216. display: flex;
  1217. justify-content: space-between;
  1218. align-items: center;
  1219. margin: 10px 0;
  1220. "
  1221. >
  1222. <div>
  1223. <el-button
  1224. size="small"
  1225. type="primary"
  1226. :disabled="browseStatus"
  1227. @click.prevent="addCollection()"
  1228. >新行
  1229. </el-button>
  1230. <!-- <el-button :disabled="browseStatus" @click.prevent="deleteRow(warehouseDrList)"
  1231. >删除
  1232. </el-button> -->
  1233. <el-button
  1234. type="primary"
  1235. size="small"
  1236. :disabled="browseStatus"
  1237. @click="saveForm"
  1238. >保 存
  1239. </el-button
  1240. >
  1241. <!-- <el-button @click.prevent="addAgreement()" type="warning">仓储费协议</el-button> -->
  1242. <el-button
  1243. size="small"
  1244. @click.prevent="handleSelect(3)"
  1245. type="danger"
  1246. >作业费协议
  1247. </el-button>
  1248. <el-button
  1249. @click="calculationFee"
  1250. size="small"
  1251. :disabled="browseStatus"
  1252. type="warning"
  1253. >计算仓储费
  1254. </el-button>
  1255. <el-button
  1256. type="primary"
  1257. size="small"
  1258. v-if="browseStatus"
  1259. @click="feeChange('D')"
  1260. >
  1261. 费用变更
  1262. </el-button>
  1263. </div>
  1264. </div>
  1265. <el-table
  1266. :data="warehouseDrList"
  1267. ref="table"
  1268. tooltip-effect="dark"
  1269. border
  1270. stripe
  1271. show-summary
  1272. @selection-change="Collectionoptions"
  1273. :summary-method="warehouseDrSummaries"
  1274. >
  1275. <el-table-column type="selection" width="55" align="center"/>
  1276. <el-table-column label="序号" type="index" width="80">
  1277. </el-table-column>
  1278. <el-table-column
  1279. prop="fCorpid"
  1280. header-align="center"
  1281. align="center"
  1282. width="300px"
  1283. label="客户名称"
  1284. >
  1285. <template slot-scope="scope">
  1286. <el-select
  1287. v-model="scope.row.fCorpid"
  1288. filterable
  1289. clearable
  1290. placeholder="客户名称"
  1291. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1292. >
  1293. <el-option
  1294. v-for="(item, index) in fMblnoOptions"
  1295. :key="index.fId"
  1296. :label="item.fName"
  1297. :value="item.fId"
  1298. ></el-option>
  1299. </el-select>
  1300. </template>
  1301. </el-table-column>
  1302. <el-table-column
  1303. prop="fFeeid"
  1304. header-align="center"
  1305. align="center"
  1306. width="240px"
  1307. label="费用名称"
  1308. >
  1309. <template slot-scope="scope">
  1310. <el-select
  1311. v-model="scope.row.fFeeid"
  1312. clearable
  1313. filterable
  1314. placeholder="费用名称"
  1315. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1316. >
  1317. <el-option
  1318. v-for="(item, index) in fDNameOptions"
  1319. :key="index.fId"
  1320. :label="item.fName"
  1321. :value="item.fId"
  1322. ></el-option>
  1323. </el-select>
  1324. </template>
  1325. </el-table-column>
  1326. <el-table-column
  1327. prop="fBusinessType"
  1328. header-align="center"
  1329. align="center"
  1330. width="180px"
  1331. label="作业类型"
  1332. >
  1333. <template slot-scope="scope">
  1334. <el-select
  1335. style="width: 80%"
  1336. v-model="scope.row.fBusinessType"
  1337. filterable
  1338. disabled
  1339. >
  1340. <el-option
  1341. v-for="(item, index) in businessTypeOption"
  1342. :key="index.dictValue"
  1343. :label="item.dictLabel"
  1344. :value="item.dictValue"
  1345. ></el-option>
  1346. </el-select>
  1347. </template>
  1348. </el-table-column>
  1349. <el-table-column
  1350. prop="fFeeUnitid"
  1351. header-align="center"
  1352. align="center"
  1353. width="180px"
  1354. label="计价单位"
  1355. >
  1356. <template slot-scope="scope">
  1357. <el-select
  1358. v-model="scope.row.fFeeUnitid"
  1359. placeholder="请选择计价单位"
  1360. clearable
  1361. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1362. @change="changeFeeUnit(scope.row)"
  1363. >
  1364. <el-option
  1365. v-for="(item, index) in fFeetUnitOptions"
  1366. :key="index.dictValue"
  1367. :label="item.dictLabel"
  1368. :value="item.dictValue"
  1369. />
  1370. </el-select>
  1371. </template>
  1372. </el-table-column>
  1373. <el-table-column
  1374. prop="fQty"
  1375. header-align="center"
  1376. align="center"
  1377. width="130px"
  1378. label="数量"
  1379. >
  1380. <template slot-scope="scope">
  1381. <el-input
  1382. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1383. v-model="scope.row.fQty"
  1384. placeholder="数量"
  1385. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1386. @change="changeContractAmt(scope.row)"
  1387. show-word-limit
  1388. />
  1389. </template>
  1390. </el-table-column>
  1391. <el-table-column
  1392. prop="fUnitprice"
  1393. header-align="center"
  1394. align="center"
  1395. width="130px"
  1396. label="单价"
  1397. >
  1398. <template slot-scope="scope">
  1399. <el-input
  1400. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1401. v-model="scope.row.fUnitprice"
  1402. placeholder="单价"
  1403. :disabled="browseStatus || scope.row.fSrcTypeId !== 0 || scope.row.fBillstatus == 6"
  1404. @change="changeContractAmt(scope.row)"
  1405. show-word-limit
  1406. />
  1407. </template>
  1408. </el-table-column>
  1409. <el-table-column
  1410. prop="fAmount"
  1411. header-align="center"
  1412. align="center"
  1413. width="130px"
  1414. label="金额"
  1415. >
  1416. <template slot-scope="scope">
  1417. <el-input
  1418. :disabled="browseStatus || scope.row.fSrcTypeId !== 0 || scope.row.fBillstatus == 6"
  1419. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1420. v-model="scope.row.fAmount"
  1421. placeholder="金额"
  1422. show-word-limit
  1423. />
  1424. </template>
  1425. </el-table-column>
  1426. <el-table-column
  1427. prop="fStltypeid"
  1428. header-align="center"
  1429. align="center"
  1430. width="130px"
  1431. label="结算方式"
  1432. >
  1433. <template slot-scope="scope">
  1434. <el-select
  1435. v-model="scope.row.fStltypeid"
  1436. placeholder="请选择结算表票结、月结"
  1437. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1438. >
  1439. <el-option
  1440. v-for="(item, index) in fStltypeOptions"
  1441. :key="index.dictValue"
  1442. :label="item.dictLabel"
  1443. :value="item.dictValue"
  1444. ></el-option>
  1445. </el-select>
  1446. </template>
  1447. </el-table-column>
  1448. <el-table-column
  1449. prop="fCurrency"
  1450. header-align="center"
  1451. align="center"
  1452. width="130px"
  1453. label="币别"
  1454. >
  1455. <template slot-scope="scope">
  1456. <el-input
  1457. v-model="scope.row.fCurrency"
  1458. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1459. placeholder="币别"
  1460. show-word-limit
  1461. />
  1462. </template>
  1463. </el-table-column>
  1464. <el-table-column
  1465. prop="fExrate"
  1466. header-align="center"
  1467. align="center"
  1468. width="130px"
  1469. label="汇率"
  1470. >
  1471. <template slot-scope="scope">
  1472. <el-input
  1473. v-model="scope.row.fExrate"
  1474. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1475. placeholder="汇率"
  1476. show-word-limit
  1477. />
  1478. </template>
  1479. </el-table-column>
  1480. <el-table-column
  1481. prop="fTaxrate"
  1482. header-align="center"
  1483. align="center"
  1484. width="130px"
  1485. label="税率"
  1486. >
  1487. <template slot-scope="scope">
  1488. <el-input
  1489. v-model="scope.row.fTaxrate"
  1490. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1491. placeholder="税率"
  1492. show-word-limit
  1493. />
  1494. </template>
  1495. </el-table-column>
  1496. <el-table-column
  1497. prop="fMblno"
  1498. header-align="center"
  1499. align="center"
  1500. width="130px"
  1501. label="提单号"
  1502. >
  1503. <template slot-scope="scope">
  1504. <el-input
  1505. v-model="scope.row.fMblno"
  1506. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1507. placeholder="提单号"
  1508. show-word-limit
  1509. />
  1510. </template>
  1511. </el-table-column>
  1512. <el-table-column
  1513. prop="fProductName"
  1514. header-align="center"
  1515. align="center"
  1516. width="140px"
  1517. label="品名"
  1518. >
  1519. <template slot-scope="scope">
  1520. <el-input
  1521. v-model="scope.row.fProductName"
  1522. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1523. placeholder="品名"
  1524. show-word-limit
  1525. />
  1526. </template>
  1527. </el-table-column>
  1528. <el-table-column
  1529. prop="fMarks"
  1530. header-align="center"
  1531. align="center"
  1532. width="130px"
  1533. label="品牌"
  1534. >
  1535. <template slot-scope="scope">
  1536. <el-input
  1537. v-model="scope.row.fMarks"
  1538. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1539. placeholder="品牌"
  1540. show-word-limit
  1541. />
  1542. </template>
  1543. </el-table-column>
  1544. <el-table-column
  1545. prop="fSrcTypeId"
  1546. header-align="center"
  1547. align="center"
  1548. width="130px"
  1549. label="来源"
  1550. >
  1551. <template slot-scope="scope">
  1552. <span v-if="scope.row.fSrcTypeId === 0">录入</span>
  1553. <span v-if="scope.row.fSrcTypeId == 1">协议</span>
  1554. <span v-if="scope.row.fSrcTypeId == 10">变更</span>
  1555. </template>
  1556. </el-table-column>
  1557. <el-table-column
  1558. prop="fBilltype"
  1559. header-align="center"
  1560. align="center"
  1561. width="140px"
  1562. label="业务来源"
  1563. >
  1564. <template slot-scope="scope">
  1565. <span v-if="scope.row.fBilltype === 'SJRK'">入库</span>
  1566. <span v-if="scope.row.fBilltype === 'SJCK'">出库</span>
  1567. <span v-if="scope.row.fBilltype === 'KCZZ'">库存总账</span>
  1568. </template>
  1569. </el-table-column>
  1570. <el-table-column
  1571. prop="fMblno"
  1572. header-align="center"
  1573. align="center"
  1574. width="140px"
  1575. label="业务单号"
  1576. :disabled="browseStatus"
  1577. >
  1578. <template slot-scope="scope">
  1579. <el-input v-model="scope.row.fMblno" :disabled="browseStatus || scope.row.fBillstatus == 6" placeholder="请输入业务单号"></el-input>
  1580. </template>
  1581. </el-table-column>
  1582. <el-table-column
  1583. prop="fMarks"
  1584. header-align="center"
  1585. align="center"
  1586. width="140px"
  1587. label="唛头"
  1588. >
  1589. <template slot-scope="scope">
  1590. <el-input v-model="scope.row.fMarks" :disabled="browseStatus || scope.row.fBillstatus == 6" placeholder="请输入唛头"></el-input>
  1591. </template>
  1592. </el-table-column>
  1593. <el-table-column
  1594. prop="fBsdate"
  1595. header-align="center"
  1596. align="center"
  1597. width="165px"
  1598. label="业务日期"
  1599. >
  1600. <template slot-scope="scope">
  1601. <el-date-picker
  1602. style="width: 100%;"
  1603. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1604. v-model="scope.row.fBsdate"
  1605. type="date"
  1606. placeholder="选择日期">
  1607. </el-date-picker>
  1608. </template>
  1609. </el-table-column>
  1610. <el-table-column
  1611. prop="fBillingway"
  1612. header-align="center"
  1613. align="center"
  1614. width="180px"
  1615. label="计费单位"
  1616. >
  1617. <template slot-scope="scope">
  1618. <el-select
  1619. v-model="scope.row.fBillingway"
  1620. placeholder="请选择计费单位"
  1621. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1622. clearable
  1623. >
  1624. <el-option
  1625. v-for="dict in fFeetUnitOptions"
  1626. :key="dict.dictValue"
  1627. :label="dict.dictLabel"
  1628. :value="dict.dictValue"
  1629. />
  1630. </el-select>
  1631. </template>
  1632. </el-table-column>
  1633. <el-table-column
  1634. prop="fBillingQty"
  1635. header-align="center"
  1636. align="center"
  1637. width="140px"
  1638. label="计费数量"
  1639. >
  1640. <template slot-scope="scope">
  1641. <el-input v-model="scope.row.fBillingQty" :disabled="browseStatus || scope.row.fBillstatus == 6" placeholder="请输入计费数量"></el-input>
  1642. </template>
  1643. </el-table-column>
  1644. <el-table-column
  1645. prop="fChargedate"
  1646. header-align="center"
  1647. align="center"
  1648. width="165px"
  1649. label="计费起始日期"
  1650. >
  1651. <template slot-scope="scope">
  1652. <el-date-picker
  1653. style="width: 100%;"
  1654. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1655. v-model="scope.row.fChargedate"
  1656. type="date"
  1657. placeholder="选择日期">
  1658. </el-date-picker>
  1659. </template>
  1660. </el-table-column>
  1661. <el-table-column
  1662. prop="fBillingDeadline"
  1663. header-align="center"
  1664. align="center"
  1665. width="165px"
  1666. label="计费截止日期"
  1667. >
  1668. <template slot-scope="scope">
  1669. <el-date-picker
  1670. style="width: 100%;"
  1671. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1672. v-model="scope.row.fBillingDeadline"
  1673. type="date"
  1674. placeholder="选择日期">
  1675. </el-date-picker>
  1676. </template>
  1677. </el-table-column>
  1678. <el-table-column
  1679. prop="fBillingDays"
  1680. header-align="center"
  1681. align="center"
  1682. width="140px"
  1683. label="计费天数"
  1684. >
  1685. <template slot-scope="scope">
  1686. <el-input v-model="scope.row.fBillingDays" :disabled="browseStatus || scope.row.fBillstatus == 6" placeholder="请输入计费天数"></el-input>
  1687. </template>
  1688. </el-table-column>
  1689. <el-table-column
  1690. prop="fInventoryDays"
  1691. header-align="center"
  1692. align="center"
  1693. width="140px"
  1694. label="库存天数"
  1695. >
  1696. <template slot-scope="scope">
  1697. <el-input v-model="scope.row.fInventoryDays" :disabled="browseStatus || scope.row.fBillstatus == 6" placeholder="请输入库存天数"></el-input>
  1698. </template>
  1699. </el-table-column>
  1700. <el-table-column
  1701. prop="fAmt"
  1702. header-align="center"
  1703. align="center"
  1704. width="140px"
  1705. label="计费金额"
  1706. >
  1707. <template slot-scope="scope">
  1708. <el-input v-model="scope.row.fAmt" :disabled="browseStatus || scope.row.fBillstatus == 6" placeholder="请输入计费金额"
  1709. @change="calculationFAmt(scope.row)"></el-input>
  1710. </template>
  1711. </el-table-column>
  1712. <el-table-column
  1713. prop="remark"
  1714. header-align="center"
  1715. align="center"
  1716. width="150px"
  1717. label="备注"
  1718. >
  1719. <template slot-scope="scope">
  1720. <el-input
  1721. v-model="scope.row.remark"
  1722. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1723. placeholder="备注"
  1724. show-word-limit
  1725. />
  1726. </template>
  1727. </el-table-column>
  1728. <el-table-column
  1729. header-align="center"
  1730. align="center"
  1731. label="操作"
  1732. width="200px"
  1733. fixed="right"
  1734. >
  1735. <template slot-scope="scope">
  1736. <el-button
  1737. @click.native.prevent="deleteRow(scope.$index, warehouseDrList)"
  1738. size="small"
  1739. :disabled="browseStatus || scope.row.fBillstatus == 6"
  1740. >移除
  1741. </el-button
  1742. >
  1743. <el-button
  1744. size="small"
  1745. @click="listCheck(scope.row)"
  1746. v-if="scope.row.fBillstatus < 6"
  1747. >请核</el-button>
  1748. <el-button
  1749. size="small"
  1750. @click="revokeListCheck(scope.row)"
  1751. v-if="scope.row.fBillstatus == 6"
  1752. >撤销请核</el-button>
  1753. </template>
  1754. </el-table-column>
  1755. </el-table>
  1756. </el-collapse-item>
  1757. <el-collapse-item>
  1758. <template slot="title">
  1759. <i class="el-icon-remove" style="font-size: 16px"></i>
  1760. <span style="font-size: 16px; font-weight: bolder; margin-left: 5px"
  1761. >付款信息</span>
  1762. </template>
  1763. <div
  1764. class="dialogTableTitle flex a-center jlr"
  1765. style="
  1766. display: flex;
  1767. justify-content: space-between;
  1768. align-items: center;
  1769. margin: 10px 0;
  1770. "
  1771. >
  1772. <div>
  1773. <el-button
  1774. type="primary"
  1775. :disabled="browseStatus"
  1776. @click.prevent="addpayment()"
  1777. size="small"
  1778. >新行
  1779. </el-button>
  1780. <el-button
  1781. type="primary"
  1782. size="small"
  1783. @click="saveForm"
  1784. :disabled="browseStatus"
  1785. >保 存
  1786. </el-button
  1787. >
  1788. <el-button
  1789. type="danger"
  1790. size="small"
  1791. @click.prevent="handleSelect(1)"
  1792. >作业费协议
  1793. </el-button
  1794. >
  1795. <el-button
  1796. type="info"
  1797. size="small"
  1798. @click.prevent="printCr"
  1799. >请款单
  1800. </el-button
  1801. >
  1802. <el-button
  1803. type="primary"
  1804. size="small"
  1805. v-if="browseStatus"
  1806. @click="feeChange('C')"
  1807. >
  1808. 费用变更
  1809. </el-button>
  1810. </div>
  1811. </div>
  1812. <el-table
  1813. :data="warehouseCrList"
  1814. ref="table"
  1815. tooltip-effect="dark"
  1816. border
  1817. stripe
  1818. show-summary
  1819. :summary-method="warehouseDrSummaries"
  1820. @selection-change="SelectCr"
  1821. >
  1822. <el-table-column type="selection" width="50" align="center" fixed/>
  1823. <el-table-column
  1824. label="序号"
  1825. type="index"
  1826. width="50"
  1827. fixed
  1828. align="center"
  1829. />
  1830. <el-table-column
  1831. prop="fCorpid"
  1832. header-align="center"
  1833. align="center"
  1834. width="300px"
  1835. label="客户名称"
  1836. >
  1837. <template slot-scope="scope">
  1838. <el-select
  1839. v-model="scope.row.fCorpid"
  1840. filterable
  1841. clearable
  1842. placeholder="客户名称"
  1843. :disabled="browseStatus || scope.row.fBillstatus === 6"
  1844. >
  1845. <el-option
  1846. v-for="(item, index) in fMblnoOptions"
  1847. :key="index.fId"
  1848. :label="item.fName"
  1849. :value="item.fId"
  1850. ></el-option>
  1851. </el-select>
  1852. </template>
  1853. </el-table-column>
  1854. <el-table-column
  1855. prop="fFeeid"
  1856. header-align="center"
  1857. align="center"
  1858. width="240px"
  1859. label="费用名称"
  1860. >
  1861. <template slot-scope="scope">
  1862. <el-select
  1863. v-model="scope.row.fFeeid"
  1864. clearable
  1865. filterable
  1866. placeholder="费用名称"
  1867. :disabled="browseStatus || scope.row.fBillstatus === 6"
  1868. >
  1869. <el-option
  1870. v-for="(item, index) in fCNameOptions"
  1871. :key="index.fId"
  1872. :label="item.fName"
  1873. :value="item.fId"
  1874. ></el-option>
  1875. </el-select>
  1876. </template>
  1877. </el-table-column>
  1878. <el-table-column
  1879. prop="fBusinessType"
  1880. header-align="center"
  1881. align="center"
  1882. width="180px"
  1883. label="作业类型"
  1884. >
  1885. <template slot-scope="scope">
  1886. <el-select
  1887. style="width: 80%"
  1888. v-model="scope.row.fBusinessType"
  1889. filterable
  1890. disabled
  1891. >
  1892. <el-option
  1893. v-for="(item, index) in businessTypeOption"
  1894. :key="index.dictValue"
  1895. :label="item.dictLabel"
  1896. :value="item.dictValue"
  1897. ></el-option>
  1898. </el-select>
  1899. </template>
  1900. </el-table-column>
  1901. <el-table-column
  1902. prop="fFeeUnitid"
  1903. header-align="center"
  1904. align="center"
  1905. width="180px"
  1906. label="计价单位"
  1907. >
  1908. <template slot-scope="scope">
  1909. <el-select
  1910. v-model="scope.row.fFeeUnitid"
  1911. placeholder="请选择计价单位"
  1912. clearable
  1913. :disabled="browseStatus || scope.row.fBillstatus === 6"
  1914. @change="changeFeeUnit(scope.row)"
  1915. >
  1916. <el-option
  1917. v-for="(item, index) in fFeetUnitOptions"
  1918. :key="index.dictValue"
  1919. :label="item.dictLabel"
  1920. :value="item.dictValue"
  1921. />
  1922. </el-select>
  1923. </template>
  1924. </el-table-column>
  1925. <el-table-column
  1926. prop="fQty"
  1927. header-align="center"
  1928. align="center"
  1929. width="150px"
  1930. label="数量"
  1931. >
  1932. <template slot-scope="scope">
  1933. <el-input
  1934. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d\d\d).*$/, "$1$2.$3")'
  1935. v-model="scope.row.fQty"
  1936. :disabled="browseStatus || scope.row.fBillstatus === 6"
  1937. @change="changeContractAmt(scope.row)"
  1938. placeholder="数量"
  1939. show-word-limit
  1940. />
  1941. </template>
  1942. </el-table-column>
  1943. <el-table-column
  1944. prop="fUnitprice"
  1945. header-align="center"
  1946. align="center"
  1947. width="150px"
  1948. label="单价"
  1949. >
  1950. <template slot-scope="scope">
  1951. <el-input
  1952. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1953. v-model="scope.row.fUnitprice"
  1954. :disabled="browseStatus || scope.row.fSrcTypeId !== 0 || scope.row.fBillstatus === 6"
  1955. @change="changeContractAmt(scope.row)"
  1956. placeholder="单价"
  1957. show-word-limit
  1958. />
  1959. </template>
  1960. </el-table-column>
  1961. <el-table-column
  1962. prop="fAmount"
  1963. header-align="center"
  1964. align="center"
  1965. width="150px"
  1966. label="金额"
  1967. >
  1968. <template slot-scope="scope">
  1969. <el-input
  1970. disabled
  1971. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1972. v-model="scope.row.fAmount"
  1973. placeholder="金额"
  1974. show-word-limit
  1975. />
  1976. </template>
  1977. </el-table-column>
  1978. <el-table-column
  1979. prop="fStltypeid"
  1980. header-align="center"
  1981. align="center"
  1982. width="130px"
  1983. label="结算方式"
  1984. >
  1985. <template slot-scope="scope">
  1986. <el-select
  1987. v-model="scope.row.fStltypeid"
  1988. placeholder="请选择结算表票结、月结"
  1989. :disabled="browseStatus || scope.row.fBillstatus === 6"
  1990. >
  1991. <el-option
  1992. v-for="(item, index) in fStltypeOptions"
  1993. :key="index.dictValue"
  1994. :label="item.dictLabel"
  1995. :value="item.dictValue"
  1996. ></el-option>
  1997. </el-select>
  1998. </template>
  1999. </el-table-column>
  2000. <el-table-column
  2001. prop="fCurrency"
  2002. header-align="center"
  2003. align="center"
  2004. width="150px"
  2005. label="币别"
  2006. >
  2007. <template slot-scope="scope">
  2008. <el-input
  2009. v-model="scope.row.fCurrency"
  2010. :disabled="browseStatus || scope.row.fBillstatus === 6"
  2011. placeholder="币别"
  2012. show-word-limit
  2013. />
  2014. </template>
  2015. </el-table-column>
  2016. <el-table-column
  2017. prop="fExrate"
  2018. header-align="center"
  2019. align="center"
  2020. width="150px"
  2021. label="汇率"
  2022. >
  2023. <template slot-scope="scope">
  2024. <el-input
  2025. v-model="scope.row.fExrate"
  2026. :disabled="browseStatus || scope.row.fBillstatus === 6"
  2027. placeholder="汇率"
  2028. show-word-limit
  2029. />
  2030. </template>
  2031. </el-table-column>
  2032. <el-table-column
  2033. prop="fTaxrate"
  2034. header-align="center"
  2035. align="center"
  2036. width="150px"
  2037. label="税率"
  2038. >
  2039. <template slot-scope="scope">
  2040. <el-input
  2041. v-model="scope.row.fTaxrate"
  2042. :disabled="browseStatus || scope.row.fBillstatus === 6"
  2043. placeholder="税率"
  2044. show-word-limit
  2045. />
  2046. </template>
  2047. </el-table-column>
  2048. <el-table-column
  2049. prop="fMblno"
  2050. header-align="center"
  2051. align="center"
  2052. width="130px"
  2053. label="提单号"
  2054. >
  2055. <template slot-scope="scope">
  2056. <el-input
  2057. v-model="scope.row.fMblno"
  2058. :disabled="browseStatus || scope.row.fBillstatus === 6"
  2059. placeholder="提单号"
  2060. show-word-limit
  2061. />
  2062. </template>
  2063. </el-table-column>
  2064. <el-table-column
  2065. prop="fProductName"
  2066. header-align="center"
  2067. align="center"
  2068. width="140px"
  2069. label="品名"
  2070. >
  2071. <template slot-scope="scope">
  2072. <el-input
  2073. v-model="scope.row.fProductName"
  2074. :disabled="browseStatus || scope.row.fBillstatus === 6"
  2075. placeholder="品名"
  2076. show-word-limit
  2077. />
  2078. </template>
  2079. </el-table-column>
  2080. <el-table-column
  2081. prop="fMarks"
  2082. header-align="center"
  2083. align="center"
  2084. width="130px"
  2085. label="品牌"
  2086. >
  2087. <template slot-scope="scope">
  2088. <el-input
  2089. v-model="scope.row.fMarks"
  2090. :disabled="browseStatus || scope.row.fBillstatus === 6"
  2091. placeholder="品牌"
  2092. show-word-limit
  2093. />
  2094. </template>
  2095. </el-table-column>
  2096. <el-table-column
  2097. prop="fSrcTypeId"
  2098. header-align="center"
  2099. align="center"
  2100. width="130px"
  2101. label="来源"
  2102. >
  2103. <template slot-scope="scope">
  2104. <span v-if="scope.row.fSrcTypeId === 0">录入</span>
  2105. <span v-if="scope.row.fSrcTypeId == 1">协议</span>
  2106. <span v-if="scope.row.fSrcTypeId == 10">变更</span>
  2107. </template>
  2108. </el-table-column>
  2109. <el-table-column
  2110. prop="remark"
  2111. header-align="center"
  2112. align="center"
  2113. width="150px"
  2114. label="备注"
  2115. >
  2116. <template slot-scope="scope">
  2117. <el-input
  2118. v-model="scope.row.remark"
  2119. :disabled="browseStatus || scope.row.fBillstatus === 6"
  2120. placeholder="备注"
  2121. show-word-limit
  2122. />
  2123. </template>
  2124. </el-table-column>
  2125. <el-table-column
  2126. header-align="center"
  2127. align="center"
  2128. width="200px"
  2129. label="操作"
  2130. fixed="right"
  2131. >
  2132. <template slot-scope="scope">
  2133. <!-- <el-button size="small">审核费用</el-button> -->
  2134. <el-button
  2135. @click.native.prevent="deleteRow(scope.$index, warehouseCrList)"
  2136. size="small"
  2137. :disabled="browseStatus || scope.row.fBillstatus === 6"
  2138. >移除
  2139. </el-button>
  2140. <el-button
  2141. size="small"
  2142. @click="listCheck(scope.row)"
  2143. v-if="scope.row.fBillstatus < 6"
  2144. >请核</el-button>
  2145. <el-button
  2146. size="small"
  2147. @click="revokeListCheck(scope.row)"
  2148. v-if="scope.row.fBillstatus == 6"
  2149. >撤销请核</el-button>
  2150. </template>
  2151. </el-table-column>
  2152. </el-table>
  2153. </el-collapse-item>
  2154. </el-collapse>
  2155. <el-dialog
  2156. title="在库物资"
  2157. :modal="false"
  2158. style="box-shadow: 0 1px 3px rgba(0, 0, 0, 0) !important"
  2159. :visible.sync="whgenlegVisible"
  2160. width="85%"
  2161. @close="init2()"
  2162. :close-on-click-modal="false"
  2163. v-dialogDrag
  2164. >
  2165. <el-dialog
  2166. title="自定义列显示"
  2167. :visible.sync="showSetting2"
  2168. width="700px"
  2169. v-dialogDrag
  2170. append-to-body
  2171. :close-on-click-modal="false"
  2172. >
  2173. <template slot="title">
  2174. <div class="avue-crud__dialog__header">
  2175. <span class="el-dialog__title">
  2176. <span
  2177. style="
  2178. display: inline-block;
  2179. width: 3px;
  2180. height: 20px;
  2181. margin-right: 5px;
  2182. float: left;
  2183. margin-top: 2px;
  2184. "
  2185. ></span>
  2186. </span>
  2187. </div>
  2188. </template>
  2189. <div>配置排序列数据(拖动调整顺序)</div>
  2190. <div style="margin-left: 17px">
  2191. <el-checkbox
  2192. v-model="allCheck2"
  2193. label="全选"
  2194. @change="allChecked2"
  2195. ></el-checkbox>
  2196. </div>
  2197. <div style="padding: 4px; display: flex; justify-content: center">
  2198. <draggable
  2199. v-model="setRowList2"
  2200. group="site"
  2201. animation="300"
  2202. @start="onStart"
  2203. @end="onEnd"
  2204. handle=".indraggable"
  2205. >
  2206. <transition-group>
  2207. <div
  2208. v-for="item in setRowList2"
  2209. :key="item.surface"
  2210. class="listStyle"
  2211. >
  2212. <div style="width: 500px" class="indraggable">
  2213. <div class="progress" :style="{ width: item.width + 'px' }">
  2214. <el-checkbox
  2215. :label="item.name"
  2216. v-model="item.checked"
  2217. :true-label="0"
  2218. :false-label="1"
  2219. >{{ item.name }}
  2220. </el-checkbox>
  2221. </div>
  2222. </div>
  2223. <el-input-number
  2224. v-model.number="item.width"
  2225. controls-position="right"
  2226. :min="1"
  2227. :max="500"
  2228. size="mini"
  2229. ></el-input-number>
  2230. </div>
  2231. </transition-group>
  2232. </draggable>
  2233. </div>
  2234. <span slot="footer" class="dialog-footer">
  2235. <el-button @click="showSetting2 = false">取 消</el-button>
  2236. <el-button @click="delRow2" type="danger">重 置</el-button>
  2237. <el-button type="primary" @click="save2()">确 定</el-button>
  2238. </span>
  2239. </el-dialog>
  2240. <el-form ref="whgenlegParams" :model="whgenlegParams">
  2241. <el-row>
  2242. <el-col :span="5">
  2243. <el-form-item label="提单号" prop="fMblno" label-width="70px">
  2244. <el-input
  2245. v-model="whgenlegParams.fMblno"
  2246. placeholder="请输入提单号"
  2247. clearable
  2248. />
  2249. </el-form-item>
  2250. </el-col>
  2251. <el-col :span="5">
  2252. <el-form-item label="箱号" prop="fCntrno" label-width="70px">
  2253. <el-input
  2254. v-model="whgenlegParams.fCntrno"
  2255. placeholder="请输入箱号"
  2256. clearable
  2257. />
  2258. </el-form-item>
  2259. </el-col>
  2260. <el-col :span="5">
  2261. <el-form-item label="属性详情" prop="fMarks" label-width="70px">
  2262. <el-input
  2263. v-model="whgenlegParams.fMarks"
  2264. placeholder="请输入属性详情"
  2265. clearable
  2266. />
  2267. </el-form-item>
  2268. </el-col>
  2269. <el-col :span="9">
  2270. <el-form-item
  2271. label="入库日期区间"
  2272. prop="orgStorageDate"
  2273. label-width="120px"
  2274. >
  2275. <el-date-picker
  2276. style="width: 80%"
  2277. v-model="whgenlegParams.orgStorageDate"
  2278. type="daterange"
  2279. start-placeholder="开始日期"
  2280. end-placeholder="结束日期"
  2281. value-format="yyyy-MM-dd HH:mm:ss"
  2282. :default-time="['00:00:00', '23:59:59']"
  2283. >
  2284. </el-date-picker>
  2285. </el-form-item>
  2286. </el-col>
  2287. </el-row>
  2288. <el-row :gutter="10">
  2289. <div class="tabSetting">
  2290. <el-button
  2291. type="cyan"
  2292. icon="el-icon-search"
  2293. @click="getDetailsList()"
  2294. style="margin-right: 10px"
  2295. >搜索
  2296. </el-button
  2297. >
  2298. <el-button
  2299. icon="el-icon-setting"
  2300. circle
  2301. @click="showSetting2 = !showSetting2"
  2302. ></el-button>
  2303. </div>
  2304. </el-row>
  2305. </el-form>
  2306. <el-table
  2307. :data="whgenlegList"
  2308. ref="table"
  2309. tooltip-effect="dark"
  2310. width="100%"
  2311. stripe
  2312. @selection-change="whgenlegSelectionChange"
  2313. >
  2314. <el-table-column type="selection" width="50"></el-table-column>
  2315. <el-table-column
  2316. v-for="(item, index) in getRowList2"
  2317. :key="index"
  2318. :label="item.name"
  2319. :width="item.width"
  2320. :prop="item.label"
  2321. align="center"
  2322. :fixed="item.fixed"
  2323. sortable
  2324. >
  2325. <template slot-scope="scope">
  2326. <span v-if="item.label == 'fGoodsid'">
  2327. {{ scope.row.fGoodsid | goodsFormat(goodsOptions) }}
  2328. </span>
  2329. <span v-else-if="item.label == 'fQtyblc2'">
  2330. <el-input
  2331. @change="qtyChange(scope.row)"
  2332. v-model="scope.row.fQtyblc2"
  2333. placeholder="件数"
  2334. />
  2335. </span>
  2336. <span v-else-if="item.label == 'fGrossweightblc2'">
  2337. <el-input
  2338. v-model="scope.row.fGrossweightblc2"
  2339. @change="changeOutStock(scope.row)"
  2340. placeholder="毛重"
  2341. />
  2342. </span>
  2343. <span v-else-if="item.label == 'fNetweightblc2'">
  2344. <el-input
  2345. v-model="scope.row.fNetweightblc2"
  2346. @change="changeOutStock(scope.row)"
  2347. placeholder="净重"
  2348. />
  2349. </span>
  2350. <span v-else>{{ scope.row[item.label] }}</span>
  2351. </template>
  2352. </el-table-column>
  2353. </el-table>
  2354. <pagination
  2355. v-show="whgenlegTotal > 0"
  2356. :total="whgenlegTotal"
  2357. :page.sync="whgenlegParams.pageNum"
  2358. :limit.sync="whgenlegParams.pageSize"
  2359. @pagination="getDetailsList"
  2360. />
  2361. <div slot="footer" class="dialog-footer">
  2362. <el-button type="primary" @click="whgenlegData()"
  2363. >导入库存总账
  2364. </el-button
  2365. >
  2366. <el-button @click="whgenlegVisible = false">取 消</el-button>
  2367. </div>
  2368. </el-dialog>
  2369. <!-- 付款信息作业单-->
  2370. <el-dialog
  2371. :visible.sync="print_Cr"
  2372. width="70%"
  2373. :close-on-click-modal="false"
  2374. :modal="false"
  2375. >
  2376. <div id="print_Cr" class="print-div">
  2377. <div
  2378. class="print-title"
  2379. style="
  2380. display: flex;
  2381. justify-content: center;
  2382. font-size: 24px;
  2383. margin-bottom: 5px;
  2384. "
  2385. >
  2386. {{ company }}请款单
  2387. </div>
  2388. <div
  2389. style="
  2390. display: flex;
  2391. justify-content: center;
  2392. font-size: 18px;
  2393. margin-bottom: 5px;
  2394. "
  2395. ></div>
  2396. <div
  2397. style="
  2398. display: flex;
  2399. justify-content: space-between;
  2400. margin-bottom: 5px;
  2401. "
  2402. class="print_form"
  2403. >
  2404. <div style="display: flex; flex-direction: column;">
  2405. <!-- <div>请款单号:</div>-->
  2406. <div>源业务编码:{{ form.fBillno }}</div>
  2407. <div>委托单位:{{ form.fCorpid | fMblnoFormat(fMblnoOptions) }}</div>
  2408. </div>
  2409. <div style="display: flex; flex-direction: column;margin-right: 15px;width: 150px">
  2410. <div style="">请款日期:</div>
  2411. </div>
  2412. </div>
  2413. <div class="print_table" style="display: flex">
  2414. <table
  2415. border="0"
  2416. cellspacing="0"
  2417. cellpadding="0"
  2418. style="width: 100%; line-height: 30px"
  2419. >
  2420. <tr>
  2421. <td>结算单位</td>
  2422. <td>提单号</td>
  2423. <!-- <td>源业务编码</td>-->
  2424. <td>业务日期</td>
  2425. <td>数量</td>
  2426. <td>单价</td>
  2427. <td>费用</td>
  2428. <td>人民币</td>
  2429. <td>美元</td>
  2430. </tr>
  2431. <tr v-for="(item, index) in PrintingCrlist" :key="index">
  2432. <td>{{ item.fCorpid | fMblnoFormat(fMblnoOptions) }}</td>
  2433. <td>{{ form.fMblno }}</td>
  2434. <!-- <td>{{ form.fBillno }}</td>-->
  2435. <td>{{ form.fBsdate | fBsdateFormat }}</td>
  2436. <td>{{ item.fQty }}</td>
  2437. <td>{{ item.fUnitprice }}</td>
  2438. <td>{{ item.fFeeid | fFeetFormat(fCNameOptions) }}</td>
  2439. <td>{{ item.fAmount }}</td>
  2440. <td></td>
  2441. </tr>
  2442. <tr>
  2443. <td>合计</td>
  2444. <td></td>
  2445. <td></td>
  2446. <td>{{ allCrfQty }}</td>
  2447. <td></td>
  2448. <td></td>
  2449. <td>{{ allCrfAmount }}</td>
  2450. <td></td>
  2451. </tr>
  2452. </table>
  2453. </div>
  2454. <div
  2455. style="display: flex; justify-content: space-between; font-size: 12px"
  2456. >
  2457. <div>领款人:</div>
  2458. <div>业务经理:</div>
  2459. <div>财务:</div>
  2460. <div style="width: 150px">经理:</div>
  2461. </div>
  2462. </div>
  2463. <span lot="footer" class="dialog-footer">
  2464. <el-button
  2465. type="primary"
  2466. size="mini"
  2467. @click="
  2468. print_Cr = false;
  2469. addprint('crzyd');
  2470. "
  2471. >打印
  2472. </el-button>
  2473. <el-button @click="print_Cr = false" size="mini">取消 </el-button>
  2474. </span>
  2475. </el-dialog>
  2476. <el-dialog
  2477. :visible.sync="print_zyd"
  2478. width="70%"
  2479. :close-on-click-modal="false"
  2480. :modal="false"
  2481. >
  2482. <el-radio v-model="radio" :label="1">吨(T)</el-radio>
  2483. <el-radio v-model="radio" :label="2">千克(KG)</el-radio>
  2484. <div id="print_area1" class="print-div">
  2485. <div
  2486. class="print-title"
  2487. style="
  2488. display: flex;
  2489. justify-content: center;
  2490. font-size: 24px;
  2491. margin-bottom: 5px;
  2492. position:relative;
  2493. "
  2494. >
  2495. {{ company }}作业单
  2496. <div
  2497. style="
  2498. display: flex;
  2499. justify-content: space-between;
  2500. position: absolute;
  2501. right: 0;
  2502. font-size: 13px;
  2503. "
  2504. >
  2505. <div>
  2506. </div>
  2507. <div>
  2508. <div>办单号:{{ Printinglist.length > 0 ? Printinglist[0].fSerialNumber : '' }}</div>
  2509. <div>办单日期:{{ nowTime }}</div>
  2510. </div>
  2511. </div>
  2512. </div>
  2513. <div class="print_table" style="display: flex">
  2514. <table
  2515. border="0"
  2516. cellspacing="0"
  2517. cellpadding="0"
  2518. style="width: 100%; line-height: 30px"
  2519. >
  2520. <tr>
  2521. <td>作业类型</td>
  2522. <td colspan="4">
  2523. {{ form.fBusinessType | fBusinessTypeFormat }}
  2524. </td>
  2525. <td>出库时间</td>
  2526. <td colspan="4">{{ form.fBsdate | fBsdateFormat }}</td>
  2527. </tr>
  2528. <tr>
  2529. <td>序号</td>
  2530. <td>车号</td>
  2531. <td>物品名称</td>
  2532. <td>提单号</td>
  2533. <td>货物属性/属性详情</td>
  2534. <td v-if="radio == 1">净重(T)</td>
  2535. <td v-else>净重(KG)</td>
  2536. <td>件数/规格</td>
  2537. <td>箱号</td>
  2538. <td>库位</td>
  2539. <td>车型</td>
  2540. </tr>
  2541. <tr v-for="(item, index) in Printinglist" :key="index">
  2542. <td>{{ index + 1 }}</td>
  2543. <td>{{ item.fTruckno }}</td>
  2544. <td>{{ item.fGoodsid | goodsFormat(goodsOptions) }}</td>
  2545. <td>{{ item.fMblno }}</td>
  2546. <td>
  2547. {{ item.fBusinessType | fStorageFormat }}/{{ item.fMarks }}
  2548. </td>
  2549. <td v-if="radio == 1">{{ (item.fNetweight / 1000).toFixed(4) }}</td>
  2550. <td v-else>{{ item.fNetweight }}</td>
  2551. <td>{{ item.fQty }}/{{ item.fPackagespecs }}</td>
  2552. <td>{{ item.fCntrno }}
  2553. <td>{{ item.fWarehouseInformation }}</td>
  2554. <td>{{ item.fCartypeId | fCartypeFormat(fCartypeOptions) }}</td>
  2555. </tr>
  2556. <tr>
  2557. <td>收费</td>
  2558. <td colspan="4">
  2559. <span v-for="(item, index) in Collectionoptionss" :key="index">
  2560. {{ item.fFeeid | fFeetFormat(fDNameOptions) }}:{{ item.fAmount }} 元<b v-if="index + 1 != Collectionoptionss.length">,</b>
  2561. </span>
  2562. </td>
  2563. <td>备注</td>
  2564. <td colspan="4">{{ form.remark }}</td>
  2565. </tr>
  2566. <!-- <tr v-for="(item, index) in Collectionoptionss" :key="index">-->
  2567. <!-- <td>收费</td>-->
  2568. <!-- <td colspan="4">{{ item.fFeeid | fFeetFormat(fDNameOptions) }}</td>-->
  2569. <!-- <td colspan="5">{{ item.fAmount }} 元</td>-->
  2570. <!-- </tr>-->
  2571. <tr>
  2572. <td>司机签字</td>
  2573. <td colspan="2"></td>
  2574. <td>电话</td>
  2575. <td colspan="2">{{ fDriverTel }}</td>
  2576. <td colspan="4" rowspan="2">
  2577. 确认货物数量无误,包装于货物完好!<br/>出库盖好篷布,如有违背责任自负<br/>装卸工是否收小费
  2578. </td>
  2579. </tr>
  2580. <tr>
  2581. <td>制表</td>
  2582. <td colspan="2">{{ form.createBy }}</td>
  2583. <td>机械/人工</td>
  2584. <td colspan="2"></td>
  2585. </tr>
  2586. <tr>
  2587. <td>地址</td>
  2588. <td colspan="2">{{ stockaddr }}</td>
  2589. <td>电话</td>
  2590. <td colspan="6">{{ form.fTel }}</td>
  2591. </tr>
  2592. </table>
  2593. </div>
  2594. </div>
  2595. <span lot="footer" class="dialog-footer">
  2596. <el-button
  2597. type="primary"
  2598. size="mini"
  2599. @click="
  2600. print_zyd = false;
  2601. addprint('zyd');
  2602. "
  2603. >打印
  2604. </el-button>
  2605. <el-button @click="print_zyd = false;detailList = zcList.concat()" size="mini">取消 </el-button>
  2606. </span>
  2607. </el-dialog>
  2608. <el-dialog
  2609. :visible.sync="print_rkd"
  2610. width="70%"
  2611. :close-on-click-modal="false"
  2612. :modal="false"
  2613. >
  2614. <div id="print_area2" class="print-div">
  2615. <div
  2616. class="print-title"
  2617. style="
  2618. display: flex;
  2619. justify-content: center;
  2620. font-size: 24px;
  2621. margin-bottom: 5px;
  2622. "
  2623. >
  2624. {{ company }}出库单
  2625. </div>
  2626. <div class="print_table" style="display: flex">
  2627. <table
  2628. border="0"
  2629. cellspacing="0"
  2630. cellpadding="0"
  2631. style="width: 100%; line-height: 30px"
  2632. >
  2633. <tr>
  2634. <td>客户</td>
  2635. <td>{{ form.fCorpidName }}</td>
  2636. <td>仓库</td>
  2637. <td>{{ form.fWarehouseids }}</td>
  2638. <td>地址</td>
  2639. <td colspan="2">{{ stockaddr }}</td>
  2640. </tr>
  2641. <tr>
  2642. <td>保管方</td>
  2643. <td width="200">{{ company }}</td>
  2644. <td>联系人</td>
  2645. <td>{{ form.fContacts }}</td>
  2646. <td>电话</td>
  2647. <td colspan="2">{{ form.fTel }}</td>
  2648. </tr>
  2649. <tr>
  2650. <td>提单号</td>
  2651. <td>品名</td>
  2652. <td>箱型</td>
  2653. <td>品牌</td>
  2654. <td>件数</td>
  2655. <td>重量</td>
  2656. <td>包装规格</td>
  2657. </tr>
  2658. <tr v-for="(item, index) in Printinglist" :key="index">
  2659. <td>{{ item.fMblno }}</td>
  2660. <td>{{ item.fGoodsid | goodsFormat(goodsOptions) }}</td>
  2661. <td>{{ item.fCntrtype }}</td>
  2662. <td>{{ item.fMarks }}</td>
  2663. <td>{{ item.fQty }}</td>
  2664. <td>{{ item.fGrossweight }}</td>
  2665. <td>{{ item.fPackagespecs }}</td>
  2666. </tr>
  2667. <tr>
  2668. <td>序号</td>
  2669. <td>出货日期</td>
  2670. <td>箱量(20GP)</td>
  2671. <td>重量(吨)</td>
  2672. <td>件数</td>
  2673. <td>出库重量(吨)</td>
  2674. <td>出库件数</td>
  2675. </tr>
  2676. <tr v-for="(item, index) in Printinglist" :key="'info2-' + index">
  2677. <td>{{ index + 1 }}</td>
  2678. <td>{{ item.fBsdate | fBsdateFormat }}</td>
  2679. <td>{{ item.fCntqty }}</td>
  2680. <td v-if="item.fGrossweight">
  2681. {{ (item.fGrossweight / 1000).toFixed(4) }}
  2682. </td>
  2683. <td v-else></td>
  2684. <td>{{ item.fPlanqty }}</td>
  2685. <td v-if="item.fNetweight">
  2686. {{ (item.fNetweight / 1000).toFixed(4) }}
  2687. </td>
  2688. <td v-else></td>
  2689. <td>{{ item.fQty }}</td>
  2690. </tr>
  2691. <tr>
  2692. <td colspan="2">合计</td>
  2693. <td>{{ allfCntqty }}</td>
  2694. <td>{{ (allfGrossweight / 1000).toFixed(4) }}</td>
  2695. <td>{{ allfPlanqty }}</td>
  2696. <td>{{ (allfNetweight / 1000).toFixed(4) }}</td>
  2697. <td>{{ allfQty }}</td>
  2698. </tr>
  2699. <tr>
  2700. <td>备注</td>
  2701. <td colspan="6"></td>
  2702. </tr>
  2703. <tr>
  2704. <td colspan="7">
  2705. 本进仓单经仓管员签字并经保管方盖章后即专项作为货物所有人的货权证明,本单据不得转让。
  2706. </td>
  2707. </tr>
  2708. </table>
  2709. </div>
  2710. <div
  2711. style="display: flex; justify-content: space-between; font-size: 12px"
  2712. >
  2713. <div>开单员:</div>
  2714. <div style="width: 150px">仓管员:</div>
  2715. </div>
  2716. <div
  2717. style="display: flex; justify-content: space-between; font-size: 12px"
  2718. >
  2719. <div>开单时间:</div>
  2720. <div style="width: 150px">(盖章)</div>
  2721. </div>
  2722. </div>
  2723. <span slot="footer" class="dialog-footer">
  2724. <el-button
  2725. type="primary"
  2726. @click="
  2727. print_rkd = false;
  2728. addprint('rkd');
  2729. "
  2730. >打印
  2731. </el-button>
  2732. <el-button @click="print_rkd = false">取消 </el-button>
  2733. </span>
  2734. </el-dialog>
  2735. <div class="receiptForm">
  2736. <el-dialog
  2737. :visible.sync="print_signFor"
  2738. :show-close="false"
  2739. :close-on-press-escape="false"
  2740. :fullscreen="true"
  2741. style="box-shadow:none"
  2742. width="70%">
  2743. <el-radio v-model="radio" :label="1">吨(T)</el-radio>
  2744. <el-radio v-model="radio" :label="2">千克(KG)</el-radio>
  2745. <section ref="print">
  2746. <p><span class="no-print">打印日期:</span><span
  2747. style="padding-left: 100px">{{ new Date().toLocaleDateString().replace(/\//g, "-") }}</span></p>
  2748. <table class="table" valign="center">
  2749. <tr>
  2750. <td style="width: 9%;"><span class="no-print">提 单 号</span></td>
  2751. <td style="width: 14%;">{{ Printinglist.length === 1 ? Printinglist[0].fMblno : '' }}</td>
  2752. <td style="width: 8%;"><span class="no-print">合 同 号</span></td>
  2753. <td style="width: 13%;">{{ Printinglist.length === 1 ? Printinglist[0].fSerialNumber : '' }}</td>
  2754. <td style="width: 9%;"><span class="no-print">品 名</span></td>
  2755. <td style="width: 16%;">{{ Printinglist.length === 1 ? Printinglist[0].fGoodsids : '' }}</td>
  2756. </tr>
  2757. <tr>
  2758. <td><span class="no-print">件 数</span></td>
  2759. <td>{{ Printinglist.length === 1 ? Printinglist[0].fQty : '' }}</td>
  2760. <td><span class="no-print">重 量</span></td>
  2761. <td v-if="radio == 1">{{ Printinglist.length === 1 ? Printinglist[0].fNetweight : '' }}</td>
  2762. <td v-else>{{ Printinglist.length === 1 ? (Printinglist[0].fNetweight / 1000).toFixed(4) : '' }}</td>
  2763. <td><span class="no-print">尺 码</span></td>
  2764. <td></td>
  2765. </tr>
  2766. <tr>
  2767. <td><span class="no-print">原箱号</span></td>
  2768. <td>{{ Printinglist.length === 1 ? Printinglist[0].fCntrno : '' }}</td>
  2769. <td><span class="no-print">现箱号</span></td>
  2770. <td>{{ Printinglist.length === 1 ? Printinglist[0].fNowCarton : '' }}</td>
  2771. <td><span class="no-print">铅封号</span></td>
  2772. <td>{{ Printinglist.length === 1 ? Printinglist[0].fSealno : '' }}</td>
  2773. </tr>
  2774. <tr>
  2775. <td><span class="no-print">出库日</span></td>
  2776. <td>{{ Printinglist.length === 1 ? Printinglist[0].fBsdate : '' }}</td>
  2777. <td><span class="no-print">预计到厂日</span></td>
  2778. <td>{{ form.fPredictBranch ? form.fPredictBranch : '' }}</td>
  2779. <td><span class="no-print">等级</span></td>
  2780. <td>{{ form.fGrade ? form.fGrade : '' }}</td>
  2781. </tr>
  2782. <tr>
  2783. <td><span class="no-print">车牌号</span></td>
  2784. <td>{{ Printinglist.length === 1 ? Printinglist[0].fTruckno : '' }}</td>
  2785. <td><span class="no-print">司机姓名</span></td>
  2786. <td>{{ Printinglist.length === 1 ? Printinglist[0].fDriverName : '' }}</td>
  2787. <td><span class="no-print">司机电话</span></td>
  2788. <td>{{ Printinglist.length === 1 ? Printinglist[0].fDriverTel : '' }}</td>
  2789. </tr>
  2790. <tr>
  2791. <td style="height: 70px;"><span class="no-print">送货详情</span></td>
  2792. <td colspan="5">{{ form.fDeliveryDetails ? form.fDeliveryDetails : '' }}</td>
  2793. </tr>
  2794. <tr>
  2795. <td><span class="no-print">送货备注</span></td>
  2796. <td colspan="5">{{ Printinglist.length === 1 ? Printinglist[0].remark : '' }}</td>
  2797. </tr>
  2798. <tr>
  2799. <td><span class="no-print">到厂名称</span></td>
  2800. <td></td>
  2801. <td><span class="no-print">到厂日期</span></td>
  2802. <td></td>
  2803. <td rowspan="4"><span class="no-print">工厂盖章</span></td>
  2804. <td rowspan="4"></td>
  2805. </tr>
  2806. <tr>
  2807. <td><span class="no-print">签收人姓名</span></td>
  2808. <td></td>
  2809. <td><span class="no-print">签收人电话</span></td>
  2810. <td></td>
  2811. </tr>
  2812. <tr>
  2813. <td><span class="no-print">其他</span></td>
  2814. <td colspan="4"></td>
  2815. </tr>
  2816. <tr>
  2817. <td><span class="no-print">业务员</span></td>
  2818. <td v-for="item in fSalesmanId" v-if="form.fSalesmanId === item.userId">
  2819. {{ item.userName }}
  2820. </td>
  2821. <td><span class="no-print">叉车工</span></td>
  2822. <td>{{ Printinglist.length === 1 ? Printinglist[0].fForkliftman : '' }}</td>
  2823. </tr>
  2824. <tr>
  2825. <td style="height: 200px"><span class="no-print">车队注意事项</span></td>
  2826. <td colspan="5"></td>
  2827. </tr>
  2828. <tr>
  2829. <td style="height: 140px;"><span class="no-print">工厂注意事项</span></td>
  2830. <td colspan="5"></td>
  2831. </tr>
  2832. <tr>
  2833. <td style="height: 190px"><span class="no-print">关于我们</span></td>
  2834. <td colspan="5" style="height: 170px;">
  2835. 1、出口优势:东南亚马尼拉、宿务、卡加延、达沃、胡志明、曼谷、台湾、巴生等<br>
  2836. 2、进口优势:承接各种板材、塑料颗粒、原木、棕榈纤维、红酒、等货物订舱、清<br>
  2837. 关、仓储、运输一条龙服务<br>
  2838. 3、陆运优势:我司自有28部集卡车,专业承接临沂、沭阳等板材运输<br>
  2839. 4、仓储优势:我司自有仓库10000平米,可提供进口分拨、仓储、出口装箱服务
  2840. </td>
  2841. </tr>
  2842. </table>
  2843. </section>
  2844. <span slot="footer" class="dialog-footer">
  2845. <el-button @click="print_signFor = false">取 消</el-button>
  2846. <el-button type="primary" @click="Printing()">打 印</el-button>
  2847. </span>
  2848. </el-dialog>
  2849. </div>
  2850. <el-dialog
  2851. :visible.sync="print_bzckd"
  2852. width="70%"
  2853. :close-on-click-modal="false"
  2854. :modal="false"
  2855. >
  2856. <el-radio v-model="radio" :label="1">吨(T)</el-radio>
  2857. <el-radio v-model="radio" :label="2">千克(KG)</el-radio>
  2858. <div id="print_area3" class="print-div">
  2859. <div
  2860. class="print-title"
  2861. style="
  2862. display: flex;
  2863. justify-content: center;
  2864. font-size: 24px;
  2865. margin-bottom: 5px;
  2866. "
  2867. >
  2868. {{ company }}
  2869. </div>
  2870. <div style="font-size: 22px;margin-bottom: 5px;width: 100%;text-align: center">出库单</div>
  2871. <div class="print_table" style="display: flex">
  2872. <table
  2873. border="0"
  2874. cellspacing="0"
  2875. cellpadding="0"
  2876. style="width: 100%; line-height: 30px"
  2877. >
  2878. <tr>
  2879. <td>公司名称</td>
  2880. <td colspan="3">{{ form.fCorpidName }}</td>
  2881. <td>出库日期</td>
  2882. <td colspan="3" v-if="Printinglist.length">
  2883. {{ Printinglist[0].fBsdate | fBsdateFormat }}{{ " " + ckTime }}
  2884. </td>
  2885. <td colspan="3" v-else></td>
  2886. </tr>
  2887. <tr>
  2888. <td style="width: 15%">货物名称</td>
  2889. <td>提单号</td>
  2890. <td>箱号</td>
  2891. <td>件数</td>
  2892. <td v-if="radio == 1">计量单位(吨)</td>
  2893. <td v-else>计量单位(千克)</td>
  2894. <td>车型</td>
  2895. <td>库位</td>
  2896. <td>备注</td>
  2897. </tr>
  2898. <tr v-for="(item, index) in Printinglist" :key="index">
  2899. <td>{{ item.fGoodsid | goodsFormat(goodsOptions) }}</td>
  2900. <td>{{ item.fMblno }}</td>
  2901. <td>{{ item.fCntrno }}</td>
  2902. <td>{{ item.fQty }}</td>
  2903. <td v-if="item.fGrossweight && radio == 1">
  2904. {{ (item.fGrossweight / 1000).toFixed(4) }}
  2905. </td>
  2906. <td v-else-if="item.fGrossweight && radio == 2">
  2907. {{ item.fGrossweight }}
  2908. </td>
  2909. <td v-else></td>
  2910. <td>{{ form.fCartype | fCartypeFormat(fCartypeOptions) }}</td>
  2911. <td>{{ item.fWarehouseInformation }}</td>
  2912. <td>{{ item.remark }}</td>
  2913. </tr>
  2914. <tr>
  2915. <td>车号</td>
  2916. <td colspan="2" v-if="Printinglist.length">
  2917. {{ Printinglist[0].fTruckno }}
  2918. </td>
  2919. <td colspan="2" v-else></td>
  2920. <td colspan="2">身份证号</td>
  2921. <td colspan="3" v-if="Printinglist.length">{{ Printinglist[0].fDriverIdCar }}</td>
  2922. <td colspan="3" v-else></td>
  2923. </tr>
  2924. <tr>
  2925. <td>地址</td>
  2926. <td colspan="7">{{ stockaddr }}</td>
  2927. </tr>
  2928. <tr>
  2929. <td colspan="8">
  2930. 雨/雪天装货司机自愿装车,出现货物水湿与仓库无关!数量准确无误,货物包装完好!
  2931. </td>
  2932. </tr>
  2933. </table>
  2934. </div>
  2935. <div
  2936. style="display: flex; justify-content: space-between; font-size: 12px"
  2937. >
  2938. <div>操作:</div>
  2939. <div>理货:</div>
  2940. <div>叉车:</div>
  2941. <div>司机:</div>
  2942. <div style="width: 200px">电话:{{ Printinglist.length === 1 ? Printinglist[0].fDriverTel : '' }}</div>
  2943. </div>
  2944. </div>
  2945. <span slot="footer" class="dialog-footer">
  2946. <el-button
  2947. type="primary"
  2948. @click="
  2949. print_bzckd = false;
  2950. addprint('bzckd');
  2951. "
  2952. >打印
  2953. </el-button>
  2954. <el-button @click="print_bzckd = false">取消 </el-button>
  2955. </span>
  2956. </el-dialog>
  2957. <!-- 出库单(详情)-->
  2958. <el-dialog
  2959. :visible.sync="print_xqckd"
  2960. width="70%"
  2961. :close-on-click-modal="false"
  2962. :modal="false"
  2963. >
  2964. <el-radio v-model="radio" :label="1">吨(T)</el-radio>
  2965. <el-radio v-model="radio" :label="2">千克(KG)</el-radio>
  2966. <div id="print_areaDetail" class="print-div">
  2967. <div
  2968. class="print-title"
  2969. style="
  2970. display: flex;
  2971. justify-content: center;
  2972. font-size: 24px;
  2973. margin-bottom: 5px;
  2974. "
  2975. >
  2976. {{ company }}出库单
  2977. </div>
  2978. <div class="print_table" style="display: flex">
  2979. <table
  2980. border="0"
  2981. cellspacing="0"
  2982. cellpadding="0"
  2983. style="width: 100%; line-height: 30px"
  2984. >
  2985. <tr>
  2986. <td>公司名称</td>
  2987. <td colspan="3">{{ form.fCorpidName }}</td>
  2988. <td>出库日期</td>
  2989. <td colspan="4" v-if="Printinglist.length">
  2990. {{ Printinglist[0].fBsdate | fBsdateFormat }}{{ " " + ckTime }}
  2991. </td>
  2992. <td colspan="4" v-else></td>
  2993. </tr>
  2994. <tr>
  2995. <td style="width: 15%">货物名称</td>
  2996. <td>提单号</td>
  2997. <td>箱号</td>
  2998. <td>货物属性</td>
  2999. <td>属性详情</td>
  3000. <td>件数</td>
  3001. <td v-if="radio == 1">计量单位(吨)</td>
  3002. <td v-else>计量单位(千克)</td>
  3003. <td>车型</td>
  3004. <td>备注</td>
  3005. </tr>
  3006. <tr v-for="(item, index) in Printinglist" :key="index">
  3007. <td>{{ item.fGoodsid | goodsFormat(goodsOptions) }}</td>
  3008. <td>{{ item.fMblno }}</td>
  3009. <td>{{ item.fCntrno }}</td>
  3010. <td>{{ item.fBusinessType | fStorageTypeFormat(fStorageTypeOptions) }}</td>
  3011. <td>{{ item.fMarks }}</td>
  3012. <td>{{ item.fQty }}</td>
  3013. <td v-if="item.fGrossweight && radio == 1">
  3014. {{ (item.fGrossweight / 1000).toFixed(4) }}
  3015. </td>
  3016. <td v-else-if="item.fGrossweight && radio == 2">
  3017. {{ item.fGrossweight }}
  3018. </td>
  3019. <td v-else></td>
  3020. <td>{{ form.fCartype | fCartypeFormat(fCartypeOptions) }}</td>
  3021. <td>{{ item.remark }}</td>
  3022. </tr>
  3023. <tr>
  3024. <td>车号</td>
  3025. <td colspan="3" v-if="Printinglist.length">
  3026. {{ Printinglist[0].fTruckno }}
  3027. </td>
  3028. <td colspan="3" v-else></td>
  3029. <td colspan="2">身份证号</td>
  3030. <td colspan="3" v-if="Printinglist.length">{{ Printinglist[0].fDriverIdCar }}</td>
  3031. <td colspan="3" v-else></td>
  3032. </tr>
  3033. <tr>
  3034. <td>地址</td>
  3035. <td colspan="8">{{ stockaddr }}</td>
  3036. </tr>
  3037. <tr>
  3038. <td colspan="9">
  3039. 雨/雪天装货司机自愿装车,出现货物水湿与仓库无关!数量准确无误,货物包装完好!
  3040. </td>
  3041. </tr>
  3042. </table>
  3043. </div>
  3044. <div
  3045. style="display: flex; justify-content: space-between; font-size: 12px"
  3046. >
  3047. <div>操作:</div>
  3048. <div>理货:</div>
  3049. <div>叉车:</div>
  3050. <div>司机:</div>
  3051. <div style="width: 200px">电话:</div>
  3052. </div>
  3053. </div>
  3054. <span slot="footer" class="dialog-footer">
  3055. <el-button
  3056. type="primary"
  3057. @click="
  3058. print_xqckd = false;
  3059. addprint('xqckd');
  3060. "
  3061. >打印
  3062. </el-button>
  3063. <el-button @click="print_xqckd = false">取消 </el-button>
  3064. </span>
  3065. </el-dialog>
  3066. <el-dialog
  3067. :visible.sync="print_lhd"
  3068. width="70%"
  3069. :close-on-click-modal="false"
  3070. :modal="false"
  3071. >
  3072. <div id="print_area5" class="print-div">
  3073. <div
  3074. class="print-title"
  3075. style="
  3076. display: flex;
  3077. justify-content: center;
  3078. font-size: 24px;
  3079. margin-bottom: 5px;
  3080. "
  3081. >
  3082. {{ company }}
  3083. </div>
  3084. <div
  3085. style="
  3086. display: flex;
  3087. justify-content: center;
  3088. font-size: 18px;
  3089. margin-bottom: 5px;
  3090. "
  3091. >
  3092. <div>出&nbsp;库&nbsp;单</div>
  3093. </div>
  3094. <div
  3095. style="
  3096. display: flex;
  3097. justify-content: space-between;
  3098. margin-bottom: 5px;
  3099. "
  3100. class="print_form"
  3101. >
  3102. <div>
  3103. <div>提单号:{{ form.fMblno }}</div>
  3104. <div>客户名称:{{ form.fCorpidName }}</div>
  3105. <div>货物名称:{{ form.fProductName }}</div>
  3106. <div>预计净重:{{ form.fPlannetweight }}</div>
  3107. </div>
  3108. <div>
  3109. <div>入库计划单号:{{ form.fBillno }}</div>
  3110. <div>计划入库日期:{{ form.fBstime }}</div>
  3111. <div>制单日期:{{ form.createTime }}</div>
  3112. <div>实际毛重:</div>
  3113. </div>
  3114. <div>
  3115. <div>清单号:{{ form.fCustomno }}</div>
  3116. <div>存放仓库:{{ stockName }}</div>
  3117. <div>预计毛重:{{ form.fPlangrossweight }}</div>
  3118. <div>实际净重:</div>
  3119. </div>
  3120. </div>
  3121. <div class="print_table" style="display: flex">
  3122. <table
  3123. border="0"
  3124. cellspacing="0"
  3125. cellpadding="0"
  3126. style="width: 100%; line-height: 30px"
  3127. >
  3128. <tr>
  3129. <td>箱号</td>
  3130. <td>铅封号</td>
  3131. <td>预计件数</td>
  3132. <td>实际件数</td>
  3133. <td>垛位</td>
  3134. <td>实际入库日期</td>
  3135. <td>送货车号</td>
  3136. <td>送货司机</td>
  3137. <td>备注</td>
  3138. </tr>
  3139. <tr v-for="(item, index) in Printinglist" :key="index">
  3140. <td>{{ item.fCntrno }}</td>
  3141. <td></td>
  3142. <td>{{ item.fQty }}</td>
  3143. <td></td>
  3144. <td>{{ item.fWarehouseInformation }}</td>
  3145. <td>{{ item.fChargedate }}</td>
  3146. <td>{{ item.fTruckno }}</td>
  3147. <td>{{ item.fDriverName }}</td>
  3148. <td>{{ item.remark }}</td>
  3149. </tr>
  3150. <tr>
  3151. <td colspan="2">合计:</td>
  3152. <td>{{ allfQty }}</td>
  3153. <td></td>
  3154. <td></td>
  3155. <td></td>
  3156. <td></td>
  3157. <td></td>
  3158. <td></td>
  3159. </tr>
  3160. </table>
  3161. </div>
  3162. <div
  3163. style="display: flex; justify-content: space-between; font-size: 12px"
  3164. >
  3165. <div>操作:{{ form.createBy }}</div>
  3166. <div>库管:{{ form.fContacts }}</div>
  3167. <div style="width: 100px">叉车:</div>
  3168. </div>
  3169. </div>
  3170. <span slot="footer" class="dialog-footer">
  3171. <el-button
  3172. type="primary"
  3173. @click="
  3174. addprint('lhd');
  3175. print_lhd = false;
  3176. "
  3177. >打印
  3178. </el-button>
  3179. <el-button @click="print_lhd = false">取消 </el-button>
  3180. </span>
  3181. </el-dialog>
  3182. <el-dialog
  3183. :visible.sync="print_lwqr"
  3184. width="70%"
  3185. :close-on-click-modal="false"
  3186. :modal="false"
  3187. >
  3188. <div id="print_area10" class="print-div">
  3189. <div
  3190. class="print-title"
  3191. style="
  3192. display: flex;
  3193. justify-content: center;
  3194. font-size: 24px;
  3195. margin-bottom: 5px;
  3196. "
  3197. >
  3198. {{ company }}
  3199. </div>
  3200. <div
  3201. style="
  3202. display: flex;
  3203. justify-content: center;
  3204. font-size: 18px;
  3205. margin-bottom: 5px;
  3206. "
  3207. >
  3208. <div>出&nbsp;库&nbsp;单</div>
  3209. </div>
  3210. <div style="display: flex; margin-bottom: 5px">
  3211. <div>
  3212. <div>报关单号:{{ form.fCustomno }}</div>
  3213. <div>存货地点:</div>
  3214. </div>
  3215. </div>
  3216. <div class="print_table" style="display: flex">
  3217. <table
  3218. border="0"
  3219. cellspacing="0"
  3220. cellpadding="0"
  3221. style="width: 100%; line-height: 30px"
  3222. >
  3223. <tr>
  3224. <td>品名</td>
  3225. <td colspan="3">{{ form.fProductName }}</td>
  3226. <td colspan="3">清单号</td>
  3227. <td colspan="2">{{ form.fCustomno }}</td>
  3228. </tr>
  3229. <tr>
  3230. <td>提单号</td>
  3231. <td colspan="8">{{ form.fMblno }}</td>
  3232. </tr>
  3233. <tr>
  3234. <td>入库日期</td>
  3235. <td>箱号</td>
  3236. <td>铅封号</td>
  3237. <td>预计件数</td>
  3238. <td>垛位</td>
  3239. <td>实收件数</td>
  3240. <td>实收净重(吨)</td>
  3241. <td>毛重(吨)</td>
  3242. <td>备注</td>
  3243. </tr>
  3244. <tr v-for="(item, index) in Printinglist" :key="index">
  3245. <td>{{ item.fChargedate }}</td>
  3246. <td>{{ item.fCntrno }}</td>
  3247. <td></td>
  3248. <td>{{ item.fQty }}</td>
  3249. <td>{{ item.fWarehouseInformation }}</td>
  3250. <td></td>
  3251. <td></td>
  3252. <td></td>
  3253. <td>{{ item.remark }}</td>
  3254. </tr>
  3255. </table>
  3256. </div>
  3257. <div style="display: flex; justify-content: space-between; font-size: 12px">
  3258. <div>库管:{{ form.fContacts }}</div>
  3259. <div style="width: 100px">叉车:</div>
  3260. </div>
  3261. </div>
  3262. <span slot="footer" class="dialog-footer">
  3263. <el-button
  3264. type="primary"
  3265. @click="
  3266. addprint('lwqr');
  3267. print_lwqr = false;
  3268. "
  3269. >打印
  3270. </el-button>
  3271. <el-button @click="print_lwqr = false">取消 </el-button>
  3272. </span>
  3273. </el-dialog>
  3274. <el-dialog
  3275. :visible.sync="print_ccckd"
  3276. width="70%"
  3277. :close-on-click-modal="false"
  3278. :modal="false"
  3279. >
  3280. <el-radio v-model="radio" :label="1">吨(T)</el-radio>
  3281. <el-radio v-model="radio" :label="2">千克(KG)</el-radio>
  3282. <div id="print_area6" class="print-div">
  3283. <div
  3284. class="print-title"
  3285. style="
  3286. display: flex;
  3287. justify-content: center;
  3288. font-size: 24px;
  3289. margin-bottom: 5px;
  3290. "
  3291. >
  3292. {{ company }}
  3293. </div>
  3294. <div
  3295. style="
  3296. display: flex;
  3297. justify-content: center;
  3298. margin-left: 350px;
  3299. margin-bottom: 5px;
  3300. "
  3301. >
  3302. <div style="font-size: 18px">出&nbsp;库&nbsp;单</div>
  3303. <div style="margin-left: 200px">
  3304. <div style="margin-bottom: 5px">{{ form.fBillno }}</div>
  3305. <div>存放地点:{{ stockName }}</div>
  3306. </div>
  3307. </div>
  3308. <div class="print_table" style="display: flex">
  3309. <table
  3310. border="0"
  3311. cellspacing="0"
  3312. cellpadding="0"
  3313. style="width: 100%; line-height: 30px"
  3314. >
  3315. <tr>
  3316. <td>品名</td>
  3317. <td colspan="2">{{ form.fProductName }}</td>
  3318. <td>清单号</td>
  3319. <td colspan="3">{{ form.fCustomsdeclartion }}</td>
  3320. </tr>
  3321. <tr>
  3322. <td>提单号</td>
  3323. <td colspan="2">{{ form.fMblno }}</td>
  3324. <td>出库日期</td>
  3325. <td colspan="3">{{ fBsdate }}</td>
  3326. </tr>
  3327. <tr>
  3328. <td>原入库箱号</td>
  3329. <td>出库车号</td>
  3330. <td>铅封号</td>
  3331. <td>垛位</td>
  3332. <td>件数</td>
  3333. <td v-if="radio == 1">净重(吨)</td>
  3334. <td v-else>净重(千克)</td>
  3335. <td>备注</td>
  3336. </tr>
  3337. <tr v-for="(item, index) in Printinglist" :key="index">
  3338. <td>{{ item.fCntrno }}</td>
  3339. <td>{{ item.fTruckno }}</td>
  3340. <td>{{ item.fSealno }}</td>
  3341. <td>{{ item.fWarehouseInformation }}</td>
  3342. <td>{{ item.fQty }}</td>
  3343. <td v-if="radio == 1">{{ item.fNetweight }}</td>
  3344. <td v-else>{{ (item.fNetweight / 1000).toFixed(4) }}</td>
  3345. <td>{{ item.remark }}</td>
  3346. </tr>
  3347. <tr>
  3348. <td colspan="4">合计:</td>
  3349. <td>{{ allfQty }}</td>
  3350. <td v-if="radio == 1">{{ (allfNetweight / 1000).toFixed(4) }}</td>
  3351. <td v-else>{{ allfNetweight }}</td>
  3352. <td></td>
  3353. </tr>
  3354. </table>
  3355. </div>
  3356. <div
  3357. style="display: flex; justify-content: space-between; font-size: 12px"
  3358. >
  3359. <div>库管:{{ form.fContacts }}</div>
  3360. <div style="width: 130px;margin-right: 20px">叉车:</div>
  3361. </div>
  3362. <div
  3363. style="display: flex; justify-content: space-between; font-size: 12px"
  3364. >
  3365. <div>制单人:{{ form.createBy }}</div>
  3366. <div style="width: 100px">初审核人:{{ firstReviewer }}</div>
  3367. <div style="width: 130px;margin-right: 20px">复式审核人:{{ secondReviewer }}</div>
  3368. </div>
  3369. </div>
  3370. <span slot="footer" class="dialog-footer">
  3371. <el-button
  3372. type="primary"
  3373. @click="
  3374. addprint('ccckd');
  3375. print_ccckd = false;
  3376. "
  3377. >打印
  3378. </el-button>
  3379. <el-button @click="print_ccckd = false">取消 </el-button>
  3380. </span>
  3381. </el-dialog>
  3382. <el-dialog
  3383. :visible.sync="print_dcckd"
  3384. width="70%"
  3385. :close-on-click-modal="false"
  3386. :modal="false"
  3387. >
  3388. <el-radio v-model="radio" :label="1">吨(T)</el-radio>
  3389. <el-radio v-model="radio" :label="2">千克(KG)</el-radio>
  3390. <div id="print_area7" class="print-div">
  3391. <div
  3392. class="print-title"
  3393. style="
  3394. display: flex;
  3395. justify-content: center;
  3396. font-size: 24px;
  3397. margin-bottom: 5px;
  3398. "
  3399. >
  3400. {{ company }}
  3401. </div>
  3402. <div
  3403. style="
  3404. display: flex;
  3405. justify-content: center;
  3406. margin-left: 350px;
  3407. margin-bottom: 5px;
  3408. "
  3409. >
  3410. <div style="font-size: 18px">出&nbsp;库&nbsp;单</div>
  3411. <div style="margin-left: 200px">
  3412. <div style="margin-bottom: 5px">{{ form.fBillno }}</div>
  3413. </div>
  3414. </div>
  3415. <div style="display: flex; margin-bottom: 5px">
  3416. <div style="width: 50%">客户名称:{{ form.fCorpidName }}</div>
  3417. <div style="margin-left: 250px">存放地点:{{ stockName }}</div>
  3418. </div>
  3419. <div class="print_table" style="display: flex">
  3420. <table
  3421. border="0"
  3422. cellspacing="0"
  3423. cellpadding="0"
  3424. style="width: 100%; line-height: 30px"
  3425. >
  3426. <tr>
  3427. <td>品名</td>
  3428. <td colspan="2">{{ form.fProductName }}</td>
  3429. <td>清单号</td>
  3430. <td colspan="4">{{ form.fCustomsdeclartion }}</td>
  3431. </tr>
  3432. <tr>
  3433. <td>提单号</td>
  3434. <td colspan="2">{{ form.fMblno }}</td>
  3435. <td>出库日期</td>
  3436. <td colspan="4">{{ fBsdate }}</td>
  3437. </tr>
  3438. <tr>
  3439. <td>原入库箱号</td>
  3440. <td>出库车号</td>
  3441. <td>铅封号</td>
  3442. <td>垛位</td>
  3443. <td>件数</td>
  3444. <td v-if="radio == 1">净重(吨)</td>
  3445. <td v-if="radio == 1">毛重(吨)</td>
  3446. <td v-if="radio == 2">净重(千克)</td>
  3447. <td v-if="radio == 2">毛重(千克)</td>
  3448. <td>备注</td>
  3449. </tr>
  3450. <tr v-for="(item, index) in Printinglist" :key="index">
  3451. <td>{{ item.fCntrno }}</td>
  3452. <td>{{ item.fTruckno }}</td>
  3453. <td>{{ item.fSealno }}</td>
  3454. <td>{{ item.fWarehouseInformation }}</td>
  3455. <td>{{ item.fQty }}</td>
  3456. <td v-if="radio == 1">{{ (item.fNetweight / 1000).toFixed(4) }}</td>
  3457. <td v-if="radio == 1">{{ (item.fGrossweight / 1000).toFixed(4) }}</td>
  3458. <td v-if="radio == 2">{{ item.fNetweight }}</td>
  3459. <td v-if="radio == 2">{{ item.fGrossweight }}</td>
  3460. <td>{{ item.remark }}</td>
  3461. </tr>
  3462. <tr>
  3463. <td colspan="4">合计:</td>
  3464. <td>{{ allfQty }}</td>
  3465. <td v-if="radio == 1">{{ (allfNetweight / 1000).toFixed(4) }}</td>
  3466. <td v-if="radio == 1">{{ (allfGrossweight / 1000).toFixed(4) }}</td>
  3467. <td v-if="radio == 2">{{ allfNetweight }}</td>
  3468. <td v-if="radio == 2">{{ allfGrossweight }}</td>
  3469. <td></td>
  3470. </tr>
  3471. </table>
  3472. </div>
  3473. <div
  3474. style="display: flex; justify-content: space-between; font-size: 12px"
  3475. >
  3476. <div>库管:{{ form.fContacts }}</div>
  3477. </div>
  3478. </div>
  3479. <span slot="footer" class="dialog-footer">
  3480. <el-button
  3481. type="primary"
  3482. @click="
  3483. addprint('dcckd');
  3484. print_dcckd = false;
  3485. "
  3486. >打印
  3487. </el-button>
  3488. <el-button @click="print_dcckd = false">取消 </el-button>
  3489. </span>
  3490. </el-dialog>
  3491. <el-dialog
  3492. :visible.sync="print_zccdckd"
  3493. width="70%"
  3494. :close-on-click-modal="false"
  3495. :modal="false"
  3496. >
  3497. <el-radio v-model="radio" :label="1">吨(T)</el-radio>
  3498. <el-radio v-model="radio" :label="2">千克(KG)</el-radio>
  3499. <div id="print_area8" class="print-div">
  3500. <div
  3501. class="print-title"
  3502. style="
  3503. display: flex;
  3504. justify-content: center;
  3505. font-size: 24px;
  3506. margin-bottom: 5px;
  3507. "
  3508. >
  3509. {{ company }}
  3510. </div>
  3511. <div
  3512. style="
  3513. display: flex;
  3514. justify-content: center;
  3515. margin-left: 350px;
  3516. margin-bottom: 5px;
  3517. "
  3518. >
  3519. <div style="font-size: 18px">出&nbsp;库&nbsp;单</div>
  3520. <div style="margin-left: 200px">
  3521. <div style="margin-bottom: 5px">{{ form.fBillno }}</div>
  3522. </div>
  3523. </div>
  3524. <div style="display: flex; margin-bottom: 5px">
  3525. <div style="width: 50%">客户名称:{{ form.fCorpidName }}</div>
  3526. <div style="margin-left: 250px">存放地点:{{ stockName }}</div>
  3527. </div>
  3528. <div class="print_table" style="display: flex">
  3529. <table
  3530. border="0"
  3531. cellspacing="0"
  3532. cellpadding="0"
  3533. style="width: 100%; line-height: 30px"
  3534. >
  3535. <tr>
  3536. <td>品名</td>
  3537. <td colspan="3">{{ form.fProductName }}</td>
  3538. <td colspan="3">清单号</td>
  3539. <td colspan="3">{{ form.fCustomsdeclartion }}</td>
  3540. </tr>
  3541. <tr>
  3542. <td>提单号</td>
  3543. <td colspan="3">{{ form.fMblno }}</td>
  3544. <td colspan="3">出库日期</td>
  3545. <td colspan="3">{{ fBsdate }}</td>
  3546. </tr>
  3547. <tr>
  3548. <td>原入库箱号</td>
  3549. <td>出库车号</td>
  3550. <td>垛位</td>
  3551. <td>件数</td>
  3552. <td v-if="radio == 1">净重(吨)</td>
  3553. <td v-if="radio == 1">毛重(吨)</td>
  3554. <td v-if="radio == 2">净重(千克)</td>
  3555. <td v-if="radio == 2">毛重(千克)</td>
  3556. <td>提货人签字手印</td>
  3557. <td>提货人电话</td>
  3558. <td>所收费用</td>
  3559. <td>备注</td>
  3560. </tr>
  3561. <tr v-for="(item, index) in Printinglist" :key="index">
  3562. <td>{{ item.fCntrno }}</td>
  3563. <td>{{ item.fTruckno }}</td>
  3564. <td>{{ item.fWarehouseInformation }}</td>
  3565. <td>{{ item.fQty }}</td>
  3566. <td v-if="radio == 1">{{ (item.fNetweight / 1000).toFixed(4) }}</td>
  3567. <td v-if="radio == 1">{{ (item.fGrossweight / 1000).toFixed(4) }}</td>
  3568. <td v-if="radio == 2">{{ item.fNetweight }}</td>
  3569. <td v-if="radio == 2">{{ item.fGrossweight }}</td>
  3570. <td></td>
  3571. <td></td>
  3572. <td></td>
  3573. <td>{{ item.remark }}</td>
  3574. </tr>
  3575. <tr>
  3576. <td colspan="3">合计:</td>
  3577. <td>{{ allfQty }}</td>
  3578. <td v-if="radio == 1">{{ (allfNetweight / 1000).toFixed(4) }}</td>
  3579. <td v-if="radio == 1">{{ (allfGrossweight / 1000).toFixed(4) }}</td>
  3580. <td v-if="radio == 2">{{ allfNetweight }}</td>
  3581. <td v-if="radio == 2">{{ allfGrossweight }}</td>
  3582. <td></td>
  3583. <td></td>
  3584. <td></td>
  3585. <td></td>
  3586. </tr>
  3587. </table>
  3588. </div>
  3589. <div
  3590. style="display: flex; justify-content: space-between; font-size: 12px;margin-bottom: 20px"
  3591. >
  3592. <div>库管:{{ form.fContacts }}</div>
  3593. <div style="width: 130px;margin-right: 20px">叉车:</div>
  3594. </div>
  3595. <div
  3596. style="display: flex; justify-content: space-between; font-size: 12px"
  3597. >
  3598. <div>制单人:{{ form.createBy }}</div>
  3599. <div style="width: 100px">初审核人:{{ firstReviewer }}</div>
  3600. <div style="width: 130px;margin-right: 20px">复式审核人:{{ secondReviewer }}</div>
  3601. </div>
  3602. </div>
  3603. <span slot="footer" class="dialog-footer">
  3604. <el-button
  3605. type="primary"
  3606. @click="
  3607. addprint('zccdckd');
  3608. print_zccdckd = false;
  3609. "
  3610. >打印
  3611. </el-button>
  3612. <el-button @click="print_zccdckd = false">取消 </el-button>
  3613. </span>
  3614. </el-dialog>
  3615. <!-- 选择作业费协议数据 -->
  3616. <el-dialog
  3617. v-dialogDrag
  3618. title="作业费协议"
  3619. :close-on-click-modal="false"
  3620. :modal="false"
  3621. style="box-shadow: 0 1px 3px rgba(0, 0, 0, 0) !important"
  3622. :visible.sync="warehousingagreements"
  3623. width="70%"
  3624. >
  3625. <template slot="作业费协议">
  3626. <div class="avue-crud__dialog__header">
  3627. <span class="el-dialog__title">
  3628. <span
  3629. style="
  3630. display: inline-block;
  3631. width: 3px;
  3632. height: 20px;
  3633. margin-right: 5px;
  3634. float: left;
  3635. margin-top: 2px;
  3636. "
  3637. ></span>
  3638. </span>
  3639. </div>
  3640. </template>
  3641. <el-menu
  3642. :default-active="activeIndex"
  3643. v-if="Navigation === true"
  3644. class="el-menu-demo"
  3645. mode="horizontal"
  3646. @select="handleSelect"
  3647. >
  3648. <el-menu-item index="1">车队作业费</el-menu-item>
  3649. <el-menu-item index="2">劳务作业费</el-menu-item>
  3650. </el-menu>
  3651. <el-table
  3652. :data="tasklegList"
  3653. ref="table"
  3654. tooltip-effect="dark"
  3655. width="100%"
  3656. border
  3657. stripe
  3658. @selection-change="whgenlegSelectionChange"
  3659. >
  3660. <el-table-column type="selection" width="55"></el-table-column>
  3661. <el-table-column label="行号" type="index" width="80">
  3662. </el-table-column>
  3663. <el-table-column
  3664. prop="fCorpname"
  3665. header-align="center"
  3666. align="center"
  3667. label="客户名称"
  3668. />
  3669. <el-table-column
  3670. prop="fName"
  3671. header-align="center"
  3672. align="center"
  3673. label="费用名称"
  3674. />
  3675. <el-table-column
  3676. prop="fFeeUnitid"
  3677. header-align="center"
  3678. align="center"
  3679. width="180px"
  3680. label="计价单位"
  3681. >
  3682. <template slot-scope="scope">
  3683. <el-select
  3684. v-model="scope.row.fFeeUnitid"
  3685. placeholder="请选择计价单位"
  3686. @change="changeFeeUnit(scope.row)"
  3687. disabled
  3688. clearable
  3689. >
  3690. <el-option
  3691. v-for="(dict, index) in fFeetUnitOptions"
  3692. :key="index.dictValue"
  3693. :label="dict.dictLabel"
  3694. :value="dict.dictValue"
  3695. />
  3696. </el-select>
  3697. </template>
  3698. </el-table-column>
  3699. <el-table-column
  3700. prop="fPrice"
  3701. header-align="center"
  3702. align="center"
  3703. label="单价"
  3704. width="100px"
  3705. />
  3706. <el-table-column
  3707. prop="remark"
  3708. header-align="center"
  3709. align="center"
  3710. label="备注"
  3711. />
  3712. </el-table>
  3713. <pagination
  3714. v-show="whgenlegTotal > 0"
  3715. :total="whgenlegTotal"
  3716. :page.sync="pageNum"
  3717. :limit.sync="pageSize"
  3718. @pagination="getWhgenlegList(key_id)"
  3719. />
  3720. <div slot="footer" class="dialog-footer">
  3721. <el-button type="primary" @click="zhgenlegData" :disabled="browseStatus">导 入</el-button>
  3722. <el-button
  3723. @click="
  3724. warehousingagreements = false;
  3725. Navigation = false;
  3726. "
  3727. >取 消
  3728. </el-button
  3729. >
  3730. </div>
  3731. </el-dialog>
  3732. <div style="display: flex; justify-content: flex-end; margin-top: 10px">
  3733. <!-- 弹窗, 新增 / 修改 -->
  3734. <add-or-update
  3735. v-if="addOrUpdateVisible"
  3736. ref="addOrUpdate"
  3737. @refreshDataList="getDataList"
  3738. ></add-or-update>
  3739. <approval-comments
  3740. v-if="addOrUpdateVisib"
  3741. ref="ApprovalComments"
  3742. @refreshDataList="returnData"
  3743. ></approval-comments>
  3744. <el-button
  3745. type="primary"
  3746. :disabled="approvalStatus"
  3747. v-if="form.fBillstatus > 3"
  3748. @click="addOrUpdateHandle(form, 'f_billstatus')"
  3749. >查看审批
  3750. </el-button
  3751. >
  3752. <el-button
  3753. type="primary"
  3754. v-if="approVal == true && form.fBillstatus >= 4 && form.fBillstatus < 6"
  3755. @click="addOrUpdateHand(form, 'f_billstatus')"
  3756. >审批
  3757. </el-button
  3758. >
  3759. <el-button type="success" prop="打印" @click="print_shd = true"
  3760. >收货单
  3761. </el-button>
  3762. <el-button type="warning" prop="打印" @click="print_rkd = true"
  3763. >出库单
  3764. </el-button>
  3765. <el-button @click="discharge" :disabled="browseStatus">卸货</el-button>
  3766. <el-button type="info" prop="打印" @click="print_zyd = true"
  3767. >作业单
  3768. </el-button>
  3769. <el-button :disabled="browseStatus" type="primary" @click="saveForm()"
  3770. >保 存
  3771. </el-button
  3772. >
  3773. <el-button
  3774. :disabled="form.fBillstatus > 3"
  3775. style="background-color: #008000; color: #fff"
  3776. @click="submitForm()"
  3777. >请核
  3778. </el-button
  3779. >
  3780. <el-button type="danger" v-if="form.fBillstatus === 6" @click="revoke"
  3781. >撤销请核
  3782. </el-button
  3783. >
  3784. <el-button
  3785. type="danger"
  3786. v-if="form.fBillstatus === 4 && current == before"
  3787. :disabled="doNot"
  3788. @click="revokeTwo('f_billstatus')"
  3789. >撤销审批
  3790. </el-button
  3791. >
  3792. <el-button @click="cancel">取 消</el-button>
  3793. </div>
  3794. </div>
  3795. </template>
  3796. <script>
  3797. import print from "print-js";
  3798. import {selectUserByRole} from "@/api/basicdata/warehouse"
  3799. import {
  3800. addWhgenleg,
  3801. listWarehousebills,
  3802. getWarehousebills,
  3803. delWarehousebills,
  3804. addWarehousebills,
  3805. updateCredit,
  3806. addJoblist,
  3807. disChargelist,
  3808. warehouseSubmission,
  3809. updateWarehousebills,
  3810. exportWarehousebills,
  3811. revokeTwo,
  3812. revoke,
  3813. delOutStock_s,
  3814. serialNumber,
  3815. submitWarehousingApproval,
  3816. ordersRevoke,
  3817. checkCode,
  3818. deliveryCalculation,
  3819. matchWarehouse,
  3820. queryReviewer,
  3821. feesCheck,
  3822. revokefeeCheck
  3823. } from "@/api/warehouseBusiness/warehouseOutStock";
  3824. import {operationAgreement} from "@/api/agreement/agreement";
  3825. import {listCorps} from "@/api/basicdata/corps";
  3826. import {listFees, getFees} from "@/api/basicdata/fees";
  3827. import {
  3828. listWarehouse,
  3829. treeselect,
  3830. listWarehousesss,
  3831. deliveryDetails
  3832. } from "@/api/basicdata/warehouse";
  3833. import {listGoods} from "@/api/basicdata/goods";
  3834. import {listCntrs} from "@/api/basicdata/cntr";
  3835. import {listUser, queryUserVal} from "@/api/system/user";
  3836. import {listWhgenleg} from "@/api/reportManagement/whgenleg";
  3837. import ApprovalComments from "@/views/startApproval";
  3838. import AddOrUpdate from "@/views/viewApproval";
  3839. import Global from "@/layout/components/global";
  3840. import Treeselect from "@riophae/vue-treeselect";
  3841. import "@riophae/vue-treeselect/dist/vue-treeselect.css";
  3842. import UploadFile from "@/components/Uploadfile";
  3843. import Cookies from "js-cookie";
  3844. import {getToken} from "@/utils/auth";
  3845. import {addSet, select, resetModule} from "@/api/system/set";
  3846. import upLoad from "../components/upLoad";
  3847. import draggable from "vuedraggable";
  3848. import {queryClerkRoleList} from "@/api/warehouseBusiness/warehouseInStock";
  3849. import { listCharge } from "@/api/system/viewApproval";
  3850. import { getDept } from "@/api/basicdata/dept";
  3851. export default {
  3852. name: "inStock",
  3853. props: {
  3854. chiId: {
  3855. type: Number,
  3856. required: null,
  3857. },
  3858. copyStatus: {
  3859. type: Number,
  3860. required: null,
  3861. },
  3862. },
  3863. components: {
  3864. UploadFile,
  3865. Treeselect,
  3866. AddOrUpdate,
  3867. ApprovalComments,
  3868. draggable,
  3869. upLoad,
  3870. },
  3871. data() {
  3872. return {
  3873. radio: 1,
  3874. nowTime: null,
  3875. pageNum: 1,
  3876. pageSize: 10,
  3877. dialogWhgenlegList: [],
  3878. tasklegList: [],
  3879. Navigation: false,
  3880. key_id: "",
  3881. warehousingagreements: false,
  3882. mblnoStatus: "",
  3883. selectloading: false,
  3884. fMblnoOptions: [],
  3885. warehouseDrList: [],
  3886. relevantAttachments: [],
  3887. warehouseCrList: [],
  3888. fStltypeOptions: [],
  3889. form: {},
  3890. rules: {
  3891. fDeptid: [{required: true, message: " ", trigger: "blur"}],
  3892. fBsdeptid: [{required: true, message: " ", trigger: "blur"}],
  3893. fCorpid: [{required: true, message: " ", trigger: "blur"}],
  3894. fChargedate: [{required: true, message: " ", trigger: "blur"}],
  3895. fMarks: [{required: true, message: " ", trigger: "blur"}],
  3896. fBsdate: [{required: true, message: " ", trigger: "blur"}],
  3897. fTrademodeid: [{required: true, message: " ", trigger: "blur"}],
  3898. fSbu: [{required: true, message: " ", trigger: "blur"}],
  3899. fBusinessType: [{required: true, message: " ", trigger: "blur"}],
  3900. fStorekeeper: {required: true, message: " ", trigger: "blur"},
  3901. fWarehouseid: [{required: true, message: " ", trigger: "blur"}],
  3902. fbillingway: [{required: true, message: " ", trigger: "blur"}],
  3903. fTocorpid: [{required: true, message: " ", trigger: "blur"}],
  3904. fFeetUnit: [{required: true, message: " ", trigger: "blur"}],
  3905. },
  3906. browseStatus: false,
  3907. goodsOptions: [],
  3908. warehouseOptions: [],
  3909. warehouseSwitching: [],
  3910. userOptions: [],
  3911. businessTypeOption: [],
  3912. fCompanyOptIons: [],
  3913. fleetOptions: [],
  3914. fFeetUnitOptions: [],
  3915. current: "",
  3916. before: "",
  3917. contrOl: false,
  3918. isrequired: 2,
  3919. isrequired2: 2,
  3920. detailsHidden: false,
  3921. CntrTable: [],
  3922. cntrList: [],
  3923. fTrademodeidOptions: [],
  3924. fIfweighOptions: [],
  3925. fSbuOptions: [],
  3926. collapselist: ["1"],
  3927. fStorageTypeOptions: [],
  3928. weightList: false,
  3929. sumMum: 0,
  3930. detailList: [],
  3931. print_zyd: false,
  3932. print_shd: false,
  3933. print_rkd: false,
  3934. print_lhd: false,
  3935. print_signFor: false,
  3936. print_hwqr: false,
  3937. print_lwqr: false,
  3938. print_dpxx: false,
  3939. print_ccckd: false,
  3940. print_dcckd: false,
  3941. print_zccdckd: false,
  3942. print_bzckd: false,
  3943. print_xqckd: false,
  3944. company: "",
  3945. Printinglist: [],
  3946. // 收款信息明细
  3947. PrintingCrlist: [],
  3948. allCrfAmount: 0,
  3949. allCrfQty: 0,
  3950. //库位
  3951. stockName: "",
  3952. //库位地址
  3953. stockaddr: "",
  3954. Collectionoptionss: [],
  3955. fDriverTel: "",
  3956. fBsdate: "",
  3957. fTruckno: "",
  3958. allfCntqty: 0,
  3959. allfGrossweight: 0,
  3960. allfNetweight: 0,
  3961. allfQty: 0,
  3962. fixdetaiNum: null,
  3963. dataListSelection: [],
  3964. deliveryConfirmation: true,
  3965. cancelDelivery: true,
  3966. dataWithdrawList: [],
  3967. title: "",
  3968. fCNameOptions: [],
  3969. fDNameOptions: [],
  3970. whgenlegTotal: 0,
  3971. fGrossweight: 0,
  3972. fQty: 0,
  3973. fNetweight: 0,
  3974. fCntqty: 0,
  3975. activeIndex: "1",
  3976. ifCntrnoStatus: null,
  3977. addOrUpdateVisible: false,
  3978. addOrUpdateVisib: false,
  3979. approVal: false,
  3980. approvalStatus: false,
  3981. doNot: false,
  3982. fCartypeOptions: [],
  3983. fIfdamageOptions: [],
  3984. whgenlegList: [],
  3985. releaseList: [
  3986. {dictLabel: "已放行", dictValue: "T"},
  3987. {dictLabel: "未放行", dictValue: "F"},
  3988. ],
  3989. whgenlegVisible: false,
  3990. whgenlegParams: {
  3991. pageNum: 1,
  3992. pageSize: 10,
  3993. fCorpid: null,
  3994. fWarehouseid: null,
  3995. fTruckno: null,
  3996. fCntrno: null,
  3997. fMblno: null,
  3998. orgStorageDate: null,
  3999. fMarks: null
  4000. },
  4001. stockoi: null,
  4002. fSalesmanId: [],
  4003. drag: false,
  4004. tableDate: [
  4005. {
  4006. surface: "0",
  4007. label: "fBillstatus",
  4008. name: "状态",
  4009. checked: 0,
  4010. width: 80,
  4011. fixed: "left",
  4012. },
  4013. {
  4014. surface: "1",
  4015. label: "fBsdate",
  4016. name: "出库日期",
  4017. checked: 0,
  4018. width: 200,
  4019. fixed: "left",
  4020. },
  4021. {
  4022. surface: "2",
  4023. label: "fMblno",
  4024. name: "提单号",
  4025. checked: 0,
  4026. width: 100,
  4027. },
  4028. {
  4029. surface: "3",
  4030. label: "fGoodsid",
  4031. name: "品名",
  4032. checked: 0,
  4033. width: 100,
  4034. },
  4035. {
  4036. surface: "4",
  4037. label: "fBusinessType",
  4038. name: "货物属性",
  4039. checked: 0,
  4040. width: 100,
  4041. },
  4042. {
  4043. surface: "5",
  4044. label: "fMarks",
  4045. name: "属性详情",
  4046. checked: 0,
  4047. width: 100,
  4048. },
  4049. {
  4050. surface: "6",
  4051. label: "fWarehouseInformation",
  4052. name: "库区",
  4053. checked: 0,
  4054. width: 150,
  4055. },
  4056. {
  4057. surface: "7",
  4058. label: "fPlanqty",
  4059. name: "结余库存",
  4060. checked: 0,
  4061. width: 100,
  4062. },
  4063. {
  4064. surface: "8",
  4065. label: "fPlangrossweight",
  4066. name: "结余毛重(kg)",
  4067. checked: 0,
  4068. width: 120,
  4069. },
  4070. {
  4071. surface: "9",
  4072. label: "fPlannetweight",
  4073. name: "结余净重(kg)",
  4074. checked: 0,
  4075. width: 120,
  4076. },
  4077. {
  4078. surface: "10",
  4079. label: "fQty",
  4080. name: "出库件数",
  4081. checked: 0,
  4082. width: 100,
  4083. },
  4084. {
  4085. surface: "11",
  4086. label: "fGrossweight",
  4087. name: "出库毛重(kg)",
  4088. checked: 0,
  4089. width: 120,
  4090. },
  4091. {
  4092. surface: "12",
  4093. label: "fNetweight",
  4094. name: "出库净重(kg)",
  4095. checked: 0,
  4096. width: 120,
  4097. },
  4098. {
  4099. surface: "13",
  4100. label: "fPackagespecs",
  4101. name: "包装规格",
  4102. checked: 0,
  4103. width: 100,
  4104. },
  4105. {
  4106. surface: "14",
  4107. label: "fCntrtype",
  4108. name: "箱型",
  4109. checked: 0,
  4110. width: 100,
  4111. },
  4112. {
  4113. surface: "15",
  4114. label: "fCntqty",
  4115. name: "箱量",
  4116. checked: 0,
  4117. width: 100,
  4118. },
  4119. {
  4120. surface: "16",
  4121. label: "fCntrno",
  4122. name: "箱号",
  4123. checked: 0,
  4124. width: 100,
  4125. },
  4126. {
  4127. surface: "17",
  4128. label: "fGoodsval",
  4129. name: "货值",
  4130. checked: 0,
  4131. width: 100,
  4132. },
  4133. {
  4134. surface: "18",
  4135. label: "fFleet",
  4136. name: "车队",
  4137. checked: 0,
  4138. width: 100,
  4139. },
  4140. {
  4141. surface: "19",
  4142. label: "fTruckno",
  4143. name: "车号",
  4144. checked: 0,
  4145. width: 100,
  4146. },
  4147. {
  4148. surface: "20",
  4149. label: "fDriverName",
  4150. name: "司机名称",
  4151. checked: 0,
  4152. width: 100,
  4153. },
  4154. {
  4155. surface: "21",
  4156. label: "fDriverTel",
  4157. name: "司机电话",
  4158. checked: 0,
  4159. width: 100,
  4160. },
  4161. {
  4162. surface: "22",
  4163. label: "fDriverIdCar",
  4164. name: "司机身份证",
  4165. checked: 0,
  4166. width: 150,
  4167. },
  4168. {
  4169. surface: "23",
  4170. label: "fIsPass",
  4171. name: "是否放行",
  4172. checked: 0,
  4173. width: 150,
  4174. },
  4175. {
  4176. surface: "24",
  4177. label: "fLntype",
  4178. name: "装卸方式",
  4179. checked: 0,
  4180. width: 100,
  4181. },
  4182. {
  4183. surface: "25",
  4184. label: "fForkliftman",
  4185. name: "叉车工",
  4186. checked: 0,
  4187. width: 100,
  4188. },
  4189. {
  4190. surface: "26",
  4191. label: "fLocalcntrno",
  4192. name: "库内箱号",
  4193. checked: 0,
  4194. width: 100,
  4195. },
  4196. {
  4197. surface: "27",
  4198. label: "fSealno",
  4199. name: "封号",
  4200. checked: 0,
  4201. width: 100,
  4202. },
  4203. {
  4204. surface: "28",
  4205. label: "fSerialNumber",
  4206. name: "流水号",
  4207. checked: 0,
  4208. width: 100,
  4209. },
  4210. {
  4211. surface: "29",
  4212. label: "remark",
  4213. name: "备注",
  4214. checked: 0,
  4215. width: 100,
  4216. }, {
  4217. surface: "30",
  4218. label: "fNowCarton",
  4219. name: "现箱号",
  4220. checked: 0,
  4221. width: 100,
  4222. }, {
  4223. surface: "31",
  4224. label: "fCartypeId",
  4225. name: "车辆类型",
  4226. checked: 0,
  4227. width: 100,
  4228. }
  4229. ],
  4230. cartypeId:[],
  4231. setRowList: [],
  4232. getRowList: [],
  4233. allCheck: false,
  4234. showSetting: false,
  4235. tableDate2: [
  4236. {
  4237. surface: "1",
  4238. label: "fMblno",
  4239. name: "提单号",
  4240. checked: 0,
  4241. width: 150,
  4242. },
  4243. {
  4244. surface: "2",
  4245. label: "fOriginalbilldate",
  4246. name: "入库日期",
  4247. checked: 0,
  4248. width: 100,
  4249. },
  4250. {
  4251. surface: "3",
  4252. label: "fGoodsid",
  4253. name: "品名",
  4254. checked: 0,
  4255. width: 100,
  4256. },
  4257. {
  4258. surface: "4",
  4259. label: "fCntrno",
  4260. name: "箱号",
  4261. checked: 0,
  4262. width: 100,
  4263. },
  4264. {
  4265. surface: "5",
  4266. label: "fQtyblc",
  4267. name: "结余数量",
  4268. checked: 0,
  4269. width: 150,
  4270. },
  4271. {
  4272. surface: "6",
  4273. label: "fGrossweightblc",
  4274. name: "结余毛重(kg)",
  4275. checked: 0,
  4276. width: 150,
  4277. },
  4278. {
  4279. surface: "7",
  4280. label: "fNetweightblc",
  4281. name: "结余净重(kg)",
  4282. checked: 0,
  4283. width: 150,
  4284. },
  4285. {
  4286. surface: "8",
  4287. label: "fWarehouseids",
  4288. name: "库位",
  4289. checked: 0,
  4290. width: 150,
  4291. },
  4292. {
  4293. surface: "9",
  4294. label: "fMarks",
  4295. name: "品牌",
  4296. checked: 0,
  4297. width: 100,
  4298. },
  4299. {
  4300. surface: "10",
  4301. label: "fQtyblc2",
  4302. name: "数量",
  4303. checked: 0,
  4304. width: 100,
  4305. },
  4306. {
  4307. surface: "11",
  4308. label: "fGrossweightblc2",
  4309. name: "毛重(kg)",
  4310. checked: 0,
  4311. width: 100,
  4312. },
  4313. {
  4314. surface: "12",
  4315. label: "fNetweightblc2",
  4316. name: "净重(kg)",
  4317. checked: 0,
  4318. width: 100,
  4319. },
  4320. {
  4321. surface: "13",
  4322. label: "fLocalcntrno",
  4323. name: "库内箱号",
  4324. checked: 0,
  4325. width: 100,
  4326. },
  4327. ],
  4328. setRowList2: [],
  4329. getRowList2: [],
  4330. allCheck2: false,
  4331. showSetting2: false,
  4332. detailsHidden2: true,
  4333. unloadModes: [],
  4334. dataShowcar: null,
  4335. tfNetweightnum: 0,
  4336. tfGrossweightnum: 0,
  4337. showApproval: null,
  4338. allfPlanqty: 0,
  4339. ckTime: null,
  4340. entryPrinting: 1,
  4341. // 滚动加载显示
  4342. isFlag: false,
  4343. // Cr打印弹窗是否开启
  4344. print_Cr: false,
  4345. zcList: [],
  4346. // 初级审核人
  4347. firstReviewer: '',
  4348. // 复级审核人
  4349. secondReviewer: '',
  4350. };
  4351. },
  4352. computed: {
  4353. noMore() {
  4354. return false
  4355. },
  4356. loadDisabled() {
  4357. return this.isFlag || this.noMore
  4358. },
  4359. },
  4360. created() {
  4361. this.setRowList = this.tableDate;
  4362. this.getRowList = this.tableDate;
  4363. this.setRowList2 = this.tableDate2;
  4364. this.getRowList2 = this.tableDate2;
  4365. this.getConfigKey("data_showcar").then((response) => {
  4366. this.dataShowcar = response.msg;
  4367. if (this.dataShowcar == "0") {
  4368. this.detailsHidden2 = false;
  4369. } else {
  4370. this.detailsHidden2 = true;
  4371. }
  4372. });
  4373. selectUserByRole().then(res => {
  4374. this.fSalesmanId = res.rows
  4375. })
  4376. this.getConfigKey("entry.printing").then((response) => {
  4377. this.entryPrinting = response.msg;
  4378. });
  4379. this.getDicts("data_stltype_type").then((response) => {
  4380. this.fStltypeOptions = response.data;
  4381. });
  4382. this.getDicts("st_out_type").then((response) => {
  4383. this.businessTypeOption = response.data;
  4384. localStorage.setItem("businessTypeList", JSON.stringify(response.data));
  4385. });
  4386. this.getDicts("data_unitfees").then((response) => {
  4387. this.fFeetUnitOptions = response.data;
  4388. });
  4389. this.getDicts("data_trademodes").then((response) => {
  4390. this.fTrademodeidOptions = response.data;
  4391. });
  4392. this.getDicts("data_ifweigh_status").then((response) => {
  4393. this.fIfweighOptions = response.data;
  4394. });
  4395. this.getDicts("storage_type").then((response) => {
  4396. this.fStorageTypeOptions = response.data;
  4397. localStorage.setItem("fStorageTypeList", JSON.stringify(response.data));
  4398. });
  4399. this.getDicts("sys_car_type").then((response) => {
  4400. this.fCartypeOptions = response.data;
  4401. });
  4402. this.getDicts("sys_car_type").then((response) => {
  4403. this.cartypeId = response.data;
  4404. this.cartypeId.forEach(item =>{
  4405. item.dictValue = Number(item.dictValue)
  4406. })
  4407. });
  4408. this.getDicts("data_ifdamage_status").then((response) => {
  4409. this.fIfdamageOptions = response.data;
  4410. });
  4411. this.getConfigKey("stockoi").then((response) => {
  4412. this.stockoi = response.msg;
  4413. });
  4414. this.getConfigKey("outStock.orders.approvalFlow").then((response) => {
  4415. this.showApproval = response.msg;
  4416. });
  4417. listWarehousesss({fStatus: 0, delFlag: 0}).then((response) => {
  4418. this.warehouseOptions = response.rows;
  4419. });
  4420. listFees({fDc: "C"}).then((response) => {
  4421. this.fCNameOptions = response.rows;
  4422. });
  4423. listFees({fDc: "D"}).then((response) => {
  4424. this.fDNameOptions = response.rows;
  4425. });
  4426. listCorps({type: 1}).then((response) => {
  4427. this.fMblnoOptions = response.rows;
  4428. });
  4429. listCorps().then((response) => {
  4430. this.fSbuOptions = response.rows;
  4431. });
  4432. queryClerkRoleList().then((response) => {
  4433. this.userOptions = response.data;
  4434. });
  4435. listGoods({fStatus: 0, delFlag: 0}).then((response) => {
  4436. this.goodsOptions = response.rows;
  4437. });
  4438. listCntrs({fStatus: "T"}).then((response) => {
  4439. this.cntrList = response.rows;
  4440. });
  4441. listCorps({fTypeid: 6}).then((response) => {
  4442. this.fCompanyOptIons = response.rows;
  4443. });
  4444. listCorps({fTypeid: 2}).then((response) => {
  4445. this.fleetOptions = response.rows;
  4446. });
  4447. this.getDicts("unload_mode").then((response) => {
  4448. this.unloadModes = response.data;
  4449. });
  4450. this.company = Cookies.get("companyName")
  4451. this.queryUser();
  4452. this.getRow();
  4453. this.getRow2();
  4454. },
  4455. filters: {
  4456. fBsdateFormat(row) {
  4457. if (row) {
  4458. const dateMat = new Date(row);
  4459. const year = dateMat.getFullYear();
  4460. const month = dateMat.getMonth() + 1;
  4461. const day = dateMat.getDate();
  4462. const timeFormat = year + "-" + month + "-" + day;
  4463. return timeFormat;
  4464. }
  4465. },
  4466. fStorageFormat(row) {
  4467. let name;
  4468. for (const item of JSON.parse(localStorage.getItem("fStorageTypeList"))) {
  4469. if (row == item.dictValue) {
  4470. name = item.dictLabel;
  4471. }
  4472. }
  4473. return name;
  4474. },
  4475. fBusinessTypeFormat(row) {
  4476. let name;
  4477. for (const item of JSON.parse(localStorage.getItem("businessTypeList"))) {
  4478. if (row == item.dictValue) {
  4479. name = item.dictLabel;
  4480. }
  4481. }
  4482. return name;
  4483. },
  4484. goodsFormat(row, goodsOptions) {
  4485. let goods;
  4486. goodsOptions.map((e) => {
  4487. if (row == e.fId) {
  4488. goods = e.fName;
  4489. }
  4490. });
  4491. return goods;
  4492. },
  4493. fFeetFormat(row, fCNameOptions) {
  4494. let name;
  4495. fCNameOptions.map((e) => {
  4496. if (row == e.fId) {
  4497. name = e.fName;
  4498. }
  4499. });
  4500. return name;
  4501. },
  4502. fMblnoFormat(row, fMblnoOptions) {
  4503. let name;
  4504. fMblnoOptions.map((e) => {
  4505. if (row == e.fId) {
  4506. name = e.fName;
  4507. }
  4508. });
  4509. return name;
  4510. },
  4511. fCartypeFormat(row, fCartypeOptions) {
  4512. let name;
  4513. fCartypeOptions.map((e) => {
  4514. if (row == e.dictValue) {
  4515. name = e.dictLabel;
  4516. }
  4517. });
  4518. return name;
  4519. },
  4520. fStorageTypeFormat(row, fStorageTypeOptions) {
  4521. let fStorageType;
  4522. fStorageTypeOptions.map((e) => {
  4523. if (row == e.dictValue) {
  4524. fStorageType = e.dictLabel;
  4525. }
  4526. });
  4527. return fStorageType;
  4528. },
  4529. fCartypeIdFormat(row, fCartypeId) {
  4530. let fCartype;
  4531. fCartypeId.map((e) => {
  4532. if (row == e.dictValue) {
  4533. fCartype = e.dictLabel;
  4534. }
  4535. });
  4536. return fCartype;
  4537. },
  4538. },
  4539. methods: {
  4540. init() {
  4541. this.approVal = false;
  4542. this.resetForm("form");
  4543. this.detailList = [];
  4544. this.relevantAttachments = [];
  4545. this.warehouseCrList = [];
  4546. this.warehouseDrList = [];
  4547. this.CntrTable = [];
  4548. if (this.dataShowcar == "0") {
  4549. this.detailsHidden2 = false;
  4550. } else {
  4551. this.detailsHidden2 = true;
  4552. }
  4553. if (this.$route.query.id) {
  4554. this.approVal = true;
  4555. this.$router.push({query: {}});
  4556. }
  4557. this.getForm();
  4558. },
  4559. init2() {
  4560. this.whgenlegParams = {
  4561. pageNum: 1,
  4562. pageSize: 10,
  4563. fCorpid: null,
  4564. fWarehouseid: null,
  4565. fTruckno: null,
  4566. fCntrno: null,
  4567. fMblno: null,
  4568. orgStorageDate: null,
  4569. };
  4570. },
  4571. tfNetweight(row) {
  4572. this.tfNetweightnum = (row / 1000).toFixed(4);
  4573. },
  4574. tfGrossweight(row) {
  4575. this.tfGrossweightnum = (row / 1000).toFixed(4);
  4576. },
  4577. //列设置全选
  4578. allChecked() {
  4579. if (this.allCheck == true) {
  4580. this.setRowList.map((e) => {
  4581. return (e.checked = 0);
  4582. });
  4583. } else {
  4584. this.setRowList.map((e) => {
  4585. return (e.checked = 1);
  4586. });
  4587. }
  4588. },
  4589. //查询列数据
  4590. getRow() {
  4591. let that = this;
  4592. this.data = {
  4593. tableName: "出库明细",
  4594. userId: Cookies.get("userName"),
  4595. };
  4596. select(this.data).then((res) => {
  4597. if (res.data.length != 0) {
  4598. this.getRowList = res.data.filter((e) => e.checked == 0);
  4599. this.setRowList = res.data;
  4600. this.setRowList = this.setRowList.reduce((res, item) => {
  4601. res.push({
  4602. surface: item.surface,
  4603. label: item.label,
  4604. name: item.name,
  4605. checked: item.checked,
  4606. width: item.width,
  4607. fixed: item.fixed,
  4608. });
  4609. return res;
  4610. }, []);
  4611. }
  4612. });
  4613. },
  4614. //重置列表
  4615. delRow() {
  4616. this.data = {
  4617. tableName: "出库明细",
  4618. userId: Cookies.get("userName"),
  4619. };
  4620. resetModule(this.data).then((res) => {
  4621. if (res.code == 200) {
  4622. this.showSetting = false;
  4623. this.setRowList = this.$options.data().tableDate;
  4624. this.getRowList = this.$options.data().tableDate;
  4625. }
  4626. });
  4627. },
  4628. //保存列设置
  4629. save() {
  4630. this.showSetting = false;
  4631. this.data = {
  4632. tableName: "出库明细",
  4633. userId: Cookies.get("userName"),
  4634. sysTableSetList: this.setRowList,
  4635. };
  4636. addSet(this.data).then((res) => {
  4637. if (res.code == 200) {
  4638. this.showSetting = false;
  4639. this.getRowList = this.setRowList.filter((e) => e.checked == 0);
  4640. }
  4641. });
  4642. },
  4643. //列设置全选
  4644. allChecked2() {
  4645. if (this.allCheck2 == true) {
  4646. this.setRowList2.map((e) => {
  4647. return (e.checked = 0);
  4648. });
  4649. } else {
  4650. this.setRowList2.map((e) => {
  4651. return (e.checked = 1);
  4652. });
  4653. }
  4654. },
  4655. //查询列数据
  4656. getRow2() {
  4657. let that = this;
  4658. this.data = {
  4659. tableName: "出库总账",
  4660. userId: Cookies.get("userName"),
  4661. };
  4662. select(this.data).then((res) => {
  4663. if (res.data.length != 0) {
  4664. this.getRowList2 = res.data.filter((e) => e.checked == 0);
  4665. this.setRowList2 = res.data;
  4666. this.setRowList2 = this.setRowList2.reduce((res, item) => {
  4667. res.push({
  4668. surface: item.surface,
  4669. label: item.label,
  4670. name: item.name,
  4671. checked: item.checked,
  4672. width: item.width,
  4673. fixed: item.fixed,
  4674. });
  4675. return res;
  4676. }, []);
  4677. }
  4678. });
  4679. },
  4680. calculationFAmt(row) {
  4681. row.fAmt = Number(row.fAmt)
  4682. if (row.fAmt) {
  4683. row.fAmt = row.fAmt.toFixed(2)
  4684. } else {
  4685. return false
  4686. }
  4687. },
  4688. //重置列表
  4689. delRow2() {
  4690. this.data = {
  4691. tableName: "出库总账",
  4692. userId: Cookies.get("userName"),
  4693. };
  4694. resetModule(this.data).then((res) => {
  4695. if (res.code == 200) {
  4696. this.showSetting2 = false;
  4697. this.setRowList2 = this.$options.data().tableDate2;
  4698. this.getRowList2 = this.$options.data().tableDate2;
  4699. }
  4700. });
  4701. },
  4702. //保存列设置
  4703. save2() {
  4704. this.showSetting2 = false;
  4705. this.data = {
  4706. tableName: "出库总账",
  4707. userId: Cookies.get("userName"),
  4708. sysTableSetList: this.setRowList2,
  4709. };
  4710. addSet(this.data).then((res) => {
  4711. if (res.code == 200) {
  4712. this.showSetting2 = false;
  4713. this.getRowList2 = this.setRowList2.filter((e) => e.checked == 0);
  4714. }
  4715. });
  4716. },
  4717. //开始拖拽事件
  4718. onStart() {
  4719. this.drag = true;
  4720. },
  4721. //拖拽结束事件
  4722. onEnd() {
  4723. this.drag = false;
  4724. },
  4725. // 修改毛重净重
  4726. changeOutStock(row) {
  4727. this.$refs['detailTable'].clearSelection()
  4728. let fNetweight = 0;
  4729. let fGrossweight = 0;
  4730. if (row.fNetweight) {
  4731. fNetweight = row.fNetweight;
  4732. }
  4733. if (row.fGrossweight) {
  4734. fGrossweight = row.fGrossweight;
  4735. }
  4736. if (row.fPlannetweight < fNetweight) {
  4737. this.$message({message: "出库净重超出结余净重", type: "warning"});
  4738. return false;
  4739. }
  4740. if (row.fPlangrossweight < fGrossweight) {
  4741. this.$message({message: "出库毛重超出结余毛重", type: "warning"});
  4742. return false;
  4743. }
  4744. },
  4745. // 出库件数的计算
  4746. qtyChange(row) {
  4747. // if (!row.fQty || row.fQty === "") {
  4748. // this.$set(row, "fNetweight", 0);
  4749. // this.$set(row, "fGrossweight", 0);
  4750. // return false;
  4751. // }
  4752. if (row.fPlanqty < row.fQty) {
  4753. this.$message.error("出库件数超出结余件数!");
  4754. this.$set(row, "fQty", 0);
  4755. this.$set(row, "fNetweight", 0);
  4756. this.$set(row, "fGrossweight", 0);
  4757. return false;
  4758. }
  4759. if (row.fQtyblc2 > row.fQtyblc) {
  4760. this.$message.error("出库件数超出结余件数!");
  4761. this.$set(row, "fQtyblc2", 0);
  4762. this.$set(row, "fGrossweightblc2", 0);
  4763. this.$set(row, "fNetweightblc2", 0);
  4764. return false;
  4765. }
  4766. this.$set(
  4767. row,
  4768. "fNetweight",
  4769. parseFloat(
  4770. (Number(row.fPlannetweight) / Number(row.fPlanqty)) * Number(row.fQty)
  4771. ).toFixed(2)
  4772. );
  4773. this.$set(
  4774. row,
  4775. "fGrossweight",
  4776. parseFloat(
  4777. (Number(row.fPlangrossweight) / Number(row.fPlanqty)) *
  4778. Number(row.fQty)
  4779. ).toFixed(2)
  4780. );
  4781. this.$set(
  4782. row,
  4783. "fNetweightblc2",
  4784. parseFloat(
  4785. (Number(row.fNetweightblc) / Number(row.fQtyblc)) *
  4786. Number(row.fQtyblc2)
  4787. ).toFixed(2)
  4788. );
  4789. this.$set(
  4790. row,
  4791. "fGrossweightblc2",
  4792. parseFloat(
  4793. (Number(row.fGrossweightblc) / Number(row.fQtyblc)) *
  4794. Number(row.fQtyblc2)
  4795. ).toFixed(2)
  4796. );
  4797. },
  4798. whgenlegData() {
  4799. if (this.dialogWhgenlegList.length === 0) {
  4800. this.$message({message: "未勾选信息", type: "warning"});
  4801. return false;
  4802. }
  4803. this.dialogWhgenlegList.map((e) => {
  4804. this.detailList.push({
  4805. fBsdate: this.form.fBsdate,
  4806. fId: null,
  4807. fMblno: e.fMblno,
  4808. fGoodsid: e.fGoodsid,
  4809. fCntrtype: null,
  4810. fPlanqty: e.fQtyblc,
  4811. fPlannetweight: e.fNetweightblc,
  4812. fPlangrossweight: e.fGrossweightblc,
  4813. fWarehouseLocationids: e.fWarehouseLocationids,
  4814. fGoodsids: e.fGoodsids,
  4815. fBillingway: e.fBillingway,
  4816. fChargedate: e.fChargedate,
  4817. fMarks: e.fMarks,
  4818. fOriginalbilldate: e.fOriginalbilldate,
  4819. fOriginalbillno: e.fOriginalbillno,
  4820. fPackagespecs: e.fPackagespecs,
  4821. fGrossweight: e.fGrossweightblc2,
  4822. fNetweight: e.fNetweightblc2,
  4823. fQty: e.fQtyblc2,
  4824. fCntqty: 1,
  4825. fBillstatus: 10,
  4826. fWarehouselocid: e.fWarehouseLocationid,
  4827. fWarehouselocids: e.fWarehouseLocationids,
  4828. fCntrno: e.fCntrno,
  4829. fGoodsval: null,
  4830. fTruckno: this.whgenlegList.fTruckno,
  4831. remark: null,
  4832. fIsPass: "F",
  4833. fDriverName: this.whgenlegList.fDriverName,
  4834. fDriverTel: this.whgenlegList.fDriverTel,
  4835. fDriverIdCar: this.whgenlegList.fDriverIdCar,
  4836. fBusinessType: e.fBusinessType ? e.fBusinessType.toString() : null,
  4837. fWarehouseInformation: e.fWarehouseids,
  4838. fSrcid: e.fId,
  4839. fSrcBsdate: e.fBsdate,
  4840. });
  4841. console.log(this.detailList)
  4842. });
  4843. this.whgenlegVisible = false;
  4844. },
  4845. //撤销请核
  4846. revoke() {
  4847. revoke(this.form.fId).then(async (data) => {
  4848. if (data.code === 200) {
  4849. this.browseStatus = false;
  4850. await getWarehousebills(this.form.fId).then((response) => {
  4851. this.form = response.data.warehousebills;
  4852. if (this.form.fBillstatus > 3) {
  4853. this.approvalStatus = false;
  4854. this.browseStatus = true;
  4855. } else {
  4856. this.approvalStatus = true;
  4857. this.browseStatus = false;
  4858. }
  4859. this.$set(this.form, "fBsdate", Date.parse(this.form.fBsdate));
  4860. this.$set(this.form, "fBstifime", Date.parse(this.form.fBstime));
  4861. this.$set(this.form, "createTime", Date.parse(this.form.createTime));
  4862. this.$set(this.form, "fFeetUnit", this.form.fFeetunit);
  4863. this.tfNetweightnum = (this.form.fPlannetweight / 1000).toFixed(4);
  4864. this.tfGrossweightnum = (this.form.fPlangrossweight / 1000).toFixed(4);
  4865. if (this.form.fCartype || this.form.fCartype == 0) {
  4866. this.$set(this.form, "fCartype", this.form.fCartype.toString());
  4867. }
  4868. if (this.form.fStltypeid || this.form.fStltypeid == 0) {
  4869. this.$set(this.form, "fStltypeid", this.form.fStltypeid.toString());
  4870. }
  4871. if (this.form.fTrademodeid) {
  4872. this.$set(
  4873. this.form,
  4874. "fTrademodeid",
  4875. this.form.fTrademodeid.toString()
  4876. );
  4877. }
  4878. if (!this.copyStatus) {
  4879. if (response.data.warehouseBillsItem) {
  4880. response.data.warehouseBillsItem.map((e) => {
  4881. e.fBsdate = Date.parse(e.fBsdate);
  4882. e.fBusinessType = e.fBusinessType.toString();
  4883. e.fLntype = e.fLntype ? e.fLntype.toString() : null;
  4884. });
  4885. this.detailList = response.data.warehouseBillsItem;
  4886. } else {
  4887. this.detailList = [];
  4888. }
  4889. response.data.warehousebillsfeesCr.map((e) => {
  4890. if (e.fFeeunitid) {
  4891. e.fFeeUnitid = e.fFeeunitid.toString();
  4892. }
  4893. if (e.fStltypeid || e.fStltypeid == 0) {
  4894. e.fStltypeid = e.fStltypeid.toString();
  4895. }
  4896. });
  4897. this.warehouseCrList = response.data.warehousebillsfeesCr;
  4898. response.data.warehousebillsfeesDr.map((e) => {
  4899. if (e.fFeeunitid) {
  4900. e.fFeeUnitid = e.fFeeunitid.toString();
  4901. }
  4902. if (e.fStltypeid || e.fStltypeid == 0) {
  4903. e.fStltypeid = e.fStltypeid.toString();
  4904. }
  4905. });
  4906. this.warehouseDrList = response.data.warehousebillsfeesDr;
  4907. this.warehouseDrList.forEach(item => item.fBillingway = JSON.stringify(item.fBillingway))
  4908. if (response.data.tCntrList) {
  4909. this.CntrTable = response.data.tCntrList;
  4910. } else {
  4911. this.CntrTable = [];
  4912. }
  4913. if (response.data.enclosures) {
  4914. this.relevantAttachments = response.data.enclosures;
  4915. }
  4916. } else {
  4917. this.$set(this.form, "fId", null);
  4918. this.$set(this.form, "fMblno", null);
  4919. this.$set(this.form, "fMarks", null);
  4920. this.$set(this.form, "fProductName",null);
  4921. this.$set(this.form, "fNetweight", 0);
  4922. this.$set(this.form, "fPlanvolumn", 0);
  4923. this.$set(this.form, "fGrossweight", 0);
  4924. }
  4925. });
  4926. this.warehouseCrList.forEach((item, index) => {
  4927. if (item.fQty != 0 && item.fUnitprice !== 0 && item.fAmount !==0) {
  4928. item.fBillstatus = 6;
  4929. }
  4930. })
  4931. let formData = new window.FormData();
  4932. formData.append("warehouseBills", JSON.stringify(this.form));
  4933. this.detailList.forEach(item => {
  4934. if (item.srcId !== null) {
  4935. // item.fStorageFeeDeadline = item.fBsdate
  4936. }
  4937. })
  4938. // 费用明细付款
  4939. formData.append(
  4940. "warehousebillsfeesCr",
  4941. JSON.stringify(this.warehouseCrList)
  4942. );
  4943. // 库存明细
  4944. formData.append(
  4945. "warehousebillsitems",
  4946. JSON.stringify(this.detailList)
  4947. );
  4948. formData.append(
  4949. "tEnclosure",
  4950. JSON.stringify(this.relevantAttachments)
  4951. );
  4952. // 收款
  4953. formData.append(
  4954. "warehousebillsfeesDr",
  4955. JSON.stringify(this.warehouseDrList)
  4956. );
  4957. formData.append("mblnoStatus", JSON.stringify(this.mblnoStatus));
  4958. formData.append("tCntr", JSON.stringify(this.CntrTable));
  4959. addWarehousebills(formData).then(res => {
  4960. })
  4961. this.msgSuccess("撤销成功");
  4962. }
  4963. });
  4964. },
  4965. ordersRevoke() {
  4966. ordersRevoke(this.form.fId).then((data) => {
  4967. if (data.code === 200) {
  4968. this.$set(this.form, "warehouseStatus", 2);
  4969. this.msgSuccess("撤销成功");
  4970. }
  4971. });
  4972. },
  4973. //撤销审批
  4974. revokeTwo(status) {
  4975. let data = {
  4976. actId: 120,
  4977. billId: this.form.fId,
  4978. id: this.form.fId,
  4979. fidStatus: status,
  4980. };
  4981. revokeTwo(data).then((data) => {
  4982. if (data.code === 200) {
  4983. this.browseStatus = false;
  4984. this.msgSuccess("撤销成功");
  4985. if (status) {
  4986. this.$set(this.form, "warehouseStatus", 2);
  4987. }
  4988. }
  4989. });
  4990. },
  4991. // 查看审批流
  4992. getDataList() {
  4993. this.addOrUpdateVisible = false;
  4994. },
  4995. returnData() {
  4996. this.addOrUpdateVisib = false;
  4997. this.$router.push({path: "/index"});
  4998. },
  4999. addOrUpdateHandle(form, status) {
  5000. this.addOrUpdateVisible = true;
  5001. this.$nextTick(() => {
  5002. this.$refs.addOrUpdate.init(form.fId, 120, status);
  5003. });
  5004. },
  5005. addOrUpdateHand(form, status) {
  5006. this.addOrUpdateVisib = true;
  5007. this.$nextTick(() => {
  5008. this.$refs.ApprovalComments.init(form.fId, status, 120);
  5009. });
  5010. },
  5011. judgmentWarehouse() {
  5012. if (this.form.fMblno && this.form.fCorpid) {
  5013. matchWarehouse({fMblno: this.form.fMblno, fCorpid: this.form.fCorpid}).then(res => {
  5014. this.warehouseSwitching = res.data
  5015. })
  5016. }
  5017. },
  5018. changefStltype(row) {
  5019. this.judgmentWarehouse()
  5020. this.fMblnoOptions.map((e) => {
  5021. if (row == e.fId) {
  5022. this.$set(this.form, "fStltypeid", e.fStltypeid.toString());
  5023. }
  5024. });
  5025. },
  5026. changeGoods(row) {
  5027. this.goodsOptions.map((e) => {
  5028. if (row == e.fId) {
  5029. if (e.ifCntrno == "1") {
  5030. this.ifCntrnoStatus = 1;
  5031. } else {
  5032. this.ifCntrnoStatus = null;
  5033. }
  5034. }
  5035. });
  5036. },
  5037. //确认打印签收单
  5038. Printing() {
  5039. this.$print(this.$refs.print)
  5040. },
  5041. discharge() {
  5042. let checkData = {
  5043. fId: this.form.fId,
  5044. fType: "warehouse",
  5045. codeVal: this.form.fDateChanged,
  5046. };
  5047. checkCode(checkData).then((response) => {
  5048. if (!response) {
  5049. this.$confirm("数据发生变化,请更新一下数据?", "提示", {
  5050. confirmButtonText: "确认",
  5051. cancelButtonText: "取消",
  5052. type: "warning",
  5053. }).then(() => {
  5054. this.getForm();
  5055. });
  5056. } else {
  5057. if (this.Printinglist.length > 0) {
  5058. for (let item in this.Printinglist) {
  5059. if (this.Printinglist[item].fBillstatus === 10) {
  5060. return this.$message.error("请先打印作业单");
  5061. }
  5062. if (
  5063. this.Printinglist[item].fBillstatus >= 30 &&
  5064. this.stockoi == "0"
  5065. ) {
  5066. return this.$message.error("请勿重复卸货");
  5067. }
  5068. }
  5069. if (this.CntrTable.length > 0) {
  5070. let arr = [];
  5071. this.CntrTable.map((e) => {
  5072. this.cntrList.map((item) => {
  5073. if (item.fId == e.fCntrid) {
  5074. arr.push(item.fName + "X" + e.fCntrcount);
  5075. }
  5076. });
  5077. });
  5078. arr = [...new Set(arr)];
  5079. this.form.fCntval = arr.join(",");
  5080. } else {
  5081. this.form.fCntval = null;
  5082. }
  5083. if (this.detailList.length > 0) {
  5084. let arr = [];
  5085. this.detailList.map((e) => {
  5086. this.goodsOptions.map((item) => {
  5087. if (e.fGoodsid == item.fId) {
  5088. arr.push(item.fName);
  5089. }
  5090. });
  5091. });
  5092. arr = [...new Set(arr)];
  5093. this.form.fProductName = arr.join(",");
  5094. } else {
  5095. this.form.fProductName = "";
  5096. }
  5097. if (this.detailList.length > 0) {
  5098. let arr = [];
  5099. this.detailList.map((e) => {
  5100. arr.push(e.fMarks);
  5101. });
  5102. arr = [...new Set(arr)];
  5103. this.form.fMarks = arr.join(",");
  5104. } else {
  5105. this.form.fMarks = "";
  5106. }
  5107. if (this.detailList.length == 0) {
  5108. this.form.fNetweight = 0;
  5109. this.form.fPlanvolumn = 0;
  5110. this.form.fGrossweight = 0;
  5111. } else {
  5112. this.form.fNetweight = this.fNetweight;
  5113. this.form.fPlanvolumn = this.fPlanvolumn;
  5114. this.form.fGrossweight = this.fGrossweight;
  5115. }
  5116. let formData = new window.FormData();
  5117. formData.append("warehouseBills", JSON.stringify(this.form));
  5118. formData.append(
  5119. "tEnclosure",
  5120. JSON.stringify(this.relevantAttachments)
  5121. );
  5122. formData.append(
  5123. "warehousebillsitems",
  5124. JSON.stringify(this.Printinglist)
  5125. );
  5126. formData.append(
  5127. "warehousebillsfeesDr",
  5128. JSON.stringify(this.warehouseDrList)
  5129. );
  5130. formData.append(
  5131. "warehousebillsfeesCr",
  5132. JSON.stringify(this.warehouseCrList)
  5133. );
  5134. formData.append("tCntr", JSON.stringify(this.CntrTable));
  5135. disChargelist(formData).then((response) => {
  5136. if ((response.code = 200)) {
  5137. this.$set(
  5138. this.form,
  5139. "fDateChanged",
  5140. response.data.fDateChanged
  5141. );
  5142. this.detailList.map((e, index) => {
  5143. response.data.warehousebillsitems.map((item) => {
  5144. item.fBsdate = Date.parse(new Date(item.fBsdate));
  5145. if (item.fBusinessType) {
  5146. item.fBusinessType = item.fBusinessType.toString();
  5147. }
  5148. item.fLntype = item.fLntype
  5149. ? item.fLntype.toString()
  5150. : null;
  5151. if (e.fId == item.fId) {
  5152. e = item;
  5153. this.$set(this.detailList, index, e);
  5154. }
  5155. });
  5156. });
  5157. this.msgSuccess("装货成功");
  5158. this.$set(this.form, "fItemsStatus", 3);
  5159. }
  5160. });
  5161. } else {
  5162. this.$message.error("请选择需要卸货的明细!");
  5163. }
  5164. }
  5165. });
  5166. },
  5167. creditClick() {
  5168. let checkData = {
  5169. fId: this.form.fId,
  5170. fType: "warehouse",
  5171. codeVal: this.form.fDateChanged,
  5172. };
  5173. checkCode(checkData).then((response) => {
  5174. if (!response) {
  5175. this.$confirm("数据发生变化,请更新一下数据?", "提示", {
  5176. confirmButtonText: "确认",
  5177. cancelButtonText: "取消",
  5178. type: "warning",
  5179. }).then(() => {
  5180. this.getForm();
  5181. });
  5182. } else {
  5183. for (let item in this.Printinglist) {
  5184. if (!this.Printinglist[item].fId) {
  5185. return this.$message.error("请存在未保存的数据");
  5186. }
  5187. if (this.entryPrinting == 0) {
  5188. if (
  5189. this.Printinglist[item].fBillstatus == 10 &&
  5190. this.stockoi == "0"
  5191. ) {
  5192. return this.$message.error("请存在未打印的作业单");
  5193. }
  5194. }
  5195. if (
  5196. this.Printinglist[item].fBillstatus == 20 &&
  5197. this.stockoi == "0"
  5198. ) {
  5199. return this.$message.error("请存在未卸货的数据");
  5200. }
  5201. if (!this.Printinglist[item].fTruckno) {
  5202. return this.$message.error("车号不能为空");
  5203. }
  5204. if (this.Printinglist[item].fIsPass == "F") {
  5205. return this.$message.error("未放行,不能出库");
  5206. }
  5207. }
  5208. if (this.CntrTable.length > 0) {
  5209. let arr = [];
  5210. this.CntrTable.map((e) => {
  5211. this.cntrList.map((item) => {
  5212. if (item.fId == e.fCntrid) {
  5213. arr.push(item.fName + "X" + e.fCntrcount);
  5214. }
  5215. });
  5216. });
  5217. arr = [...new Set(arr)];
  5218. this.form.fCntval = arr.join(",");
  5219. } else {
  5220. this.form.fCntval = null;
  5221. }
  5222. if (this.detailList.length > 0) {
  5223. let arr = [];
  5224. this.detailList.map((e) => {
  5225. this.goodsOptions.map((item) => {
  5226. if (e.fGoodsid == item.fId) {
  5227. arr.push(item.fName);
  5228. }
  5229. });
  5230. });
  5231. arr = [...new Set(arr)];
  5232. this.form.fProductName = arr.join(",");
  5233. } else {
  5234. this.form.fProductName = "";
  5235. }
  5236. if (this.detailList.length > 0) {
  5237. let arr = [];
  5238. this.detailList.map((e) => {
  5239. arr.push(e.fMarks);
  5240. });
  5241. arr = [...new Set(arr)];
  5242. this.form.fMarks = arr.join(",");
  5243. } else {
  5244. this.form.fMarks = "";
  5245. }
  5246. if (this.detailList.length == 0) {
  5247. this.form.fNetweight = 0;
  5248. this.form.fPlanvolumn = 0;
  5249. this.form.fGrossweight = 0;
  5250. } else {
  5251. this.form.fNetweight = this.fNetweight;
  5252. this.form.fPlanvolumn = this.fPlanvolumn;
  5253. this.form.fGrossweight = this.fGrossweight;
  5254. }
  5255. let formData = new window.FormData();
  5256. formData.append("warehouseBills", JSON.stringify(this.form));
  5257. formData.append(
  5258. "warehousebillsitems",
  5259. JSON.stringify(this.Printinglist)
  5260. );
  5261. formData.append(
  5262. "warehousebillsfeesDr",
  5263. JSON.stringify(this.warehouseDrList)
  5264. );
  5265. formData.append(
  5266. "warehousebillsfeesCr",
  5267. JSON.stringify(this.warehouseCrList)
  5268. );
  5269. formData.append(
  5270. "tEnclosure",
  5271. JSON.stringify(this.relevantAttachments)
  5272. );
  5273. formData.append("whgenleg", JSON.stringify(this.relevantAttachments));
  5274. formData.append("tCntr", JSON.stringify(this.CntrTable));
  5275. addWhgenleg(formData).then((response) => {
  5276. if ((response.code = 200)) {
  5277. this.mblnoStatus = "";
  5278. this.form = response.data.warehouse;
  5279. this.$set(this.form, "fBsdate", Date.parse(this.form.fBsdate));
  5280. this.$set(this.form, "fBstime", Date.parse(this.form.fBstime));
  5281. this.$set(
  5282. this.form,
  5283. "createTime",
  5284. Date.parse(this.form.createTime)
  5285. );
  5286. if (this.form.fStltypeid || this.form.fStltypeid == 0) {
  5287. this.$set(
  5288. this.form,
  5289. "fStltypeid",
  5290. this.form.fStltypeid.toString()
  5291. );
  5292. }
  5293. this.$set(this.form, "fFeetUnit", this.form.fFeetunit);
  5294. if (this.form.fCartype || this.form.fCartype == 0) {
  5295. this.$set(this.form, "fCartype", this.form.fCartype.toString());
  5296. }
  5297. if (this.form.fTrademodeid) {
  5298. this.$set(this.form, "fTrademodeid", this.form.fTrademodeid.toString());
  5299. }
  5300. response.data.warehouseItem.map((e) => {
  5301. e.fBsdate = Date.parse(e.fBsdate);
  5302. e.fBusinessType = e.fBusinessType.toString();
  5303. e.fLntype = e.fLntype ? e.fLntype.toString() : null;
  5304. });
  5305. this.detailList.map((e, index) => {
  5306. response.data.warehouseItem.map((item) => {
  5307. item.fBsdate = Date.parse(new Date(item.fBsdate));
  5308. if (item.fBusinessType) {
  5309. item.fBusinessType = item.fBusinessType.toString();
  5310. }
  5311. item.fLntype = item.fLntype ? item.fLntype.toString() : null;
  5312. if (e.fId == item.fId) {
  5313. e = item;
  5314. this.$set(this.detailList, index, e);
  5315. }
  5316. });
  5317. });
  5318. this.msgSuccess("出库成功");
  5319. this.$set(this.form, "fItemsStatus", 4);
  5320. }
  5321. });
  5322. }
  5323. });
  5324. },
  5325. // 撤回入账
  5326. withdrawClick() {
  5327. let checkData = {
  5328. fId: this.form.fId,
  5329. fType: "warehouse",
  5330. codeVal: this.form.fDateChanged,
  5331. };
  5332. checkCode(checkData).then((response) => {
  5333. if (!response) {
  5334. this.$confirm("数据发生变化,请更新一下数据?", "提示", {
  5335. confirmButtonText: "确认",
  5336. cancelButtonText: "取消",
  5337. type: "warning",
  5338. }).then(() => {
  5339. this.getForm();
  5340. });
  5341. } else {
  5342. for (let item in this.Printinglist) {
  5343. if (!this.Printinglist[item].fId) {
  5344. return this.$message.error("请存在未保存的数据");
  5345. }
  5346. if (this.Printinglist[item].fBillstatus == 10) {
  5347. return this.$message.error("请存在未打印的作业单");
  5348. }
  5349. if (this.Printinglist[item].fBillstatus == 20) {
  5350. return this.$message.error("请存在未卸货的数据");
  5351. }
  5352. if (this.Printinglist[item].fBillstatus == 30) {
  5353. return this.$message.error("请存在未出库的数据");
  5354. }
  5355. }
  5356. if (this.CntrTable.length > 0) {
  5357. let arr = [];
  5358. this.CntrTable.map((e) => {
  5359. this.cntrList.map((item) => {
  5360. if (item.fId == e.fCntrid) {
  5361. arr.push(item.fName + "X" + e.fCntrcount);
  5362. }
  5363. });
  5364. });
  5365. arr = [...new Set(arr)];
  5366. this.form.fCntval = arr.join(",");
  5367. } else {
  5368. this.form.fCntval = null;
  5369. }
  5370. if (this.detailList.length > 0) {
  5371. let arr = [];
  5372. this.detailList.map((e) => {
  5373. this.goodsOptions.map((item) => {
  5374. if (e.fGoodsid == item.fId) {
  5375. arr.push(item.fName);
  5376. }
  5377. });
  5378. });
  5379. arr = [...new Set(arr)];
  5380. this.form.fProductName = arr.join(",");
  5381. } else {
  5382. this.form.fProductName = "";
  5383. }
  5384. if (this.detailList.length > 0) {
  5385. let arr = [];
  5386. this.detailList.map((e) => {
  5387. arr.push(e.fMarks);
  5388. });
  5389. arr = [...new Set(arr)];
  5390. this.form.fMarks = arr.join(",");
  5391. } else {
  5392. this.form.fMarks = "";
  5393. }
  5394. if (this.detailList.length == 0) {
  5395. this.form.fNetweight = 0;
  5396. this.form.fPlanvolumn = 0;
  5397. this.form.fGrossweight = 0;
  5398. } else {
  5399. this.form.fNetweight = this.fNetweight;
  5400. this.form.fPlanvolumn = this.fPlanvolumn;
  5401. this.form.fGrossweight = this.fGrossweight;
  5402. }
  5403. // 撤回入库
  5404. let formData = new window.FormData();
  5405. formData.append("warehouseBills", JSON.stringify(this.form));
  5406. formData.append(
  5407. "warehousebillsitems",
  5408. JSON.stringify(this.Printinglist)
  5409. );
  5410. formData.append(
  5411. "warehousebillsfeesDr",
  5412. JSON.stringify(this.warehouseDrList)
  5413. );
  5414. formData.append(
  5415. "warehousebillsfeesCr",
  5416. JSON.stringify(this.warehouseCrList)
  5417. );
  5418. formData.append(
  5419. "tEnclosure",
  5420. JSON.stringify(this.relevantAttachments)
  5421. );
  5422. formData.append("tCntr", JSON.stringify(this.CntrTable));
  5423. updateCredit(formData).then((response) => {
  5424. this.Printinglist.map((e) => {
  5425. this.detailList.map((item, index) => {
  5426. if (e.fId == item.fId) {
  5427. this.$set(this.detailList[index], "fBillstatus", 10);
  5428. }
  5429. });
  5430. });
  5431. this.msgSuccess("撤回成功");
  5432. this.$refs.multipleTable.clearSelection();
  5433. this.$set(this.form, "fItemsStatus", 1);
  5434. this.$set(this.form, "fDateChanged", response.msg);
  5435. });
  5436. }
  5437. });
  5438. },
  5439. fStorageTypeFormat(row) {
  5440. let fStorageType;
  5441. this.fStorageTypeOptions.map((e) => {
  5442. if (row.fBusinessType == e.dictValue) {
  5443. fStorageType = e.dictLabel;
  5444. }
  5445. });
  5446. return fStorageType;
  5447. },
  5448. // fStorageTypeFormat(row, fStorageTypeOptions) {
  5449. // let fStorageType;
  5450. // fStorageTypeOptions.map((e) => {
  5451. // if (row == e.dictValue) {
  5452. // fStorageType = e.dictLabel;
  5453. // }
  5454. // });
  5455. // return fStorageType;
  5456. // },
  5457. fCntrtypeFormat(row) {
  5458. let fCntrtype;
  5459. this.cntrList.map((e) => {
  5460. if (row.fCntrtype == e.fId) {
  5461. fCntrtype = e.fName;
  5462. }
  5463. });
  5464. return fCntrtype;
  5465. },
  5466. goodsFormat(row) {
  5467. let goods;
  5468. this.goodsOptions.map((e) => {
  5469. if (row.fGoodsid == e.fId) {
  5470. goods = e.fName;
  5471. }
  5472. });
  5473. return goods;
  5474. },
  5475. fBsdateFormat(row) {
  5476. const dateMat = new Date(row.fBsdate);
  5477. const year = dateMat.getFullYear();
  5478. const month = dateMat.getMonth() + 1;
  5479. const day = dateMat.getDate();
  5480. const timeFormat = year + "-" + month + "-" + day;
  5481. return timeFormat;
  5482. },
  5483. calculationFee() {
  5484. if (this.detailList.length !== 0) {
  5485. let list = []
  5486. let i = 0
  5487. try {
  5488. this.detailList.forEach(item => {
  5489. i++
  5490. if (item.fBillstatus === 40) {
  5491. list.push({
  5492. fCorpid: this.form.fCorpid,
  5493. fBillingDeadline: item.fBsdate,
  5494. fMblno: item.fMblno,
  5495. fGoodsid: item.fGoodsid,
  5496. fId: item.fId
  5497. })
  5498. } else {
  5499. this.$message.error('第' + i + '条出库明细未出库');
  5500. throw new Error("EndIterative")
  5501. }
  5502. })
  5503. deliveryCalculation(list).then(res => {
  5504. let arr = [];
  5505. arr = res.data
  5506. arr.forEach(index => {
  5507. index.fBillingway = JSON.stringify(index.fBillingway)
  5508. index.fBusinessType = this.form.fBusinessType
  5509. index.fAmt = index.fAmt.toFixed(2)
  5510. console.log(index.fFeeunitid )
  5511. index.fFeeUnitid = String(index.fFeeunitid)
  5512. index.fSrcTypeId = 1
  5513. })
  5514. this.warehouseDrList = this.warehouseDrList.concat(arr)
  5515. console.log(this.warehouseDrList)
  5516. // this.warehouseDrList = res.data
  5517. // this.warehouseDrList.forEach(index => {
  5518. // index.fBillingway = JSON.stringify(index.fBillingway)
  5519. // index.fBusinessType = this.form.fBusinessType
  5520. // index.fAmt = index.fAmt.toFixed(2)
  5521. // })
  5522. })
  5523. } catch (e) {
  5524. if (e.message !== "EndIterative") throw e;
  5525. }
  5526. } else {
  5527. this.$message.error('出库明细不能为空');
  5528. }
  5529. },
  5530. getForm() {
  5531. getWarehousebills(this.chiId).then((response) => {
  5532. this.form = response.data.warehousebills;
  5533. // queryReviewer(this.form.fId).then(res => {
  5534. // if (!res.data) {
  5535. // this.firstReviewer = '';
  5536. // this.secondReviewer = '';
  5537. // } else {
  5538. // this.firstReviewer = res.data[1];
  5539. // this.secondReviewer = res.data[0];
  5540. // }
  5541. // })
  5542. if (this.form.fBillstatus > 3) {
  5543. this.approvalStatus = false;
  5544. this.browseStatus = true;
  5545. } else {
  5546. this.approvalStatus = true;
  5547. this.browseStatus = false;
  5548. }
  5549. this.$set(this.form, "fBsdate", Date.parse(this.form.fBsdate));
  5550. this.$set(this.form, "fBstifime", Date.parse(this.form.fBstime));
  5551. this.$set(this.form, "createTime", Date.parse(this.form.createTime));
  5552. this.$set(this.form, "fFeetUnit", this.form.fFeetunit);
  5553. this.tfNetweightnum = (this.form.fPlannetweight / 1000).toFixed(4);
  5554. this.tfGrossweightnum = (this.form.fPlangrossweight / 1000).toFixed(4);
  5555. if (this.form.fCartype || this.form.fCartype == 0) {
  5556. this.$set(this.form, "fCartype", this.form.fCartype.toString());
  5557. }
  5558. if (this.form.fStltypeid || this.form.fStltypeid == 0) {
  5559. this.$set(this.form, "fStltypeid", this.form.fStltypeid.toString());
  5560. }
  5561. if (this.form.fTrademodeid) {
  5562. this.$set(
  5563. this.form,
  5564. "fTrademodeid",
  5565. this.form.fTrademodeid.toString()
  5566. );
  5567. }
  5568. if (!this.copyStatus) {
  5569. if (response.data.warehouseBillsItem) {
  5570. response.data.warehouseBillsItem.map((e) => {
  5571. e.fBsdate = Date.parse(e.fBsdate);
  5572. e.fBusinessType = e.fBusinessType.toString();
  5573. e.fLntype = e.fLntype ? e.fLntype.toString() : null;
  5574. });
  5575. this.detailList = response.data.warehouseBillsItem;
  5576. } else {
  5577. this.detailList = [];
  5578. }
  5579. response.data.warehousebillsfeesCr.map((e) => {
  5580. if (e.fFeeunitid) {
  5581. e.fFeeUnitid = e.fFeeunitid.toString();
  5582. }
  5583. if (e.fStltypeid || e.fStltypeid == 0) {
  5584. e.fStltypeid = e.fStltypeid.toString();
  5585. }
  5586. });
  5587. this.warehouseCrList = response.data.warehousebillsfeesCr;
  5588. response.data.warehousebillsfeesDr.map((e) => {
  5589. if (e.fFeeunitid) {
  5590. e.fFeeUnitid = e.fFeeunitid.toString();
  5591. }
  5592. if (e.fStltypeid || e.fStltypeid == 0) {
  5593. e.fStltypeid = e.fStltypeid.toString();
  5594. }
  5595. });
  5596. this.warehouseDrList = response.data.warehousebillsfeesDr;
  5597. this.warehouseDrList.forEach(item => item.fBillingway = JSON.stringify(item.fBillingway))
  5598. if (response.data.tCntrList) {
  5599. this.CntrTable = response.data.tCntrList;
  5600. } else {
  5601. this.CntrTable = [];
  5602. }
  5603. if (response.data.enclosures) {
  5604. this.relevantAttachments = response.data.enclosures;
  5605. }
  5606. } else {
  5607. this.$set(this.form, "fId", null);
  5608. this.$set(this.form, "fMblno", null);
  5609. this.$set(this.form, "fMarks", null);
  5610. this.$set(this.form, "fProductName",null);
  5611. this.$set(this.form, "fNetweight", 0);
  5612. this.$set(this.form, "fPlanvolumn", 0);
  5613. this.$set(this.form, "fGrossweight", 0);
  5614. }
  5615. });
  5616. },
  5617. submitForm() {
  5618. let checkData = {
  5619. fId: this.form.fId,
  5620. fType: "warehouse",
  5621. codeVal: this.form.fDateChanged,
  5622. };
  5623. checkCode(checkData).then((response) => {
  5624. if (!response) {
  5625. this.$confirm("数据发生变化,请更新一下数据?", "提示", {
  5626. confirmButtonText: "确认",
  5627. cancelButtonText: "取消",
  5628. type: "warning",
  5629. }).then(() => {
  5630. this.getForm();
  5631. });
  5632. } else {
  5633. this.$refs["form"].validate((valid) => {
  5634. if (valid) {
  5635. // if (this.detailList.length === 0) {
  5636. // return this.$message.error("请新增库存明细!");
  5637. // }
  5638. this.updateDeduplication();
  5639. for (let item in this.warehouseDrList) {
  5640. if (!this.warehouseDrList[item].fCorpid) {
  5641. if (item === "fBusinessType") {
  5642. } else {
  5643. this.$message.error(
  5644. "请维护收款信息第" + (Number(item) + 1) + "行客户名称"
  5645. );
  5646. return false;
  5647. }
  5648. }
  5649. if (!this.warehouseDrList[item].fFeeid) {
  5650. if (item === "fBusinessType") {
  5651. } else {
  5652. this.$message.error(
  5653. "请维护收款信息第" + (Number(item) + 1) + "行费用名称"
  5654. );
  5655. return false;
  5656. }
  5657. }
  5658. if (!this.warehouseDrList[item].fBillingway) {
  5659. if (item === "fBusinessType") {
  5660. } else {
  5661. this.$message.error(
  5662. "请维护收款信息第" + (Number(item) + 1) + "行计价单位"
  5663. );
  5664. return false;
  5665. }
  5666. }
  5667. }
  5668. for (let item in this.warehouseCrList) {
  5669. if (!this.warehouseCrList[item].fCorpid) {
  5670. if (item === "fBusinessType") {
  5671. } else {
  5672. this.$message.error(
  5673. "请维护付款信息第" + (Number(item) + 1) + "行客户名称"
  5674. );
  5675. return false;
  5676. }
  5677. }
  5678. if (!this.warehouseCrList[item].fFeeid) {
  5679. if (item === "fBusinessType") {
  5680. } else {
  5681. this.$message.error(
  5682. "请维护付款信息第" + (Number(item) + 1) + "行费用名称"
  5683. );
  5684. return false;
  5685. }
  5686. }
  5687. if (!this.warehouseCrList[item].fFeeUnitid) {
  5688. if (item === "fBusinessType") {
  5689. } else {
  5690. this.$message.error(
  5691. "请维护付款信息第" + (Number(item) + 1) + "行计价单位"
  5692. );
  5693. return false;
  5694. }
  5695. }
  5696. }
  5697. // 附件数据
  5698. this.form.fBillingway = this.form.fFeetUnit;
  5699. if (this.detailList.length == 0) {
  5700. this.form.fNetweight = 0;
  5701. this.form.fPlanvolumn = 0;
  5702. this.form.fGrossweight = 0;
  5703. } else {
  5704. this.form.fNetweight = this.fNetweight;
  5705. this.form.fPlanvolumn = this.fPlanvolumn;
  5706. this.form.fGrossweight = this.fGrossweight;
  5707. }
  5708. if (this.CntrTable.length > 0) {
  5709. let arr = [];
  5710. this.CntrTable.map((e) => {
  5711. this.cntrList.map((item) => {
  5712. if (item.fId == e.fCntrid) {
  5713. arr.push(item.fName + "X" + e.fCntrcount);
  5714. }
  5715. });
  5716. });
  5717. arr = [...new Set(arr)];
  5718. this.form.fCntval = arr.join(",");
  5719. } else {
  5720. this.form.fCntval = null;
  5721. }
  5722. if (this.detailList.length > 0) {
  5723. let arr = [];
  5724. this.detailList.map((e) => {
  5725. this.goodsOptions.map((item) => {
  5726. if (e.fGoodsid == item.fId) {
  5727. arr.push(item.fName);
  5728. }
  5729. });
  5730. });
  5731. arr = [...new Set(arr)];
  5732. this.form.fProductName = arr.join(",");
  5733. } else {
  5734. this.form.fProductName = "";
  5735. }
  5736. if (this.detailList.length > 0) {
  5737. let arr = [];
  5738. this.detailList.map((e) => {
  5739. arr.push(e.fMarks);
  5740. });
  5741. arr = [...new Set(arr)];
  5742. this.form.fMarks = arr.join(",");
  5743. } else {
  5744. this.form.fMarks = "";
  5745. }
  5746. let formData = new window.FormData();
  5747. formData.append("warehouseBills", JSON.stringify(this.form));
  5748. // 库存明细
  5749. formData.append(
  5750. "warehousebillsitems",
  5751. JSON.stringify(this.detailList)
  5752. );
  5753. // 附件数据
  5754. formData.append(
  5755. "tEnclosure",
  5756. JSON.stringify(this.relevantAttachments)
  5757. );
  5758. // 费用明细付款
  5759. formData.append(
  5760. "warehousebillsfeesCr",
  5761. JSON.stringify(this.warehouseCrList)
  5762. );
  5763. // 收款
  5764. formData.append(
  5765. "warehousebillsfeesDr",
  5766. JSON.stringify(this.warehouseDrList)
  5767. );
  5768. formData.append("mblnoStatus", JSON.stringify(this.mblnoStatus));
  5769. formData.append("tCntr", JSON.stringify(this.CntrTable));
  5770. warehouseSubmission(formData).then((response) => {
  5771. if (response.code == 200) {
  5772. this.msgSuccess("提交成功");
  5773. setTimeout(() => {
  5774. this.cancel();
  5775. }, 200);
  5776. }
  5777. });
  5778. }
  5779. });
  5780. }
  5781. });
  5782. },
  5783. updateDeduplication() {
  5784. if (this.detailList.length) {
  5785. let fMarks = [];
  5786. let fProductName = [];
  5787. let fMblno = [];
  5788. this.detailList.map((e) => {
  5789. if (e.fMarks) {
  5790. fMarks.push(e.fMarks);
  5791. }
  5792. if (e.fGoodsids) {
  5793. fProductName.push(e.fGoodsids);
  5794. }
  5795. if (e.fMblno) {
  5796. fMblno.push(e.fMblno);
  5797. }
  5798. });
  5799. this.$set(this.form, "fMarks", [...new Set(fMarks)].join(","));
  5800. this.$set(
  5801. this.form,
  5802. "fProductName",
  5803. [...new Set(fProductName)].join(",")
  5804. );
  5805. fMblno = [...new Set(fMblno)];
  5806. if (fMblno.length <= 2) {
  5807. this.$set(this.form, "fMblno", [...new Set(fMblno)].join(","));
  5808. } else {
  5809. this.$set(this.form, "fMblno", fMblno[0] + "," + fMblno[1] + "…");
  5810. }
  5811. }
  5812. },
  5813. verifyForm() {
  5814. let checkData = {
  5815. fId: this.form.fId,
  5816. fType: "warehouse",
  5817. codeVal: this.form.fDateChanged,
  5818. };
  5819. checkCode(checkData).then((response) => {
  5820. if (!response) {
  5821. this.$confirm("数据发生变化,请更新一下数据?", "提示", {
  5822. confirmButtonText: "确认",
  5823. cancelButtonText: "取消",
  5824. type: "warning",
  5825. }).then(() => {
  5826. this.getForm();
  5827. });
  5828. } else {
  5829. this.$refs["form"].validate((valid) => {
  5830. if (valid) {
  5831. this.updateDeduplication();
  5832. this.form.fBillingway = this.form.fFeetUnit;
  5833. this.form.fFeetunit = this.form.fFeetUnit;
  5834. if (this.detailList.length == 0) {
  5835. this.form.fNetweight = 0;
  5836. this.form.fPlanvolumn = 0;
  5837. this.form.fGrossweight = 0;
  5838. } else {
  5839. this.form.fNetweight = this.fNetweight;
  5840. this.form.fPlanvolumn = this.fPlanvolumn;
  5841. this.form.fGrossweight = this.fGrossweight;
  5842. }
  5843. let formData = new window.FormData();
  5844. // 附件数据
  5845. this.form.fQty = this.fQty;
  5846. if (this.CntrTable.length > 0) {
  5847. let arr = [];
  5848. this.CntrTable.map((e) => {
  5849. this.cntrList.map((item) => {
  5850. if (item.fId == e.fCntrid) {
  5851. arr.push(item.fName + "X" + e.fCntrcount);
  5852. }
  5853. });
  5854. });
  5855. arr = [...new Set(arr)];
  5856. this.form.fCntval = arr.join(",");
  5857. } else {
  5858. this.form.fCntval = null;
  5859. }
  5860. if (this.detailList.length > 0) {
  5861. let arr = [];
  5862. this.detailList.map((e) => {
  5863. this.goodsOptions.map((item) => {
  5864. if (e.fGoodsid == item.fId) {
  5865. arr.push(item.fName);
  5866. }
  5867. });
  5868. });
  5869. arr = [...new Set(arr)];
  5870. this.form.fProductName = arr.join(",");
  5871. } else {
  5872. this.form.fProductName = "";
  5873. }
  5874. if (this.detailList.length > 0) {
  5875. let arr = [];
  5876. this.detailList.map((e) => {
  5877. arr.push(e.fMarks);
  5878. });
  5879. arr = [...new Set(arr)];
  5880. this.form.fMarks = arr.join(",");
  5881. } else {
  5882. this.form.fMarks = "";
  5883. }
  5884. formData.append("tWarehouseBills", JSON.stringify(this.form));
  5885. // 库存明细
  5886. formData.append(
  5887. "tWarehousebillsitems",
  5888. JSON.stringify(this.detailList)
  5889. );
  5890. // 附件数据
  5891. formData.append(
  5892. "tEnclosure",
  5893. JSON.stringify(this.relevantAttachments)
  5894. );
  5895. // 费用明细付款
  5896. formData.append(
  5897. "tWarehousebillsfeesCr",
  5898. JSON.stringify(this.warehouseCrList)
  5899. );
  5900. // 收款
  5901. formData.append(
  5902. "tWarehousebillsfeesDr",
  5903. JSON.stringify(this.warehouseDrList)
  5904. );
  5905. formData.append("mblnoStatus", JSON.stringify(this.mblnoStatus));
  5906. formData.append("tCntr", JSON.stringify(this.CntrTable));
  5907. submitWarehousingApproval(formData).then((response) => {
  5908. if (response.code == 200) {
  5909. this.msgSuccess("请核成功");
  5910. this.$set(this.form, "warehouseStatus", 4);
  5911. this.cancel();
  5912. }
  5913. });
  5914. }
  5915. });
  5916. }
  5917. });
  5918. },
  5919. saveForm(status) {
  5920. let checkData = {
  5921. fId: this.form.fId,
  5922. fType: "warehouse",
  5923. codeVal: this.form.fDateChanged,
  5924. };
  5925. checkCode(checkData).then((response) => {
  5926. if (!response) {
  5927. this.$confirm("数据发生变化,请更新一下数据?", "提示", {
  5928. confirmButtonText: "确认",
  5929. cancelButtonText: "取消",
  5930. type: "warning",
  5931. }).then(() => {
  5932. this.getForm();
  5933. });
  5934. } else {
  5935. this.$refs["form"].validate((valid) => {
  5936. if (valid) {
  5937. this.updateDeduplication();
  5938. this.form.fBillingway = this.form.fFeetUnit;
  5939. this.form.fFeetunit = this.form.fFeetUnit;
  5940. if (this.detailList.length == 0) {
  5941. this.form.fNetweight = 0;
  5942. this.form.fPlanvolumn = 0;
  5943. this.form.fGrossweight = 0;
  5944. } else {
  5945. this.form.fNetweight = this.fNetweight;
  5946. this.form.fPlanvolumn = this.fPlanvolumn;
  5947. this.form.fGrossweight = this.fGrossweight;
  5948. }
  5949. let formData = new window.FormData();
  5950. // 附件数据
  5951. this.form.fQty = this.fQty;
  5952. if (this.CntrTable.length > 0) {
  5953. let arr = [];
  5954. this.CntrTable.map((e) => {
  5955. this.cntrList.map((item) => {
  5956. if (item.fId == e.fCntrid) {
  5957. arr.push(item.fName + "X" + e.fCntrcount);
  5958. }
  5959. });
  5960. });
  5961. arr = [...new Set(arr)];
  5962. this.form.fCntval = arr.join(",");
  5963. } else {
  5964. this.form.fCntval = null;
  5965. }
  5966. if (this.detailList.length > 0) {
  5967. let arr = [];
  5968. this.detailList.map((e) => {
  5969. this.goodsOptions.map((item) => {
  5970. if (e.fGoodsid == item.fId) {
  5971. arr.push(item.fName);
  5972. }
  5973. });
  5974. });
  5975. arr = [...new Set(arr)];
  5976. this.form.fProductName = arr.join(",");
  5977. } else {
  5978. this.form.fProductName = "";
  5979. }
  5980. if (this.detailList.length > 0) {
  5981. let arr = [];
  5982. this.detailList.map((e) => {
  5983. arr.push(e.fMarks);
  5984. });
  5985. arr = [...new Set(arr)];
  5986. this.form.fMarks = arr.join(",");
  5987. } else {
  5988. this.form.fMarks = "";
  5989. }
  5990. // 主表没有司机信息 从表添加
  5991. if (!this.form.fTruckno && !this.form.fDriverName && !this.form.fDriverTel && !this.form.fDriverIdCar) {
  5992. if (this.detailList.length > 0) {
  5993. for (let i = 0;i < this.detailList.length;i++) {
  5994. if (this.detailList[i].fTruckno || this.detailList[i].fDriverName || this.detailList[i].fDriverTel || this.detailList[i].fDriverIdCar) {
  5995. this.form.fTruckno = this.detailList[i].fTruckno
  5996. this.form.fDriverName = this.detailList[i].fDriverName
  5997. this.form.fDriverTel = this.detailList[i].fDriverTel
  5998. this.form.fDriverIdCar = this.detailList[i].fDriverIdCar
  5999. break;
  6000. }
  6001. }
  6002. }
  6003. }
  6004. for (let item in this.warehouseDrList) {
  6005. if (!this.warehouseDrList[item].fCorpid) {
  6006. return this.$message.error('收款信息第' + (Number(item) + 1) + '行' + '客户名称不能为空');
  6007. } else if (!this.warehouseDrList[item].fFeeid) {
  6008. return this.$message.error('收款信息第' + (Number(item) + 1) + '行' + '费用名称不能为空');
  6009. } else if (!this.warehouseDrList[item].fFeeUnitid) {
  6010. return this.$message.error('收款信息第' + (Number(item) + 1) + '行' + '计价单位不能为空');
  6011. }
  6012. }
  6013. for (let item in this.warehouseCrList) {
  6014. if (!this.warehouseCrList[item].fCorpid) {
  6015. return this.$message.error('付款信息第' + (Number(item) + 1) + '行' + '客户名称不能为空');
  6016. } else if (!this.warehouseCrList[item].fFeeid) {
  6017. return this.$message.error('付款信息第' + (Number(item) + 1) + '行' + '费用名称不能为空');
  6018. } else if (!this.warehouseCrList[item].fFeeUnitid) {
  6019. return this.$message.error('付款信息第' + (Number(item) + 1) + '行' + '计价单位不能为空');
  6020. }
  6021. }
  6022. formData.append("warehouseBills", JSON.stringify(this.form));
  6023. this.detailList.forEach(item => {
  6024. if (item.srcId !== null) {
  6025. // item.fStorageFeeDeadline = item.fBsdate
  6026. }
  6027. })
  6028. // 库存明细
  6029. formData.append(
  6030. "warehousebillsitems",
  6031. JSON.stringify(this.detailList)
  6032. );
  6033. // 附件数据
  6034. formData.append(
  6035. "tEnclosure",
  6036. JSON.stringify(this.relevantAttachments)
  6037. );
  6038. // 费用明细付款
  6039. formData.append(
  6040. "warehousebillsfeesCr",
  6041. JSON.stringify(this.warehouseCrList)
  6042. );
  6043. // 收款
  6044. formData.append(
  6045. "warehousebillsfeesDr",
  6046. JSON.stringify(this.warehouseDrList)
  6047. );
  6048. formData.append("mblnoStatus", JSON.stringify(this.mblnoStatus));
  6049. formData.append("tCntr", JSON.stringify(this.CntrTable));
  6050. addWarehousebills(formData).then((response) => {
  6051. if (response.data == false) {
  6052. this.$confirm(response.msg, "提示", {
  6053. confirmButtonText: "确定",
  6054. cancelButtonText: "取消",
  6055. type: "warning",
  6056. })
  6057. .then(() => {
  6058. this.mblnoStatus = true;
  6059. this.saveForm();
  6060. })
  6061. .catch(() => {
  6062. this.$message({
  6063. type: "info",
  6064. message: "已取消",
  6065. });
  6066. });
  6067. } else {
  6068. if ((response.code = 200)) {
  6069. this.mblnoStatus = "";
  6070. this.form = response.data.warehouseBills;
  6071. this.$set(
  6072. this.form,
  6073. "fBsdate",
  6074. Date.parse(this.form.fBsdate)
  6075. );
  6076. this.$set(
  6077. this.form,
  6078. "fBstime",
  6079. Date.parse(this.form.fBstime)
  6080. );
  6081. this.$set(
  6082. this.form,
  6083. "createTime",
  6084. Date.parse(this.form.createTime)
  6085. );
  6086. if (this.form.fStltypeid || this.form.fStltypeid == 0) {
  6087. this.$set(
  6088. this.form,
  6089. "fStltypeid",
  6090. this.form.fStltypeid.toString()
  6091. );
  6092. }
  6093. this.$set(this.form, "fFeetUnit", this.form.fFeetunit);
  6094. if (this.form.fCartype || this.form.fCartype == 0) {
  6095. this.$set(
  6096. this.form,
  6097. "fCartype",
  6098. this.form.fCartype.toString()
  6099. );
  6100. }
  6101. if (this.form.fTrademodeid) {
  6102. this.$set(
  6103. this.form,
  6104. "fTrademodeid",
  6105. this.form.fTrademodeid.toString()
  6106. );
  6107. }
  6108. response.data.warehousebillsitems.map((e) => {
  6109. e.fBsdate = Date.parse(e.fBsdate);
  6110. e.fBusinessType = e.fBusinessType.toString();
  6111. e.fLntype = e.fLntype ? e.fLntype.toString() : null;
  6112. });
  6113. this.detailList = response.data.warehousebillsitems;
  6114. this.msgSuccess("保存成功");
  6115. getWarehousebills(this.form.fId).then((response) => {
  6116. this.form = response.data.warehousebills;
  6117. if (this.form.fBillstatus > 3) {
  6118. this.approvalStatus = false;
  6119. this.browseStatus = true;
  6120. } else {
  6121. this.approvalStatus = true;
  6122. this.browseStatus = false;
  6123. }
  6124. this.$set(this.form, "fBsdate", Date.parse(this.form.fBsdate));
  6125. this.$set(this.form, "fBstifime", Date.parse(this.form.fBstime));
  6126. this.$set(this.form, "createTime", Date.parse(this.form.createTime));
  6127. this.$set(this.form, "fFeetUnit", this.form.fFeetunit);
  6128. this.tfNetweightnum = (this.form.fPlannetweight / 1000).toFixed(4);
  6129. this.tfGrossweightnum = (this.form.fPlangrossweight / 1000).toFixed(4);
  6130. if (this.form.fCartype || this.form.fCartype == 0) {
  6131. this.$set(this.form, "fCartype", this.form.fCartype.toString());
  6132. }
  6133. if (this.form.fStltypeid || this.form.fStltypeid == 0) {
  6134. this.$set(this.form, "fStltypeid", this.form.fStltypeid.toString());
  6135. }
  6136. if (this.form.fTrademodeid) {
  6137. this.$set(
  6138. this.form,
  6139. "fTrademodeid",
  6140. this.form.fTrademodeid.toString()
  6141. );
  6142. }
  6143. if (!this.copyStatus) {
  6144. if (response.data.warehouseBillsItem) {
  6145. response.data.warehouseBillsItem.map((e) => {
  6146. e.fBsdate = Date.parse(e.fBsdate);
  6147. e.fBusinessType = e.fBusinessType.toString();
  6148. e.fLntype = e.fLntype ? e.fLntype.toString() : null;
  6149. });
  6150. this.detailList = response.data.warehouseBillsItem;
  6151. } else {
  6152. this.detailList = [];
  6153. }
  6154. response.data.warehousebillsfeesCr.map((e) => {
  6155. if (e.fFeeunitid) {
  6156. e.fFeeUnitid = e.fFeeunitid.toString();
  6157. }
  6158. if (e.fStltypeid || e.fStltypeid == 0) {
  6159. e.fStltypeid = e.fStltypeid.toString();
  6160. }
  6161. });
  6162. this.warehouseCrList = response.data.warehousebillsfeesCr;
  6163. response.data.warehousebillsfeesDr.map((e) => {
  6164. if (e.fFeeunitid) {
  6165. e.fFeeUnitid = e.fFeeunitid.toString();
  6166. }
  6167. if (e.fStltypeid || e.fStltypeid == 0) {
  6168. e.fStltypeid = e.fStltypeid.toString();
  6169. }
  6170. });
  6171. this.warehouseDrList = response.data.warehousebillsfeesDr;
  6172. this.warehouseDrList.forEach(item => item.fBillingway = JSON.stringify(item.fBillingway))
  6173. if (response.data.tCntrList) {
  6174. this.CntrTable = response.data.tCntrList;
  6175. } else {
  6176. this.CntrTable = [];
  6177. }
  6178. if (response.data.enclosures) {
  6179. this.relevantAttachments = response.data.enclosures;
  6180. }
  6181. }
  6182. // else {
  6183. // this.$set(this.form, "fId", null);
  6184. // this.$set(this.form, "fMblno", null);
  6185. // this.$set(this.form, "fMarks", null);
  6186. // this.$set(this.form, "fProductName",null);
  6187. // this.$set(this.form, "fNetweight", 0);
  6188. // this.$set(this.form, "fPlanvolumn", 0);
  6189. // this.$set(this.form, "fGrossweight", 0);
  6190. // }
  6191. });
  6192. if (status == "goBack") {
  6193. this.cancel();
  6194. }
  6195. }
  6196. }
  6197. });
  6198. }
  6199. });
  6200. }
  6201. });
  6202. },
  6203. // 库存明细多选
  6204. Selectinventory(selection) {
  6205. this.Printinglist = selection;
  6206. //允许撤销入库list
  6207. this.dataWithdrawList = selection;
  6208. //允许确认入库list
  6209. this.dataListSelection = selection;
  6210. if (this.dataWithdrawList.length === 0) {
  6211. this.cancelDelivery = true
  6212. } else {
  6213. for (let item in this.dataWithdrawList) {
  6214. if (this.dataWithdrawList[item].fBillstatus === 40) {
  6215. this.cancelDelivery = false
  6216. this.deliveryConfirmation = true
  6217. for (let li in this.dataWithdrawList) {
  6218. if (this.entryPrinting != 0 ? this.dataWithdrawList[li].fBillstatus === 10 : this.dataWithdrawList[li].fBillstatus === 30) {
  6219. this.deliveryConfirmation = true
  6220. this.cancelDelivery = true
  6221. return
  6222. }
  6223. }
  6224. } else if (this.entryPrinting != 0 ? this.dataWithdrawList[item].fBillstatus === 10 : this.dataWithdrawList[item].fBillstatus === 30) {
  6225. this.deliveryConfirmation = false
  6226. this.cancelDelivery = true
  6227. for (let li in this.dataWithdrawList) {
  6228. if (this.dataWithdrawList[li].fBillstatus === 40) {
  6229. this.deliveryConfirmation = true
  6230. this.cancelDelivery = true
  6231. return
  6232. }
  6233. }
  6234. }
  6235. }
  6236. }
  6237. },
  6238. // 付款明细多选
  6239. SelectCr(selection) {
  6240. this.PrintingCrlist = selection;
  6241. },
  6242. // 合计
  6243. getSummaries(param) {
  6244. const {columns, data} = param;
  6245. const sums = [];
  6246. var values = [];
  6247. columns.forEach((column, index) => {
  6248. if (index === 0) {
  6249. sums[index] = "";
  6250. return;
  6251. }
  6252. if (column.property === "fGrossweight") {
  6253. values = data.map((item) => Number(item["fGrossweight"]));
  6254. }
  6255. if (column.property === "fNetweight") {
  6256. values = data.map((item) => Number(item["fNetweight"]));
  6257. }
  6258. if (column.property === "fQty") {
  6259. values = data.map((item) => Number(item["fQty"]));
  6260. }
  6261. if (column.property === "fCntqty") {
  6262. values = data.map((item) => Number(item["fCntqty"]));
  6263. }
  6264. if (
  6265. column.property === "fGrossweight" ||
  6266. column.property === "fNetweight" ||
  6267. column.property === "fQty" ||
  6268. column.property === "fCntqty"
  6269. ) {
  6270. sums[index] = values.reduce((prev, curr) => {
  6271. const value = Number(curr);
  6272. if (!isNaN(value)) {
  6273. if (column.property === "fGrossweight") {
  6274. this.fGrossweight = prev + curr;
  6275. }
  6276. if (column.property === "fNetweight") {
  6277. this.fNetweight = prev + curr;
  6278. }
  6279. if (column.property === "fQty") {
  6280. this.fQty = prev + curr;
  6281. this.sumMum = prev + curr;
  6282. }
  6283. if (column.property === "fCntqty") {
  6284. this.fCntqty = prev + curr;
  6285. }
  6286. return prev + curr;
  6287. } else {
  6288. return prev;
  6289. }
  6290. }, 0);
  6291. if (column.property === "fGrossweight") {
  6292. sums[index] = (sums[index] / 1000).toFixed(4) + "吨";
  6293. } else if (column.property === "fNetweight") {
  6294. sums[index] = (sums[index] / 1000).toFixed(4) + "吨";
  6295. } else {
  6296. // sums[index] = sums[index].toFixed(2);
  6297. sums[index] = sums[index]
  6298. }
  6299. }
  6300. });
  6301. this.sums = sums;
  6302. return sums;
  6303. },
  6304. // 付款合计
  6305. warehouseDrSummaries(param) {
  6306. const {columns, data} = param;
  6307. const sums = [];
  6308. columns.forEach((column, index) => {
  6309. if (index === 0) {
  6310. sums[index] = "合计";
  6311. return;
  6312. }
  6313. const values = data.map((item) => Number(item[column.property]));
  6314. // column.property === "fQty"
  6315. if (
  6316. column.property === "fUnitprice" ||
  6317. column.property === "fAmount"
  6318. ) {
  6319. sums[index] = values.reduce((prev, curr) => {
  6320. const value = Number(curr);
  6321. if (!isNaN(value)) {
  6322. return prev + curr;
  6323. } else {
  6324. return prev;
  6325. }
  6326. }, 0);
  6327. sums[index] = sums[index].toFixed(2);
  6328. }
  6329. });
  6330. return sums;
  6331. },
  6332. // 库存总账多选框
  6333. whgenlegSelectionChange(selection) {
  6334. this.dialogWhgenlegList = selection;
  6335. },
  6336. handleSelect(key) {
  6337. if (!this.form.fCorpid) {
  6338. this.$message({
  6339. message: "请维护客户",
  6340. type: "warning",
  6341. });
  6342. } else if (this.form.fProductName == undefined) {
  6343. this.$message({
  6344. message: "请维护入库明细品名",
  6345. type: "warning",
  6346. });
  6347. } else {
  6348. this.pageNum = 1;
  6349. this.pageSize = 10;
  6350. this.dialogWhgenlegList = [];
  6351. this.whgenlegTotal = 0;
  6352. this.warehousingagreements = true;
  6353. this.getWhgenlegList(key);
  6354. }
  6355. },
  6356. // 查询作业费信息
  6357. getWhgenlegList(key) {
  6358. console.log(key)
  6359. let data = {};
  6360. if (key == 2) {
  6361. this.key_id = key;
  6362. this.Navigation = true;
  6363. data = {
  6364. pageNum: this.pageNum,
  6365. pageSize: this.pageSize,
  6366. fTaskType: key,
  6367. fLabour: this.form.fLabour,
  6368. };
  6369. } else if (key == 1) {
  6370. this.key_id = key;
  6371. this.Navigation = true;
  6372. data = {
  6373. pageNum: this.pageNum,
  6374. pageSize: this.pageSize,
  6375. fTaskType: key,
  6376. fFleet: this.form.fFleet,
  6377. };
  6378. } else {
  6379. this.Navigation = false;
  6380. this.key_id = key;
  6381. data = {
  6382. pageNum: this.pageNum,
  6383. pageSize: this.pageSize,
  6384. fCorpid: this.form.fCorpid,
  6385. };
  6386. }
  6387. operationAgreement(data).then((response) => {
  6388. response.rows.map((e) => {
  6389. if (e.fFeeUnitid) {
  6390. e.fFeeUnitid = e.fFeeUnitid.toString();
  6391. }
  6392. });
  6393. this.tasklegList = response.rows;
  6394. this.whgenlegTotal = response.total;
  6395. });
  6396. },
  6397. // 入库明细新增list
  6398. addRelevant() {
  6399. this.$refs["form"].validate((valid) => {
  6400. if (valid) {
  6401. this.whgenlegList = [];
  6402. this.dialogWhgenlegList = [];
  6403. this.whgenlegTotal = 0;
  6404. this.whgenlegVisible = true;
  6405. this.$set(this.whgenlegParams, 'fMblno', this.form.fMblno)
  6406. this.getDetailsList();
  6407. }
  6408. });
  6409. },
  6410. // 查询库存总账信息
  6411. getDetailsList() {
  6412. this.$set(this.whgenlegParams, 'fCorpid', this.form.fCorpid)
  6413. this.$set(this.whgenlegParams, 'fWarehouseid', this.form.fWarehouseid)
  6414. this.$set(this.whgenlegParams, 'fTrademodeid', this.form.fTrademodeid)
  6415. listWhgenleg(this.whgenlegParams).then((response) => {
  6416. response.rows.map((e) => {
  6417. e.fQtyblc2 = e.fQtyblc;
  6418. e.fGrossweightblc2 = e.fGrossweightblc;
  6419. e.fNetweightblc2 = e.fNetweightblc;
  6420. });
  6421. this.whgenlegList = response.rows;
  6422. this.whgenlegTotal = response.total;
  6423. });
  6424. },
  6425. // 无限滚动加载
  6426. load() {
  6427. this.isFlag = true;
  6428. setTimeout(() => {
  6429. this.getDetailsList()
  6430. this.whgenlegParams.pageNum++
  6431. this.isFlag = false
  6432. }, 2000)
  6433. },
  6434. async printZyd() {
  6435. this.radio = 1;
  6436. this.nowTime = new Date(+new Date() + 8 * 3600 * 1000 ).toJSON().substr(0, 19).replace("T"," ")
  6437. if (this.Printinglist.length > 0) {
  6438. for (let item in this.Printinglist) {
  6439. if (!this.Printinglist[item].fId) {
  6440. return this.$message.error("请先保存!");
  6441. }
  6442. if (
  6443. this.Printinglist[item].fTruckno !== this.Printinglist[0].fTruckno
  6444. ) {
  6445. return this.$message.error("请选择车相同车号");
  6446. }
  6447. }
  6448. let formData = new window.FormData();
  6449. formData.append("warehouseBills", JSON.stringify(this.form));
  6450. formData.append(
  6451. "warehousebillsitems",
  6452. JSON.stringify(this.Printinglist)
  6453. );
  6454. formData.append(
  6455. "warehousebillsfeesDr",
  6456. JSON.stringify(this.warehouseDrList)
  6457. );
  6458. formData.append(
  6459. "warehousebillsfeesCr",
  6460. JSON.stringify(this.warehouseCrList)
  6461. );
  6462. formData.append(
  6463. "tEnclosure",
  6464. JSON.stringify(this.relevantAttachments)
  6465. );
  6466. formData.append("tCntr", JSON.stringify(this.CntrTable));
  6467. await addJoblist(formData).then((response) => {
  6468. if (response.code == 200) {
  6469. this.Printinglist.forEach((item, index) => {
  6470. item.fSerialNumber = response.data.warehousebillsitems[index].fSerialNumber
  6471. })
  6472. for (let item in this.detailList) {
  6473. this.zcList[item] = this.detailList[item]
  6474. }
  6475. this.$set(this.form, "fDateChanged", response.data.fDateChanged);
  6476. this.zcList.map((e, index) => {
  6477. response.data.warehousebillsitems.map((item) => {
  6478. item.fBsdate = Date.parse(new Date(item.fBsdate));
  6479. if (item.fBusinessType) {
  6480. item.fBusinessType = item.fBusinessType.toString();
  6481. }
  6482. if (e.fId == item.fId) {
  6483. this.$set(this.zcList, index, item);
  6484. }
  6485. });
  6486. });
  6487. this.$set(this.form, "fItemsStatus", 2);
  6488. }
  6489. });
  6490. this.print_zyd = true;
  6491. this.warehouseOptions.map((e) => {
  6492. if (e.fId == this.form.fWarehouseid) {
  6493. this.stockaddr = e.fAddr;
  6494. }
  6495. });
  6496. this.fDriverTel = this.Printinglist[0].fDriverTel;
  6497. } else {
  6498. this.$message.error("请选择需要打印的明细!");
  6499. }
  6500. },
  6501. // 付款信息打印准备
  6502. printCr() {
  6503. if (this.PrintingCrlist.length > 0) {
  6504. for (let item in this.PrintingCrlist) {
  6505. if (!this.PrintingCrlist[item].fId) {
  6506. return this.$message.error("请先保存!");
  6507. }
  6508. }
  6509. this.allCrfAmount = 0;
  6510. this.allCrfQty = 0;
  6511. this.PrintingCrlist.forEach(item => {
  6512. this.allCrfAmount = this.allCrfAmount + item.fAmount
  6513. this.allCrfQty += item.fQty
  6514. })
  6515. this.print_Cr = true;
  6516. } else {
  6517. this.$message.error("请选择需要打印的明细!");
  6518. }
  6519. },
  6520. detailedApproval(command) {
  6521. if (command === 'QH') {
  6522. deliveryDetails(this.form.fId).then(res => {
  6523. if (res.code == 200) {
  6524. this.msgSuccess("请核成功");
  6525. this.$set(this.form, 'fItemstatus', 4)
  6526. }
  6527. })
  6528. } else if (command === 'CK') {
  6529. this.addOrUpdateVisible = true;
  6530. let actId = "180";
  6531. this.$nextTick(() => {
  6532. this.$refs.addOrUpdate.init(this.form.fId, actId, 'f_itemstatus');
  6533. });
  6534. } else if (command === 'SP') {
  6535. this.addOrUpdateVisib = true;
  6536. this.$nextTick(() => {
  6537. this.$refs.ApprovalComments.init(this.form.fId, 'f_itemstatus', 180);
  6538. });
  6539. } else if (command === 'CX') {
  6540. let data = {
  6541. actId: 180,
  6542. billId: this.form.fId,
  6543. id: this.form.fId,
  6544. fidStatus: 'f_itemstatus',
  6545. };
  6546. revokeTwo(data).then((data) => {
  6547. if (data.code === 200) {
  6548. this.browseStatus = false;
  6549. this.msgSuccess("撤销成功");
  6550. this.$set(this.form, 'fItemstatus', 2)
  6551. }
  6552. });
  6553. }
  6554. },
  6555. handleCommand(command) {
  6556. if (this.Printinglist.length > 0) {
  6557. for (let item in this.Printinglist) {
  6558. if (!this.Printinglist[item].fId) {
  6559. return this.$message.error("请先保存!");
  6560. }
  6561. }
  6562. this.$refs["form"].validate((valid) => {
  6563. if (valid) {
  6564. this.radio = 1
  6565. for (let corp in this.fMblnoOptions) {
  6566. if (this.form.fCorpid === this.fMblnoOptions[corp].fId) {
  6567. this.$set(
  6568. this.form,
  6569. "fCorpidName",
  6570. this.fMblnoOptions[corp].fName
  6571. );
  6572. }
  6573. }
  6574. this.warehouseOptions.map((e) => {
  6575. if (e.fId == this.form.fWarehouseid) {
  6576. this.stockName = e.fName;
  6577. this.stockaddr = e.fAddr;
  6578. }
  6579. });
  6580. this.fDriverTel = this.Printinglist[0].fDriverTel;
  6581. let date = new Date(this.Printinglist[0].fBsdate);
  6582. let Y = date.getFullYear();
  6583. let M =
  6584. date.getMonth() + 1 < 10
  6585. ? "0" + (date.getMonth() + 1)
  6586. : date.getMonth() + 1;
  6587. let D = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
  6588. this.fBsdate = Y + "-" + M + "-" + D;
  6589. // this.fBsdate = this.Printinglist[0].fBsdate;
  6590. this.fTruckno = this.Printinglist[0].fTruckno;
  6591. this.allfCntqty = 0;
  6592. this.allfGrossweight = 0;
  6593. this.allfPlanqty = 0;
  6594. this.allfNetweight = 0;
  6595. this.allfQty = 0;
  6596. this.Printinglist.map((e) => {
  6597. if (e.fCntqty) {
  6598. this.allfCntqty += e.fCntqty;
  6599. }
  6600. if (e.fGrossweight) {
  6601. this.allfGrossweight += e.fGrossweight;
  6602. }
  6603. if (e.fPlanqty) {
  6604. this.allfPlanqty += e.fPlanqty;
  6605. }
  6606. if (e.fNetweight) {
  6607. this.allfNetweight += e.fNetweight;
  6608. }
  6609. if (e.fQty) {
  6610. this.allfQty += e.fQty;
  6611. }
  6612. let data = {
  6613. id: this.form.fId,
  6614. actId: 120,
  6615. fidStatus: 'f_billstatus',
  6616. };
  6617. listCharge(data).then((data) => {
  6618. console.log(data.data)
  6619. });
  6620. });
  6621. if (command == "a") {
  6622. this.print_shd = true;
  6623. } else if (command == "b") {
  6624. this.print_rkd = true;
  6625. } else if (command == "c") {
  6626. this.print_lhd = true;
  6627. } else if (command == "q") {
  6628. this.print_signFor = true;
  6629. } else if (command == "d") {
  6630. let date = new Date();
  6631. let hours =
  6632. date.getHours() < 10 ? "0" + date.getHours() : date.getHours();
  6633. let minutes =
  6634. date.getMinutes() < 10
  6635. ? "0" + date.getMinutes()
  6636. : date.getMinutes();
  6637. this.ckTime = hours + ":" + minutes;
  6638. this.print_bzckd = true;
  6639. } else if (command == "e") {
  6640. this.print_lwqr = true;
  6641. } else if (command == "f") {
  6642. this.print_ccckd = true;
  6643. } else if (command == "g") {
  6644. for (let i = 1; i < this.Printinglist.length;i++) {
  6645. if (this.Printinglist[i].fTruckno !== this.Printinglist[0].fTruckno) return this.$message.error('请选择相同的车号')
  6646. }
  6647. this.print_dcckd = true;
  6648. } else if (command == "h") {
  6649. this.print_zccdckd = true;
  6650. } else if (command == "i") {
  6651. let date = new Date();
  6652. let hours =
  6653. date.getHours() < 10 ? "0" + date.getHours() : date.getHours();
  6654. let minutes =
  6655. date.getMinutes() < 10
  6656. ? "0" + date.getMinutes()
  6657. : date.getMinutes();
  6658. this.ckTime = hours + ":" + minutes;
  6659. this.print_xqckd = true;
  6660. }
  6661. }
  6662. });
  6663. } else {
  6664. this.$message.error("请选择需要打印的明细!");
  6665. }
  6666. },
  6667. //计算仓储费日期变更
  6668. changeDate() {
  6669. this.$set(this.form, "fChargedate", this.form.fBsdate);
  6670. },
  6671. addRow() {
  6672. var obj = {};
  6673. this.CntrTable.push(obj);
  6674. },
  6675. deleteRow(index, rows) {
  6676. rows.splice(index, 1);
  6677. },
  6678. wDeleteRow(index, rows) {
  6679. rows.splice(index, 1);
  6680. this.sumMum = 0;
  6681. this.detailList.map((e) => {
  6682. if (e.fQty) {
  6683. this.sumMum += e.fQty;
  6684. }
  6685. });
  6686. if (this.detailList.length == 0) {
  6687. this.form.fProductName = "";
  6688. this.form.fMarks = "";
  6689. this.form.fNetweight = 0;
  6690. this.form.fPlanvolumn = 0;
  6691. this.form.fGrossweight = 0;
  6692. }
  6693. },
  6694. // 收款信息新行
  6695. addCollection() {
  6696. this.$refs["form"].validate((valid) => {
  6697. if (valid) {
  6698. if (this.form.fBusinessType == null) {
  6699. this.$message.error("请维护作业类型");
  6700. return false;
  6701. } else {
  6702. this.warehouseDrList.push({
  6703. fCorpid: null,
  6704. fFeeid: null,
  6705. fFeeUnitid: "",
  6706. fQty: null,
  6707. fUnitprice: null,
  6708. fAmount: null,
  6709. fCurrency: "RMB",
  6710. fExrate: "1",
  6711. fTaxrate: this.fTaxrate,
  6712. fCxrate: null,
  6713. fRate: null,
  6714. remarks: null,
  6715. fMblno: this.form.fMblno,
  6716. fProductName: this.form.fProductName,
  6717. fMarks: this.form.fMarks,
  6718. fBusinessType: this.form.fBusinessType,
  6719. fSrcTypeId: 0,
  6720. fBilltype: 'SJCK',
  6721. fStltypeid: '1',
  6722. });
  6723. this.fWbuOptions = [];
  6724. let queryParams = {pageNum: 1, fDc: "D"};
  6725. listFees(queryParams).then((response) => {
  6726. this.fDNameOptions = response.rows;
  6727. });
  6728. }
  6729. }
  6730. });
  6731. },
  6732. //付款信息新行
  6733. addpayment() {
  6734. this.$refs["form"].validate((valid) => {
  6735. if (valid) {
  6736. if (this.form.fBusinessType == null) {
  6737. return this.$message.error("请维护作业类型");
  6738. } else {
  6739. this.warehouseCrList.push({
  6740. fCorpid: null,
  6741. fFeeid: null,
  6742. fFeeUnitid: "",
  6743. fQty: null,
  6744. fUnitprice: null,
  6745. fAmount: null,
  6746. fCurrency: "RMB",
  6747. fExrate: "1",
  6748. fTaxrate: this.fTaxrate,
  6749. fCxrate: null,
  6750. fRate: null,
  6751. remarks: null,
  6752. fMblno: this.form.fMblno,
  6753. fProductName: this.form.fProductName,
  6754. fMarks: this.form.fMarks,
  6755. fBusinessType: this.form.fBusinessType,
  6756. fSrcTypeId: 0,
  6757. fStltypeid: '1',
  6758. });
  6759. this.fWbuOptions = [];
  6760. let queryParams = {pageNum: 1, fDc: "C"};
  6761. listFees(queryParams).then((response) => {
  6762. this.fCNameOptions = response.rows;
  6763. });
  6764. }
  6765. }
  6766. });
  6767. },
  6768. //导入收付款信息明细
  6769. zhgenlegData() {
  6770. if (this.dialogWhgenlegList.length === 0) {
  6771. this.$message({
  6772. message: "请选择需要导入的数据",
  6773. type: "warning",
  6774. });
  6775. } else {
  6776. this.dialogWhgenlegList.map((e) => {
  6777. let qty = 1;
  6778. if (e.fFeeUnitid == 1) {
  6779. qty = this.fQty;
  6780. } else if (e.fFeeUnitid == 2) {
  6781. qty = (this.fGrossweight / 1000).toFixed(2);
  6782. } else if (e.fFeeUnitid == 3) {
  6783. qty = (this.fNetweight / 1000).toFixed(2);
  6784. } else if (e.fFeeUnitid == 7) {
  6785. qty = this.fCntqty;
  6786. }
  6787. let fAmount = 0;
  6788. fAmount = e.fPrice * qty;
  6789. if (this.key_id == 3) {
  6790. this.warehouseDrList.push({
  6791. fQty: qty,
  6792. fCorpid: e.fCorpid,
  6793. fFeeid: e.feeFId,
  6794. fFeeUnitid: e.fFeeUnitid,
  6795. fUnitprice: e.fPrice,
  6796. fCurrency: "RMB",
  6797. fExrate: 1,
  6798. fAmount: fAmount,
  6799. fTaxrate: this.fTaxrate,
  6800. fMblno: this.form.fMblno,
  6801. fProductName: this.form.fProductName,
  6802. fMarks: this.form.fMarks,
  6803. fBusinessType: this.form.fBusinessType,
  6804. fSrcTypeId: 1,
  6805. fBillingway: e.fFeeUnitid,
  6806. remark: e.remark,
  6807. fStltypeid: '1',
  6808. });
  6809. } else {
  6810. this.warehouseCrList.push({
  6811. fQty: qty,
  6812. fCorpid: e.fCorpid,
  6813. fFeeid: e.feeFId,
  6814. fFeeUnitid: e.fFeeUnitid,
  6815. fUnitprice: e.fPrice,
  6816. fCurrency: "RMB",
  6817. fExrate: 1,
  6818. fAmount: fAmount,
  6819. fTaxrate: this.fTaxrate,
  6820. fMblno: this.form.fMblno,
  6821. fProductName: this.form.fProductName,
  6822. fMarks: this.form.fMarks,
  6823. fBusinessType: this.form.fBusinessType,
  6824. fSrcTypeId: 1,
  6825. fStltypeid: '1',
  6826. });
  6827. }
  6828. });
  6829. this.warehousingagreements = false;
  6830. }
  6831. },
  6832. // 收款选
  6833. Collectionoptions(selection) {
  6834. this.Collectionoptionss = selection;
  6835. console.log(selection)
  6836. for (let item in this.fWbuOptions) {
  6837. for (let li in this.Collectionoptionss) {
  6838. if (
  6839. this.fWbuOptions[item].fId === this.Collectionoptionss[li].fFeeid
  6840. ) {
  6841. this.$set(
  6842. this.Collectionoptionss[li],
  6843. "fFeeids",
  6844. this.fWbuOptions[item].fName
  6845. );
  6846. }
  6847. }
  6848. }
  6849. },
  6850. //获取登陆人
  6851. queryUser() {
  6852. queryUserVal().then((response) => {
  6853. if (response.user !== null) {
  6854. this.userVal = response.user;
  6855. this.$set(this.form, "fDeptid", this.userVal.deptId);
  6856. this.$set(this.form, "createBy", this.userVal.userName);
  6857. this.$set(this.form, "fStorekeeper", this.userVal.nickName);
  6858. this.$set(this.form, "fIfdamage", "1");
  6859. this.$set(this.form, "fIfweigh", "1");
  6860. this.$set(this.form, "fTrademodeid", "1");
  6861. this.$set(this.form, "createTime", Date.parse(new Date()));
  6862. this.$set(this.form, "fBstime", Date.parse(new Date()));
  6863. this.$set(this.form, "fBusinessType", "5");
  6864. this.$set(this.form, "fFeetUnit", "2");
  6865. }
  6866. if (response.dept !== null) {
  6867. this.deptOptions = [];
  6868. this.deptOptions.push(response.dept);
  6869. }
  6870. });
  6871. },
  6872. //作业类型校验
  6873. educationChange() {
  6874. if (this.form.fBusinessType === "1" || this.form.fBusinessType === "2") {
  6875. this.isrequired = 1;
  6876. this.isrequired2 = 2;
  6877. } else if (
  6878. this.form.fBusinessType === "3" ||
  6879. this.form.fBusinessType === "4"
  6880. ) {
  6881. this.isrequired2 = 1;
  6882. this.isrequired = 2;
  6883. } else {
  6884. this.isrequired = 2;
  6885. this.isrequired2 = 2;
  6886. }
  6887. },
  6888. // 数量计算
  6889. changeContractAmt(row) {
  6890. let fQty = 0;
  6891. let fUnitprice = 0;
  6892. if (row.fUnitprice) {
  6893. fUnitprice = row.fUnitprice;
  6894. }
  6895. if (row.fQty) {
  6896. fQty = row.fQty;
  6897. }
  6898. this.$set(row, "fAmount", Number(fUnitprice) * Number(fQty)).toFixed(2);
  6899. },
  6900. // 变更计价单位
  6901. changeFeeUnit(row) {
  6902. if (!row.fFeeUnitid) {
  6903. return false;
  6904. }
  6905. if (row.fFeeUnitid === "2") {
  6906. this.$set(row, "fQty", (this.fGrossweight / 1000).toFixed(2));
  6907. } else if (row.fFeeUnitid === "1") {
  6908. this.$set(row, "fQty", this.fQty.toFixed(2));
  6909. } else if (row.fFeeUnitid === "3") {
  6910. this.$set(row, "fQty", (this.fNetweight / 1000).toFixed(2));
  6911. } else if (row.fFeeUnitid === "7") {
  6912. this.$set(row, "fQty", this.fCntqty);
  6913. } else {
  6914. this.$set(row, "fQty", 0);
  6915. }
  6916. if (row.fUnitprice) {
  6917. this.$set(
  6918. row,
  6919. "fAmount",
  6920. parseFloat(Number(row.fUnitprice) * Number(row.fQty)).toFixed(2)
  6921. );
  6922. }
  6923. },
  6924. //打印
  6925. addprint(status) {
  6926. // if (status == "zyd") {
  6927. // if (this.CntrTable.length > 0) {
  6928. // let arr = [];
  6929. // this.CntrTable.map((e) => {
  6930. // this.cntrList.map((item) => {
  6931. // if (item.fId == e.fCntrid) {
  6932. // arr.push(item.fName + "X" + e.fCntrcount);
  6933. // }
  6934. // });
  6935. // });
  6936. // arr = [...new Set(arr)];
  6937. // this.form.fCntval = arr.join(",");
  6938. // } else {
  6939. // this.form.fCntval = null;
  6940. // }
  6941. // if (this.detailList.length > 0) {
  6942. // let arr = [];
  6943. // this.detailList.map((e) => {
  6944. // this.goodsOptions.map((item) => {
  6945. // if (e.fGoodsid == item.fId) {
  6946. // arr.push(item.fName);
  6947. // }
  6948. // });
  6949. // });
  6950. // arr = [...new Set(arr)];
  6951. // this.form.fProductName = arr.join(",");
  6952. // } else {
  6953. // this.form.fProductName = "";
  6954. // }
  6955. // if (this.detailList.length > 0) {
  6956. // let arr = [];
  6957. // this.detailList.map((e) => {
  6958. // arr.push(e.fMarks);
  6959. // });
  6960. // arr = [...new Set(arr)];
  6961. // this.form.fMarks = arr.join(",");
  6962. // } else {
  6963. // this.form.fMarks = "";
  6964. // }
  6965. // this.form.fBillingway = this.form.fFeetUnit;
  6966. // if (this.detailList.length == 0) {
  6967. // this.form.fNetweight = 0;
  6968. // this.form.fPlanvolumn = 0;
  6969. // this.form.fGrossweight = 0;
  6970. // } else {
  6971. // this.form.fNetweight = this.fNetweight;
  6972. // this.form.fPlanvolumn = this.fPlanvolumn;
  6973. // this.form.fGrossweight = this.fGrossweight;
  6974. // }
  6975. // let formData = new window.FormData();
  6976. // formData.append("warehouseBills", JSON.stringify(this.form));
  6977. // formData.append(
  6978. // "warehousebillsitems",
  6979. // JSON.stringify(this.Printinglist)
  6980. // );
  6981. // formData.append(
  6982. // "warehousebillsfeesDr",
  6983. // JSON.stringify(this.warehouseDrList)
  6984. // );
  6985. // formData.append(
  6986. // "warehousebillsfeesCr",
  6987. // JSON.stringify(this.warehouseCrList)
  6988. // );
  6989. // formData.append("tEnclosure", JSON.stringify(this.relevantAttachments));
  6990. // formData.append("tCntr", JSON.stringify(this.CntrTable));
  6991. // addJoblist(formData).then((response) => {
  6992. // if (response.code == 200) {
  6993. // this.detailList.map((e, index) => {
  6994. // response.data.warehousebillsitems.map((item) => {
  6995. // item.fBsdate = Date.parse(new Date(item.fBsdate));
  6996. // if (item.fBusinessType) {
  6997. // item.fBusinessType = item.fBusinessType.toString();
  6998. // }
  6999. // if (e.fId == item.fId) {
  7000. // this.$set(this.detailList, index, item);
  7001. // }
  7002. // });
  7003. // });
  7004. // this.$set(this.form, "fItemsStatus", 2);
  7005. // }
  7006. // });
  7007. // }
  7008. const style =
  7009. "@page { } " +
  7010. "@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;}";
  7011. switch (status) {
  7012. case "zyd":
  7013. if (this.CntrTable.length > 0) {
  7014. let arr = [];
  7015. this.CntrTable.map((e) => {
  7016. this.cntrList.map((item) => {
  7017. if (item.fId == e.fCntrid) {
  7018. arr.push(item.fName + "X" + e.fCntrcount);
  7019. }
  7020. });
  7021. });
  7022. arr = [...new Set(arr)];
  7023. this.form.fCntval = arr.join(",");
  7024. } else {
  7025. this.form.fCntval = null;
  7026. }
  7027. if (this.detailList.length > 0) {
  7028. let arr = [];
  7029. this.detailList.map((e) => {
  7030. this.goodsOptions.map((item) => {
  7031. if (e.fGoodsid == item.fId) {
  7032. arr.push(item.fName);
  7033. }
  7034. });
  7035. });
  7036. arr = [...new Set(arr)];
  7037. this.form.fProductName = arr.join(",");
  7038. } else {
  7039. this.form.fProductName = "";
  7040. }
  7041. if (this.detailList.length > 0) {
  7042. let arr = [];
  7043. this.detailList.map((e) => {
  7044. arr.push(e.fMarks);
  7045. });
  7046. arr = [...new Set(arr)];
  7047. this.form.fMarks = arr.join(",");
  7048. } else {
  7049. this.form.fMarks = "";
  7050. }
  7051. this.form.fBillingway = this.form.fFeetUnit;
  7052. if (this.detailList.length == 0) {
  7053. this.form.fNetweight = 0;
  7054. this.form.fPlanvolumn = 0;
  7055. this.form.fGrossweight = 0;
  7056. } else {
  7057. this.form.fNetweight = this.fNetweight;
  7058. this.form.fPlanvolumn = this.fPlanvolumn;
  7059. this.form.fGrossweight = this.fGrossweight;
  7060. }
  7061. this.detailList = this.zcList
  7062. // let formData = new window.FormData();
  7063. // formData.append("warehouseBills", JSON.stringify(this.form));
  7064. // formData.append(
  7065. // "warehousebillsitems",
  7066. // JSON.stringify(this.Printinglist)
  7067. // );
  7068. // formData.append(
  7069. // "warehousebillsfeesDr",
  7070. // JSON.stringify(this.warehouseDrList)
  7071. // );
  7072. // formData.append(
  7073. // "warehousebillsfeesCr",
  7074. // JSON.stringify(this.warehouseCrList)
  7075. // );
  7076. // formData.append(
  7077. // "tEnclosure",
  7078. // JSON.stringify(this.relevantAttachments)
  7079. // );
  7080. // formData.append("tCntr", JSON.stringify(this.CntrTable));
  7081. // addJoblist(formData).then((response) => {
  7082. // if (response.code == 200) {
  7083. // this.$set(this.form, "fDateChanged", response.data.fDateChanged);
  7084. // this.detailList.map((e, index) => {
  7085. // response.data.warehousebillsitems.map((item) => {
  7086. // item.fBsdate = Date.parse(new Date(item.fBsdate));
  7087. // if (item.fBusinessType) {
  7088. // item.fBusinessType = item.fBusinessType.toString();
  7089. // }
  7090. // if (e.fId == item.fId) {
  7091. // this.$set(this.detailList, index, item);
  7092. // }
  7093. // });
  7094. // });
  7095. // this.$set(this.form, "fItemsStatus", 2);
  7096. // }
  7097. // });
  7098. print({
  7099. printable: "print_area1",
  7100. type: "html",
  7101. style: style, // 亦可使用引入的外部css;
  7102. scanStyles: false,
  7103. });
  7104. break;
  7105. case "rkd":
  7106. print({
  7107. printable: "print_area2",
  7108. type: "html",
  7109. style: style, // 亦可使用引入的外部css;
  7110. scanStyles: false,
  7111. });
  7112. break;
  7113. case "crzyd":
  7114. print({
  7115. printable: "print_Cr",
  7116. type: "html",
  7117. style: style, // 亦可使用引入的外部css;
  7118. scanStyles: false,
  7119. });
  7120. break;
  7121. case "bzckd":
  7122. print({
  7123. printable: "print_area3",
  7124. type: "html",
  7125. style: style, // 亦可使用引入的外部css;
  7126. scanStyles: false,
  7127. });
  7128. break;
  7129. case "xqckd":
  7130. print({
  7131. printable: "print_areaDetail",
  7132. type: "html",
  7133. style: style, // 亦可使用引入的外部css;
  7134. scanStyles: false,
  7135. });
  7136. break;
  7137. case "lhd":
  7138. print({
  7139. printable: "print_area5",
  7140. type: "html",
  7141. style: style, // 亦可使用引入的外部css;
  7142. scanStyles: false,
  7143. });
  7144. break;
  7145. case "dcckd":
  7146. print({
  7147. printable: "print_area7",
  7148. type: "html",
  7149. style: style, // 亦可使用引入的外部css;
  7150. scanStyles: false,
  7151. });
  7152. break;
  7153. case "zccdckd":
  7154. print({
  7155. printable: "print_area8",
  7156. type: "html",
  7157. style: style, // 亦可使用引入的外部css;
  7158. scanStyles: false,
  7159. });
  7160. break;
  7161. case "lwqr":
  7162. print({
  7163. printable: "print_area10",
  7164. type: "html",
  7165. style: style, // 亦可使用引入的外部css;
  7166. scanStyles: false,
  7167. });
  7168. break;
  7169. case "ccckd":
  7170. print({
  7171. printable: "print_area6",
  7172. type: "html",
  7173. style: style, // 亦可使用引入的外部css;
  7174. scanStyles: false,
  7175. });
  7176. break;
  7177. }
  7178. },
  7179. cancel() {
  7180. if (this.$route.query.id) {
  7181. this.$router.push({query: {}});
  7182. }
  7183. this.resetForm("form");
  7184. this.detailList = [];
  7185. this.relevantAttachments = [];
  7186. this.warehouseCrList = [];
  7187. this.warehouseDrList = [];
  7188. this.CntrTable = [];
  7189. this.$emit("changeShow", "true");
  7190. },
  7191. goBack() {
  7192. this.$confirm("是否确定返回列表?", "提示", {
  7193. confirmButtonText: "保存",
  7194. cancelButtonText: "取消",
  7195. type: "warning",
  7196. })
  7197. .then(() => {
  7198. this.saveForm("goBack");
  7199. })
  7200. .catch(() => {
  7201. this.cancel();
  7202. });
  7203. },
  7204. feeChange(fDC) {
  7205. let data = {
  7206. form: {},
  7207. warehousebillsfeesCr: [],
  7208. warehousebillsfeesDr: [],
  7209. billType: 'outStock',
  7210. fDc: fDC
  7211. }
  7212. data.form = this.form
  7213. if (fDC == 'C') {
  7214. data.warehousebillsfeesCr = this.warehouseCrList
  7215. } else {
  7216. data.warehousebillsfeesDr = this.warehouseDrList
  7217. }
  7218. this.$router.push({
  7219. path: "/business/costModify",
  7220. query: { data: data},
  7221. });
  7222. },
  7223. // 付款信息请核
  7224. checkRow(index, rows) {
  7225. if (!rows[index].fQty) {
  7226. this.$message.error("请维护数量")
  7227. return false
  7228. }
  7229. if (!rows[index].fUnitprice) {
  7230. this.$message.error("请维护单价")
  7231. return false
  7232. }
  7233. if (!rows[index].fAmount) {
  7234. this.$message.error("请维护金额")
  7235. return false
  7236. }
  7237. rows[index].fBillstatus = 6
  7238. let formData = new window.FormData();
  7239. formData.append("warehouseBills", JSON.stringify(this.form));
  7240. this.detailList.forEach(item => {
  7241. if (item.srcId !== null) {
  7242. console.log('第三个')
  7243. // item.fStorageFeeDeadline = item.fBsdate
  7244. }
  7245. })
  7246. // 费用明细付款
  7247. formData.append(
  7248. "warehousebillsfeesCr",
  7249. JSON.stringify(this.warehouseCrList)
  7250. );
  7251. // 库存明细
  7252. formData.append(
  7253. "warehousebillsitems",
  7254. JSON.stringify(this.detailList)
  7255. );
  7256. formData.append(
  7257. "tEnclosure",
  7258. JSON.stringify(this.relevantAttachments)
  7259. );
  7260. // 收款
  7261. formData.append(
  7262. "warehousebillsfeesDr",
  7263. JSON.stringify(this.warehouseDrList)
  7264. );
  7265. formData.append("mblnoStatus", JSON.stringify(this.mblnoStatus));
  7266. formData.append("tCntr", JSON.stringify(this.CntrTable));
  7267. addWarehousebills(formData).then(res => {
  7268. this.msgSuccess("请核成功");
  7269. })
  7270. },
  7271. revokeRow(index, rows) {
  7272. rows[index].fBillstatus = 2
  7273. let formData = new window.FormData();
  7274. formData.append("warehouseBills", JSON.stringify(this.form));
  7275. this.detailList.forEach(item => {
  7276. if (item.srcId !== null) {
  7277. console.log('第四个')
  7278. // item.fStorageFeeDeadline = item.fBsdate
  7279. }
  7280. })
  7281. // 费用明细付款
  7282. formData.append(
  7283. "warehousebillsfeesCr",
  7284. JSON.stringify(this.warehouseCrList)
  7285. );
  7286. // 库存明细
  7287. formData.append(
  7288. "warehousebillsitems",
  7289. JSON.stringify(this.detailList)
  7290. );
  7291. formData.append(
  7292. "tEnclosure",
  7293. JSON.stringify(this.relevantAttachments)
  7294. );
  7295. // 收款
  7296. formData.append(
  7297. "warehousebillsfeesDr",
  7298. JSON.stringify(this.warehouseDrList)
  7299. );
  7300. formData.append("mblnoStatus", JSON.stringify(this.mblnoStatus));
  7301. formData.append("tCntr", JSON.stringify(this.CntrTable));
  7302. addWarehousebills(formData).then(res => {
  7303. this.msgSuccess("撤销成功");
  7304. })
  7305. },
  7306. // 费用明细请核
  7307. listCheck(row) {
  7308. feesCheck(row.fId).then(res => {
  7309. this.$message.success('请核成功')
  7310. res.data.fFeeUnitid = res.data.fFeeunitid.toString();
  7311. if (res.data.fDc == 'D') {
  7312. let index = this.warehouseDrList.findIndex(item => item.fId == res.data.fId)
  7313. this.warehouseDrList.splice(index, 1, res.data)
  7314. } else {
  7315. let index = this.warehouseCrList.findIndex(item => item.fId == res.data.fId)
  7316. this.warehouseCrList.splice(index, 1, res.data)
  7317. }
  7318. })
  7319. },
  7320. // 费用明细撤销请核
  7321. revokeListCheck(row) {
  7322. revokefeeCheck(row.fId).then(res => {
  7323. res.data.fFeeUnitid = res.data.fFeeunitid.toString();
  7324. this.$message.success('操作成功')
  7325. if (res.data.fDc == 'D') {
  7326. let index = this.warehouseDrList.findIndex(item => item.fId == res.data.fId)
  7327. this.warehouseDrList.splice(index, 1, res.data)
  7328. } else {
  7329. let index = this.warehouseCrList.findIndex(item => item.fId == res.data.fId)
  7330. this.warehouseCrList.splice(index, 1, res.data)
  7331. }
  7332. })
  7333. },
  7334. // 获取仓库信息
  7335. warehouseChange() {
  7336. getDept(this.form.fWarehouseid).then(res => {
  7337. this.$set(this.form, 'fContacts', res.data.fContacts)
  7338. this.$set(this.form, 'fTel', res.data.fTel)
  7339. })
  7340. },
  7341. },
  7342. watch: {
  7343. // 监听 addOrUpdateVisible 改变
  7344. addOrUpdateVisible(oldVal, newVal) {
  7345. this.showDialog = this.addOrUpdateVisible;
  7346. },
  7347. },
  7348. };
  7349. </script>
  7350. <style lang="scss" scoped>
  7351. .tag-hover:hover {
  7352. background-color: #d9ebfb;
  7353. }
  7354. .tag-hover {
  7355. border-top-left-radius: 0;
  7356. border-bottom-left-radius: 0;
  7357. height: 15px;
  7358. padding: 0px 1px;
  7359. line-height: 12px;
  7360. }
  7361. .print-div {
  7362. color: #000;
  7363. }
  7364. .print_table {
  7365. table {
  7366. border-right: 1px solid #000;
  7367. border-bottom: 1px solid #000;
  7368. font-size: 12px;
  7369. margin-bottom: 5px;
  7370. }
  7371. table td {
  7372. border-left: 1px solid #000;
  7373. border-top: 1px solid #000;
  7374. vertical-align: middle;
  7375. padding: 2px;
  7376. text-align: center;
  7377. }
  7378. }
  7379. .print_form {
  7380. font-size: 12px;
  7381. }
  7382. .receiptForm ::v-deep .el-dialog {
  7383. box-shadow: none;
  7384. }
  7385. .receiptForm ::v-deep .el-table__body-wrapper {
  7386. z-index: 2
  7387. }
  7388. .receiptForm ::v-deep .el-dialog__header {
  7389. padding: 0;
  7390. }
  7391. .receiptForm ::v-deep .el-dialog__body {
  7392. padding: 0 20px;
  7393. }
  7394. .table {
  7395. border-collapse: collapse;
  7396. border-spacing: 0;
  7397. background-color: transparent;
  7398. display: table;
  7399. width: 99%;
  7400. max-width: 100%;
  7401. margin: 0 auto;
  7402. }
  7403. .table td {
  7404. text-align: left;
  7405. vertical-align: middle;
  7406. font-size: 14px;
  7407. color: #000000;
  7408. padding: 10.5px 0 10.5px 30px;
  7409. //border: 1px solid #000;
  7410. }
  7411. </style>