index.vue 219 KB

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