| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545554655475548554955505551555255535554555555565557555855595560556155625563556455655566556755685569557055715572557355745575557655775578557955805581558255835584558555865587558855895590559155925593559455955596559755985599560056015602560356045605560656075608560956105611561256135614561556165617561856195620562156225623562456255626562756285629563056315632563356345635563656375638563956405641564256435644564556465647564856495650565156525653565456555656565756585659566056615662566356645665566656675668566956705671567256735674567556765677567856795680568156825683568456855686568756885689569056915692569356945695569656975698569957005701570257035704570557065707570857095710571157125713571457155716571757185719572057215722572357245725572657275728572957305731573257335734573557365737573857395740574157425743574457455746574757485749575057515752575357545755575657575758575957605761576257635764576557665767576857695770577157725773577457755776577757785779578057815782578357845785578657875788578957905791579257935794579557965797579857995800580158025803580458055806580758085809581058115812581358145815581658175818581958205821582258235824582558265827582858295830583158325833583458355836583758385839584058415842584358445845584658475848584958505851585258535854585558565857585858595860586158625863586458655866586758685869587058715872587358745875587658775878587958805881588258835884588558865887588858895890589158925893589458955896589758985899590059015902590359045905590659075908590959105911591259135914591559165917591859195920592159225923592459255926592759285929593059315932593359345935593659375938593959405941594259435944594559465947594859495950595159525953595459555956595759585959596059615962596359645965596659675968596959705971597259735974597559765977597859795980598159825983598459855986598759885989599059915992599359945995599659975998599960006001600260036004600560066007600860096010601160126013601460156016601760186019602060216022602360246025602660276028602960306031603260336034603560366037603860396040604160426043604460456046604760486049605060516052605360546055605660576058605960606061606260636064606560666067606860696070607160726073607460756076607760786079608060816082608360846085608660876088608960906091609260936094609560966097609860996100610161026103610461056106610761086109611061116112611361146115611661176118611961206121612261236124612561266127612861296130613161326133613461356136613761386139614061416142614361446145614661476148614961506151615261536154615561566157615861596160616161626163616461656166616761686169617061716172617361746175617661776178617961806181618261836184618561866187618861896190619161926193619461956196619761986199620062016202620362046205620662076208620962106211621262136214621562166217621862196220622162226223622462256226622762286229623062316232623362346235623662376238623962406241624262436244624562466247624862496250625162526253625462556256625762586259626062616262626362646265626662676268626962706271627262736274627562766277627862796280628162826283628462856286628762886289629062916292629362946295629662976298629963006301630263036304630563066307630863096310631163126313631463156316631763186319632063216322632363246325632663276328632963306331633263336334633563366337633863396340634163426343634463456346634763486349635063516352635363546355635663576358635963606361636263636364636563666367636863696370637163726373637463756376637763786379638063816382638363846385638663876388638963906391639263936394639563966397639863996400640164026403640464056406640764086409641064116412641364146415641664176418641964206421642264236424642564266427642864296430643164326433643464356436643764386439644064416442644364446445644664476448644964506451645264536454645564566457645864596460646164626463646464656466646764686469647064716472647364746475647664776478647964806481648264836484648564866487648864896490649164926493649464956496649764986499650065016502650365046505650665076508650965106511651265136514651565166517651865196520652165226523652465256526652765286529653065316532653365346535653665376538653965406541654265436544654565466547654865496550655165526553655465556556655765586559656065616562656365646565656665676568656965706571657265736574657565766577657865796580658165826583658465856586658765886589659065916592659365946595659665976598659966006601660266036604660566066607660866096610661166126613661466156616661766186619662066216622662366246625662666276628662966306631663266336634663566366637663866396640664166426643664466456646664766486649665066516652665366546655665666576658665966606661666266636664666566666667666866696670667166726673667466756676667766786679668066816682668366846685668666876688668966906691669266936694669566966697669866996700670167026703670467056706670767086709671067116712671367146715671667176718671967206721672267236724672567266727672867296730673167326733673467356736673767386739674067416742674367446745674667476748674967506751675267536754675567566757675867596760676167626763676467656766676767686769677067716772677367746775677667776778677967806781678267836784678567866787678867896790679167926793679467956796679767986799680068016802680368046805680668076808680968106811681268136814681568166817681868196820682168226823682468256826682768286829683068316832683368346835683668376838683968406841684268436844684568466847684868496850685168526853685468556856685768586859686068616862686368646865686668676868686968706871687268736874687568766877687868796880688168826883688468856886688768886889689068916892689368946895689668976898689969006901690269036904690569066907690869096910691169126913691469156916691769186919692069216922692369246925692669276928692969306931693269336934693569366937693869396940694169426943694469456946694769486949695069516952695369546955695669576958695969606961696269636964696569666967696869696970697169726973697469756976697769786979698069816982698369846985698669876988698969906991699269936994699569966997699869997000700170027003700470057006700770087009701070117012701370147015701670177018701970207021702270237024702570267027702870297030703170327033703470357036703770387039704070417042704370447045704670477048704970507051705270537054705570567057705870597060706170627063706470657066706770687069707070717072707370747075707670777078707970807081708270837084708570867087708870897090709170927093709470957096709770987099710071017102710371047105710671077108710971107111711271137114711571167117711871197120712171227123712471257126712771287129713071317132713371347135713671377138713971407141714271437144714571467147714871497150715171527153715471557156715771587159716071617162716371647165716671677168716971707171717271737174717571767177717871797180718171827183718471857186718771887189719071917192719371947195719671977198719972007201720272037204720572067207720872097210721172127213721472157216721772187219722072217222722372247225722672277228722972307231723272337234723572367237723872397240724172427243724472457246724772487249725072517252725372547255725672577258725972607261726272637264726572667267726872697270727172727273727472757276727772787279728072817282728372847285728672877288728972907291729272937294729572967297729872997300730173027303730473057306730773087309731073117312731373147315731673177318731973207321732273237324732573267327732873297330733173327333733473357336733773387339734073417342734373447345734673477348734973507351735273537354735573567357735873597360736173627363736473657366736773687369737073717372737373747375737673777378737973807381738273837384738573867387738873897390739173927393739473957396739773987399740074017402740374047405740674077408740974107411741274137414741574167417741874197420742174227423742474257426742774287429743074317432743374347435743674377438743974407441744274437444744574467447744874497450745174527453745474557456745774587459746074617462746374647465746674677468746974707471747274737474747574767477747874797480748174827483748474857486748774887489749074917492749374947495749674977498749975007501750275037504750575067507750875097510751175127513751475157516751775187519752075217522752375247525752675277528752975307531753275337534753575367537753875397540754175427543754475457546754775487549755075517552755375547555755675577558755975607561756275637564756575667567756875697570757175727573757475757576757775787579758075817582758375847585758675877588758975907591759275937594759575967597759875997600760176027603760476057606760776087609761076117612761376147615761676177618761976207621762276237624762576267627762876297630763176327633763476357636763776387639764076417642764376447645764676477648764976507651765276537654765576567657765876597660766176627663766476657666766776687669767076717672767376747675767676777678767976807681768276837684768576867687768876897690769176927693769476957696769776987699770077017702770377047705770677077708770977107711771277137714771577167717771877197720772177227723772477257726772777287729773077317732773377347735773677377738773977407741774277437744774577467747774877497750775177527753775477557756775777587759776077617762776377647765776677677768776977707771777277737774777577767777777877797780778177827783778477857786778777887789779077917792779377947795779677977798779978007801780278037804780578067807780878097810781178127813781478157816781778187819782078217822782378247825782678277828782978307831783278337834783578367837783878397840784178427843784478457846784778487849785078517852785378547855785678577858785978607861786278637864786578667867786878697870787178727873787478757876787778787879788078817882788378847885788678877888788978907891789278937894789578967897789878997900790179027903790479057906790779087909791079117912791379147915791679177918791979207921792279237924792579267927792879297930793179327933793479357936793779387939794079417942794379447945794679477948794979507951795279537954795579567957795879597960796179627963796479657966796779687969797079717972797379747975797679777978797979807981798279837984798579867987798879897990799179927993799479957996799779987999800080018002800380048005800680078008800980108011801280138014801580168017801880198020802180228023802480258026802780288029803080318032803380348035803680378038803980408041804280438044804580468047804880498050805180528053805480558056805780588059806080618062806380648065806680678068806980708071807280738074807580768077807880798080808180828083808480858086808780888089809080918092809380948095809680978098809981008101810281038104810581068107810881098110811181128113811481158116811781188119812081218122812381248125812681278128812981308131813281338134813581368137813881398140814181428143814481458146814781488149815081518152815381548155815681578158815981608161816281638164816581668167816881698170817181728173817481758176817781788179818081818182818381848185818681878188818981908191819281938194819581968197819881998200820182028203820482058206820782088209821082118212821382148215821682178218821982208221822282238224822582268227822882298230823182328233823482358236823782388239824082418242824382448245824682478248824982508251825282538254825582568257825882598260826182628263826482658266826782688269827082718272827382748275827682778278827982808281828282838284828582868287828882898290829182928293829482958296829782988299830083018302830383048305830683078308830983108311831283138314831583168317831883198320832183228323832483258326832783288329833083318332833383348335833683378338833983408341834283438344834583468347834883498350835183528353835483558356835783588359836083618362836383648365836683678368836983708371837283738374837583768377837883798380838183828383838483858386838783888389839083918392839383948395839683978398839984008401840284038404840584068407840884098410841184128413841484158416841784188419842084218422842384248425842684278428842984308431843284338434843584368437843884398440844184428443844484458446844784488449845084518452845384548455845684578458845984608461846284638464846584668467846884698470847184728473847484758476847784788479848084818482848384848485848684878488848984908491849284938494849584968497849884998500850185028503850485058506850785088509851085118512851385148515851685178518851985208521852285238524852585268527852885298530853185328533853485358536853785388539854085418542854385448545854685478548854985508551855285538554855585568557855885598560856185628563856485658566856785688569857085718572857385748575857685778578857985808581858285838584858585868587858885898590859185928593859485958596859785988599860086018602860386048605860686078608860986108611861286138614861586168617861886198620862186228623862486258626862786288629863086318632863386348635863686378638863986408641864286438644864586468647864886498650865186528653865486558656865786588659866086618662866386648665866686678668866986708671867286738674867586768677867886798680868186828683868486858686868786888689869086918692869386948695869686978698869987008701870287038704870587068707870887098710871187128713871487158716871787188719872087218722872387248725872687278728872987308731873287338734873587368737873887398740874187428743874487458746874787488749875087518752875387548755875687578758875987608761876287638764876587668767876887698770877187728773877487758776877787788779878087818782878387848785878687878788878987908791879287938794879587968797879887998800880188028803880488058806880788088809881088118812881388148815881688178818881988208821882288238824882588268827882888298830883188328833883488358836883788388839884088418842884388448845884688478848884988508851885288538854885588568857885888598860886188628863886488658866886788688869887088718872887388748875887688778878887988808881888288838884888588868887888888898890889188928893889488958896889788988899890089018902890389048905890689078908890989108911891289138914891589168917891889198920892189228923892489258926892789288929893089318932893389348935893689378938893989408941894289438944894589468947894889498950895189528953895489558956895789588959896089618962896389648965896689678968896989708971897289738974897589768977897889798980898189828983898489858986898789888989899089918992899389948995899689978998899990009001900290039004900590069007900890099010901190129013901490159016901790189019902090219022902390249025902690279028902990309031903290339034903590369037903890399040904190429043904490459046904790489049905090519052905390549055905690579058905990609061906290639064906590669067906890699070907190729073907490759076907790789079908090819082908390849085908690879088908990909091909290939094909590969097909890999100910191029103910491059106910791089109911091119112911391149115911691179118911991209121912291239124912591269127912891299130913191329133913491359136913791389139914091419142914391449145914691479148914991509151915291539154915591569157915891599160916191629163916491659166916791689169917091719172917391749175917691779178917991809181918291839184918591869187918891899190919191929193919491959196919791989199920092019202920392049205920692079208920992109211921292139214921592169217921892199220922192229223922492259226922792289229923092319232923392349235923692379238923992409241924292439244924592469247924892499250925192529253925492559256925792589259926092619262926392649265926692679268926992709271927292739274927592769277927892799280928192829283928492859286928792889289929092919292929392949295929692979298929993009301930293039304930593069307930893099310931193129313931493159316931793189319932093219322932393249325932693279328932993309331933293339334933593369337933893399340934193429343934493459346934793489349935093519352935393549355935693579358935993609361936293639364936593669367936893699370937193729373937493759376937793789379938093819382938393849385938693879388938993909391939293939394939593969397939893999400940194029403940494059406940794089409941094119412941394149415941694179418941994209421942294239424942594269427942894299430943194329433943494359436943794389439944094419442944394449445944694479448944994509451945294539454945594569457945894599460946194629463946494659466946794689469947094719472947394749475947694779478947994809481948294839484948594869487948894899490949194929493949494959496949794989499950095019502950395049505950695079508950995109511951295139514951595169517951895199520952195229523952495259526952795289529953095319532953395349535953695379538953995409541954295439544954595469547954895499550955195529553955495559556955795589559956095619562956395649565956695679568956995709571957295739574957595769577957895799580958195829583958495859586958795889589959095919592959395949595959695979598959996009601960296039604960596069607960896099610961196129613961496159616961796189619962096219622962396249625962696279628962996309631963296339634963596369637963896399640964196429643964496459646964796489649965096519652965396549655965696579658965996609661966296639664966596669667966896699670967196729673967496759676967796789679968096819682968396849685968696879688968996909691969296939694969596969697969896999700970197029703970497059706970797089709971097119712971397149715971697179718971997209721972297239724972597269727972897299730973197329733973497359736973797389739974097419742974397449745974697479748974997509751975297539754975597569757975897599760976197629763976497659766976797689769977097719772977397749775977697779778977997809781978297839784978597869787978897899790979197929793979497959796979797989799980098019802980398049805980698079808980998109811981298139814981598169817981898199820982198229823982498259826982798289829983098319832983398349835983698379838983998409841984298439844984598469847984898499850985198529853985498559856985798589859986098619862986398649865986698679868986998709871987298739874987598769877987898799880988198829883988498859886988798889889989098919892989398949895989698979898989999009901990299039904990599069907990899099910991199129913991499159916991799189919992099219922992399249925992699279928992999309931993299339934993599369937993899399940994199429943994499459946994799489949995099519952995399549955995699579958995999609961996299639964996599669967996899699970997199729973997499759976997799789979998099819982998399849985998699879988998999909991999299939994999599969997999899991000010001100021000310004100051000610007100081000910010100111001210013100141001510016100171001810019100201002110022100231002410025100261002710028100291003010031100321003310034100351003610037100381003910040100411004210043100441004510046100471004810049100501005110052100531005410055100561005710058100591006010061100621006310064100651006610067100681006910070100711007210073100741007510076100771007810079100801008110082100831008410085100861008710088100891009010091100921009310094100951009610097100981009910100101011010210103101041010510106101071010810109101101011110112101131011410115101161011710118101191012010121101221012310124101251012610127101281012910130101311013210133101341013510136101371013810139101401014110142101431014410145101461014710148101491015010151101521015310154101551015610157101581015910160101611016210163101641016510166101671016810169101701017110172101731017410175101761017710178101791018010181101821018310184101851018610187101881018910190101911019210193101941019510196101971019810199102001020110202102031020410205102061020710208102091021010211102121021310214102151021610217102181021910220102211022210223102241022510226102271022810229102301023110232102331023410235102361023710238102391024010241102421024310244102451024610247102481024910250102511025210253102541025510256102571025810259102601026110262102631026410265102661026710268102691027010271102721027310274102751027610277102781027910280102811028210283102841028510286102871028810289102901029110292102931029410295102961029710298102991030010301103021030310304103051030610307103081030910310103111031210313103141031510316103171031810319103201032110322103231032410325103261032710328103291033010331103321033310334103351033610337103381033910340103411034210343103441034510346103471034810349103501035110352103531035410355103561035710358103591036010361103621036310364103651036610367103681036910370103711037210373103741037510376103771037810379103801038110382103831038410385103861038710388103891039010391103921039310394103951039610397103981039910400104011040210403104041040510406104071040810409104101041110412104131041410415104161041710418104191042010421104221042310424104251042610427104281042910430104311043210433104341043510436104371043810439104401044110442104431044410445104461044710448104491045010451104521045310454104551045610457104581045910460104611046210463104641046510466104671046810469104701047110472104731047410475104761047710478104791048010481104821048310484104851048610487104881048910490104911049210493104941049510496104971049810499105001050110502105031050410505105061050710508105091051010511105121051310514105151051610517105181051910520105211052210523105241052510526105271052810529105301053110532105331053410535105361053710538105391054010541105421054310544105451054610547105481054910550105511055210553105541055510556105571055810559105601056110562105631056410565105661056710568105691057010571105721057310574105751057610577105781057910580105811058210583105841058510586105871058810589105901059110592105931059410595105961059710598105991060010601106021060310604106051060610607106081060910610106111061210613106141061510616106171061810619106201062110622106231062410625106261062710628106291063010631106321063310634106351063610637106381063910640106411064210643106441064510646106471064810649106501065110652106531065410655106561065710658106591066010661106621066310664106651066610667106681066910670106711067210673106741067510676106771067810679106801068110682106831068410685106861068710688106891069010691106921069310694106951069610697106981069910700107011070210703107041070510706107071070810709107101071110712107131071410715107161071710718107191072010721107221072310724107251072610727107281072910730107311073210733107341073510736107371073810739107401074110742107431074410745107461074710748107491075010751107521075310754107551075610757107581075910760107611076210763107641076510766107671076810769107701077110772107731077410775107761077710778107791078010781107821078310784107851078610787107881078910790107911079210793107941079510796107971079810799108001080110802108031080410805108061080710808108091081010811108121081310814108151081610817108181081910820108211082210823108241082510826108271082810829108301083110832108331083410835108361083710838108391084010841108421084310844108451084610847108481084910850108511085210853108541085510856108571085810859108601086110862108631086410865108661086710868108691087010871108721087310874108751087610877108781087910880108811088210883108841088510886108871088810889108901089110892108931089410895108961089710898108991090010901109021090310904109051090610907109081090910910109111091210913109141091510916109171091810919109201092110922109231092410925109261092710928109291093010931109321093310934109351093610937109381093910940109411094210943109441094510946109471094810949109501095110952109531095410955109561095710958109591096010961109621096310964109651096610967109681096910970109711097210973109741097510976109771097810979109801098110982109831098410985109861098710988109891099010991109921099310994109951099610997109981099911000110011100211003110041100511006110071100811009110101101111012110131101411015110161101711018110191102011021110221102311024110251102611027110281102911030110311103211033110341103511036110371103811039110401104111042110431104411045110461104711048110491105011051110521105311054110551105611057110581105911060110611106211063110641106511066110671106811069110701107111072110731107411075110761107711078110791108011081110821108311084110851108611087110881108911090110911109211093110941109511096110971109811099111001110111102111031110411105111061110711108111091111011111111121111311114111151111611117111181111911120111211112211123111241112511126111271112811129111301113111132111331113411135111361113711138111391114011141111421114311144111451114611147111481114911150111511115211153111541115511156111571115811159111601116111162111631116411165111661116711168111691117011171111721117311174111751117611177111781117911180111811118211183111841118511186111871118811189111901119111192111931119411195111961119711198111991120011201112021120311204112051120611207112081120911210112111121211213112141121511216112171121811219112201122111222112231122411225112261122711228112291123011231112321123311234112351123611237112381123911240112411124211243112441124511246112471124811249112501125111252112531125411255112561125711258112591126011261112621126311264112651126611267112681126911270112711127211273112741127511276112771127811279112801128111282112831128411285112861128711288112891129011291112921129311294112951129611297112981129911300113011130211303113041130511306113071130811309113101131111312113131131411315113161131711318113191132011321113221132311324113251132611327113281132911330113311133211333113341133511336113371133811339113401134111342113431134411345113461134711348113491135011351113521135311354113551135611357113581135911360113611136211363113641136511366113671136811369113701137111372113731137411375113761137711378113791138011381113821138311384113851138611387113881138911390113911139211393113941139511396113971139811399114001140111402114031140411405114061140711408114091141011411114121141311414114151141611417114181141911420114211142211423114241142511426114271142811429114301143111432114331143411435114361143711438114391144011441114421144311444114451144611447114481144911450114511145211453114541145511456114571145811459114601146111462114631146411465114661146711468114691147011471114721147311474114751147611477114781147911480114811148211483114841148511486114871148811489114901149111492114931149411495114961149711498114991150011501115021150311504115051150611507115081150911510115111151211513115141151511516115171151811519115201152111522115231152411525115261152711528115291153011531115321153311534115351153611537115381153911540115411154211543115441154511546115471154811549115501155111552115531155411555115561155711558115591156011561115621156311564115651156611567115681156911570115711157211573115741157511576115771157811579115801158111582115831158411585115861158711588115891159011591115921159311594115951159611597115981159911600116011160211603116041160511606116071160811609116101161111612116131161411615116161161711618116191162011621116221162311624116251162611627116281162911630116311163211633116341163511636116371163811639116401164111642116431164411645116461164711648116491165011651116521165311654116551165611657116581165911660116611166211663116641166511666116671166811669116701167111672116731167411675116761167711678116791168011681116821168311684116851168611687116881168911690116911169211693116941169511696116971169811699117001170111702117031170411705117061170711708117091171011711117121171311714117151171611717117181171911720117211172211723117241172511726117271172811729117301173111732117331173411735117361173711738117391174011741117421174311744117451174611747117481174911750117511175211753117541175511756117571175811759117601176111762117631176411765117661176711768117691177011771117721177311774117751177611777117781177911780117811178211783117841178511786117871178811789117901179111792117931179411795117961179711798117991180011801118021180311804118051180611807118081180911810118111181211813118141181511816118171181811819118201182111822118231182411825118261182711828118291183011831118321183311834118351183611837118381183911840118411184211843118441184511846118471184811849118501185111852118531185411855118561185711858118591186011861118621186311864118651186611867118681186911870118711187211873118741187511876118771187811879118801188111882118831188411885118861188711888118891189011891118921189311894118951189611897118981189911900119011190211903119041190511906119071190811909119101191111912119131191411915119161191711918119191192011921119221192311924119251192611927119281192911930119311193211933119341193511936119371193811939119401194111942119431194411945119461194711948119491195011951119521195311954119551195611957119581195911960119611196211963119641196511966 |
- if (typeof Promise !== "undefined" && !Promise.prototype.finally) {
- Promise.prototype.finally = function(callback) {
- const promise = this.constructor;
- return this.then(
- (value) => promise.resolve(callback()).then(() => value),
- (reason) => promise.resolve(callback()).then(() => {
- throw reason;
- })
- );
- };
- }
- ;
- if (typeof uni !== "undefined" && uni && uni.requireGlobal) {
- const global = uni.requireGlobal();
- ArrayBuffer = global.ArrayBuffer;
- Int8Array = global.Int8Array;
- Uint8Array = global.Uint8Array;
- Uint8ClampedArray = global.Uint8ClampedArray;
- Int16Array = global.Int16Array;
- Uint16Array = global.Uint16Array;
- Int32Array = global.Int32Array;
- Uint32Array = global.Uint32Array;
- Float32Array = global.Float32Array;
- Float64Array = global.Float64Array;
- BigInt64Array = global.BigInt64Array;
- BigUint64Array = global.BigUint64Array;
- }
- ;
- if (uni.restoreGlobal) {
- uni.restoreGlobal(Vue, weex, plus, setTimeout, clearTimeout, setInterval, clearInterval);
- }
- (function(vue) {
- "use strict";
- const _export_sfc = (sfc, props) => {
- const target = sfc.__vccOpts || sfc;
- for (const [key, val] of props) {
- target[key] = val;
- }
- return target;
- };
- const _sfc_main$D = {
- name: "privacy-popup",
- props: {
- visible: {
- type: Boolean,
- default: false
- },
- title: {
- type: String,
- default: "协议标题"
- },
- content: {
- type: String,
- // 备用,主要用 slot
- default: ""
- }
- },
- methods: {
- close() {
- this.$emit("close");
- }
- }
- };
- function _sfc_render$C(_ctx, _cache, $props, $setup, $data, $options) {
- return $props.visible ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "popup-mask",
- onClick: _cache[2] || (_cache[2] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "popup-content" }, [
- vue.createElementVNode("view", { class: "popup-header" }, [
- vue.createElementVNode(
- "text",
- { class: "popup-title" },
- vue.toDisplayString($props.title),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("view", {
- class: "close-icon",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.close && $options.close(...args))
- }, "×")
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "popup-body"
- }, [
- vue.renderSlot(_ctx.$slots, "default", {}, () => [
- vue.createElementVNode(
- "text",
- { class: "default-text" },
- vue.toDisplayString($props.content),
- 1
- /* TEXT */
- )
- ], true)
- ]),
- vue.createElementVNode("view", { class: "popup-footer" }, [
- vue.createElementVNode("button", {
- class: "confirm-btn",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.close && $options.close(...args))
- }, "我知道了")
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true);
- }
- const __easycom_0 = /* @__PURE__ */ _export_sfc(_sfc_main$D, [["render", _sfc_render$C], ["__scopeId", "data-v-af3fbef1"], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/components/privacy-popup/privacy-popup.vue"]]);
- function formatAppLog(type, filename, ...args) {
- if (uni.__log__) {
- uni.__log__(type, filename, ...args);
- } else {
- console[type].apply(console, [...args, filename]);
- }
- }
- function resolveEasycom(component, easycom) {
- return typeof component === "string" ? easycom : component;
- }
- const BASE_URL = "http://192.168.1.118:8080";
- const CLIENT_ID = "3";
- const PLATFORM_CODE = "FlfAppPlatformCodeX9kR7mT3wQ5vZ8nB1jY6pD4sL0hC2gA";
- const PLATFORM_ID = 2;
- const TENANT_ID = "000000";
- const TOKEN_KEY = "fulfiller_token";
- const USER_INFO_KEY = "fulfiller_user_info";
- function getToken() {
- return uni.getStorageSync(TOKEN_KEY) || "";
- }
- function setToken(token) {
- uni.setStorageSync(TOKEN_KEY, token);
- }
- function removeToken() {
- uni.removeStorageSync(TOKEN_KEY);
- }
- function isLoggedIn() {
- return !!getToken();
- }
- function removeUserInfo() {
- uni.removeStorageSync(USER_INFO_KEY);
- }
- function clearAuth() {
- removeToken();
- removeUserInfo();
- }
- function request(options = {}) {
- const {
- url,
- method = "GET",
- data,
- header = {},
- needToken = true
- } = options;
- const headers = {
- "Content-Type": "application/json;charset=utf-8",
- "clientid": CLIENT_ID,
- "X-Platform-Code": PLATFORM_CODE,
- ...header
- };
- if (needToken) {
- const token = getToken();
- if (token) {
- headers["Authorization"] = "Bearer " + token;
- }
- }
- return new Promise((resolve, reject) => {
- uni.request({
- url: BASE_URL + url,
- method: method.toUpperCase(),
- data,
- header: headers,
- success: (res) => {
- formatAppLog("log", "at utils/request.js:50", res);
- const statusCode = res.statusCode;
- const code = res.data.code;
- res.data.msg;
- res.data.data;
- if (statusCode !== 200) {
- const msg = msg || `请求失败(${statusCode})`;
- uni.showToast({ title: msg, icon: "none" });
- return reject(new Error(msg));
- }
- if (code === 401) {
- clearAuth();
- uni.showToast({ title: "登录已过期,请重新登录", icon: "none" });
- setTimeout(() => {
- uni.reLaunch({ url: "/pages/login/login" });
- }, 1500);
- return reject(new Error("未授权"));
- }
- resolve(res.data);
- },
- fail: (err) => {
- uni.showToast({ title: "网络异常,请稍后重试", icon: "none" });
- reject(err);
- }
- });
- });
- }
- function loginByPassword(username, password) {
- return request({
- url: "/auth/login",
- method: "POST",
- needToken: false,
- data: {
- tenantId: TENANT_ID,
- platformId: PLATFORM_ID,
- username,
- password,
- clientId: CLIENT_ID,
- grantType: "fulfiller_password"
- // 使用履约者专用认证策略
- }
- });
- }
- function loginBySms(phonenumber, smsCode) {
- return request({
- url: "/auth/login",
- method: "POST",
- needToken: false,
- data: {
- tenantId: TENANT_ID,
- platformId: PLATFORM_ID,
- phonenumber,
- smsCode,
- clientId: CLIENT_ID,
- grantType: "fulfiller_sms"
- // 使用履约者专用认证策略
- }
- });
- }
- function sendSmsCode(phonenumber) {
- return request({
- url: "/resource/sms/code",
- method: "GET",
- needToken: false,
- data: { phonenumber }
- });
- }
- function logout() {
- return request({
- url: "/auth/logout",
- method: "POST"
- });
- }
- const logic$9 = {
- data() {
- return {
- currentTab: 0,
- // 0: 免密, 1: 密码
- mobile: "",
- code: "",
- password: "",
- showPassword: false,
- isAgreed: false,
- countDown: 0,
- timer: null,
- showAgreementModal: false,
- agreementTitle: "",
- agreementContent: "",
- loginLoading: false
- };
- },
- methods: {
- showAgreement(type) {
- this.agreementTitle = type === 1 ? "用户服务协议" : "隐私政策";
- if (type === 1) {
- this.agreementContent = "1. 服务条款\n欢迎使用宠宝平台。您在使用本服务时需遵守以下条款...\n\n2. 用户责任\n用户需对自己的行为负责...\n\n3. 账号管理\n请妥善保管您的账号密码...";
- } else {
- this.agreementContent = "1. 信息收集\n为了提供服务,我们需要收集您的手机号、地理位置、设备信息等必要数据。\n\n2. 信息使用\n您的位置信息将用于订单匹配和路径规划;您的联系方式将用于接单通知和客户沟通。\n\n3. 信息保护\n我们将采取严格的安全措施保护您的个人信息,未经授权不会向第三方披露。";
- }
- this.showAgreementModal = true;
- },
- async getVerifyCode() {
- if (this.currentTab === 1)
- return;
- if (this.countDown > 0)
- return;
- if (!this.mobile || this.mobile.length !== 11) {
- uni.showToast({ title: "请输入正确的手机号", icon: "none" });
- return;
- }
- try {
- const res = await sendSmsCode(this.mobile);
- this.countDown = 60;
- this.timer = setInterval(() => {
- this.countDown--;
- if (this.countDown <= 0) {
- clearInterval(this.timer);
- }
- }, 1e3);
- const devCode = res.data;
- if (devCode) {
- this.code = devCode;
- uni.showToast({ title: "验证码: " + devCode, icon: "none", duration: 3e3 });
- } else {
- uni.showToast({ title: "验证码已发送", icon: "none" });
- }
- } catch (err) {
- formatAppLog("error", "at pages/login/logic.js:60", "发送验证码失败:", err);
- }
- },
- async handleLogin() {
- var _a;
- if (!this.isAgreed) {
- uni.showToast({ title: "请先同意用户协议", icon: "none" });
- return;
- }
- if (!this.mobile) {
- uni.showToast({ title: "请输入手机号", icon: "none" });
- return;
- }
- if (this.currentTab === 0) {
- if (!this.code) {
- uni.showToast({ title: "请输入验证码", icon: "none" });
- return;
- }
- } else {
- if (!this.password) {
- uni.showToast({ title: "请输入密码", icon: "none" });
- return;
- }
- }
- if (this.loginLoading)
- return;
- this.loginLoading = true;
- try {
- let res;
- if (this.currentTab === 0) {
- res = await loginBySms(this.mobile, this.code);
- } else {
- res = await loginByPassword(this.mobile, this.password);
- }
- const token = ((_a = res.data) == null ? void 0 : _a.access_token) || res.access_token;
- if (token) {
- setToken(token);
- }
- uni.showToast({ title: "登录成功", icon: "success" });
- setTimeout(() => {
- uni.switchTab({
- url: "/pages/home/index"
- });
- }, 1e3);
- } catch (err) {
- formatAppLog("error", "at pages/login/logic.js:114", "登录失败:", err);
- } finally {
- this.loginLoading = false;
- }
- },
- goToRecruit() {
- uni.navigateTo({
- url: "/pages/recruit/landing"
- });
- },
- goToForgotPwd() {
- uni.navigateTo({
- url: "/pages/login/reset-pwd-verify"
- });
- }
- }
- };
- const _imports_0$4 = "/static/header.png";
- const _imports_1$8 = "/static/logo.png";
- const _sfc_main$C = {
- ...logic$9,
- components: {
- PrivacyPopup: __easycom_0
- }
- };
- function _sfc_render$B(_ctx, _cache, $props, $setup, $data, $options) {
- const _component_privacy_popup = resolveEasycom(vue.resolveDynamicComponent("privacy-popup"), __easycom_0);
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "banner-area" }, [
- vue.createElementVNode("image", {
- class: "banner-img",
- src: _imports_0$4,
- mode: "widthFix"
- })
- ]),
- vue.createElementVNode("view", { class: "content-card" }, [
- vue.createElementVNode("view", { class: "logo-wrapper" }, [
- vue.createElementVNode("image", {
- class: "logo-img",
- src: _imports_1$8,
- mode: "widthFix"
- })
- ]),
- vue.createElementVNode("view", { class: "tabs" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: _ctx.currentTab === 0 }]),
- onClick: _cache[0] || (_cache[0] = ($event) => _ctx.currentTab = 0)
- },
- [
- vue.createElementVNode("text", { class: "tab-text" }, "免密登录"),
- _ctx.currentTab === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-indicator"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode("view", { class: "divider" }),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: _ctx.currentTab === 1 }]),
- onClick: _cache[1] || (_cache[1] = ($event) => _ctx.currentTab = 1)
- },
- [
- vue.createElementVNode("text", { class: "tab-text" }, "密码登录"),
- _ctx.currentTab === 1 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-indicator"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- )
- ]),
- vue.createElementVNode("view", { class: "form-area" }, [
- vue.createElementVNode("view", { class: "input-group" }, [
- vue.createElementVNode("view", { class: "area-code" }, [
- vue.createElementVNode("text", null, "+86"),
- vue.createElementVNode("text", { class: "arrow" }, "﹀")
- ]),
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "input",
- type: "number",
- placeholder: "手机号",
- "placeholder-style": "color: #ccc",
- "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.mobile = $event),
- maxlength: "11"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.mobile]
- ])
- ]),
- _ctx.currentTab === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "input-group"
- }, [
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "input",
- type: "number",
- placeholder: "验证码",
- "placeholder-style": "color: #ccc",
- "onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.code = $event),
- maxlength: "6"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.code]
- ]),
- vue.createElementVNode("view", {
- class: "get-code-btn",
- onClick: _cache[4] || (_cache[4] = (...args) => _ctx.getVerifyCode && _ctx.getVerifyCode(...args))
- }, [
- vue.createElementVNode(
- "text",
- { class: "code-text" },
- vue.toDisplayString(_ctx.countDown > 0 ? `${_ctx.countDown}s后重试` : "获取验证码"),
- 1
- /* TEXT */
- )
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.currentTab === 1 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "input-group"
- }, [
- vue.withDirectives(vue.createElementVNode("input", {
- class: "input",
- password: !_ctx.showPassword,
- type: "text",
- placeholder: "请输入密码",
- "placeholder-style": "color: #ccc",
- "onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.password = $event)
- }, null, 8, ["password"]), [
- [vue.vModelText, _ctx.password]
- ]),
- vue.createElementVNode("view", {
- class: "eye-icon",
- onClick: _cache[6] || (_cache[6] = ($event) => _ctx.showPassword = !_ctx.showPassword)
- }, [
- _ctx.showPassword ? (vue.openBlock(), vue.createElementBlock("svg", {
- key: 0,
- class: "svg-icon",
- viewBox: "0 0 24 24",
- fill: "none",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M12 4.5C7 4.5 2.73 7.61 1 12C2.73 16.39 7 19.5 12 19.5C17 19.5 21.27 16.39 23 12C21.27 7.61 17 4.5 12 4.5ZM12 17C9.24 17 7 14.76 7 12C7 9.24 9.24 7 12 7C14.76 7 17 9.24 17 12C17 14.76 14.76 17 12 17ZM12 9C10.34 9 9 10.34 9 12C9 13.66 10.34 15 12 15C13.66 15 15 13.66 15 12C15 10.34 13.66 9 12 9Z",
- fill: "#CCCCCC"
- })
- ])) : (vue.openBlock(), vue.createElementBlock("svg", {
- key: 1,
- class: "svg-icon",
- viewBox: "0 0 24 24",
- fill: "none",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M12 7C7 7 2.73 10.11 1 14.5",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M23 14.5C21.27 10.11 17 7 12 7",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M12 7V4",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M16 8L18 5",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M8 8L6 5",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M20 10L22 8",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M4 10L2 8",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- })
- ]))
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.currentTab === 1 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 2,
- class: "forgot-pwd"
- }, [
- vue.createElementVNode("text", {
- onClick: _cache[7] || (_cache[7] = (...args) => _ctx.goToForgotPwd && _ctx.goToForgotPwd(...args))
- }, "忘记密码?")
- ])) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("button", {
- class: "login-btn",
- onClick: _cache[8] || (_cache[8] = (...args) => _ctx.handleLogin && _ctx.handleLogin(...args))
- }, "登 录"),
- vue.createElementVNode("view", { class: "agreement" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["checkbox", { checked: _ctx.isAgreed }]),
- onClick: _cache[9] || (_cache[9] = ($event) => _ctx.isAgreed = !_ctx.isAgreed)
- },
- [
- _ctx.isAgreed ? (vue.openBlock(), vue.createElementBlock("text", {
- key: 0,
- class: "check-mark"
- }, "✓")) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode("text", { class: "agree-text" }, [
- vue.createTextVNode(" 我已经阅读并同意 "),
- vue.createElementVNode("text", {
- class: "link",
- onClick: _cache[10] || (_cache[10] = vue.withModifiers(($event) => _ctx.showAgreement(1), ["stop"]))
- }, "《用户服务协议》"),
- vue.createTextVNode(" 和 "),
- vue.createElementVNode("text", {
- class: "link",
- onClick: _cache[11] || (_cache[11] = vue.withModifiers(($event) => _ctx.showAgreement(2), ["stop"]))
- }, "《隐私政策》")
- ])
- ])
- ]),
- vue.createElementVNode("view", {
- class: "footer-recruit",
- onClick: _cache[12] || (_cache[12] = (...args) => _ctx.goToRecruit && _ctx.goToRecruit(...args))
- }, [
- vue.createElementVNode("view", { class: "recruit-badge" }, [
- (vue.openBlock(), vue.createElementBlock("svg", {
- class: "svg-icon flag-icon",
- viewBox: "0 0 24 24",
- fill: "none",
- xmlns: "http://www.w3.org/2000/svg",
- style: { "width": "30rpx", "height": "30rpx" }
- }, [
- vue.createElementVNode("path", {
- d: "M4 14V4H18L17 9L18 14H4Z",
- stroke: "#FF5722",
- "stroke-width": "2",
- "stroke-linejoin": "round"
- }),
- vue.createElementVNode("path", {
- d: "M4 22V14",
- stroke: "#FF5722",
- "stroke-width": "2",
- "stroke-linecap": "round"
- })
- ])),
- vue.createElementVNode("text", null, " 宠宝履约者招募")
- ])
- ]),
- vue.createVNode(_component_privacy_popup, {
- visible: _ctx.showAgreementModal,
- title: _ctx.agreementTitle,
- content: _ctx.agreementContent,
- onClose: _cache[13] || (_cache[13] = ($event) => _ctx.showAgreementModal = false)
- }, null, 8, ["visible", "title", "content"])
- ])
- ]);
- }
- const PagesLoginLogin = /* @__PURE__ */ _export_sfc(_sfc_main$C, [["render", _sfc_render$B], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/login/login.vue"]]);
- const logic$8 = {
- data() {
- return {
- statusBarHeight: 20
- // 默认状态栏高度
- };
- },
- onLoad() {
- const sysInfo = uni.getSystemInfoSync();
- this.statusBarHeight = sysInfo.statusBarHeight || 20;
- },
- methods: {
- goBack() {
- const pages = getCurrentPages();
- if (pages.length > 1) {
- uni.navigateBack();
- } else {
- uni.reLaunch({
- url: "/pages/login/login"
- });
- }
- },
- goToForm() {
- uni.navigateTo({
- url: "/pages/recruit/form"
- });
- }
- }
- };
- const _sfc_main$B = logic$8;
- function _sfc_render$A(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode(
- "view",
- {
- style: vue.normalizeStyle({ height: _ctx.statusBarHeight + "px" })
- },
- null,
- 4
- /* STYLE */
- ),
- vue.createElementVNode("view", { class: "nav-bar" }, [
- vue.createElementVNode("view", {
- class: "back-icon",
- onClick: _cache[0] || (_cache[0] = (...args) => _ctx.goBack && _ctx.goBack(...args))
- }, "‹")
- ]),
- vue.createElementVNode("view", { class: "header-area" }, [
- vue.createElementVNode("text", { class: "main-title" }, "加入宠宝履约者"),
- vue.createElementVNode("text", { class: "sub-title" }, "月薪最高可达1.5万元")
- ]),
- vue.createElementVNode("view", { class: "content-card" }, [
- vue.createElementVNode("view", { class: "benefit-item" }, [
- vue.createElementVNode("view", { class: "icon-circle icon-money" }, [
- vue.createElementVNode("text", { class: "icon-text" }, "¥")
- ]),
- vue.createElementVNode("view", { class: "info" }, [
- vue.createElementVNode("text", { class: "item-title" }, "1、收入可观"),
- vue.createElementVNode("text", { class: "item-desc" }, "小默配送为您提供一种全新的赚钱选择,利用空闲时间,获得更多收入。")
- ])
- ]),
- vue.createElementVNode("view", { class: "benefit-item" }, [
- vue.createElementVNode("view", { class: "icon-circle icon-loc" }, [
- vue.createElementVNode("text", { class: "icon-text" }, "📍")
- ]),
- vue.createElementVNode("view", { class: "info" }, [
- vue.createElementVNode("text", { class: "item-title" }, "2、地点灵活"),
- vue.createElementVNode("text", { class: "item-desc" }, "小默配送覆盖国内各城市与港澳台等地,您可随时就近使用。")
- ])
- ]),
- vue.createElementVNode("view", { class: "benefit-item" }, [
- vue.createElementVNode("view", { class: "icon-circle icon-clock" }, [
- vue.createElementVNode("text", { class: "icon-text" }, "🕒")
- ]),
- vue.createElementVNode("view", { class: "info" }, [
- vue.createElementVNode("text", { class: "item-title" }, "3、时间自由"),
- vue.createElementVNode("text", { class: "item-desc" }, "不必再受繁琐事务约束,加入小默配送,自由分配个人时间,为自己工作。")
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "footer-area" }, [
- vue.createElementVNode("button", {
- class: "join-btn",
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.goToForm && _ctx.goToForm(...args))
- }, "我要加入"),
- vue.createElementVNode("view", { class: "faq" }, [
- vue.createElementVNode("text", { class: "help-icon" }, "?"),
- vue.createTextVNode(" 常见问题 ")
- ])
- ])
- ]);
- }
- const PagesRecruitLanding = /* @__PURE__ */ _export_sfc(_sfc_main$B, [["render", _sfc_render$A], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/recruit/landing.vue"]]);
- function getMyProfile() {
- return request({
- url: "/fulfiller/fulfiller/my",
- method: "GET"
- });
- }
- function submitAudit(data) {
- return request({
- url: "/fulfiller/app/audit/submit",
- method: "POST",
- needToken: false,
- data
- });
- }
- function getServiceTypes() {
- return request({
- url: "/fulfiller/app/service/list",
- method: "GET",
- needToken: false
- });
- }
- function getAreaChildren(parentId = 0) {
- return request({
- url: "/fulfiller/app/area/children",
- method: "GET",
- needToken: false,
- data: { parentId }
- });
- }
- function uploadFile(filePath) {
- return new Promise((resolve, reject) => {
- const token = uni.getStorageSync("fulfiller_token");
- uni.uploadFile({
- url: BASE_URL + "/fulfiller/app/upload",
- filePath,
- name: "file",
- header: {
- "clientid": CLIENT_ID,
- "X-Platform-Code": PLATFORM_CODE,
- "Authorization": token ? `Bearer ${token}` : ""
- },
- success: (res) => {
- try {
- const data = JSON.parse(res.data);
- if (data.code === 200) {
- resolve(data);
- } else {
- uni.showToast({ title: data.msg || "上传失败", icon: "none" });
- reject(data);
- }
- } catch (e) {
- reject(e);
- }
- },
- fail: (err) => {
- uni.showToast({ title: "上传失败", icon: "none" });
- reject(err);
- }
- });
- });
- }
- function updateAvatar(avatar) {
- return request({
- url: "/fulfiller/fulfiller/my/avatar",
- method: "PUT",
- data: { avatar }
- });
- }
- function updateName(name) {
- return request({
- url: "/fulfiller/fulfiller/my/name",
- method: "PUT",
- data: { name }
- });
- }
- function updateStatus(status) {
- return request({
- url: "/fulfiller/fulfiller/my/status",
- method: "PUT",
- data: { status }
- });
- }
- function updateCity(cityCode, cityName) {
- return request({
- url: "/fulfiller/fulfiller/my/city",
- method: "PUT",
- data: { cityCode, cityName }
- });
- }
- function getAuthInfo() {
- return request({
- url: "/fulfiller/fulfiller/my/auth",
- method: "GET"
- });
- }
- function updatePhone(phone, code) {
- return request({
- url: "/fulfiller/fulfiller/my/phone",
- method: "PUT",
- data: { phone, code }
- });
- }
- function updatePassword(oldPassword, newPassword) {
- return request({
- url: "/fulfiller/fulfiller/my/password",
- method: "PUT",
- data: { oldPassword, newPassword }
- });
- }
- function deleteAccount() {
- return request({
- url: "/fulfiller/fulfiller/my/account",
- method: "DELETE"
- });
- }
- function updateAuthInfo(data) {
- return request({
- url: "/fulfiller/fulfiller/my/auth",
- method: "POST",
- data
- });
- }
- function getPendingOrders(params) {
- return request({
- url: "/order/subOrder/listPendingAccept",
- method: "GET",
- data: params
- });
- }
- function acceptOrder(orderId) {
- return request({
- url: "/order/subOrder/accept",
- method: "PUT",
- data: { orderId }
- });
- }
- function getOrderCount() {
- return request({
- url: "/order/subOrder/count",
- method: "GET"
- });
- }
- function getMyOrders(params) {
- return request({
- url: "/order/subOrder/listOnMyOrder",
- method: "GET",
- data: params
- });
- }
- function getOrderInfo(id) {
- return request({
- url: `/order/subOrder/getInfo?id=${id}`,
- method: "GET"
- });
- }
- function getOrderLogs(orderId) {
- return request({
- url: `/order/subOrderLog/list?orderId=${orderId}`,
- method: "GET"
- });
- }
- function clockIn(data) {
- return request({
- url: "/order/subOrder/clockIn",
- method: "PUT",
- data
- });
- }
- function uploadAnamaly(data) {
- return request({
- url: "/fulfiller/anamaly/upload",
- method: "POST",
- data
- });
- }
- function getAnomalyList(orderId) {
- return request({
- url: `/fulfiller/anamaly/listOnOrder?orderId=${orderId}`,
- method: "GET"
- });
- }
- function submitNursingSummary(data) {
- return request({
- url: "/order/subOrder/nursingSummary",
- method: "PUT",
- data
- });
- }
- const logic$7 = {
- data() {
- return {
- formData: {
- mobile: "",
- code: "",
- name: "",
- gender: 1,
- // 1男 2女
- birthday: "",
- password: "",
- serviceType: [],
- city: "",
- station: "",
- stationId: null
- },
- showPwd: false,
- isAgreed: false,
- serviceTypes: [],
- // 验证码倒计时
- countDown: 0,
- timer: null,
- // 日期选择器相关
- showPicker: false,
- years: [],
- months: [],
- days: [],
- pickerValue: [0, 0, 0],
- tempYear: 0,
- tempMonth: 0,
- tempDay: 0,
- // 城市选择器相关(从后端加载)
- showCityPicker: false,
- selectStep: 0,
- selectedPathway: [],
- currentList: [],
- selectedCityId: null,
- // 站点选择器相关(从后端加载)
- showStationPicker: false,
- stationList: [],
- // 协议弹窗
- showPrivacy: false,
- privacyTitle: "",
- privacyContent: ""
- };
- },
- created() {
- this.initDateData();
- this.loadServiceTypes();
- },
- beforeDestroy() {
- if (this.timer)
- clearInterval(this.timer);
- },
- methods: {
- initDateData() {
- const now = /* @__PURE__ */ new Date();
- const currentYear = now.getFullYear();
- for (let i = 1980; i <= currentYear + 5; i++) {
- this.years.push(i);
- }
- for (let i = 1; i <= 12; i++) {
- this.months.push(i);
- }
- for (let i = 1; i <= 31; i++) {
- this.days.push(i);
- }
- },
- // 打开选择器
- openPicker() {
- const dateStr = this.formData.birthday || "2000-01-01";
- const [y, m, d] = dateStr.split("-").map(Number);
- const yIndex = this.years.indexOf(y);
- const mIndex = this.months.indexOf(m);
- const dIndex = this.days.indexOf(d);
- this.pickerValue = [
- yIndex > -1 ? yIndex : 0,
- mIndex > -1 ? mIndex : 0,
- dIndex > -1 ? dIndex : 0
- ];
- this.tempYear = this.years[this.pickerValue[0]];
- this.tempMonth = this.months[this.pickerValue[1]];
- this.tempDay = this.days[this.pickerValue[2]];
- this.showPicker = true;
- },
- closePicker() {
- this.showPicker = false;
- },
- onPickerChange(e) {
- const val = e.detail.value;
- this.tempYear = this.years[val[0]];
- this.tempMonth = this.months[val[1]];
- this.tempDay = this.days[val[2]];
- },
- confirmPicker() {
- const mStr = this.tempMonth < 10 ? "0" + this.tempMonth : this.tempMonth;
- const dStr = this.tempDay < 10 ? "0" + this.tempDay : this.tempDay;
- this.formData.birthday = `${this.tempYear}-${mStr}-${dStr}`;
- this.closePicker();
- },
- async loadServiceTypes() {
- try {
- const res = await getServiceTypes();
- this.serviceTypes = (res.data || []).map((item) => ({
- id: item.id,
- name: item.name
- }));
- } catch (err) {
- formatAppLog("error", "at pages/recruit/logic.js:131", "加载服务类型失败:", err);
- this.serviceTypes = [];
- }
- },
- toggleService(item) {
- const idx = this.formData.serviceType.indexOf(item.id);
- if (idx > -1) {
- this.formData.serviceType.splice(idx, 1);
- } else {
- this.formData.serviceType.push(item.id);
- }
- },
- // 验证码
- async getVerifyCode() {
- if (this.countDown > 0)
- return;
- if (!this.formData.mobile || this.formData.mobile.length !== 11) {
- uni.showToast({ title: "请输入正确的手机号", icon: "none" });
- return;
- }
- try {
- const res = await sendSmsCode(this.formData.mobile);
- this.countDown = 60;
- this.timer = setInterval(() => {
- this.countDown--;
- if (this.countDown <= 0)
- clearInterval(this.timer);
- }, 1e3);
- const devCode = res.data;
- if (devCode) {
- this.formData.code = devCode;
- uni.showToast({ title: "验证码: " + devCode, icon: "none", duration: 3e3 });
- } else {
- uni.showToast({ title: "验证码已发送", icon: "none" });
- }
- } catch (err) {
- formatAppLog("error", "at pages/recruit/logic.js:168", "发送验证码失败:", err);
- }
- },
- // 城市选择器 logic(从后端加载)
- async openCityPicker() {
- this.showCityPicker = true;
- if (this.selectedPathway.length === 0) {
- await this.resetCityPicker();
- }
- },
- async resetCityPicker() {
- this.selectStep = 0;
- this.selectedPathway = [];
- await this.loadAreaChildren(0);
- },
- closeCityPicker() {
- this.showCityPicker = false;
- },
- async loadAreaChildren(parentId) {
- try {
- const res = await getAreaChildren(parentId);
- this.currentList = (res.data || []).filter((item) => item.type !== 2).map((item) => ({
- id: item.id,
- name: item.name,
- type: item.type,
- parentId: item.parentId
- }));
- } catch (err) {
- formatAppLog("error", "at pages/recruit/logic.js:200", "加载区域数据失败:", err);
- this.currentList = [];
- }
- },
- async selectCityItem(item) {
- this.selectedPathway[this.selectStep] = item;
- if (item.type === 0) {
- this.selectStep++;
- this.selectedPathway = this.selectedPathway.slice(0, this.selectStep);
- await this.loadAreaChildren(item.id);
- if (this.currentList.length === 0) {
- this.selectedCityId = item.id;
- this.confirmCity();
- }
- } else {
- this.selectedCityId = item.id;
- this.confirmCity();
- }
- },
- async jumpToStep(step) {
- this.selectStep = step;
- if (step === 0) {
- await this.loadAreaChildren(0);
- } else {
- const parent = this.selectedPathway[step - 1];
- if (parent) {
- await this.loadAreaChildren(parent.id);
- }
- }
- },
- confirmCity() {
- const fullPath = this.selectedPathway.map((i) => i.name).join(" ");
- this.formData.city = fullPath;
- this.formData.station = "";
- this.formData.stationId = null;
- const lastSelected = this.selectedPathway[this.selectedPathway.length - 1];
- if (lastSelected) {
- this.loadStations(lastSelected.id);
- }
- this.closeCityPicker();
- },
- // 站点选择器(从后端加载,只取type=2的站点)
- async loadStations(parentId) {
- try {
- const res = await getAreaChildren(parentId);
- this.stationList = (res.data || []).filter((item) => item.type === 2).map((item) => ({
- id: item.id,
- name: item.name
- }));
- } catch (err) {
- formatAppLog("error", "at pages/recruit/logic.js:259", "加载站点数据失败:", err);
- this.stationList = [];
- }
- },
- openStationPicker() {
- if (this.stationList.length === 0) {
- uni.showToast({ title: "请先选择工作城市", icon: "none" });
- return;
- }
- this.showStationPicker = true;
- },
- closeStationPicker() {
- this.showStationPicker = false;
- },
- selectStation(item) {
- this.formData.station = item.name;
- this.formData.stationId = item.id;
- this.closeStationPicker();
- },
- openPrivacy() {
- this.privacyTitle = "宠宝履约者说明";
- this.privacyContent = "1. 履约职责\n作为宠宝履约者,您需要按照平台标准完成宠物接送、喂遛或洗护服务,确保宠物安全与健康。\n\n2. 结算方式\n服务费用将根据订单类型和距离计算,定期结算至您的账户。具体结算周期请查看钱包说明。\n\n3. 行为规范\n请在这个过程中保持专业,穿着整洁,礼貌待人。严禁虐待宠物,违反者将承担法律责任。";
- this.showPrivacy = true;
- },
- goToAuth() {
- if (!this.isAgreed) {
- uni.showToast({ title: "请勾选协议", icon: "none" });
- return;
- }
- if (!this.formData.mobile || this.formData.mobile.length !== 11) {
- uni.showToast({ title: "请输入正确的手机号", icon: "none" });
- return;
- }
- if (!this.formData.name) {
- uni.showToast({ title: "请输入姓名", icon: "none" });
- return;
- }
- if (this.formData.serviceType.length === 0) {
- uni.showToast({ title: "请选择服务类型", icon: "none" });
- return;
- }
- uni.setStorageSync("recruit_form_data", JSON.stringify(this.formData));
- const selectedServices = this.serviceTypes.filter((s) => this.formData.serviceType.includes(s.id));
- const services = JSON.stringify(selectedServices);
- uni.navigateTo({
- url: `/pages/recruit/auth?services=${encodeURIComponent(services)}`
- });
- }
- }
- };
- const _sfc_main$A = {
- ...logic$7,
- components: {
- PrivacyPopup: __easycom_0
- }
- };
- function _sfc_render$z(_ctx, _cache, $props, $setup, $data, $options) {
- const _component_privacy_popup = resolveEasycom(vue.resolveDynamicComponent("privacy-popup"), __easycom_0);
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "card" }, [
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "手机号"),
- vue.createElementVNode("view", { class: "input-box" }, [
- vue.createElementVNode("view", { class: "prefix-area" }, [
- vue.createElementVNode("text", { class: "prefix" }, "+86"),
- vue.createElementVNode("text", { class: "arrow-down" }, "﹀")
- ]),
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "input",
- type: "number",
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.formData.mobile = $event)
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.formData.mobile]
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "验证码"),
- vue.createElementVNode("view", { class: "input-box" }, [
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "input",
- type: "number",
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.formData.code = $event),
- placeholder: "验证码"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.formData.code]
- ]),
- vue.createElementVNode(
- "text",
- {
- class: "get-code-text",
- onClick: _cache[2] || (_cache[2] = (...args) => _ctx.getVerifyCode && _ctx.getVerifyCode(...args))
- },
- vue.toDisplayString(_ctx.countDown > 0 ? _ctx.countDown + "s" : "获取验证码"),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "姓名"),
- vue.createElementVNode("view", { class: "input-box" }, [
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "input",
- type: "text",
- "onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.formData.name = $event)
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.formData.name]
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "性别"),
- vue.createElementVNode("view", { class: "gender-group" }, [
- vue.createElementVNode("view", {
- class: "radio-item",
- onClick: _cache[4] || (_cache[4] = ($event) => _ctx.formData.gender = 1)
- }, [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["radio-icon", { active: _ctx.formData.gender === 1 }])
- },
- vue.toDisplayString(_ctx.formData.gender === 1 ? "♂" : "○"),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["radio-label", { active: _ctx.formData.gender === 1 }])
- },
- " 男",
- 2
- /* CLASS */
- )
- ]),
- vue.createElementVNode("view", {
- class: "radio-item",
- onClick: _cache[5] || (_cache[5] = ($event) => _ctx.formData.gender = 2)
- }, [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["radio-icon", { active: _ctx.formData.gender === 2 }])
- },
- vue.toDisplayString(_ctx.formData.gender === 2 ? "♀" : "○"),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["radio-label", { active: _ctx.formData.gender === 2 }])
- },
- " 女",
- 2
- /* CLASS */
- )
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "生日"),
- vue.createElementVNode("view", {
- class: "input-box",
- onClick: _cache[6] || (_cache[6] = (...args) => _ctx.openPicker && _ctx.openPicker(...args))
- }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(_ctx.formData.birthday || "请选择生日"),
- 1
- /* TEXT */
- ),
- (vue.openBlock(), vue.createElementBlock("svg", {
- class: "arrow-right",
- style: { "width": "24rpx", "height": "24rpx", "margin-left": "auto" },
- viewBox: "0 0 1024 1024",
- version: "1.1",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M340.864 149.312a30.592 30.592 0 0 0 0 42.752L652.736 512 340.864 831.872a30.592 30.592 0 0 0 0 42.752 29.12 29.12 0 0 0 41.728 0L714.24 534.336a32 32 0 0 0 0-45.056L382.592 149.312a29.12 29.12 0 0 0-41.728 0z",
- fill: "#CCCCCC"
- })
- ]))
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "密码"),
- vue.createElementVNode("view", { class: "input-box" }, [
- vue.withDirectives(vue.createElementVNode("input", {
- class: "input",
- password: !_ctx.showPwd,
- "onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => _ctx.formData.password = $event),
- placeholder: "设置登录密码"
- }, null, 8, ["password"]), [
- [vue.vModelText, _ctx.formData.password]
- ]),
- vue.createElementVNode("view", {
- class: "monkey-icon",
- onClick: _cache[8] || (_cache[8] = ($event) => _ctx.showPwd = !_ctx.showPwd)
- }, [
- _ctx.showPwd ? (vue.openBlock(), vue.createElementBlock("svg", {
- key: 0,
- class: "svg-icon",
- viewBox: "0 0 24 24",
- fill: "none",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M12 4.5C7 4.5 2.73 7.61 1 12C2.73 16.39 7 19.5 12 19.5C17 19.5 21.27 16.39 23 12C21.27 7.61 17 4.5 12 4.5ZM12 17C9.24 17 7 14.76 7 12C7 9.24 9.24 7 12 7C14.76 7 17 9.24 17 12C17 14.76 14.76 17 12 17ZM12 9C10.34 9 9 10.34 9 12C9 13.66 10.34 15 12 15C13.66 15 15 13.66 15 12C15 10.34 13.66 9 12 9Z",
- fill: "#CCCCCC"
- })
- ])) : (vue.openBlock(), vue.createElementBlock("svg", {
- key: 1,
- class: "svg-icon",
- viewBox: "0 0 24 24",
- fill: "none",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M12 7C7 7 2.73 10.11 1 14.5",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M23 14.5C21.27 10.11 17 7 12 7",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M12 7V4",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M16 8L18 5",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M8 8L6 5",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M20 10L22 8",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- }),
- vue.createElementVNode("path", {
- d: "M4 10L2 8",
- stroke: "#CCCCCC",
- "stroke-width": "2",
- "stroke-linecap": "round"
- })
- ]))
- ])
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "card" }, [
- vue.createElementVNode("view", { class: "section-title" }, "服务类型"),
- vue.createElementVNode("view", { class: "service-types" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.serviceTypes, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: vue.normalizeClass(["type-btn", { selected: _ctx.formData.serviceType.includes(item.id) }]),
- key: item.id,
- onClick: ($event) => _ctx.toggleService(item)
- }, vue.toDisplayString(item.name), 11, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "工作城市"),
- vue.createElementVNode("view", {
- class: "input-box",
- onClick: _cache[9] || (_cache[9] = (...args) => _ctx.openCityPicker && _ctx.openCityPicker(...args))
- }, [
- vue.createElementVNode(
- "text",
- {
- style: vue.normalizeStyle({ color: _ctx.formData.city ? "#333" : "#ccc" })
- },
- vue.toDisplayString(_ctx.formData.city || "请选择工作城市"),
- 5
- /* TEXT, STYLE */
- ),
- (vue.openBlock(), vue.createElementBlock("svg", {
- class: "arrow-right",
- style: { "width": "24rpx", "height": "24rpx", "margin-left": "auto" },
- viewBox: "0 0 1024 1024",
- version: "1.1",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M340.864 149.312a30.592 30.592 0 0 0 0 42.752L652.736 512 340.864 831.872a30.592 30.592 0 0 0 0 42.752 29.12 29.12 0 0 0 41.728 0L714.24 534.336a32 32 0 0 0 0-45.056L382.592 149.312a29.12 29.12 0 0 0-41.728 0z",
- fill: "#CCCCCC"
- })
- ]))
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "服务站点"),
- vue.createElementVNode("view", {
- class: "input-box",
- onClick: _cache[10] || (_cache[10] = (...args) => _ctx.openStationPicker && _ctx.openStationPicker(...args))
- }, [
- vue.createElementVNode(
- "text",
- {
- style: vue.normalizeStyle({ color: _ctx.formData.station ? "#333" : "#ccc" })
- },
- vue.toDisplayString(_ctx.formData.station || "请选择服务站点"),
- 5
- /* TEXT, STYLE */
- ),
- (vue.openBlock(), vue.createElementBlock("svg", {
- class: "arrow-right",
- style: { "width": "24rpx", "height": "24rpx", "margin-left": "auto" },
- viewBox: "0 0 1024 1024",
- version: "1.1",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M340.864 149.312a30.592 30.592 0 0 0 0 42.752L652.736 512 340.864 831.872a30.592 30.592 0 0 0 0 42.752 29.12 29.12 0 0 0 41.728 0L714.24 534.336a32 32 0 0 0 0-45.056L382.592 149.312a29.12 29.12 0 0 0-41.728 0z",
- fill: "#CCCCCC"
- })
- ]))
- ])
- ])
- ]),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["picker-mask", { show: _ctx.showCityPicker }]),
- onClick: _cache[14] || (_cache[14] = (...args) => _ctx.closeCityPicker && _ctx.closeCityPicker(...args))
- },
- [
- vue.createElementVNode("view", {
- class: "picker-content",
- onClick: _cache[13] || (_cache[13] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "picker-header" }, [
- vue.createElementVNode("text", {
- class: "picker-btn-cancel",
- onClick: _cache[11] || (_cache[11] = (...args) => _ctx.closeCityPicker && _ctx.closeCityPicker(...args))
- }, "取消"),
- vue.createElementVNode("text", { class: "picker-title" }, "请选择工作城市"),
- vue.createElementVNode("text", {
- class: "picker-btn-confirm",
- onClick: _cache[12] || (_cache[12] = (...args) => _ctx.confirmCity && _ctx.confirmCity(...args))
- }, "确定")
- ]),
- vue.createElementVNode("view", { class: "picker-body" }, [
- vue.createElementVNode("view", { class: "timeline-area" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.selectedPathway, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "timeline-item",
- key: index,
- onClick: ($event) => _ctx.jumpToStep(index)
- }, [
- vue.createElementVNode("view", { class: "timeline-dot" }),
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(item.name),
- 1
- /* TEXT */
- )
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- _ctx.selectStep === _ctx.selectedPathway.length ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "timeline-item active"
- }, [
- vue.createElementVNode("view", { class: "timeline-dot" }),
- vue.createElementVNode("text", null, "请选择")
- ])) : vue.createCommentVNode("v-if", true)
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "list-area"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.currentList, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "list-item",
- key: item.id,
- onClick: ($event) => _ctx.selectCityItem(item)
- }, vue.toDisplayString(item.name), 9, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- _ctx.currentList.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- style: { "padding": "20rpx", "color": "#999" }
- }, " 无数据 ")) : vue.createCommentVNode("v-if", true)
- ])
- ])
- ])
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["picker-mask", { show: _ctx.showStationPicker }]),
- onClick: _cache[17] || (_cache[17] = (...args) => _ctx.closeStationPicker && _ctx.closeStationPicker(...args))
- },
- [
- vue.createElementVNode("view", {
- class: "picker-content",
- onClick: _cache[16] || (_cache[16] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", {
- class: "picker-header",
- style: { "justify-content": "center", "position": "relative" }
- }, [
- vue.createElementVNode("text", {
- class: "picker-btn-cancel",
- style: { "position": "absolute", "left": "30rpx" },
- onClick: _cache[15] || (_cache[15] = (...args) => _ctx.closeStationPicker && _ctx.closeStationPicker(...args))
- }, "取消"),
- vue.createElementVNode("text", { class: "picker-title" }, "选择服务站点")
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "picker-list"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.stationList, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "station-item",
- key: index,
- onClick: ($event) => _ctx.selectStation(item)
- }, vue.toDisplayString(item.name), 9, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ])
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode("view", { class: "footer-actions" }, [
- vue.createElementVNode("view", { class: "agreement-row" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["checkbox", { checked: _ctx.isAgreed }]),
- onClick: _cache[18] || (_cache[18] = ($event) => _ctx.isAgreed = !_ctx.isAgreed)
- },
- [
- _ctx.isAgreed ? (vue.openBlock(), vue.createElementBlock("text", {
- key: 0,
- class: "check-mark"
- }, "✓")) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode("text", { class: "agree-text" }, [
- vue.createTextVNode("我已阅读并同意 "),
- vue.createElementVNode("text", {
- style: { "color": "#2979ff" },
- onClick: _cache[19] || (_cache[19] = vue.withModifiers((...args) => _ctx.openPrivacy && _ctx.openPrivacy(...args), ["stop"]))
- }, "《宠宝履约者说明》")
- ])
- ]),
- vue.createElementVNode("view", { class: "footer-btn-area" }, [
- vue.createElementVNode("button", {
- class: "submit-btn",
- onClick: _cache[20] || (_cache[20] = (...args) => _ctx.goToAuth && _ctx.goToAuth(...args))
- }, "下一步,实名认证")
- ])
- ]),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["picker-mask", { show: _ctx.showPicker }]),
- onClick: _cache[25] || (_cache[25] = (...args) => _ctx.closePicker && _ctx.closePicker(...args))
- },
- [
- vue.createElementVNode("view", {
- class: "picker-content",
- onClick: _cache[24] || (_cache[24] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "picker-header" }, [
- vue.createElementVNode("text", {
- class: "picker-btn-cancel",
- onClick: _cache[21] || (_cache[21] = (...args) => _ctx.closePicker && _ctx.closePicker(...args))
- }, "取消"),
- vue.createElementVNode("text", { class: "picker-title" }, "选择出生日期"),
- vue.createElementVNode("text", {
- class: "picker-btn-confirm",
- onClick: _cache[22] || (_cache[22] = (...args) => _ctx.confirmPicker && _ctx.confirmPicker(...args))
- }, "确定")
- ]),
- vue.createElementVNode("picker-view", {
- class: "picker-view",
- "indicator-style": "height: 50px;",
- value: _ctx.pickerValue,
- onChange: _cache[23] || (_cache[23] = (...args) => _ctx.onPickerChange && _ctx.onPickerChange(...args))
- }, [
- vue.createElementVNode("picker-view-column", null, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.years, (item, index) => {
- return vue.openBlock(), vue.createElementBlock(
- "view",
- {
- class: "picker-item",
- key: index
- },
- vue.toDisplayString(item) + "年",
- 1
- /* TEXT */
- );
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("picker-view-column", null, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.months, (item, index) => {
- return vue.openBlock(), vue.createElementBlock(
- "view",
- {
- class: "picker-item",
- key: index
- },
- vue.toDisplayString(item) + "月",
- 1
- /* TEXT */
- );
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("picker-view-column", null, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.days, (item, index) => {
- return vue.openBlock(), vue.createElementBlock(
- "view",
- {
- class: "picker-item",
- key: index
- },
- vue.toDisplayString(item) + "日",
- 1
- /* TEXT */
- );
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ], 40, ["value"])
- ])
- ],
- 2
- /* CLASS */
- ),
- vue.createVNode(_component_privacy_popup, {
- visible: _ctx.showPrivacy,
- title: _ctx.privacyTitle,
- content: _ctx.privacyContent,
- onClose: _cache[26] || (_cache[26] = ($event) => _ctx.showPrivacy = false)
- }, null, 8, ["visible", "title", "content"])
- ]);
- }
- const PagesRecruitForm = /* @__PURE__ */ _export_sfc(_sfc_main$A, [["render", _sfc_render$z], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/recruit/form.vue"]]);
- const logic$6 = {
- data() {
- return {
- formData: {
- idType: "居民身份证",
- name: "",
- idNumber: "",
- expiryDate: ""
- },
- idCardFront: "",
- // 身份证正面本地预览路径
- idCardBack: "",
- // 身份证反面本地预览路径
- idCardFrontOssId: "",
- // 身份证正面 OSS ID
- idCardBackOssId: "",
- // 身份证反面 OSS ID
- showDatePicker: false,
- pickerValue: [0, 0, 0],
- // YYYY-MM-DD
- years: [],
- months: [],
- days: [],
- serviceType: []
- // 接收上一页的服务类型
- };
- },
- onLoad(options) {
- if (options.services) {
- try {
- this.serviceType = JSON.parse(decodeURIComponent(options.services));
- } catch (e) {
- formatAppLog("error", "at pages/recruit/auth_logic.js:29", "Parse services failed", e);
- }
- }
- this.initDateData();
- this.restoreAuthData();
- },
- methods: {
- // --- 日期选择器逻辑 (简化版, 仅示意) ---
- initDateData() {
- const date = /* @__PURE__ */ new Date();
- const year = date.getFullYear();
- for (let i = year; i <= year + 20; i++) {
- this.years.push(i);
- }
- for (let i = 1; i <= 12; i++) {
- this.months.push(i);
- }
- for (let i = 1; i <= 31; i++) {
- this.days.push(i);
- }
- },
- openDatePicker() {
- },
- onDateChange(e) {
- this.formData.expiryDate = e.detail.value;
- },
- // --- 数据持久化(防止返回上一级丢失) ---
- restoreAuthData() {
- try {
- const saved = uni.getStorageSync("recruit_auth_data");
- if (saved) {
- const d = JSON.parse(saved);
- this.formData.name = d.name || "";
- this.formData.idNumber = d.idNumber || "";
- this.formData.expiryDate = d.expiryDate || "";
- this.idCardFront = d.idCardFront || "";
- this.idCardBack = d.idCardBack || "";
- this.idCardFrontOssId = d.idCardFrontOssId || "";
- this.idCardBackOssId = d.idCardBackOssId || "";
- }
- } catch (e) {
- formatAppLog("error", "at pages/recruit/auth_logic.js:76", "恢复认证数据失败", e);
- }
- },
- saveAuthData() {
- try {
- uni.setStorageSync("recruit_auth_data", JSON.stringify({
- name: this.formData.name,
- idNumber: this.formData.idNumber,
- expiryDate: this.formData.expiryDate,
- idCardFront: this.idCardFront,
- idCardBack: this.idCardBack,
- idCardFrontOssId: this.idCardFrontOssId,
- idCardBackOssId: this.idCardBackOssId
- }));
- } catch (e) {
- formatAppLog("error", "at pages/recruit/auth_logic.js:91", "保存认证数据失败", e);
- }
- },
- // --- 图片上传(选择后自动上传到OSS) ---
- chooseImage(side) {
- uni.chooseImage({
- count: 1,
- sizeType: ["compressed"],
- sourceType: ["album", "camera"],
- success: async (res) => {
- const tempPath = res.tempFilePaths[0];
- if (side === "front") {
- this.idCardFront = tempPath;
- } else {
- this.idCardBack = tempPath;
- }
- try {
- uni.showLoading({ title: "上传中..." });
- const uploadRes = await uploadFile(tempPath);
- if (side === "front") {
- this.idCardFrontOssId = uploadRes.data.ossId;
- } else {
- this.idCardBackOssId = uploadRes.data.ossId;
- }
- uni.hideLoading();
- this.saveAuthData();
- } catch (err) {
- uni.hideLoading();
- formatAppLog("error", "at pages/recruit/auth_logic.js:121", "上传身份证图片失败:", err);
- }
- }
- });
- },
- // --- 提交 ---
- goToQualifications() {
- this.saveAuthData();
- try {
- const stored = uni.getStorageSync("recruit_form_data");
- if (stored) {
- const data = JSON.parse(stored);
- data.realName = this.formData.name;
- data.idNumber = this.formData.idNumber;
- data.expiryDate = this.formData.expiryDate;
- data.idCardFrontOssId = this.idCardFrontOssId;
- data.idCardBackOssId = this.idCardBackOssId;
- uni.setStorageSync("recruit_form_data", JSON.stringify(data));
- }
- } catch (e) {
- formatAppLog("error", "at pages/recruit/auth_logic.js:158", "保存认证数据失败", e);
- }
- const services = JSON.stringify(this.serviceType);
- uni.navigateTo({
- url: `/pages/recruit/qualifications?services=${encodeURIComponent(services)}`
- });
- }
- }
- };
- const _sfc_main$z = logic$6;
- function _sfc_render$y(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "auth-container" }, [
- vue.createElementVNode("view", { class: "top-tip" }, "请确保身份信息的准确,以免影响后续履约费用结算。"),
- vue.createElementVNode("view", { class: "form-card" }, [
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "证件类型"),
- vue.createElementVNode("view", { class: "read-only-text" }, "居民身份证")
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "真实姓名"),
- vue.createElementVNode("view", { class: "gray-input-box" }, [
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "input-area",
- type: "text",
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.formData.name = $event),
- placeholder: "证件姓名",
- "placeholder-class": "input-placeholder"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.formData.name]
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "证件号码"),
- vue.createElementVNode("view", { class: "gray-input-box" }, [
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "input-area",
- type: "idcard",
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.formData.idNumber = $event),
- placeholder: "身份证号",
- "placeholder-class": "input-placeholder"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.formData.idNumber]
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "label" }, "有效日期"),
- vue.createElementVNode("view", { class: "gray-input-box" }, [
- vue.createElementVNode(
- "picker",
- {
- mode: "date",
- onChange: _cache[2] || (_cache[2] = (...args) => _ctx.onDateChange && _ctx.onDateChange(...args)),
- style: { "width": "100%" }
- },
- [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["input-area", { "input-placeholder": !_ctx.formData.expiryDate }])
- },
- vue.toDisplayString(_ctx.formData.expiryDate || "选择有效结束期限"),
- 3
- /* TEXT, CLASS */
- )
- ],
- 32
- /* NEED_HYDRATION */
- ),
- (vue.openBlock(), vue.createElementBlock("svg", {
- class: "arrow-right",
- viewBox: "0 0 1024 1024",
- version: "1.1",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M340.864 149.312a30.592 30.592 0 0 0 0 42.752L652.736 512 340.864 831.872a30.592 30.592 0 0 0 0 42.752 29.12 29.12 0 0 0 41.728 0L714.24 534.336a32 32 0 0 0 0-45.056L382.592 149.312a29.12 29.12 0 0 0-41.728 0z",
- fill: "#CCCCCC"
- })
- ]))
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "upload-card" }, [
- vue.createElementVNode("view", {
- class: "upload-box",
- onClick: _cache[3] || (_cache[3] = ($event) => _ctx.chooseImage("front"))
- }, [
- _ctx.idCardFront ? (vue.openBlock(), vue.createElementBlock("image", {
- key: 0,
- src: _ctx.idCardFront,
- class: "preview-img",
- mode: "aspectFill"
- }, null, 8, ["src"])) : (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 1 },
- [
- (vue.openBlock(), vue.createElementBlock("svg", {
- class: "camera-icon",
- viewBox: "0 0 24 24",
- fill: "none",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M12 12C14.7614 12 17 9.76142 17 7C17 4.23858 14.7614 2 12 2C9.23858 2 7 4.23858 7 7C7 9.76142 9.23858 12 12 12Z",
- fill: "#E0E0E0"
- }),
- vue.createElementVNode("circle", {
- cx: "12",
- cy: "12",
- r: "3",
- stroke: "#CCCCCC",
- "stroke-width": "2"
- }),
- vue.createElementVNode("path", {
- d: "M20 6H17.82L16.4 4.47C15.96 4 15.34 3.73 14.68 3.73H9.32C8.66 3.73 8.04 4 7.6 4.47L6.18 6H4C2.9 6 2 6.9 2 8V18C2 19.1 2.9 20 4 20H20C21.1 20 22 19.1 22 18V8C22 6.9 21.1 6 20 6ZM12 17C9.24 17 7 14.76 7 12C7 9.24 9.24 7 12 7C14.76 7 17 9.24 17 12C17 14.76 14.76 17 12 17Z",
- fill: "#CCCCCC"
- })
- ])),
- vue.createElementVNode("text", { class: "upload-text" }, "点击上传")
- ],
- 64
- /* STABLE_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("text", { class: "card-label" }, "证件带照片面")
- ]),
- vue.createElementVNode("view", { class: "upload-card" }, [
- vue.createElementVNode("view", {
- class: "upload-box",
- onClick: _cache[4] || (_cache[4] = ($event) => _ctx.chooseImage("back"))
- }, [
- _ctx.idCardBack ? (vue.openBlock(), vue.createElementBlock("image", {
- key: 0,
- src: _ctx.idCardBack,
- class: "preview-img",
- mode: "aspectFill"
- }, null, 8, ["src"])) : (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 1 },
- [
- (vue.openBlock(), vue.createElementBlock("svg", {
- class: "camera-icon",
- viewBox: "0 0 24 24",
- fill: "none",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M20 6H17.82L16.4 4.47C15.96 4 15.34 3.73 14.68 3.73H9.32C8.66 3.73 8.04 4 7.6 4.47L6.18 6H4C2.9 6 2 6.9 2 8V18C2 19.1 2.9 20 4 20H20C21.1 20 22 19.1 22 18V8C22 6.9 21.1 6 20 6ZM12 17C9.24 17 7 14.76 7 12C7 9.24 9.24 7 12 7C14.76 7 17 9.24 17 12C17 14.76 14.76 17 12 17Z",
- fill: "#CCCCCC"
- })
- ])),
- vue.createElementVNode("text", { class: "upload-text" }, "点击上传")
- ],
- 64
- /* STABLE_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("text", { class: "card-label" }, "证件国徽面")
- ]),
- vue.createElementVNode("view", { class: "footer-btn-area" }, [
- vue.createElementVNode("button", {
- class: "next-btn",
- onClick: _cache[5] || (_cache[5] = (...args) => _ctx.goToQualifications && _ctx.goToQualifications(...args))
- }, "下一步,完善资质")
- ])
- ]);
- }
- const PagesRecruitAuth = /* @__PURE__ */ _export_sfc(_sfc_main$z, [["render", _sfc_render$y], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/recruit/auth.vue"]]);
- const logic$5 = {
- data() {
- return {
- serviceTypes: [],
- // 从上一页传递过来的服务类型列表
- qualifications: {},
- // 存储本地预览路径 { '宠物接送': ['path1', ...], ... }
- qualOssIds: {}
- // 存储OSS ID { '宠物接送': ['id1', ...], ... }
- };
- },
- onLoad(options) {
- if (options.services) {
- try {
- this.serviceTypes = JSON.parse(decodeURIComponent(options.services));
- this.serviceTypes.forEach((item) => {
- this.qualifications[item.name] = [];
- this.qualOssIds[item.name] = [];
- });
- } catch (e) {
- formatAppLog("error", "at pages/recruit/qualifications_logic.js:21", "Parse services failed", e);
- }
- }
- },
- methods: {
- chooseImage(serviceName) {
- uni.chooseImage({
- count: 9,
- sizeType: ["compressed"],
- sourceType: ["album", "camera"],
- success: async (res) => {
- if (!this.qualifications[serviceName]) {
- this.qualifications[serviceName] = [];
- this.qualOssIds[serviceName] = [];
- }
- for (const tempPath of res.tempFilePaths) {
- this.qualifications[serviceName].push(tempPath);
- this.$forceUpdate();
- try {
- const uploadRes = await uploadFile(tempPath);
- this.qualOssIds[serviceName].push(uploadRes.data.ossId);
- } catch (err) {
- formatAppLog("error", "at pages/recruit/qualifications_logic.js:44", "上传资质图片失败:", err);
- }
- }
- }
- });
- },
- deleteImage(serviceName, index) {
- this.qualifications[serviceName].splice(index, 1);
- if (this.qualOssIds[serviceName]) {
- this.qualOssIds[serviceName].splice(index, 1);
- }
- this.$forceUpdate();
- },
- goBackToForm() {
- const pages = getCurrentPages();
- if (pages.length > 2) {
- uni.navigateBack({
- delta: 2
- });
- } else {
- uni.reLaunch({
- url: "/pages/recruit/form"
- });
- }
- },
- async submit() {
- let recruitData = {};
- try {
- const stored = uni.getStorageSync("recruit_form_data");
- if (stored) {
- recruitData = JSON.parse(stored);
- }
- } catch (e) {
- formatAppLog("error", "at pages/recruit/qualifications_logic.js:80", "读取招募表单数据失败", e);
- }
- const allQualOssIds = [];
- Object.values(this.qualOssIds).forEach((ids) => {
- allQualOssIds.push(...ids);
- });
- const auditData = {
- name: recruitData.name || "",
- phone: recruitData.mobile || "",
- password: recruitData.password || "",
- gender: recruitData.gender === 1 ? "0" : "1",
- birthday: recruitData.birthday || "",
- serviceTypes: (recruitData.serviceType || []).join(","),
- // 逗号分隔的服务类型ID
- city: recruitData.city || "",
- stationId: recruitData.stationId || null,
- realName: recruitData.realName || "",
- idCard: recruitData.idNumber || "",
- idValidDate: recruitData.expiryDate || "",
- idCardFront: recruitData.idCardFrontOssId || null,
- idCardBack: recruitData.idCardBackOssId || null,
- qualifications: allQualOssIds.join(",")
- // 逗号分隔的资质图片OSS ID
- };
- uni.showLoading({ title: "提交中..." });
- try {
- await submitAudit(auditData);
- uni.hideLoading();
- uni.reLaunch({
- url: "/pages/recruit/success"
- });
- } catch (err) {
- uni.hideLoading();
- formatAppLog("error", "at pages/recruit/qualifications_logic.js:116", "提交申请失败:", err);
- }
- }
- }
- };
- const _sfc_main$y = logic$5;
- function _sfc_render$x(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "qual-container" }, [
- vue.createElementVNode("view", { class: "top-tip" }, "根据国家政策要求,请尽快完成实名认证与健康认证,否则无法开展配送业务。我们承诺将严格保管好您的个人信息。"),
- _ctx.serviceTypes.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "empty-state"
- }, [
- vue.createElementVNode("text", { class: "empty-tip" }, "请返回第一步选择服务类型"),
- vue.createElementVNode("button", {
- class: "back-btn",
- onClick: _cache[0] || (_cache[0] = (...args) => _ctx.goBackToForm && _ctx.goBackToForm(...args))
- }, "返回选择")
- ])) : vue.createCommentVNode("v-if", true),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.serviceTypes, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "qual-card",
- key: item.id
- }, [
- vue.createElementVNode(
- "view",
- { class: "card-title" },
- vue.toDisplayString(item.name) + "服务资质",
- 1
- /* TEXT */
- ),
- vue.createElementVNode("view", { class: "upload-wrapper" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.qualifications[item.name], (img, imgIndex) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "img-item",
- key: imgIndex
- }, [
- vue.createElementVNode("image", {
- src: img,
- class: "preview-img",
- mode: "aspectFill",
- onClick: ($event) => _ctx.previewImage(item.name, imgIndex)
- }, null, 8, ["src", "onClick"]),
- vue.createElementVNode("view", {
- class: "delete-btn",
- onClick: vue.withModifiers(($event) => _ctx.deleteImage(item.name, imgIndex), ["stop"])
- }, "×", 8, ["onClick"])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("view", {
- class: "upload-box",
- onClick: ($event) => _ctx.chooseImage(item.name)
- }, [
- vue.createElementVNode("text", { class: "plus-icon" }, "+"),
- vue.createElementVNode("text", { class: "upload-text" }, "上传")
- ], 8, ["onClick"])
- ])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("view", { class: "footer-actions" }, [
- vue.createElementVNode("button", {
- class: "submit-btn",
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.submit && _ctx.submit(...args))
- }, "立即提交")
- ])
- ]);
- }
- const PagesRecruitQualifications = /* @__PURE__ */ _export_sfc(_sfc_main$y, [["render", _sfc_render$x], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/recruit/qualifications.vue"]]);
- const logic$4 = {
- data() {
- return {
- station: "民治街道第一站",
- name: "张三哥",
- phone: "+8613612345678"
- };
- },
- methods: {
- goHome() {
- uni.reLaunch({
- url: "/pages/login/login"
- });
- }
- }
- };
- const _sfc_main$x = logic$4;
- function _sfc_render$w(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "success-container" }, [
- vue.createElementVNode("view", { class: "icon-area" }, [
- (vue.openBlock(), vue.createElementBlock("svg", {
- class: "success-icon",
- viewBox: "0 0 1024 1024",
- version: "1.1",
- xmlns: "http://www.w3.org/2000/svg"
- }, [
- vue.createElementVNode("path", {
- d: "M512 0C229.23 0 0 229.23 0 512s229.23 512 512 512 512-229.23 512-512S794.77 0 512 0z m0 960C264.58 960 64 759.42 64 512S264.58 64 512 64s448 200.58 448 448-200.58 448-448 448z",
- fill: "#64D01D"
- }),
- vue.createElementVNode("path", {
- d: "M743.08 335.78c-12.23-12.24-32.07-12.24-44.3 0L426.6 607.96 325.22 506.58c-12.24-12.24-32.07-12.24-44.3 0-12.24 12.24-12.24 32.07 0 44.3l124.58 124.58c6.12 6.12 14.14 9.17 22.15 9.17s16.03-3.05 22.15-9.17L743.08 380.08c12.24-12.24 12.24-32.07 0-44.3z",
- fill: "#64D01D"
- })
- ])),
- vue.createElementVNode("text", { class: "main-title" }, "提交成功")
- ]),
- vue.createElementVNode("text", { class: "sub-tip" }, "请保持手机畅通,等待平台工作人员与您联系"),
- vue.createElementVNode("view", { class: "info-card" }, [
- vue.createElementVNode("view", { class: "info-item" }, [
- vue.createElementVNode("text", { class: "label" }, "服务站点:"),
- vue.createElementVNode(
- "text",
- { class: "value" },
- vue.toDisplayString(_ctx.station),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "info-item" }, [
- vue.createElementVNode("text", { class: "label" }, "报 名 人 :"),
- vue.createElementVNode(
- "text",
- { class: "value" },
- vue.toDisplayString(_ctx.name),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "info-item" }, [
- vue.createElementVNode("text", { class: "label" }, "联系手机:"),
- vue.createElementVNode(
- "text",
- { class: "value" },
- vue.toDisplayString(_ctx.phone),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", {
- class: "footer-btn",
- onClick: _cache[0] || (_cache[0] = (...args) => _ctx.goHome && _ctx.goHome(...args))
- }, "我知道了")
- ]);
- }
- const PagesRecruitSuccess = /* @__PURE__ */ _export_sfc(_sfc_main$x, [["render", _sfc_render$w], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/recruit/success.vue"]]);
- const _sfc_main$w = {
- data() {
- return {
- mobile: "",
- code: "",
- countDown: 0,
- timer: null
- };
- },
- computed: {
- mobileMask() {
- if (!this.mobile)
- return "";
- return this.mobile.replace(/(\d{3})\d{4}(\d{4})/, "$1****$2");
- }
- },
- onLoad(options) {
- if (options.mobile) {
- this.mobile = options.mobile;
- } else {
- this.mobile = "13412346783";
- }
- },
- methods: {
- getVerifyCode() {
- if (this.countDown > 0)
- return;
- this.countDown = 60;
- this.timer = setInterval(() => {
- this.countDown--;
- if (this.countDown <= 0) {
- clearInterval(this.timer);
- }
- }, 1e3);
- uni.showToast({ title: "验证码已发送", icon: "none" });
- },
- nextStep() {
- if (!this.code) {
- uni.showToast({ title: "请输入验证码", icon: "none" });
- return;
- }
- uni.navigateTo({
- url: "/pages/login/reset-pwd-set"
- });
- }
- }
- };
- function _sfc_render$v(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "reset-container" }, [
- vue.createElementVNode("view", { class: "content" }, [
- vue.createElementVNode(
- "view",
- { class: "tip-text" },
- "请输入 +86 " + vue.toDisplayString($options.mobileMask) + " 收到的短信验证码,进行验证~",
- 1
- /* TEXT */
- ),
- vue.createElementVNode("view", { class: "input-group" }, [
- vue.createElementVNode("text", { class: "label" }, "验证码"),
- vue.createElementVNode("view", { class: "input-wrapper" }, [
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "code-input",
- type: "number",
- maxlength: "6",
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => $data.code = $event)
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, $data.code]
- ]),
- vue.createElementVNode("view", {
- class: "get-code-btn",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.getVerifyCode && $options.getVerifyCode(...args))
- }, [
- vue.createElementVNode(
- "text",
- { class: "btn-text" },
- vue.toDisplayString($data.countDown > 0 ? `${$data.countDown}s` : "获取验证码"),
- 1
- /* TEXT */
- )
- ])
- ])
- ]),
- vue.createElementVNode("button", {
- class: "next-btn",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.nextStep && $options.nextStep(...args))
- }, "下一步")
- ])
- ]);
- }
- const PagesLoginResetPwdVerify = /* @__PURE__ */ _export_sfc(_sfc_main$w, [["render", _sfc_render$v], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/login/reset-pwd-verify.vue"]]);
- const _sfc_main$v = {
- data() {
- return {
- pwd1: "",
- pwd2: ""
- };
- },
- methods: {
- confirmReset() {
- if (!this.pwd1 || !this.pwd2) {
- uni.showToast({ title: "请输入密码", icon: "none" });
- return;
- }
- if (this.pwd1 !== this.pwd2) {
- uni.showToast({ title: "两次密码不一致", icon: "none" });
- return;
- }
- uni.showToast({ title: "重置成功", icon: "success" });
- setTimeout(() => {
- uni.navigateBack({
- delta: 2
- // 返回到登录页
- });
- }, 1500);
- }
- }
- };
- function _sfc_render$u(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "reset-container" }, [
- vue.createElementVNode("view", { class: "content" }, [
- vue.createElementVNode("view", { class: "tip-text" }, "请输入新密码,并重新登录验证"),
- vue.createElementVNode("view", { class: "input-form" }, [
- vue.createElementVNode("view", { class: "input-row" }, [
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "pwd-input",
- type: "text",
- password: "",
- placeholder: "限12-20位字母和数字组合",
- "placeholder-style": "color:#ccc",
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => $data.pwd1 = $event)
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, $data.pwd1]
- ])
- ]),
- vue.createElementVNode("view", { class: "divider" }),
- vue.createElementVNode("view", { class: "input-row" }, [
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "pwd-input",
- type: "text",
- password: "",
- placeholder: "限12-20位字母和数字组合",
- "placeholder-style": "color:#ccc",
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => $data.pwd2 = $event)
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, $data.pwd2]
- ])
- ]),
- vue.createElementVNode("view", { class: "divider" })
- ]),
- vue.createElementVNode("button", {
- class: "confirm-btn",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.confirmReset && $options.confirmReset(...args))
- }, "确定")
- ])
- ]);
- }
- const PagesLoginResetPwdSet = /* @__PURE__ */ _export_sfc(_sfc_main$v, [["render", _sfc_render$u], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/login/reset-pwd-set.vue"]]);
- function getServiceList() {
- return request({
- url: "/service/list/listOnTaskHall",
- method: "GET"
- });
- }
- function getServiceDetail(id) {
- return request({
- url: `/service/list/${id}`,
- method: "GET"
- });
- }
- function cancelOrderApi(data) {
- return request({
- url: "/order/subOrder/cancel",
- method: "PUT",
- data
- });
- }
- function rejectOrderApi(data) {
- return request({
- url: "/order/subOrder/reject",
- method: "PUT",
- data
- });
- }
- const _sfc_main$u = {
- __name: "index",
- props: {
- currentPath: {
- type: String,
- required: true
- }
- },
- setup(__props, { expose: __expose }) {
- __expose();
- const props = __props;
- const list = vue.ref([
- {
- pagePath: "pages/home/index",
- text: "任务中心",
- iconPath: "/static/tabbar/home.svg",
- selectedIconPath: "/static/tabbar/home-active.svg"
- },
- {
- pagePath: "pages/orders/index",
- text: "我的订单",
- iconPath: "/static/tabbar/order.svg",
- selectedIconPath: "/static/tabbar/order-active.svg"
- },
- {
- pagePath: "pages/mine/index",
- text: "我的",
- iconPath: "/static/tabbar/mine.svg",
- selectedIconPath: "/static/tabbar/mine-active.svg"
- }
- ]);
- const switchTab = (path) => {
- if (props.currentPath === path)
- return;
- uni.switchTab({
- url: "/" + path
- });
- };
- const __returned__ = { props, list, switchTab, ref: vue.ref };
- Object.defineProperty(__returned__, "__isScriptSetup", { enumerable: false, value: true });
- return __returned__;
- }
- };
- function _sfc_render$t(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "custom-tabbar" }, [
- vue.createElementVNode("view", { class: "tabbar-border" }),
- vue.createElementVNode("view", { class: "tabbar-list" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($setup.list, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "tabbar-item",
- key: index,
- onClick: ($event) => $setup.switchTab(item.pagePath)
- }, [
- vue.createElementVNode("image", {
- class: "tabbar-icon",
- src: $props.currentPath === item.pagePath ? item.selectedIconPath : item.iconPath
- }, null, 8, ["src"]),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tabbar-text", { "tabbar-text-active": $props.currentPath === item.pagePath }])
- },
- vue.toDisplayString(item.text),
- 3
- /* TEXT, CLASS */
- )
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ]);
- }
- const customTabbar = /* @__PURE__ */ _export_sfc(_sfc_main$u, [["render", _sfc_render$t], ["__scopeId", "data-v-52454e90"], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/components/custom-tabbar/index.vue"]]);
- const logic$3 = {
- components: {
- customTabbar
- },
- data() {
- return {
- taskList: [],
- currentFilter: "default",
- // default, distance, time
- filterCondition: "筛选条件",
- sortDistance: "asc",
- // asc, desc
- sortTime: "asc",
- scrollTop: 0,
- // Track scroll position
- isFilterShow: false,
- tempFilter: {
- service: null,
- distance: "全部",
- amount: "全部"
- },
- activeFilter: {
- service: null,
- distance: "全部",
- amount: "全部"
- },
- workStatus: "working",
- // working | resting
- showConfirmModal: false,
- showPetModal: false,
- currentPetInfo: {},
- showRejectModal: false,
- rejectReason: "",
- currentOrder: null,
- showAcceptConfirmModal: false,
- showNavModal: false,
- navTargetItem: null,
- navTargetPointType: "",
- profile: null,
- profileLoading: false,
- serviceList: [],
- orderStats: {
- total: 0,
- reject: 0,
- award: 0,
- punishment: 0
- }
- };
- },
- onPageScroll(e) {
- this.scrollTop = e.scrollTop;
- },
- async onLoad() {
- this.checkWorkStatus();
- await this.loadServiceList();
- this.loadTaskList();
- },
- onShow() {
- uni.hideTabBar();
- this.checkWorkStatus();
- if (isLoggedIn()) {
- this.loadProfile();
- this.loadOrderStats();
- }
- },
- async onPullDownRefresh() {
- this.checkWorkStatus();
- try {
- await this.loadServiceList();
- const tasks = [
- this.loadTaskList()
- ];
- if (isLoggedIn()) {
- tasks.push(this.loadProfile());
- tasks.push(this.loadOrderStats());
- }
- await Promise.all(tasks);
- } catch (err) {
- formatAppLog("error", "at pages/home/logic.js:86", "刷新异常:", err);
- } finally {
- uni.stopPullDownRefresh();
- uni.showToast({ title: "刷新成功", icon: "success" });
- }
- },
- methods: {
- async loadProfile() {
- if (this.profileLoading)
- return;
- this.profileLoading = true;
- try {
- const res = await getMyProfile();
- this.profile = res.data || null;
- } catch (err) {
- formatAppLog("error", "at pages/home/logic.js:100", "获取个人信息失败:", err);
- } finally {
- this.profileLoading = false;
- }
- },
- async loadServiceList() {
- try {
- const res = await getServiceList();
- this.serviceList = res.data || [];
- } catch (err) {
- formatAppLog("error", "at pages/home/logic.js:110", "获取服务类型失败:", err);
- }
- },
- async loadOrderStats() {
- try {
- const res = await getOrderCount();
- this.orderStats = res.data || { total: 0, reject: 0, award: 0, punishment: 0 };
- } catch (err) {
- formatAppLog("error", "at pages/home/logic.js:118", "获取订单统计失败:", err);
- }
- },
- checkWorkStatus() {
- const status = uni.getStorageSync("workStatus");
- if (status) {
- this.workStatus = status;
- } else {
- this.workStatus = "working";
- uni.setStorageSync("workStatus", "working");
- }
- },
- toggleFilter() {
- if (this.workStatus === "resting")
- return;
- this.isFilterShow = !this.isFilterShow;
- },
- goToWorkStatus() {
- uni.navigateTo({
- url: "/pages/home/work-status"
- });
- },
- startWork() {
- this.showConfirmModal = true;
- },
- confirmStartWork() {
- this.workStatus = "working";
- uni.setStorageSync("workStatus", "working");
- this.loadTaskList();
- this.showConfirmModal = false;
- uni.showToast({ title: "已开始接单", icon: "success" });
- },
- closeConfirmModal() {
- this.showConfirmModal = false;
- },
- showPetProfile(item) {
- this.currentPetInfo = item;
- this.showPetModal = true;
- },
- closePetProfile() {
- this.showPetModal = false;
- },
- openRejectModal(item) {
- this.currentOrder = item;
- this.rejectReason = "";
- this.showRejectModal = true;
- },
- closeRejectModal() {
- this.showRejectModal = false;
- this.currentOrder = null;
- },
- async confirmReject() {
- var _a;
- if (!this.rejectReason.trim()) {
- uni.showToast({ title: "请输入拒绝理由", icon: "none" });
- return;
- }
- if (!((_a = this.currentOrder) == null ? void 0 : _a.id))
- return;
- try {
- uni.showLoading({ title: "提交中...", mask: true });
- await rejectOrderApi({
- orderId: this.currentOrder.id,
- rejectReason: this.rejectReason
- });
- uni.showToast({ title: "已拒绝接单", icon: "success" });
- this.showRejectModal = false;
- this.currentOrder = null;
- this.loadTaskList();
- } catch (err) {
- formatAppLog("error", "at pages/home/logic.js:186", "拒绝接单失败:", err);
- uni.showToast({ title: "操作失败", icon: "none" });
- } finally {
- uni.hideLoading();
- }
- },
- openAcceptModal(item) {
- this.currentOrder = item;
- this.showAcceptConfirmModal = true;
- },
- closeAcceptModal() {
- this.showAcceptConfirmModal = false;
- this.currentOrder = null;
- },
- async confirmAccept() {
- var _a;
- if (!((_a = this.currentOrder) == null ? void 0 : _a.id))
- return;
- try {
- await acceptOrder(this.currentOrder.id);
- uni.showToast({ title: "接单成功", icon: "success" });
- this.showAcceptConfirmModal = false;
- this.currentOrder = null;
- this.loadTaskList();
- this.loadProfile();
- } catch (err) {
- formatAppLog("error", "at pages/home/logic.js:210", "接单失败:", err);
- uni.showToast({ title: "接单失败", icon: "none" });
- }
- },
- openNavigation(item, pointType) {
- this.navTargetItem = item;
- this.navTargetPointType = pointType;
- this.showNavModal = true;
- },
- closeNavModal() {
- this.showNavModal = false;
- },
- chooseMap(mapType) {
- let item = this.navTargetItem;
- let pointType = this.navTargetPointType;
- let name = pointType === "start" ? item.startLocation : item.endLocation;
- let address = pointType === "start" ? item.startAddress : item.endAddress;
- this.showNavModal = false;
- uni.openLocation({
- latitude: 30.52,
- // Mock lat
- longitude: 114.31,
- // Mock lng
- name: name || "目的地",
- address: address || "默认地址",
- success: function() {
- formatAppLog("log", "at pages/home/logic.js:236", "打开导航成功: " + mapType);
- }
- });
- },
- selectService(type) {
- this.tempFilter.service = type;
- },
- selectDistance(type) {
- this.tempFilter.distance = type;
- },
- selectAmount(type) {
- this.tempFilter.amount = type;
- },
- resetFilter() {
- this.tempFilter = {
- service: null,
- distance: "全部",
- amount: "全部"
- };
- },
- confirmFilter() {
- this.activeFilter = { ...this.tempFilter };
- this.isFilterShow = false;
- this.loadTaskList();
- },
- closeFilter() {
- this.isFilterShow = false;
- },
- goToDetail(item) {
- formatAppLog("log", "at pages/home/logic.js:265", "Go to detail", item);
- },
- async loadTaskList() {
- try {
- const params = {
- service: this.activeFilter.service,
- minPrice: this.getMinPrice(),
- maxPrice: this.getMaxPrice(),
- pageNum: 1,
- pageSize: 20
- };
- const res = await getPendingOrders(params);
- this.taskList = (res.rows || []).map((item) => this.transformOrder(item));
- } catch (err) {
- formatAppLog("error", "at pages/home/logic.js:279", "获取订单列表失败:", err);
- uni.showToast({ title: "加载失败", icon: "none" });
- this.taskList = [];
- }
- },
- getMinPrice() {
- const amount = this.activeFilter.amount;
- if (amount === "100以下")
- return 0;
- if (amount === "100-200")
- return 1e4;
- if (amount === "200-500")
- return 2e4;
- if (amount === "500以上")
- return 5e4;
- return void 0;
- },
- getMaxPrice() {
- const amount = this.activeFilter.amount;
- if (amount === "100以下")
- return 1e4;
- if (amount === "100-200")
- return 2e4;
- if (amount === "200-500")
- return 5e4;
- return void 0;
- },
- transformOrder(item) {
- const service = this.serviceList.find((s) => s.id === item.service);
- const serviceText = (service == null ? void 0 : service.name) || "未知";
- const serviceIcon = (service == null ? void 0 : service.iconUrl) || "";
- const mode = (service == null ? void 0 : service.mode) || 0;
- const isRoundTrip = mode === 1;
- return {
- id: item.id,
- type: isRoundTrip ? 1 : item.service,
- typeText: serviceText,
- typeIcon: serviceIcon,
- price: (item.price / 100).toFixed(2),
- timeLabel: "服务时间",
- time: item.serviceTime,
- petAvatar: "/static/dog.png",
- petName: item.petName,
- petBreed: item.breed,
- petGender: "M",
- petAge: "",
- petWeight: "",
- petPersonality: "",
- petHobby: "",
- petRemark: "",
- petTags: [],
- petLogs: [],
- startLocation: isRoundTrip ? item.fromAddress : "",
- startAddress: isRoundTrip ? item.fromAddress : "",
- startDistance: "0km",
- endLocation: (item.customerName || item.contact || "") + " " + (item.customerPhone || ""),
- endAddress: item.toAddress,
- endDistance: "0km",
- serviceContent: "",
- remark: item.remark || ""
- };
- },
- setFilter(type) {
- this.currentFilter = type;
- if (type === "distance") {
- this.sortDistance = this.sortDistance === "asc" ? "desc" : "asc";
- uni.showToast({ title: `按距离${this.sortDistance === "asc" ? "升序" : "降序"}`, icon: "none" });
- } else if (type === "time") {
- this.sortTime = this.sortTime === "asc" ? "desc" : "asc";
- uni.showToast({ title: `按时间${this.sortTime === "asc" ? "升序" : "降序"}`, icon: "none" });
- }
- },
- showFilterDropdown() {
- this.toggleFilter();
- }
- }
- };
- const _imports_0$3 = "/static/icons/bell.svg";
- const _imports_3$2 = "/static/icons/nav_arrow.svg";
- const _sfc_main$t = {
- ...logic$3
- };
- function _sfc_render$s(_ctx, _cache, $props, $setup, $data, $options) {
- var _a, _b, _c;
- const _component_custom_tabbar = vue.resolveComponent("custom-tabbar");
- return vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- null,
- [
- vue.createElementVNode("view", { class: "container" }, [
- vue.createElementVNode(
- "view",
- {
- class: "custom-nav-bar",
- style: vue.normalizeStyle({ backgroundColor: _ctx.scrollTop > 20 ? "#fff" : "transparent" })
- },
- [
- vue.createElementVNode("text", { class: "nav-title" }, "任务中心")
- ],
- 4
- /* STYLE */
- ),
- vue.createElementVNode("view", { class: "nav-bg" }, [
- vue.createElementVNode("view", { class: "bg-circle-left" }),
- vue.createElementVNode("view", { class: "bg-circle-right" })
- ]),
- vue.createElementVNode("view", { class: "header-section" }, [
- vue.createElementVNode("view", { class: "user-info" }, [
- vue.createElementVNode("image", {
- class: "avatar",
- src: ((_a = _ctx.profile) == null ? void 0 : _a.avatarUrl) || "/static/touxiang.png",
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "info-content" }, [
- vue.createElementVNode("view", { class: "top-row" }, [
- vue.createElementVNode(
- "text",
- { class: "name" },
- vue.toDisplayString(((_b = _ctx.profile) == null ? void 0 : _b.name) || "未登录"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["status-pill", { "resting": _ctx.workStatus === "resting" }]),
- onClick: _cache[0] || (_cache[0] = (...args) => _ctx.goToWorkStatus && _ctx.goToWorkStatus(...args))
- },
- [
- vue.createElementVNode("view", { class: "status-dot-bg" }, [
- _ctx.workStatus === "working" ? (vue.openBlock(), vue.createElementBlock("text", {
- key: 0,
- class: "check-mark"
- }, "✔")) : (vue.openBlock(), vue.createElementBlock("text", {
- key: 1,
- class: "check-mark",
- style: { "font-size": "16rpx", "line-height": "20rpx" }
- }, "✕"))
- ]),
- vue.createElementVNode(
- "text",
- { class: "status-text" },
- vue.toDisplayString(_ctx.workStatus === "working" ? "接单中" : "正在休息"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", { class: "arrow-down" }, "▼")
- ],
- 2
- /* CLASS */
- )
- ]),
- vue.createElementVNode("view", { class: "bottom-row" }, [
- vue.createElementVNode(
- "text",
- { class: "city-label" },
- "接单城市:" + vue.toDisplayString(((_c = _ctx.profile) == null ? void 0 : _c.cityName) || "暂无"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", { class: "city-arrow" }, ">")
- ])
- ]),
- vue.createElementVNode("view", { class: "notification-box" }, [
- vue.createElementVNode("image", {
- class: "bell-img",
- src: _imports_0$3
- }),
- vue.createElementVNode("view", { class: "badge-count" }, "2")
- ])
- ]),
- vue.createElementVNode("view", { class: "stats-card" }, [
- vue.createElementVNode("view", { class: "stat-item" }, [
- vue.createElementVNode(
- "text",
- { class: "num" },
- vue.toDisplayString(_ctx.orderStats.total),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", { class: "label" }, "累计接单")
- ]),
- vue.createElementVNode("view", { class: "divider" }),
- vue.createElementVNode("view", { class: "stat-item" }, [
- vue.createElementVNode(
- "text",
- { class: "num" },
- vue.toDisplayString(_ctx.orderStats.reject),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", { class: "label" }, "拒接订单")
- ]),
- vue.createElementVNode("view", { class: "divider" }),
- vue.createElementVNode("view", { class: "stat-item" }, [
- vue.createElementVNode(
- "text",
- { class: "num" },
- vue.toDisplayString(_ctx.orderStats.award),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", { class: "label" }, "奖励订单")
- ]),
- vue.createElementVNode("view", { class: "divider" }),
- vue.createElementVNode("view", { class: "stat-item" }, [
- vue.createElementVNode(
- "text",
- { class: "num" },
- vue.toDisplayString(_ctx.orderStats.punishment),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", { class: "label" }, "惩罚订单")
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "task-header" }, [
- vue.createElementVNode(
- "view",
- {
- class: "header-inner",
- style: vue.normalizeStyle({ backgroundColor: _ctx.scrollTop > 300 || _ctx.isFilterShow ? "#fff" : "transparent" })
- },
- [
- vue.createElementVNode("view", { class: "left-title" }, [
- vue.createElementVNode("view", { class: "orange-bar" }),
- vue.createElementVNode("text", { class: "title" }, "任务大厅"),
- vue.createElementVNode(
- "text",
- { class: "count" },
- "- (" + vue.toDisplayString(_ctx.taskList.length) + "单)",
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "filter-options" }, [
- vue.createElementVNode("view", {
- class: "dropdown",
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.showFilterDropdown && _ctx.showFilterDropdown(...args))
- }, [
- vue.createElementVNode("text", null, "筛选条件"),
- vue.createElementVNode("text", { class: "arrow-down" }, "﹀")
- ])
- ])
- ],
- 4
- /* STYLE */
- ),
- _ctx.isFilterShow ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "filter-mask",
- onClick: _cache[2] || (_cache[2] = (...args) => _ctx.closeFilter && _ctx.closeFilter(...args))
- })) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["filter-panel", { show: _ctx.isFilterShow }])
- },
- [
- vue.createElementVNode("view", { class: "filter-section" }, [
- vue.createElementVNode("text", { class: "section-title" }, "服务类型"),
- vue.createElementVNode("view", { class: "options-grid" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["option-btn", { active: _ctx.tempFilter.service === null }]),
- onClick: _cache[3] || (_cache[3] = ($event) => _ctx.selectService(null))
- },
- "全部",
- 2
- /* CLASS */
- ),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.serviceList, (item) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: vue.normalizeClass(["option-btn", { active: _ctx.tempFilter.service === item.id }]),
- key: item.id,
- onClick: ($event) => _ctx.selectService(item.id)
- }, vue.toDisplayString(item.name), 11, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ]),
- vue.createElementVNode("view", { class: "filter-section" }, [
- vue.createElementVNode("text", { class: "section-title" }, "金额"),
- vue.createElementVNode("view", { class: "options-grid" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["option-btn", { active: _ctx.tempFilter.amount === "全部" }]),
- onClick: _cache[4] || (_cache[4] = ($event) => _ctx.selectAmount("全部"))
- },
- "全部",
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["option-btn", { active: _ctx.tempFilter.amount === "100以下" }]),
- onClick: _cache[5] || (_cache[5] = ($event) => _ctx.selectAmount("100以下"))
- },
- "100以下",
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["option-btn", { active: _ctx.tempFilter.amount === "100-200" }]),
- onClick: _cache[6] || (_cache[6] = ($event) => _ctx.selectAmount("100-200"))
- },
- "100-200",
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["option-btn", { active: _ctx.tempFilter.amount === "200-500" }]),
- onClick: _cache[7] || (_cache[7] = ($event) => _ctx.selectAmount("200-500"))
- },
- "200-500",
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["option-btn", { active: _ctx.tempFilter.amount === "500以上" }]),
- onClick: _cache[8] || (_cache[8] = ($event) => _ctx.selectAmount("500以上"))
- },
- "500以上",
- 2
- /* CLASS */
- )
- ])
- ]),
- vue.createElementVNode("view", { class: "filter-actions" }, [
- vue.createElementVNode("button", {
- class: "action-btn reset",
- onClick: _cache[9] || (_cache[9] = (...args) => _ctx.resetFilter && _ctx.resetFilter(...args))
- }, "重置"),
- vue.createElementVNode("button", {
- class: "action-btn confirm",
- onClick: _cache[10] || (_cache[10] = (...args) => _ctx.confirmFilter && _ctx.confirmFilter(...args))
- }, "确认")
- ])
- ],
- 2
- /* CLASS */
- )
- ]),
- vue.createElementVNode("view", { class: "task-list-container" }, [
- vue.createElementVNode("view", { class: "task-list" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.taskList, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "task-card",
- key: index,
- onClick: ($event) => _ctx.goToDetail(item)
- }, [
- vue.createElementVNode("view", { class: "card-header" }, [
- vue.createElementVNode("view", { class: "type-badge" }, [
- vue.createElementVNode("image", {
- class: "type-icon",
- src: item.typeIcon
- }, null, 8, ["src"]),
- vue.createElementVNode(
- "text",
- { class: "type-text" },
- vue.toDisplayString(item.typeText),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode(
- "text",
- { class: "price" },
- "¥" + vue.toDisplayString(item.price),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "card-body" }, [
- vue.createElementVNode("view", { class: "time-row" }, [
- vue.createElementVNode(
- "text",
- { class: "label" },
- vue.toDisplayString(item.timeLabel) + ":",
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "value" },
- vue.toDisplayString(item.time),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pet-card" }, [
- vue.createElementVNode("image", {
- class: "pet-avatar",
- src: item.petAvatar,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "pet-info" }, [
- vue.createElementVNode(
- "text",
- { class: "pet-name" },
- vue.toDisplayString(item.petName),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "pet-breed" },
- "品种: " + vue.toDisplayString(item.petBreed),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", { class: "route-info" }, [
- item.type === 1 ? (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 0 },
- [
- vue.createElementVNode("view", {
- class: "route-item",
- onClick: vue.withModifiers(($event) => _ctx.openNavigation(item, "start"), ["stop"])
- }, [
- vue.createElementVNode("view", { class: "icon-circle start" }, "取"),
- vue.createElementVNode("view", { class: "route-line-vertical" }),
- vue.createElementVNode("view", { class: "address-box" }, [
- vue.createElementVNode(
- "text",
- { class: "addr-title" },
- vue.toDisplayString(item.startLocation),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "addr-desc" },
- vue.toDisplayString(item.startAddress),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("image", {
- class: "nav-arrow",
- src: _imports_3$2,
- style: { "flex-shrink": "0", "align-self": "center" }
- })
- ], 8, ["onClick"]),
- vue.createElementVNode("view", {
- class: "route-item",
- onClick: vue.withModifiers(($event) => _ctx.openNavigation(item, "end"), ["stop"])
- }, [
- vue.createElementVNode("view", { class: "icon-circle end" }, "送"),
- vue.createElementVNode("view", { class: "address-box" }, [
- vue.createElementVNode(
- "text",
- { class: "addr-title" },
- vue.toDisplayString(item.endLocation),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "addr-desc" },
- vue.toDisplayString(item.endAddress),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("image", {
- class: "nav-arrow",
- src: _imports_3$2,
- style: { "flex-shrink": "0", "align-self": "center" }
- })
- ], 8, ["onClick"])
- ],
- 64
- /* STABLE_FRAGMENT */
- )) : (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 1 },
- [
- vue.createElementVNode("view", {
- class: "route-item",
- onClick: vue.withModifiers(($event) => _ctx.openNavigation(item, "end"), ["stop"])
- }, [
- vue.createElementVNode("view", { class: "icon-circle service" }, "服"),
- vue.createElementVNode("view", { class: "address-box" }, [
- vue.createElementVNode(
- "text",
- { class: "addr-title" },
- vue.toDisplayString(item.endLocation),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "addr-desc" },
- vue.toDisplayString(item.endAddress),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("image", {
- class: "nav-arrow",
- src: _imports_3$2,
- style: { "flex-shrink": "0", "align-self": "center" }
- })
- ], 8, ["onClick"]),
- item.serviceContent ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "service-content"
- }, [
- vue.createElementVNode("text", { class: "content-label" }, "服务内容:"),
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(item.serviceContent),
- 1
- /* TEXT */
- )
- ])) : vue.createCommentVNode("v-if", true)
- ],
- 64
- /* STABLE_FRAGMENT */
- ))
- ]),
- item.remark ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "remark-box"
- }, [
- vue.createElementVNode(
- "text",
- null,
- "备注:" + vue.toDisplayString(item.remark),
- 1
- /* TEXT */
- )
- ])) : vue.createCommentVNode("v-if", true)
- ]),
- vue.createElementVNode("view", { class: "action-btns" }, [
- vue.createElementVNode("button", {
- class: "btn reject",
- onClick: vue.withModifiers(($event) => _ctx.openRejectModal(item), ["stop"])
- }, "拒绝", 8, ["onClick"]),
- vue.createElementVNode("button", {
- class: "btn accept",
- onClick: vue.withModifiers(($event) => _ctx.openAcceptModal(item), ["stop"])
- }, "接单", 8, ["onClick"])
- ])
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("view", { style: { "height": "120rpx" } })
- ])
- ]),
- _ctx.showConfirmModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "modal-mask"
- }, [
- vue.createElementVNode("view", { class: "custom-modal" }, [
- vue.createElementVNode("text", { class: "modal-title" }, "提示"),
- vue.createElementVNode("text", { class: "modal-content" }, "是否确定结束休息,开始接单?"),
- vue.createElementVNode("view", { class: "modal-btns" }, [
- vue.createElementVNode("button", {
- class: "modal-btn cancel",
- onClick: _cache[11] || (_cache[11] = (...args) => _ctx.closeConfirmModal && _ctx.closeConfirmModal(...args))
- }, "取消"),
- vue.createElementVNode("button", {
- class: "modal-btn confirm",
- onClick: _cache[12] || (_cache[12] = (...args) => _ctx.confirmStartWork && _ctx.confirmStartWork(...args))
- }, "确定")
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.showPetModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "pet-modal-mask",
- onClick: _cache[16] || (_cache[16] = (...args) => _ctx.closePetProfile && _ctx.closePetProfile(...args))
- }, [
- vue.createElementVNode("view", {
- class: "pet-modal-content",
- onClick: _cache[15] || (_cache[15] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "pet-modal-header" }, [
- vue.createElementVNode("text", { class: "pet-modal-title" }, "宠物档案"),
- vue.createElementVNode("view", {
- class: "close-icon-btn",
- onClick: _cache[13] || (_cache[13] = (...args) => _ctx.closePetProfile && _ctx.closePetProfile(...args))
- }, "×")
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "pet-modal-scroll"
- }, [
- vue.createElementVNode("view", { class: "pet-base-info" }, [
- vue.createElementVNode("image", {
- class: "pm-avatar",
- src: _ctx.currentPetInfo.petAvatar,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "pm-info-text" }, [
- vue.createElementVNode("view", { class: "pm-name-row" }, [
- vue.createElementVNode(
- "text",
- { class: "pm-name" },
- vue.toDisplayString(_ctx.currentPetInfo.petName),
- 1
- /* TEXT */
- ),
- _ctx.currentPetInfo.petGender === "M" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "pm-gender"
- }, [
- vue.createElementVNode("text", { class: "gender-icon" }, "♂"),
- vue.createElementVNode("text", null, "公")
- ])) : _ctx.currentPetInfo.petGender === "F" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "pm-gender female"
- }, [
- vue.createElementVNode("text", { class: "gender-icon" }, "♀"),
- vue.createElementVNode("text", null, "母")
- ])) : vue.createCommentVNode("v-if", true)
- ]),
- vue.createElementVNode(
- "text",
- { class: "pm-breed" },
- "品种:" + vue.toDisplayString(_ctx.currentPetInfo.petBreed),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", { class: "pm-detail-grid" }, [
- vue.createElementVNode("view", { class: "pm-grid-item half" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "年龄"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petAge || "未知"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item half" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "体重"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petWeight || "未知"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item full" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "性格"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petPersonality || "无"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item full" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "爱好"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petHobby || "无"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item full" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "备注"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petRemark || "无特殊过敏史"),
- 1
- /* TEXT */
- )
- ])
- ]),
- _ctx.currentPetInfo.petTags && _ctx.currentPetInfo.petTags.length > 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "pm-tags"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.currentPetInfo.petTags, (tag, index) => {
- return vue.openBlock(), vue.createElementBlock(
- "view",
- {
- class: "pm-tag",
- key: index
- },
- vue.toDisplayString(tag),
- 1
- /* TEXT */
- );
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("view", { class: "pm-section-title" }, [
- vue.createElementVNode("view", { class: "orange-bar" }),
- vue.createElementVNode("text", null, "备注日志")
- ]),
- vue.createElementVNode("view", { class: "pm-log-list" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.currentPetInfo.petLogs, (log, lIndex) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "pm-log-item",
- key: lIndex
- }, [
- vue.createElementVNode(
- "text",
- { class: "pm-log-date" },
- vue.toDisplayString(log.date),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "pm-log-text" },
- vue.toDisplayString(log.content),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "pm-log-recorder" },
- vue.toDisplayString(log.recorder === "系统记录" ? "" : "记录人: ") + vue.toDisplayString(log.recorder),
- 1
- /* TEXT */
- )
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("view", { style: { "height": "40rpx" } }),
- vue.createElementVNode("button", {
- class: "pm-bottom-close",
- onClick: _cache[14] || (_cache[14] = (...args) => _ctx.closePetProfile && _ctx.closePetProfile(...args))
- }, "关闭"),
- vue.createElementVNode("view", { style: { "height": "20rpx" } })
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true)
- ]),
- _ctx.showRejectModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "modal-mask"
- }, [
- vue.createElementVNode("view", { class: "custom-modal" }, [
- vue.createElementVNode("text", { class: "modal-title" }, "拒绝接单"),
- vue.withDirectives(vue.createElementVNode(
- "textarea",
- {
- class: "reject-textarea",
- "onUpdate:modelValue": _cache[17] || (_cache[17] = ($event) => _ctx.rejectReason = $event),
- placeholder: "请输入拒绝理由(必填)",
- maxlength: "100"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.rejectReason]
- ]),
- vue.createElementVNode("view", { class: "modal-btns mt-30" }, [
- vue.createElementVNode("button", {
- class: "modal-btn cancel",
- onClick: _cache[18] || (_cache[18] = (...args) => _ctx.closeRejectModal && _ctx.closeRejectModal(...args))
- }, "取消"),
- vue.createElementVNode("button", {
- class: "modal-btn confirm",
- onClick: _cache[19] || (_cache[19] = (...args) => _ctx.confirmReject && _ctx.confirmReject(...args))
- }, "提交")
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.showAcceptConfirmModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "modal-mask"
- }, [
- vue.createElementVNode("view", { class: "custom-modal" }, [
- vue.createElementVNode("text", { class: "modal-title" }, "接单确认"),
- vue.createElementVNode("view", { class: "modal-content-box" }, [
- vue.createElementVNode("text", { class: "modal-content-main" }, "请确认是否接收此订单?"),
- vue.createElementVNode("text", { class: "modal-content-sub" }, "接单后请尽快通过电话联系用户")
- ]),
- vue.createElementVNode("view", { class: "modal-btns mt-30" }, [
- vue.createElementVNode("button", {
- class: "modal-btn cancel",
- onClick: _cache[20] || (_cache[20] = (...args) => _ctx.closeAcceptModal && _ctx.closeAcceptModal(...args))
- }, "再想想"),
- vue.createElementVNode("button", {
- class: "modal-btn confirm",
- onClick: _cache[21] || (_cache[21] = (...args) => _ctx.confirmAccept && _ctx.confirmAccept(...args))
- }, "确认接单")
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.showNavModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 2,
- class: "nav-modal-mask",
- onClick: _cache[27] || (_cache[27] = (...args) => _ctx.closeNavModal && _ctx.closeNavModal(...args))
- }, [
- vue.createElementVNode("view", {
- class: "nav-action-sheet",
- onClick: _cache[26] || (_cache[26] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "nav-sheet-title" }, "选择地图进行导航"),
- vue.createElementVNode("view", {
- class: "nav-sheet-item",
- onClick: _cache[22] || (_cache[22] = ($event) => _ctx.chooseMap("高德"))
- }, "高德地图"),
- vue.createElementVNode("view", {
- class: "nav-sheet-item",
- onClick: _cache[23] || (_cache[23] = ($event) => _ctx.chooseMap("腾讯"))
- }, "腾讯地图"),
- vue.createElementVNode("view", {
- class: "nav-sheet-item",
- onClick: _cache[24] || (_cache[24] = ($event) => _ctx.chooseMap("百度"))
- }, "百度地图"),
- vue.createElementVNode("view", { class: "nav-sheet-gap" }),
- vue.createElementVNode("view", {
- class: "nav-sheet-item cancel",
- onClick: _cache[25] || (_cache[25] = (...args) => _ctx.closeNavModal && _ctx.closeNavModal(...args))
- }, "取消")
- ])
- ])) : vue.createCommentVNode("v-if", true),
- vue.createVNode(_component_custom_tabbar, { currentPath: "pages/home/index" })
- ],
- 64
- /* STABLE_FRAGMENT */
- );
- }
- const PagesHomeIndex = /* @__PURE__ */ _export_sfc(_sfc_main$t, [["render", _sfc_render$s], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/home/index.vue"]]);
- const _sfc_main$s = {
- data() {
- return {
- status: "working"
- // working | resting
- };
- },
- onShow() {
- const savedStatus = uni.getStorageSync("workStatus");
- if (savedStatus) {
- this.status = savedStatus;
- }
- },
- methods: {
- toggleStatus() {
- if (this.status === "working") {
- this.status = "resting";
- uni.setStorageSync("workStatus", "resting");
- } else {
- this.status = "working";
- uni.setStorageSync("workStatus", "working");
- }
- }
- }
- };
- function _sfc_render$r(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "signboard-container" }, [
- vue.createElementVNode("view", { class: "rope" }),
- vue.createElementVNode("view", { class: "nail" }),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["board", { "resting": $data.status === "resting" }])
- },
- [
- vue.createElementVNode("view", { class: "screw top-left" }),
- vue.createElementVNode("view", { class: "screw top-right" }),
- vue.createElementVNode("view", { class: "screw bottom-left" }),
- vue.createElementVNode("view", { class: "screw bottom-right" }),
- vue.createElementVNode("view", { class: "board-inner" }, [
- vue.createElementVNode(
- "text",
- { class: "status-text" },
- vue.toDisplayString($data.status === "working" ? "接单中" : "休息中"),
- 1
- /* TEXT */
- )
- ])
- ],
- 2
- /* CLASS */
- )
- ]),
- vue.createElementVNode("view", { class: "status-desc" }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString($data.status === "working" ? "当前处于工作接单中,正常接收新订单" : "当前处于休息状态,暂停接收新订单"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "action-area" }, [
- vue.createElementVNode(
- "button",
- {
- class: vue.normalizeClass(["action-btn", { "stop": $data.status === "working", "stopped": $data.status === "resting" }]),
- onClick: _cache[0] || (_cache[0] = (...args) => $options.toggleStatus && $options.toggleStatus(...args))
- },
- vue.toDisplayString($data.status === "working" ? "停止接单" : "已停止接单"),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode("view", { class: "tips" }, [
- $data.status === "working" ? (vue.openBlock(), vue.createElementBlock("text", { key: 0 }, "当您希望长时间不再接收订单时,请点击上方按钮停止接单,开启后需手动恢复。")) : (vue.openBlock(), vue.createElementBlock("text", { key: 1 }, "点击上方按钮恢复接单,开始接收新的任务推送。"))
- ])
- ])
- ]);
- }
- const PagesHomeWorkStatus = /* @__PURE__ */ _export_sfc(_sfc_main$s, [["render", _sfc_render$r], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/home/work-status.vue"]]);
- const logic$2 = {
- components: {
- customTabbar
- },
- data() {
- return {
- currentTab: 0,
- tabs: ["待接送/服务", "配送/服务中", "已完成", "已拒绝"],
- typeFilterOptions: ["全部类型"],
- currentTypeFilterIdx: 0,
- activeDropdown: 0,
- hasTimeFilter: false,
- currentMonth: "2026年2月",
- weekDays: ["日", "一", "二", "三", "四", "五", "六"],
- calendarDays: [],
- selectedDateRange: [],
- allOrderList: [],
- serviceList: [],
- searchContent: "",
- startServiceTime: "",
- endServiceTime: "",
- showPetModal: false,
- currentPetInfo: {},
- showNavModal: false,
- navTargetItem: null,
- navTargetPointType: "",
- activeCallItem: null,
- showRemarkInput: false,
- remarkText: ""
- };
- },
- created() {
- this.initCalendar();
- },
- async onLoad() {
- await this.loadServiceList();
- await this.loadOrders();
- },
- onShow() {
- uni.hideTabBar();
- this.loadOrders();
- },
- async onPullDownRefresh() {
- try {
- await this.loadServiceList();
- await this.loadOrders();
- } finally {
- uni.stopPullDownRefresh();
- }
- },
- watch: {
- currentTab() {
- this.loadOrders();
- },
- currentTypeFilterIdx() {
- this.loadOrders();
- },
- searchContent() {
- this.loadOrders();
- }
- },
- computed: {
- orderList() {
- return this.allOrderList;
- }
- },
- methods: {
- async loadServiceList() {
- try {
- const res = await getServiceList();
- this.serviceList = res.data || [];
- this.typeFilterOptions = ["全部类型", ...this.serviceList.map((s) => s.name)];
- } catch (err) {
- formatAppLog("error", "at pages/orders/logic.js:82", "获取服务类型失败:", err);
- }
- },
- async loadOrders() {
- var _a;
- try {
- const statusMap = { 0: 2, 1: 3, 2: 4, 3: 5 };
- const serviceId = this.currentTypeFilterIdx > 0 ? (_a = this.serviceList[this.currentTypeFilterIdx - 1]) == null ? void 0 : _a.id : void 0;
- const params = {
- status: statusMap[this.currentTab],
- content: this.searchContent || void 0,
- service: serviceId,
- startServiceTime: this.startServiceTime || void 0,
- endServiceTime: this.endServiceTime || void 0
- };
- formatAppLog("log", "at pages/orders/logic.js:96", "订单列表请求参数:", params);
- const res = await getMyOrders(params);
- formatAppLog("log", "at pages/orders/logic.js:98", "订单列表响应:", res);
- const orders = res.rows || [];
- formatAppLog("log", "at pages/orders/logic.js:100", "订单数量:", orders.length);
- this.allOrderList = orders.map((order) => this.transformOrder(order, this.currentTab));
- } catch (err) {
- formatAppLog("error", "at pages/orders/logic.js:103", "获取订单列表失败:", err);
- this.allOrderList = [];
- }
- },
- transformOrder(order, tabIndex) {
- const service = this.serviceList.find((s) => s.id === order.service);
- const serviceText = (service == null ? void 0 : service.name) || "未知";
- const serviceIcon = (service == null ? void 0 : service.iconUrl) || "";
- const mode = (service == null ? void 0 : service.mode) || 0;
- const isRoundTrip = mode === 1;
- let statusText = "接单";
- if (tabIndex === 0) {
- statusText = "接单";
- } else if (tabIndex === 1) {
- statusText = isRoundTrip ? "出发" : "开始";
- } else if (tabIndex === 2) {
- statusText = "已完成";
- } else if (tabIndex === 3) {
- statusText = "已拒绝";
- }
- return {
- id: order.id,
- status: order.status,
- // 保存原始 status 用于判断权限
- type: isRoundTrip ? 1 : 2,
- typeText: serviceText,
- typeIcon: serviceIcon,
- statusText,
- price: (order.price / 100).toFixed(2),
- timeLabel: "服务时间",
- time: order.serviceTime || "",
- petAvatar: "/static/dog.png",
- petName: order.petName || "",
- petBreed: order.breed || "",
- startLocation: order.fromAddress || "",
- startAddress: order.fromAddress || "",
- startDistance: "0km",
- endLocation: (order.customerName || "") + " " + (order.customerPhone || ""),
- endAddress: order.toAddress || "",
- customerPhone: order.customerPhone || "",
- endDistance: "0km",
- serviceContent: order.remark || "",
- remark: order.remark || ""
- };
- },
- getDisplayStatus(item) {
- if (item.statusText === "已完成")
- return "已完成";
- if (item.statusText === "已拒绝")
- return "已拒绝";
- if (item.statusText === "接单") {
- return item.type === 1 ? "待接送" : "待服务";
- }
- return item.type === 1 ? "配送中" : "服务中";
- },
- getStatusClass(item) {
- let display = this.getDisplayStatus(item);
- if (display === "已完成")
- return "finish";
- if (display === "已拒绝")
- return "reject";
- if (display === "配送中" || display === "服务中")
- return "processing";
- return "highlight";
- },
- goToDetail(item) {
- uni.navigateTo({ url: `/pages/orders/detail?id=${item.id}` });
- },
- showPetProfile(item) {
- this.currentPetInfo = {
- ...item,
- petGender: "M",
- petAge: "2岁",
- petWeight: "15kg",
- petPersonality: "活泼亲人,精力旺盛",
- petHobby: "喜欢追飞盘,爱吃肉干",
- petRemark: "肠胃较弱,不能乱喂零食;出门易爆冲,请拉紧牵引绳。",
- petTags: ["拉响警报", "不能吃鸡肉", "精力旺盛"],
- petLogs: [
- { date: "2026-02-09 14:00", content: "今天遛弯拉了两次粑粑,精神状态很好。", recorder: "王阿姨" },
- { date: "2026-02-08 10:30", content: "有些挑食,剩了小半碗狗粮。", recorder: "李师傅" },
- { date: "2026-02-05 09:00", content: "建档。", recorder: "系统记录" }
- ]
- };
- this.showPetModal = true;
- },
- closePetProfile() {
- this.showPetModal = false;
- },
- openNavigation(item, pointType) {
- this.navTargetItem = item;
- this.navTargetPointType = pointType;
- this.showNavModal = true;
- },
- closeNavModal() {
- this.showNavModal = false;
- },
- chooseMap(mapType) {
- let item = this.navTargetItem;
- let pointType = this.navTargetPointType;
- let name = pointType === "start" ? item.startLocation : item.endLocation;
- let address = pointType === "start" ? item.startAddress : item.endAddress;
- this.showNavModal = false;
- uni.openLocation({
- latitude: 30.52,
- longitude: 114.31,
- name: name || "目的地",
- address: address || "默认地址",
- success: function() {
- formatAppLog("log", "at pages/orders/logic.js:208", "打开导航成功: " + mapType);
- }
- });
- },
- toggleCallMenu(item) {
- if (this.activeCallItem === item) {
- this.activeCallItem = null;
- } else {
- this.activeCallItem = item;
- }
- },
- closeCallMenu() {
- this.activeCallItem = null;
- },
- doCall(type, item) {
- let phoneNum = "";
- const targetItem = item || this.activeCallItem;
- if (type === "merchant") {
- phoneNum = "18900008451";
- } else if (type === "customer") {
- phoneNum = (targetItem == null ? void 0 : targetItem.customerPhone) || "13800000001";
- }
- if (phoneNum) {
- uni.makePhoneCall({ phoneNumber: phoneNum });
- }
- this.activeCallItem = null;
- },
- reportAbnormal(item) {
- uni.navigateTo({ url: "/pages/orders/anomaly?orderId=" + (item.id || "") });
- },
- toggleDropdown(idx) {
- if (this.activeDropdown === idx) {
- this.activeDropdown = 0;
- } else {
- this.activeDropdown = idx;
- }
- },
- closeDropdown() {
- this.activeDropdown = 0;
- },
- selectType(index) {
- this.currentTypeFilterIdx = index;
- this.closeDropdown();
- },
- initCalendar() {
- let days = [];
- for (let i = 1; i <= 28; i++) {
- days.push(i);
- }
- this.calendarDays = days;
- this.selectedDateRange = [2, 4];
- },
- prevMonth() {
- uni.showToast({ title: "上个月", icon: "none" });
- },
- nextMonth() {
- uni.showToast({ title: "下个月", icon: "none" });
- },
- selectDateItem(day) {
- if (this.selectedDateRange.length === 2) {
- this.selectedDateRange = [day];
- } else if (this.selectedDateRange.length === 1) {
- let start = this.selectedDateRange[0];
- if (day > start) {
- this.selectedDateRange = [start, day];
- } else if (day < start) {
- this.selectedDateRange = [day, start];
- } else {
- this.selectedDateRange = [];
- }
- } else {
- this.selectedDateRange = [day];
- }
- },
- getDateClass(day) {
- if (this.selectedDateRange.length === 0)
- return "";
- if (this.selectedDateRange.length === 1) {
- return day === this.selectedDateRange[0] ? "is-start" : "";
- }
- let start = this.selectedDateRange[0];
- let end = this.selectedDateRange[1];
- if (day === start)
- return "is-start";
- if (day === end)
- return "is-end";
- if (day > start && day < end)
- return "is-between";
- return "";
- },
- resetTimeFilter() {
- this.hasTimeFilter = false;
- this.selectedDateRange = [];
- this.startServiceTime = "";
- this.endServiceTime = "";
- this.closeDropdown();
- this.loadOrders();
- },
- confirmTimeFilter() {
- if (this.selectedDateRange.length === 0) {
- uni.showToast({ title: "请先选择日期", icon: "none" });
- return;
- }
- const year = this.currentMonth.replace(/[^0-9]/g, "").substring(0, 4);
- const month = this.currentMonth.replace(/[^0-9]/g, "").substring(4);
- const pad = (n) => String(n).padStart(2, "0");
- if (this.selectedDateRange.length === 2) {
- this.startServiceTime = `${year}-${pad(month)}-${pad(this.selectedDateRange[0])} 00:00:00`;
- this.endServiceTime = `${year}-${pad(month)}-${pad(this.selectedDateRange[1])} 23:59:59`;
- } else {
- this.startServiceTime = `${year}-${pad(month)}-${pad(this.selectedDateRange[0])} 00:00:00`;
- this.endServiceTime = `${year}-${pad(month)}-${pad(this.selectedDateRange[0])} 23:59:59`;
- }
- this.hasTimeFilter = true;
- this.closeDropdown();
- this.loadOrders();
- },
- getMainActionText(item) {
- return "查看详情";
- },
- mainAction(item) {
- uni.navigateTo({ url: `/pages/orders/detail?id=${item.id}` });
- },
- openRemarkInput() {
- this.remarkText = "";
- this.showRemarkInput = true;
- },
- closeRemarkInput() {
- this.showRemarkInput = false;
- this.remarkText = "";
- },
- submitRemark() {
- const text = this.remarkText.trim();
- if (!text) {
- uni.showToast({ title: "备注内容不能为空", icon: "none" });
- return;
- }
- const now = /* @__PURE__ */ new Date();
- const dateStr = `${now.getFullYear()}-${String(now.getMonth() + 1).padStart(2, "0")}-${String(now.getDate()).padStart(2, "0")} ${String(now.getHours()).padStart(2, "0")}:${String(now.getMinutes()).padStart(2, "0")}`;
- if (!this.currentPetInfo.petLogs) {
- this.$set(this.currentPetInfo, "petLogs", []);
- }
- this.currentPetInfo.petLogs.unshift({
- date: dateStr,
- content: text,
- recorder: "我"
- });
- uni.showToast({ title: "备注已添加", icon: "success" });
- this.closeRemarkInput();
- },
- /**
- * 取消订单处理逻辑
- * @param {Object} item - 订单项
- */
- handleCancelOrder(item) {
- uni.showModal({
- title: "提示",
- content: "确认是否取消这个订单?",
- success: async (res) => {
- if (res.confirm) {
- try {
- uni.showLoading({ title: "取消中...", mask: true });
- await cancelOrderApi({ orderId: item.id });
- uni.showToast({ title: "订单已取消", icon: "success" });
- setTimeout(() => {
- this.loadOrders();
- }, 1500);
- } catch (err) {
- formatAppLog("error", "at pages/orders/logic.js:370", "取消订单失败:", err);
- uni.showToast({ title: "取消失败", icon: "none" });
- } finally {
- uni.hideLoading();
- }
- }
- }
- });
- }
- }
- };
- const _sfc_main$r = {
- ...logic$2
- };
- function _sfc_render$q(_ctx, _cache, $props, $setup, $data, $options) {
- const _component_custom_tabbar = vue.resolveComponent("custom-tabbar");
- return vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- null,
- [
- vue.createElementVNode("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "sticky-header" }, [
- vue.createElementVNode("view", { class: "status-tabs" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.tabs, (tab, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: vue.normalizeClass(["tab-item", { active: _ctx.currentTab === index }]),
- key: index,
- onClick: ($event) => _ctx.currentTab = index
- }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(tab),
- 1
- /* TEXT */
- ),
- _ctx.currentTab === index ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "indicator"
- })) : vue.createCommentVNode("v-if", true)
- ], 10, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("view", { class: "search-bar" }, [
- vue.createElementVNode("view", { class: "search-input-box" }, [
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "search-input",
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.searchContent = $event),
- placeholder: "搜索地址/电话/姓名",
- "placeholder-class": "ph-style"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.searchContent]
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "filter-wrapper" }, [
- vue.createElementVNode("view", { class: "filter-bar" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["filter-item", { "active": _ctx.activeDropdown === 1 }]),
- onClick: _cache[1] || (_cache[1] = ($event) => _ctx.toggleDropdown(1))
- },
- [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass({ "active-text": _ctx.activeDropdown === 1 || _ctx.currentTypeFilterIdx > 0 })
- },
- vue.toDisplayString(_ctx.currentTypeFilterIdx > 0 ? _ctx.typeFilterOptions[_ctx.currentTypeFilterIdx] : "全部类型"),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["triangle", _ctx.activeDropdown === 1 ? "up" : "down"])
- },
- null,
- 2
- /* CLASS */
- )
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["filter-item", { "active": _ctx.activeDropdown === 2 }]),
- onClick: _cache[2] || (_cache[2] = ($event) => _ctx.toggleDropdown(2))
- },
- [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass({ "active-text": _ctx.activeDropdown === 2 || _ctx.hasTimeFilter })
- },
- "服务时间",
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["triangle", _ctx.activeDropdown === 2 ? "up" : "down"])
- },
- null,
- 2
- /* CLASS */
- )
- ],
- 2
- /* CLASS */
- )
- ]),
- _ctx.activeDropdown !== 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "dropdown-mask",
- onClick: _cache[3] || (_cache[3] = (...args) => _ctx.closeDropdown && _ctx.closeDropdown(...args))
- })) : vue.createCommentVNode("v-if", true),
- _ctx.activeDropdown === 1 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "dropdown-panel"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.typeFilterOptions, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: vue.normalizeClass(["type-option", { "selected": _ctx.currentTypeFilterIdx === index }]),
- key: index,
- onClick: ($event) => _ctx.selectType(index)
- }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(item),
- 1
- /* TEXT */
- )
- ], 10, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.activeDropdown === 2 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 2,
- class: "dropdown-panel calendar-panel"
- }, [
- vue.createElementVNode("view", { class: "custom-calendar-container" }, [
- vue.createElementVNode("view", { class: "cal-header" }, [
- vue.createElementVNode("text", {
- class: "cal-nav-btn",
- onClick: _cache[4] || (_cache[4] = (...args) => _ctx.prevMonth && _ctx.prevMonth(...args))
- }, "‹"),
- vue.createElementVNode(
- "text",
- { class: "cal-title" },
- vue.toDisplayString(_ctx.currentMonth),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", {
- class: "cal-nav-btn",
- onClick: _cache[5] || (_cache[5] = (...args) => _ctx.nextMonth && _ctx.nextMonth(...args))
- }, "›")
- ]),
- vue.createElementVNode("view", { class: "cal-weekdays" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.weekDays, (wk, idx) => {
- return vue.openBlock(), vue.createElementBlock(
- "text",
- {
- key: idx,
- class: "wk-item"
- },
- vue.toDisplayString(wk),
- 1
- /* TEXT */
- );
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("view", { class: "cal-body" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.calendarDays, (day, idx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- key: idx,
- class: vue.normalizeClass(["cal-day-box", _ctx.getDateClass(day)]),
- onClick: ($event) => _ctx.selectDateItem(day)
- }, [
- vue.createElementVNode(
- "view",
- { class: "cal-day-text" },
- vue.toDisplayString(day),
- 1
- /* TEXT */
- )
- ], 10, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ]),
- vue.createElementVNode("view", { class: "calendar-actions" }, [
- vue.createElementVNode("button", {
- class: "cal-btn reset",
- onClick: _cache[6] || (_cache[6] = (...args) => _ctx.resetTimeFilter && _ctx.resetTimeFilter(...args))
- }, "重置"),
- vue.createElementVNode("button", {
- class: "cal-btn confirm",
- onClick: _cache[7] || (_cache[7] = (...args) => _ctx.confirmTimeFilter && _ctx.confirmTimeFilter(...args))
- }, "确定")
- ])
- ])) : vue.createCommentVNode("v-if", true)
- ])
- ]),
- vue.createElementVNode("view", { class: "order-list" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.orderList, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "order-card",
- key: index,
- onClick: ($event) => _ctx.goToDetail(item)
- }, [
- vue.createElementVNode("view", { class: "card-header" }, [
- vue.createElementVNode("view", { class: "type-badge" }, [
- vue.createElementVNode("image", {
- class: "type-icon",
- src: item.typeIcon
- }, null, 8, ["src"]),
- vue.createElementVNode(
- "text",
- { class: "type-text" },
- vue.toDisplayString(item.typeText),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["status-badge", _ctx.getStatusClass(item)])
- },
- vue.toDisplayString(_ctx.getDisplayStatus(item)),
- 3
- /* TEXT, CLASS */
- )
- ]),
- vue.createElementVNode("view", { class: "card-body" }, [
- vue.createElementVNode("view", { class: "time-row" }, [
- vue.createElementVNode("view", { class: "time-col" }, [
- vue.createElementVNode(
- "text",
- { class: "label" },
- vue.toDisplayString(item.timeLabel) + ":",
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "value" },
- vue.toDisplayString(item.time),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode(
- "text",
- { class: "price" },
- "¥" + vue.toDisplayString(item.price),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pet-card" }, [
- vue.createElementVNode("image", {
- class: "pet-avatar",
- src: item.petAvatar,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "pet-info" }, [
- vue.createElementVNode(
- "text",
- { class: "pet-name" },
- vue.toDisplayString(item.petName),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "pet-breed" },
- "品种: " + vue.toDisplayString(item.petBreed),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", { class: "route-info" }, [
- item.type === 1 ? (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 0 },
- [
- vue.createElementVNode("view", {
- class: "route-item",
- onClick: vue.withModifiers(($event) => _ctx.openNavigation(item, "start"), ["stop"])
- }, [
- vue.createElementVNode("view", { class: "icon-circle start" }, "取"),
- vue.createElementVNode("view", { class: "route-line-vertical" }),
- vue.createElementVNode("view", { class: "address-box" }, [
- vue.createElementVNode(
- "text",
- { class: "addr-title" },
- vue.toDisplayString(item.startLocation),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "addr-desc" },
- vue.toDisplayString(item.startAddress),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("image", {
- class: "nav-arrow",
- src: _imports_3$2,
- style: { "flex-shrink": "0", "align-self": "center" }
- })
- ], 8, ["onClick"]),
- vue.createElementVNode("view", {
- class: "route-item",
- onClick: vue.withModifiers(($event) => _ctx.openNavigation(item, "end"), ["stop"])
- }, [
- vue.createElementVNode("view", { class: "icon-circle end" }, "送"),
- vue.createElementVNode("view", { class: "address-box" }, [
- vue.createElementVNode(
- "text",
- { class: "addr-title" },
- vue.toDisplayString(item.endLocation),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "addr-desc" },
- vue.toDisplayString(item.endAddress),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("image", {
- class: "nav-arrow",
- src: _imports_3$2,
- style: { "flex-shrink": "0", "align-self": "center" }
- })
- ], 8, ["onClick"])
- ],
- 64
- /* STABLE_FRAGMENT */
- )) : (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 1 },
- [
- vue.createElementVNode("view", {
- class: "route-item",
- onClick: vue.withModifiers(($event) => _ctx.openNavigation(item, "end"), ["stop"])
- }, [
- vue.createElementVNode("view", { class: "icon-circle service" }, "服"),
- vue.createElementVNode("view", { class: "address-box" }, [
- vue.createElementVNode(
- "text",
- { class: "addr-title" },
- vue.toDisplayString(item.endLocation),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "addr-desc" },
- vue.toDisplayString(item.endAddress),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("image", {
- class: "nav-arrow",
- src: _imports_3$2,
- style: { "flex-shrink": "0", "align-self": "center" }
- })
- ], 8, ["onClick"]),
- item.serviceContent ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "service-content"
- }, [
- vue.createElementVNode("text", { class: "content-label" }, "服务内容:"),
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(item.serviceContent),
- 1
- /* TEXT */
- )
- ])) : vue.createCommentVNode("v-if", true)
- ],
- 64
- /* STABLE_FRAGMENT */
- ))
- ]),
- item.remark ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "remark-box"
- }, [
- vue.createElementVNode(
- "text",
- null,
- "备注:" + vue.toDisplayString(item.remark),
- 1
- /* TEXT */
- )
- ])) : vue.createCommentVNode("v-if", true)
- ]),
- ["接单", "到达", "出发", "开始", "送达", "结束"].includes(item.statusText) ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "action-btns"
- }, [
- vue.createElementVNode("view", { class: "action-left" }, [
- vue.createElementVNode("button", {
- class: "btn normal",
- onClick: vue.withModifiers(($event) => _ctx.doCall("customer", item), ["stop"])
- }, "拨号", 8, ["onClick"])
- ]),
- vue.createElementVNode("view", { class: "action-right" }, [
- item.status === 2 ? (vue.openBlock(), vue.createElementBlock("button", {
- key: 0,
- class: "btn normal danger",
- onClick: vue.withModifiers(($event) => _ctx.handleCancelOrder(item), ["stop"])
- }, "取消", 8, ["onClick"])) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("button", {
- class: "btn normal",
- onClick: vue.withModifiers(($event) => _ctx.reportAbnormal(item), ["stop"])
- }, "异常上报", 8, ["onClick"]),
- vue.createElementVNode("button", {
- class: "btn primary",
- onClick: vue.withModifiers(($event) => _ctx.mainAction(item), ["stop"])
- }, "打卡", 8, ["onClick"])
- ])
- ])) : vue.createCommentVNode("v-if", true)
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("view", { class: "loading-text" }, "已加载完"),
- vue.createElementVNode("view", { style: { "height": "160rpx" } })
- ]),
- _ctx.activeCallItem ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "call-mask",
- onClick: _cache[8] || (_cache[8] = (...args) => _ctx.closeCallMenu && _ctx.closeCallMenu(...args))
- })) : vue.createCommentVNode("v-if", true)
- ]),
- _ctx.showPetModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "pet-modal-mask",
- onClick: _cache[12] || (_cache[12] = (...args) => _ctx.closePetProfile && _ctx.closePetProfile(...args))
- }, [
- vue.createElementVNode("view", {
- class: "pet-modal-content",
- onClick: _cache[11] || (_cache[11] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "pet-modal-header" }, [
- vue.createElementVNode("text", { class: "pet-modal-title" }, "宠物档案"),
- vue.createElementVNode("view", { class: "pm-header-actions" }, [
- vue.createElementVNode("view", {
- class: "pm-remark-btn",
- onClick: _cache[9] || (_cache[9] = (...args) => _ctx.openRemarkInput && _ctx.openRemarkInput(...args))
- }, "备注"),
- vue.createElementVNode("view", {
- class: "close-icon-btn",
- onClick: _cache[10] || (_cache[10] = (...args) => _ctx.closePetProfile && _ctx.closePetProfile(...args))
- }, "×")
- ])
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "pet-modal-scroll"
- }, [
- vue.createElementVNode("view", { class: "pet-base-info" }, [
- vue.createElementVNode("image", {
- class: "pm-avatar",
- src: _ctx.currentPetInfo.petAvatar,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "pm-info-text" }, [
- vue.createElementVNode("view", { class: "pm-name-row" }, [
- vue.createElementVNode(
- "text",
- { class: "pm-name" },
- vue.toDisplayString(_ctx.currentPetInfo.petName),
- 1
- /* TEXT */
- ),
- _ctx.currentPetInfo.petGender === "M" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "pm-gender"
- }, [
- vue.createElementVNode("text", { class: "gender-icon" }, "♂"),
- vue.createElementVNode("text", null, "公")
- ])) : _ctx.currentPetInfo.petGender === "F" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "pm-gender female"
- }, [
- vue.createElementVNode("text", { class: "gender-icon" }, "♀"),
- vue.createElementVNode("text", null, "母")
- ])) : vue.createCommentVNode("v-if", true)
- ]),
- vue.createElementVNode(
- "text",
- { class: "pm-breed" },
- "品种:" + vue.toDisplayString(_ctx.currentPetInfo.petBreed),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", { class: "pm-detail-grid" }, [
- vue.createElementVNode("view", { class: "pm-grid-item half" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "年龄"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petAge || "未知"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item half" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "体重"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petWeight || "未知"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item full" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "性格"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petPersonality || "无"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item full" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "爱好"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petHobby || "无"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item full" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "备注"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petRemark || "无特殊过敏史"),
- 1
- /* TEXT */
- )
- ])
- ]),
- _ctx.currentPetInfo.petTags && _ctx.currentPetInfo.petTags.length > 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "pm-tags"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.currentPetInfo.petTags, (tag, index) => {
- return vue.openBlock(), vue.createElementBlock(
- "view",
- {
- class: "pm-tag",
- key: index
- },
- vue.toDisplayString(tag),
- 1
- /* TEXT */
- );
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("view", { class: "pm-section-title" }, [
- vue.createElementVNode("view", { class: "orange-bar" }),
- vue.createElementVNode("text", null, "备注日志")
- ]),
- vue.createElementVNode("view", { class: "pm-log-list" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.currentPetInfo.petLogs, (log, lIndex) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "pm-log-item",
- key: lIndex
- }, [
- vue.createElementVNode(
- "text",
- { class: "pm-log-date" },
- vue.toDisplayString(log.date),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "pm-log-text" },
- vue.toDisplayString(log.content),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "pm-log-recorder" },
- vue.toDisplayString(log.recorder === "系统记录" ? "" : "记录人: ") + vue.toDisplayString(log.recorder),
- 1
- /* TEXT */
- )
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("view", { style: { "height": "30rpx" } })
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.showRemarkInput ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "remark-mask",
- onClick: _cache[17] || (_cache[17] = (...args) => _ctx.closeRemarkInput && _ctx.closeRemarkInput(...args))
- }, [
- vue.createElementVNode("view", {
- class: "remark-sheet",
- onClick: _cache[16] || (_cache[16] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "remark-sheet-header" }, [
- vue.createElementVNode("text", { class: "remark-sheet-title" }, "添加备注"),
- vue.createElementVNode("view", {
- class: "close-icon-btn",
- onClick: _cache[13] || (_cache[13] = (...args) => _ctx.closeRemarkInput && _ctx.closeRemarkInput(...args))
- }, "×")
- ]),
- vue.withDirectives(vue.createElementVNode(
- "textarea",
- {
- class: "remark-textarea",
- "onUpdate:modelValue": _cache[14] || (_cache[14] = ($event) => _ctx.remarkText = $event),
- placeholder: "请输入备注内容...",
- maxlength: "500",
- "auto-height": ""
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.remarkText]
- ]),
- vue.createElementVNode("view", {
- class: "remark-submit-btn",
- onClick: _cache[15] || (_cache[15] = (...args) => _ctx.submitRemark && _ctx.submitRemark(...args))
- }, "提交备注")
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.showNavModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 2,
- class: "nav-modal-mask",
- onClick: _cache[23] || (_cache[23] = (...args) => _ctx.closeNavModal && _ctx.closeNavModal(...args))
- }, [
- vue.createElementVNode("view", {
- class: "nav-action-sheet",
- onClick: _cache[22] || (_cache[22] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "nav-sheet-title" }, "选择地图进行导航"),
- vue.createElementVNode("view", {
- class: "nav-sheet-item",
- onClick: _cache[18] || (_cache[18] = ($event) => _ctx.chooseMap("高德"))
- }, "高德地图"),
- vue.createElementVNode("view", {
- class: "nav-sheet-item",
- onClick: _cache[19] || (_cache[19] = ($event) => _ctx.chooseMap("腾讯"))
- }, "腾讯地图"),
- vue.createElementVNode("view", {
- class: "nav-sheet-item",
- onClick: _cache[20] || (_cache[20] = ($event) => _ctx.chooseMap("百度"))
- }, "百度地图"),
- vue.createElementVNode("view", { class: "nav-sheet-gap" }),
- vue.createElementVNode("view", {
- class: "nav-sheet-item cancel",
- onClick: _cache[21] || (_cache[21] = (...args) => _ctx.closeNavModal && _ctx.closeNavModal(...args))
- }, "取消")
- ])
- ])) : vue.createCommentVNode("v-if", true),
- vue.createVNode(_component_custom_tabbar, { currentPath: "pages/orders/index" })
- ],
- 64
- /* STABLE_FRAGMENT */
- );
- }
- const PagesOrdersIndex = /* @__PURE__ */ _export_sfc(_sfc_main$r, [["render", _sfc_render$q], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/orders/index.vue"]]);
- function getDictDataByType(dictType) {
- return request({
- url: `/system/dict/data/type/${dictType}`,
- method: "GET"
- });
- }
- function getPetDetail(id) {
- return request({
- url: `/archieves/pet/${id}`,
- method: "GET"
- });
- }
- const logic$1 = {
- data() {
- return {
- orderId: null,
- pageLoading: true,
- // 页面数据加载中
- orderType: 1,
- orderStatus: 2,
- serviceId: null,
- // 当前订单的服务类型ID
- serviceMode: null,
- // 当前订单的服务模式 (0: 喂遛/洗护, 1: 接送)
- petId: null,
- // 当前订单关联的宠物ID
- petDetail: null,
- // 宠物档案详情
- // 从后端 clockInRemark 解析出的打卡步骤列表
- // 格式: [{step:1, title:'到达打卡', remark:'照片视频二选一即可'}, ...]
- clockInSteps: [],
- // 当前应执行的打卡信息(从 clockInSteps 中取出)
- currentClockIn: null,
- currentStep: 0,
- orderDetail: {
- type: 1,
- price: "0.00",
- timeLabel: "服务时间",
- time: "",
- petAvatar: "/static/dog.png",
- petName: "",
- petBreed: "",
- serviceTag: "",
- startLocation: "",
- startAddress: "",
- endAddress: "",
- customerPhone: "",
- serviceContent: "",
- remark: "",
- orderNo: "",
- createTime: "",
- progressLogs: [],
- nursingSummary: ""
- // 宠护小结
- },
- serviceList: [],
- showPetModal: false,
- currentPetInfo: {},
- showNavModal: false,
- navTargetPointType: "",
- showUploadModal: false,
- modalMediaList: [],
- modalRemark: "",
- showSumModal: false,
- sumContent: "",
- sumDate: "",
- sumSigner: "未知",
- showPetRemarkInput: false,
- petRemarkText: "",
- showAnomalyModal: false,
- anomalyList: [],
- anomalyTypeDict: [],
- // 媒体预览相关
- videoPlayerShow: false,
- videoPlayerUrl: ""
- };
- },
- computed: {
- // 从 clockInSteps 中提取 title 数组作为打卡步骤名(内部逻辑用)
- steps() {
- if (this.clockInSteps.length > 0) {
- return this.clockInSteps.map((s) => s.title);
- }
- return this.orderType === 1 ? ["到达打卡", "确认出发", "送达打卡"] : ["到达打卡", "开始服务", "服务结束"];
- },
- // 顶部进度条展示用:已接单 -> 各打卡步骤 -> 订单完成
- progressSteps() {
- return ["已接单", ...this.steps, "订单完成"];
- },
- // 进度条当前激活索引(= currentStep + 1,因为首位是"已接单")
- progressIndex() {
- return this.currentStep + 1;
- },
- displayStatusText() {
- if (this.currentStep >= this.steps.length)
- return "已完成";
- if (this.currentStep > 0) {
- return this.orderType === 1 ? "配送中" : "服务中";
- }
- return this.orderType === 1 ? "待接送" : "待服务";
- },
- currentStatusText() {
- return this.currentStep >= this.steps.length ? "已完成" : this.steps[this.currentStep];
- },
- // 按钮文本:使用 clockInSteps 中对应步骤的 title
- currentTaskTitle() {
- if (this.currentStep >= this.steps.length)
- return "订单已完成";
- if (this.currentClockIn) {
- return this.currentClockIn.title;
- }
- return this.steps[this.currentStep] || "打卡";
- },
- // 任务描述小字:使用 clockInSteps 中对应步骤的 remark
- currentTaskDesc() {
- if (this.currentStep >= this.steps.length)
- return "感谢您的服务,请注意休息";
- if (this.currentClockIn && this.currentClockIn.remark) {
- return this.currentClockIn.remark;
- }
- return "请按要求提交照片或视频及备注";
- }
- },
- async onLoad(options) {
- if (options.id) {
- this.orderId = options.id;
- }
- this.pageLoading = true;
- try {
- await this.loadAnomalyTypeDict();
- await this.loadOrderDetail();
- } finally {
- this.pageLoading = false;
- }
- },
- methods: {
- async loadServiceList() {
- try {
- const res = await getServiceList();
- this.serviceList = res.data || [];
- } catch (err) {
- formatAppLog("error", "at pages/orders/detail-logic.js:143", "获取服务类型失败:", err);
- }
- },
- /**
- * 根据服务类型ID获取服务详情,解析 clockInRemark 为打卡步骤
- */
- async loadServiceDetail(serviceId) {
- formatAppLog("log", "at pages/orders/detail-logic.js:150", "开始加载服务详情, ID:", serviceId);
- try {
- const res = await getServiceDetail(serviceId);
- const serviceInfo = res.data;
- formatAppLog("log", "at pages/orders/detail-logic.js:154", "服务详情响应结果:", serviceInfo);
- if (serviceInfo) {
- this.serviceMode = serviceInfo.mode;
- formatAppLog("log", "at pages/orders/detail-logic.js:157", "当前服务模式(mode):", this.serviceMode);
- if (serviceInfo.clockInRemark) {
- try {
- const parsed = JSON.parse(serviceInfo.clockInRemark);
- if (Array.isArray(parsed) && parsed.length > 0) {
- this.clockInSteps = parsed;
- formatAppLog("log", "at pages/orders/detail-logic.js:163", "解析打卡步骤:", this.clockInSteps);
- }
- } catch (parseErr) {
- formatAppLog("error", "at pages/orders/detail-logic.js:166", "解析 clockInRemark 失败:", parseErr);
- }
- }
- }
- } catch (err) {
- formatAppLog("error", "at pages/orders/detail-logic.js:171", "获取服务类型详情失败:", err);
- }
- },
- async loadOrderDetail() {
- if (!this.orderId) {
- formatAppLog("log", "at pages/orders/detail-logic.js:176", "订单ID缺失");
- uni.showToast({ title: "订单ID缺失", icon: "none" });
- return;
- }
- try {
- formatAppLog("log", "at pages/orders/detail-logic.js:181", "请求订单详情,ID:", this.orderId);
- const res = await getOrderInfo(this.orderId);
- formatAppLog("log", "at pages/orders/detail-logic.js:183", "订单详情响应:", res);
- const order = res.data;
- if (!order) {
- formatAppLog("log", "at pages/orders/detail-logic.js:186", "订单数据为空");
- uni.showToast({ title: "订单不存在", icon: "none" });
- return;
- }
- formatAppLog("log", "at pages/orders/detail-logic.js:190", "订单数据:", order);
- this.serviceId = order.service;
- this.petId = order.usrPet || null;
- this.transformOrderData(order);
- formatAppLog("log", "at pages/orders/detail-logic.js:194", "解析出的 serviceId:", this.serviceId);
- if (this.serviceId) {
- await this.loadServiceDetail(this.serviceId);
- } else {
- formatAppLog("warn", "at pages/orders/detail-logic.js:200", "订单中未找到 service 字段,无法加载服务步骤");
- }
- if (this.petId) {
- await this.loadPetDetail(this.petId);
- }
- await this.loadOrderLogs();
- } catch (err) {
- formatAppLog("error", "at pages/orders/detail-logic.js:211", "获取订单详情失败:", err);
- uni.showToast({ title: "加载失败", icon: "none" });
- }
- },
- async loadOrderLogs() {
- try {
- const res = await getOrderLogs(this.orderId);
- const logs = res.data || [];
- formatAppLog("log", "at pages/orders/detail-logic.js:219", "订单日志:", logs);
- const progressLogs = logs.filter((log) => log.logType === 1);
- this.orderDetail.progressLogs = progressLogs.map((log) => ({
- status: log.title || "",
- time: log.createTime || "",
- medias: log.photoUrls || [],
- remark: log.content || ""
- }));
- const validLogs = logs.filter((log) => log.logType === 1 && log.step !== void 0 && log.step !== null).sort((a, b) => new Date(b.createTime).getTime() - new Date(a.createTime).getTime());
- if (validLogs.length > 0) {
- const latestLog = validLogs[0];
- const latestStep = latestLog.step;
- formatAppLog("log", "at pages/orders/detail-logic.js:238", "最新打卡日志 step:", latestStep);
- const stepIndex = this.clockInSteps.findIndex((s) => s.step === latestStep);
- if (stepIndex >= 0) {
- this.currentStep = stepIndex + 1;
- } else {
- this.currentStep = Number(latestStep);
- }
- } else {
- this.currentStep = 0;
- }
- this.updateCurrentClockIn();
- formatAppLog("log", "at pages/orders/detail-logic.js:254", "根据最新日志推算的当前步骤:", this.currentStep, "当前打卡信息:", this.currentClockIn);
- } catch (err) {
- formatAppLog("error", "at pages/orders/detail-logic.js:256", "获取订单日志失败:", err);
- }
- },
- /**
- * 根据 currentStep 更新当前打卡信息
- */
- updateCurrentClockIn() {
- if (this.currentStep < this.clockInSteps.length) {
- this.currentClockIn = this.clockInSteps[this.currentStep];
- } else {
- this.currentClockIn = null;
- }
- },
- transformOrderData(order) {
- const mode = order.mode || 0;
- const isRoundTrip = mode === 1;
- this.orderType = isRoundTrip ? 1 : 2;
- this.orderStatus = order.status || 2;
- this.orderDetail = {
- type: this.orderType,
- price: (order.price / 100).toFixed(2),
- timeLabel: isRoundTrip ? "取货时间" : "服务时间",
- time: order.serviceTime || "",
- petAvatar: "/static/dog.png",
- petName: order.petName || order.contact || "",
- petBreed: order.breed || "",
- serviceTag: order.groupPurchasePackageName || "",
- startLocation: order.fromAddress || "",
- startAddress: order.fromAddress || "",
- endLocation: (order.contact || "") + " " + (order.contactPhoneNumber || ""),
- endAddress: order.toAddress || "",
- customerPhone: order.contactPhoneNumber || "",
- ownerName: order.contact || "",
- // 宠主姓名(默认使用客户姓名)
- serviceContent: "",
- remark: "",
- orderNo: order.code || "T" + order.id,
- createTime: order.serviceTime || "",
- nursingSummary: order.nursingSummary || "",
- fulfillerName: order.fulfillerName || "",
- // 履约者/护宠师姓名
- progressLogs: [
- { status: "您已接单", time: order.serviceTime || "" }
- ]
- };
- if (this.orderDetail.fulfillerName) {
- this.sumSigner = this.orderDetail.fulfillerName;
- }
- },
- /**
- * 根据宠物ID获取宠物档案详情
- */
- async loadPetDetail(petId) {
- try {
- const res = await getPetDetail(petId);
- const pet = res.data;
- if (pet) {
- this.petDetail = pet;
- this.orderDetail.petAvatar = pet.avatarUrl || "/static/dog.png";
- this.orderDetail.petName = pet.name || this.orderDetail.petName;
- this.orderDetail.petBreed = pet.breed || this.orderDetail.petBreed;
- this.orderDetail.ownerName = pet.ownerName || this.orderDetail.ownerName;
- formatAppLog("log", "at pages/orders/detail-logic.js:321", "宠物档案:", pet);
- }
- } catch (err) {
- formatAppLog("error", "at pages/orders/detail-logic.js:324", "获取宠物档案失败:", err);
- }
- },
- /**
- * 加载异常记录列表
- */
- async loadAnomalyList() {
- if (!this.orderId)
- return;
- try {
- const res = await getAnomalyList(this.orderId);
- const list = res.data || [];
- this.anomalyList = list.map((item) => {
- const dict = this.anomalyTypeDict.find((d) => d.value === item.type);
- return {
- ...item,
- typeLabel: dict ? dict.label : item.type,
- // 确保有图片数组供展示,如果后端没返 photoUrls,尝试兼容
- photoUrls: item.photoUrls || []
- };
- });
- } catch (err) {
- formatAppLog("error", "at pages/orders/detail-logic.js:347", "获取异常列表失败:", err);
- }
- },
- async loadAnomalyTypeDict() {
- try {
- const res = await getDictDataByType("flf_anamaly_type");
- this.anomalyTypeDict = res.data.map((item) => ({
- label: item.dictLabel,
- value: item.dictValue
- }));
- } catch (err) {
- formatAppLog("error", "at pages/orders/detail-logic.js:358", "获取异常字典失败:", err);
- }
- },
- openAnomalyModal() {
- this.showAnomalyModal = true;
- this.loadAnomalyList();
- },
- closeAnomalyModal() {
- this.showAnomalyModal = false;
- },
- getAnomalyStatusLabel(status) {
- const map = {
- 0: "待审核",
- 1: "已通过",
- 2: "已驳回"
- };
- return map[status] || "未知";
- },
- updateStepByStatus() {
- if (this.orderStatus === 2) {
- this.currentStep = 0;
- } else if (this.orderStatus === 3) {
- this.currentStep = 1;
- } else if (this.orderStatus === 4) {
- this.currentStep = this.steps.length - 1;
- } else {
- this.currentStep = 0;
- }
- },
- showPetProfile() {
- const pet = this.petDetail;
- if (pet) {
- this.currentPetInfo = {
- petAvatar: pet.avatarUrl || "/static/dog.png",
- petName: pet.name || "",
- petBreed: pet.breed || "",
- petGender: pet.gender === 1 ? "M" : pet.gender === 2 ? "F" : "",
- petAge: pet.age ? pet.age + "岁" : "未知",
- petWeight: pet.weight ? pet.weight + "kg" : "未知",
- petPersonality: pet.personality || pet.cutePersonality || "无",
- petHobby: "",
- petRemark: pet.remark || "无",
- petTags: (pet.tags || []).map((t) => t.name),
- petLogs: [],
- // 额外信息
- petSize: pet.size || "",
- petIsSterilized: pet.isSterilized,
- petHealthStatus: pet.healthStatus || "",
- petAllergies: pet.allergies || "",
- petMedicalHistory: pet.medicalHistory || "",
- petVaccineStatus: pet.vaccineStatus || "",
- ownerName: pet.ownerName || "",
- ownerPhone: pet.ownerPhone || ""
- };
- } else {
- this.currentPetInfo = {
- ...this.orderDetail,
- petGender: "",
- petAge: "未知",
- petWeight: "未知",
- petPersonality: "无",
- petHobby: "",
- petRemark: "无",
- petTags: [],
- petLogs: []
- };
- }
- this.showPetModal = true;
- },
- closePetProfile() {
- this.showPetModal = false;
- },
- openPetRemarkInput() {
- this.petRemarkText = "";
- this.showPetRemarkInput = true;
- },
- closePetRemarkInput() {
- this.showPetRemarkInput = false;
- },
- submitPetRemark() {
- if (!this.petRemarkText.trim()) {
- uni.showToast({ title: "备注内容不能为空", icon: "none" });
- return;
- }
- const now = /* @__PURE__ */ new Date();
- const date = `${now.getFullYear()}/${String(now.getMonth() + 1).padStart(2, "0")}/${String(now.getDate()).padStart(2, "0")}`;
- if (!this.currentPetInfo.petLogs) {
- this.currentPetInfo.petLogs = [];
- }
- this.currentPetInfo.petLogs.unshift({
- date,
- content: this.petRemarkText,
- recorder: this.orderDetail.fulfillerName || "未知"
- });
- this.closePetRemarkInput();
- uni.showToast({ title: "备注已添加", icon: "success" });
- },
- goToAnomaly() {
- uni.navigateTo({
- url: "/pages/orders/anomaly?orderId=" + (this.orderDetail.orderNo || "")
- });
- },
- callPhone() {
- const phoneNum = this.orderDetail.customerPhone || "18900008451";
- uni.makePhoneCall({ phoneNumber: phoneNum });
- },
- openNavigation(type) {
- this.navTargetPointType = type;
- this.showNavModal = true;
- },
- closeNavModal() {
- this.showNavModal = false;
- },
- chooseMap(mapType) {
- let pointType = this.navTargetPointType;
- let name = pointType === "start" ? this.orderDetail.startLocation : this.orderDetail.endLocation;
- let address = pointType === "start" ? this.orderDetail.startAddress : this.orderDetail.endAddress;
- this.showNavModal = false;
- uni.openLocation({
- latitude: 30.52,
- // Mock lat
- longitude: 114.31,
- // Mock lng
- name: name || "目的地",
- address: address || "默认地址",
- success: function() {
- formatAppLog("log", "at pages/orders/detail-logic.js:486", "打开导航成功: " + mapType);
- }
- });
- },
- openUploadModal() {
- this.modalMediaList = [];
- this.modalRemark = "";
- this.showUploadModal = true;
- },
- closeUploadModal() {
- this.showUploadModal = false;
- },
- handleConfirmUpload() {
- formatAppLog("log", "at pages/orders/detail-logic.js:499", "handleConfirmUpload被调用");
- this.confirmUploadModal();
- },
- async chooseModalMedia() {
- formatAppLog("log", "at pages/orders/detail-logic.js:503", "chooseModalMedia被调用");
- uni.chooseMedia({
- count: 5 - this.modalMediaList.length,
- mediaType: ["image", "video"],
- sourceType: ["album", "camera"],
- success: async (res) => {
- formatAppLog("log", "at pages/orders/detail-logic.js:510", "选择媒体文件成功:", res.tempFiles);
- uni.showLoading({ title: "上传中...", mask: true });
- try {
- for (const file of res.tempFiles) {
- const filePath = file.tempFilePath;
- const fileType = file.fileType;
- formatAppLog("log", "at pages/orders/detail-logic.js:516", "开始上传文件:", filePath, "类型:", fileType);
- const uploadRes = await uploadFile(filePath);
- formatAppLog("log", "at pages/orders/detail-logic.js:519", "服务器响应:", uploadRes);
- if (uploadRes.code === 200) {
- this.modalMediaList.push({
- url: uploadRes.data.url,
- ossId: uploadRes.data.ossId,
- localPath: filePath,
- mediaType: fileType,
- thumb: file.thumbTempFilePath
- // 视频缩略图(如果有)
- });
- formatAppLog("log", "at pages/orders/detail-logic.js:529", "媒体文件添加成功");
- }
- }
- uni.hideLoading();
- uni.showToast({ title: "上传成功", icon: "success" });
- } catch (err) {
- uni.hideLoading();
- formatAppLog("error", "at pages/orders/detail-logic.js:536", "上传失败详情:", err);
- uni.showToast({ title: "上传失败", icon: "none" });
- }
- },
- fail: (err) => {
- formatAppLog("error", "at pages/orders/detail-logic.js:541", "选择媒体文件失败:", err);
- }
- });
- },
- removeModalMedia(index) {
- this.modalMediaList.splice(index, 1);
- },
- getCurrentTime() {
- const now = /* @__PURE__ */ new Date();
- const y = now.getFullYear();
- const m = String(now.getMonth() + 1).padStart(2, "0");
- const d = String(now.getDate()).padStart(2, "0");
- const h = String(now.getHours()).padStart(2, "0");
- const min = String(now.getMinutes()).padStart(2, "0");
- return `${y}/${m}/${d} ${h}:${min}`;
- },
- async confirmUploadModal() {
- formatAppLog("log", "at pages/orders/detail-logic.js:559", "confirmUploadModal被调用,文件数量:", this.modalMediaList.length);
- if (this.modalMediaList.length === 0) {
- uni.showToast({ title: "请上传至少一张图片或视频", icon: "none" });
- return;
- }
- try {
- uni.showLoading({ title: "提交中..." });
- const uploadedMedias = this.modalMediaList.map((item) => item.url);
- const ossIds = this.modalMediaList.map((item) => item.ossId);
- formatAppLog("log", "at pages/orders/detail-logic.js:570", "准备打卡,ossIds:", ossIds);
- const clockInType = this.currentClockIn ? this.currentClockIn.step : this.currentStep + 1;
- const clockInData = {
- orderId: this.orderId,
- photos: ossIds,
- content: this.modalRemark || "",
- step: clockInType,
- title: this.currentTaskTitle,
- startFlag: Number(clockInType) === 1,
- endFlag: Number(this.currentStep) === this.steps.length - 1
- };
- formatAppLog("log", "at pages/orders/detail-logic.js:585", "打卡数据:", clockInData);
- await clockIn(clockInData);
- uni.hideLoading();
- this.closeUploadModal();
- uni.showToast({ title: "打卡成功", icon: "success" });
- await this.loadOrderDetail();
- } catch (err) {
- uni.hideLoading();
- formatAppLog("error", "at pages/orders/detail-logic.js:595", "打卡失败:", err);
- uni.showToast({ title: "打卡失败,请重试", icon: "none" });
- }
- },
- copyOrderNo() {
- uni.setClipboardData({
- data: this.orderDetail.orderNo,
- success: () => {
- uni.showToast({ title: "复制成功", icon: "none" });
- }
- });
- },
- openSumModal() {
- let displayDate = "";
- if (this.orderDetail.time) {
- displayDate = this.orderDetail.time.split(" ")[0].replace(/-/g, "/");
- } else {
- const now = /* @__PURE__ */ new Date();
- const y = now.getFullYear();
- const m = String(now.getMonth() + 1).padStart(2, "0");
- const d = String(now.getDate()).padStart(2, "0");
- displayDate = `${y}/${m}/${d}`;
- }
- this.sumDate = displayDate;
- if (this.orderDetail.nursingSummary) {
- this.sumContent = this.orderDetail.nursingSummary;
- } else if (!this.sumContent) {
- this.sumContent = "1. 精神/身体状态:\n2. 进食/饮水:\n3. 排泤情况:\n4. 卫生情况:\n5. 互动情况:\n6. 特殊情况/备注:";
- }
- this.showSumModal = true;
- },
- closeSumModal() {
- this.showSumModal = false;
- },
- async submitSumModal() {
- if (!this.sumContent.trim()) {
- uni.showToast({ title: "请填写服务内容", icon: "none" });
- return;
- }
- uni.showLoading({ title: "提交中...", mask: true });
- try {
- const res = await submitNursingSummary({
- orderId: this.orderId,
- content: this.sumContent
- });
- uni.hideLoading();
- if (res.code === 200) {
- uni.showToast({ title: "小结已提交", icon: "success" });
- this.closeSumModal();
- await this.loadOrderDetail();
- } else {
- uni.showToast({ title: res.msg || "提交失败", icon: "none" });
- }
- } catch (err) {
- uni.hideLoading();
- formatAppLog("error", "at pages/orders/detail-logic.js:663", "提交宠护小结失败:", err);
- uni.showToast({ title: "提交失败,请重试", icon: "none" });
- }
- },
- /**
- * 检查是否为视频
- */
- isVideo(url) {
- if (!url)
- return false;
- const videoExts = [".mp4", ".mov", ".m4v", ".3gp", ".avi", ".wmv"];
- const lowerUrl = url.toLowerCase();
- return videoExts.some((ext) => lowerUrl.includes(ext));
- },
- /**
- * 获取视频封面图 (第一帧)
- * 兼容阿里云、腾讯云等主流 OSS
- */
- getVideoPoster(url) {
- if (!this.isVideo(url))
- return url;
- if (url.includes("?x-oss-process") || url.includes("?ci-process") || url.includes("?vframe")) {
- return url;
- }
- const aliyun = `?x-oss-process=video/snapshot,t_1,f_jpg,w_300,m_fast`;
- const tencent = `?ci-process=snapshot&time=1`;
- if (url.includes("myqcloud.com")) {
- return url + tencent;
- }
- return url + aliyun;
- },
- /**
- * 统一预览媒体
- */
- previewMedia(medias, currentIdx) {
- const url = medias[currentIdx];
- if (this.isVideo(url)) {
- this.videoPlayerUrl = url;
- this.videoPlayerShow = true;
- } else {
- const imageUrls = medias.filter((m) => !this.isVideo(m));
- const currentImgUrl = url;
- const newIdx = imageUrls.indexOf(currentImgUrl);
- uni.previewImage({
- current: newIdx >= 0 ? newIdx : 0,
- urls: imageUrls
- });
- }
- },
- closeVideoPlayer() {
- this.videoPlayerShow = false;
- this.videoPlayerUrl = "";
- }
- }
- };
- const _imports_14 = "/static/icons/phone_orange.svg";
- const _imports_1$7 = "/static/icons/clock.svg";
- const _imports_0$2 = "/static/icons/right_arrow_orange.svg";
- const _imports_4$1 = "/static/icons/heart.svg";
- const _imports_5 = "/static/icons/file.svg";
- const _imports_1$6 = "/static/icons/camera_grey.svg";
- const _imports_7 = "/static/icons/order_no.svg";
- const _imports_8$1 = "/static/icons/play_circle.svg";
- const _imports_9$1 = "/static/empty-rest.png";
- const _sfc_main$q = {
- ...logic$1
- };
- function _sfc_render$p(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "detail-container" }, [
- _ctx.pageLoading ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "loading-container"
- }, [
- vue.createElementVNode("view", { class: "skeleton-header" }, [
- vue.createElementVNode("view", {
- class: "skeleton-line skeleton-ani",
- style: { "width": "30%", "height": "36rpx" }
- }),
- vue.createElementVNode("view", {
- class: "skeleton-line skeleton-ani",
- style: { "width": "20%", "height": "36rpx" }
- })
- ]),
- vue.createElementVNode("view", { class: "skeleton-progress" }, [
- (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(4, (i) => {
- return vue.createElementVNode("view", {
- class: "skeleton-circle skeleton-ani",
- key: i
- });
- }),
- 64
- /* STABLE_FRAGMENT */
- ))
- ]),
- (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(3, (j) => {
- return vue.createElementVNode("view", {
- class: "skeleton-card",
- key: "c" + j
- }, [
- vue.createElementVNode("view", {
- class: "skeleton-line skeleton-ani",
- style: { "width": "60%", "height": "28rpx", "margin-bottom": "20rpx" }
- }),
- vue.createElementVNode("view", {
- class: "skeleton-line skeleton-ani",
- style: { "width": "90%", "height": "24rpx", "margin-bottom": "14rpx" }
- }),
- vue.createElementVNode("view", {
- class: "skeleton-line skeleton-ani",
- style: { "width": "75%", "height": "24rpx" }
- })
- ]);
- }),
- 64
- /* STABLE_FRAGMENT */
- ))
- ])) : (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 1 },
- [
- vue.createElementVNode("view", { class: "detail-header" }, [
- vue.createElementVNode("view", { class: "status-row" }, [
- vue.createElementVNode(
- "text",
- { class: "status-title" },
- vue.toDisplayString(_ctx.displayStatusText),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "status-price" },
- "¥" + vue.toDisplayString(_ctx.orderDetail.price),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "progress-bar" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.progressSteps, (step, index) => {
- return vue.openBlock(), vue.createElementBlock(
- "view",
- {
- class: vue.normalizeClass(["step-item", { "active": index === _ctx.progressIndex, "done": index < _ctx.progressIndex }]),
- key: index
- },
- [
- vue.createElementVNode("view", { class: "step-circle-wrapper" }, [
- index !== 0 ? (vue.openBlock(), vue.createElementBlock(
- "view",
- {
- key: 0,
- class: vue.normalizeClass(["step-line", { "active-line": index <= _ctx.progressIndex }])
- },
- null,
- 2
- /* CLASS */
- )) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode(
- "view",
- { class: "step-circle" },
- vue.toDisplayString(index + 1),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode(
- "text",
- { class: "step-text" },
- vue.toDisplayString(step),
- 1
- /* TEXT */
- )
- ],
- 2
- /* CLASS */
- );
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "detail-content"
- }, [
- vue.createElementVNode("view", { class: "white-card pet-bar" }, [
- vue.createElementVNode("image", {
- class: "pb-avatar",
- src: _ctx.orderDetail.petAvatar,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "pb-info" }, [
- vue.createElementVNode("view", { class: "pb-name-row" }, [
- vue.createElementVNode(
- "text",
- { class: "pb-name" },
- vue.toDisplayString(_ctx.orderDetail.petName),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "pb-breed" },
- "品种: " + vue.toDisplayString(_ctx.orderDetail.petBreed),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pb-tags" }, [
- vue.createElementVNode(
- "text",
- { class: "pb-tag" },
- vue.toDisplayString(_ctx.orderDetail.serviceTag),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", { class: "pb-actions" }, [
- vue.createElementVNode("view", {
- class: "pb-btn profile-btn",
- onClick: _cache[0] || (_cache[0] = (...args) => _ctx.showPetProfile && _ctx.showPetProfile(...args))
- }, "宠物档案"),
- vue.createElementVNode("view", {
- class: "pb-btn phone-btn",
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.callPhone && _ctx.callPhone(...args))
- }, [
- vue.createElementVNode("image", {
- class: "phone-icon",
- src: _imports_14
- })
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "white-card service-info-card" }, [
- vue.createElementVNode("view", { class: "si-row time-row" }, [
- vue.createElementVNode("image", {
- class: "si-icon outline",
- src: _imports_1$7
- }),
- vue.createElementVNode("view", { class: "si-content" }, [
- vue.createElementVNode("text", { class: "si-label" }, "服务时间"),
- vue.createElementVNode(
- "text",
- { class: "si-val" },
- vue.toDisplayString(_ctx.orderDetail.time),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", {
- class: "si-action record-btn",
- onClick: _cache[2] || (_cache[2] = vue.withModifiers((...args) => _ctx.openAnomalyModal && _ctx.openAnomalyModal(...args), ["stop"]))
- }, [
- vue.createElementVNode("text", null, "异常记录"),
- vue.createElementVNode("image", {
- class: "record-arrow",
- src: _imports_0$2
- })
- ])
- ]),
- _ctx.orderDetail.type === 1 ? (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 0 },
- [
- vue.createElementVNode("view", { class: "si-row addr-row start-addr" }, [
- vue.createElementVNode("view", { class: "icon-circle start" }, "起"),
- vue.createElementVNode("view", { class: "route-line-vertical" }),
- vue.createElementVNode("view", { class: "si-content" }, [
- vue.createElementVNode(
- "text",
- { class: "si-addr-title" },
- vue.toDisplayString(_ctx.orderDetail.startLocation),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "si-addr-desc" },
- vue.toDisplayString(_ctx.orderDetail.startAddress),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", {
- class: "nav-btn-circle",
- onClick: _cache[3] || (_cache[3] = ($event) => _ctx.openNavigation("start"))
- }, [
- vue.createElementVNode("image", {
- class: "nav-arrow",
- src: _imports_3$2
- })
- ])
- ]),
- vue.createElementVNode("view", { class: "si-row addr-row end-addr" }, [
- vue.createElementVNode("view", { class: "icon-circle end" }, "终"),
- vue.createElementVNode("view", { class: "si-content" }, [
- vue.createElementVNode(
- "text",
- { class: "si-addr-title" },
- vue.toDisplayString(_ctx.orderDetail.endLocation),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "si-addr-desc" },
- vue.toDisplayString(_ctx.orderDetail.endAddress),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", {
- class: "nav-btn-circle",
- onClick: _cache[4] || (_cache[4] = ($event) => _ctx.openNavigation("end"))
- }, [
- vue.createElementVNode("image", {
- class: "nav-arrow",
- src: _imports_3$2
- })
- ])
- ])
- ],
- 64
- /* STABLE_FRAGMENT */
- )) : (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 1 },
- [
- vue.createElementVNode("view", { class: "si-row addr-row end-addr" }, [
- vue.createElementVNode("view", { class: "icon-circle service" }, "服"),
- vue.createElementVNode("view", { class: "si-content" }, [
- vue.createElementVNode(
- "text",
- { class: "si-addr-title" },
- vue.toDisplayString(_ctx.orderDetail.endLocation),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "si-addr-desc" },
- vue.toDisplayString(_ctx.orderDetail.endAddress),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", {
- class: "nav-btn-circle",
- onClick: _cache[5] || (_cache[5] = ($event) => _ctx.openNavigation("end"))
- }, [
- vue.createElementVNode("image", {
- class: "nav-arrow",
- src: _imports_3$2
- })
- ])
- ]),
- vue.createElementVNode("view", { class: "si-row" }, [
- vue.createElementVNode("image", {
- class: "si-icon outline",
- src: _imports_4$1
- }),
- vue.createElementVNode("view", { class: "si-content" }, [
- vue.createElementVNode("text", { class: "si-label" }, "服务内容"),
- vue.createElementVNode(
- "text",
- { class: "si-val" },
- vue.toDisplayString(_ctx.orderDetail.serviceContent),
- 1
- /* TEXT */
- )
- ])
- ])
- ],
- 64
- /* STABLE_FRAGMENT */
- )),
- vue.createElementVNode("view", { class: "si-row" }, [
- vue.createElementVNode("image", {
- class: "si-icon outline custom-icon-file",
- src: _imports_5
- }),
- vue.createElementVNode("view", { class: "si-content" }, [
- vue.createElementVNode("text", { class: "si-label" }, "备注"),
- vue.createElementVNode(
- "text",
- { class: "si-val" },
- vue.toDisplayString(_ctx.orderDetail.remark || "无"),
- 1
- /* TEXT */
- )
- ])
- ])
- ]),
- _ctx.currentStep < _ctx.steps.length ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "white-card task-card"
- }, [
- vue.createElementVNode(
- "text",
- { class: "tc-title" },
- "当前任务:" + vue.toDisplayString(_ctx.currentTaskTitle),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "tc-desc" },
- vue.toDisplayString(_ctx.currentTaskDesc),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("view", {
- class: "full-media-add",
- onClick: _cache[6] || (_cache[6] = (...args) => _ctx.openUploadModal && _ctx.openUploadModal(...args))
- }, [
- vue.createElementVNode("image", {
- class: "upload-icon-large",
- src: _imports_1$6
- }),
- vue.createElementVNode("text", { class: "upload-text-large" }, "上传图或视频")
- ])
- ])) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("view", { class: "white-card base-info-card" }, [
- vue.createElementVNode("view", { class: "bi-row" }, [
- vue.createElementVNode("image", {
- class: "si-icon outline",
- src: _imports_7
- }),
- vue.createElementVNode("view", { class: "bi-content" }, [
- vue.createElementVNode("text", { class: "bi-label" }, "订单编号"),
- vue.createElementVNode("view", { class: "bi-val-row" }, [
- vue.createElementVNode(
- "text",
- { class: "bi-val" },
- vue.toDisplayString(_ctx.orderDetail.orderNo),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", {
- class: "bi-copy",
- onClick: _cache[7] || (_cache[7] = (...args) => _ctx.copyOrderNo && _ctx.copyOrderNo(...args))
- }, "复制")
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "bi-row" }, [
- vue.createElementVNode("image", {
- class: "si-icon outline",
- src: _imports_1$7
- }),
- vue.createElementVNode("view", { class: "bi-content" }, [
- vue.createElementVNode("text", { class: "bi-label" }, "下单时间"),
- vue.createElementVNode(
- "text",
- { class: "bi-val" },
- vue.toDisplayString(_ctx.orderDetail.createTime),
- 1
- /* TEXT */
- )
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "white-card timeline-card" }, [
- vue.createElementVNode("view", { class: "tl-title-row" }, [
- vue.createElementVNode("view", { class: "orange-bar" }),
- vue.createElementVNode("text", { class: "tl-title" }, "订单进度")
- ]),
- vue.createElementVNode("view", { class: "tl-list" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.orderDetail.progressLogs, (log, idx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "tl-item",
- key: idx
- }, [
- vue.createElementVNode("view", { class: "tl-marker active" }, [
- vue.createElementVNode("view", { class: "tl-dot-inner" })
- ]),
- vue.createElementVNode("view", { class: "tl-content-row" }, [
- vue.createElementVNode("view", { class: "tl-header" }, [
- vue.createElementVNode(
- "text",
- { class: "tl-status" },
- vue.toDisplayString(log.status),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "tl-time" },
- vue.toDisplayString(log.time),
- 1
- /* TEXT */
- )
- ]),
- log.medias && log.medias.length > 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tl-medias"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(log.medias, (media, midx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "tl-media-item",
- key: midx,
- onClick: ($event) => _ctx.previewMedia(log.medias, midx)
- }, [
- !_ctx.isVideo(media) ? (vue.openBlock(), vue.createElementBlock("image", {
- key: 0,
- class: "tl-img",
- src: media,
- mode: "aspectFill"
- }, null, 8, ["src"])) : (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "tl-video-placeholder"
- }, [
- vue.createElementVNode("view", { class: "tl-play-icon" }),
- vue.createElementVNode("text", { class: "tl-video-label" }, "视频")
- ]))
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])) : vue.createCommentVNode("v-if", true),
- log.remark ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "tl-remark"
- }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(log.remark),
- 1
- /* TEXT */
- )
- ])) : vue.createCommentVNode("v-if", true)
- ])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ]),
- vue.createElementVNode("view", { style: { "height": "140rpx" } })
- ]),
- vue.createElementVNode("view", { class: "bottom-action-bar" }, [
- vue.createElementVNode("view", { class: "action-left" }, [
- vue.createElementVNode("button", {
- class: "action-btn outline grey-outline",
- onClick: _cache[8] || (_cache[8] = (...args) => _ctx.goToAnomaly && _ctx.goToAnomaly(...args))
- }, "异常上报"),
- _ctx.serviceMode === 0 ? (vue.openBlock(), vue.createElementBlock("button", {
- key: 0,
- class: "action-btn outline orange-outline",
- onClick: _cache[9] || (_cache[9] = (...args) => _ctx.openSumModal && _ctx.openSumModal(...args))
- }, "宠护小结")) : vue.createCommentVNode("v-if", true)
- ]),
- vue.createElementVNode("view", { class: "action-right" }, [
- _ctx.currentStep < _ctx.steps.length ? (vue.openBlock(), vue.createElementBlock(
- "button",
- {
- key: 0,
- class: "action-btn primary",
- onClick: _cache[10] || (_cache[10] = (...args) => _ctx.openUploadModal && _ctx.openUploadModal(...args))
- },
- vue.toDisplayString(_ctx.currentTaskTitle),
- 1
- /* TEXT */
- )) : (vue.openBlock(), vue.createElementBlock("button", {
- key: 1,
- class: "action-btn primary grey-bg"
- }, "已完成"))
- ])
- ]),
- _ctx.showPetModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "pet-modal-mask",
- onClick: _cache[14] || (_cache[14] = (...args) => _ctx.closePetProfile && _ctx.closePetProfile(...args))
- }, [
- vue.createElementVNode("view", {
- class: "pet-modal-content",
- onClick: _cache[13] || (_cache[13] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "pet-modal-header" }, [
- vue.createElementVNode("text", { class: "pet-modal-title" }, "宠物档案"),
- vue.createElementVNode("view", { style: { "flex": "1" } }),
- vue.createElementVNode("view", {
- class: "pm-remark-btn",
- onClick: _cache[11] || (_cache[11] = (...args) => _ctx.openPetRemarkInput && _ctx.openPetRemarkInput(...args))
- }, "备注"),
- vue.createElementVNode("view", {
- class: "close-icon-btn",
- onClick: _cache[12] || (_cache[12] = (...args) => _ctx.closePetProfile && _ctx.closePetProfile(...args))
- }, "×")
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "pet-modal-scroll"
- }, [
- vue.createElementVNode("view", { class: "pet-base-info" }, [
- vue.createElementVNode("image", {
- class: "pm-avatar",
- src: _ctx.currentPetInfo.petAvatar,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "pm-info-text" }, [
- vue.createElementVNode("view", { class: "pm-name-row" }, [
- vue.createElementVNode(
- "text",
- { class: "pm-name" },
- vue.toDisplayString(_ctx.currentPetInfo.petName),
- 1
- /* TEXT */
- ),
- _ctx.currentPetInfo.petGender === "M" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "pm-gender"
- }, [
- vue.createElementVNode("text", { class: "gender-icon" }, "♂"),
- vue.createElementVNode("text", null, "公")
- ])) : _ctx.currentPetInfo.petGender === "F" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "pm-gender female"
- }, [
- vue.createElementVNode("text", { class: "gender-icon" }, "♀"),
- vue.createElementVNode("text", null, "母")
- ])) : vue.createCommentVNode("v-if", true)
- ]),
- vue.createElementVNode(
- "text",
- { class: "pm-breed" },
- "品种:" + vue.toDisplayString(_ctx.currentPetInfo.petBreed),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", { class: "pm-detail-grid" }, [
- vue.createElementVNode("view", { class: "pm-grid-item half" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "年龄"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petAge || "未知"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item half" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "体重"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petWeight || "未知"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item full" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "性格"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petPersonality || "无"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item full" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "爱好"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petHobby || "无"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "pm-grid-item full" }, [
- vue.createElementVNode("text", { class: "pm-label" }, "备注"),
- vue.createElementVNode(
- "text",
- { class: "pm-val" },
- vue.toDisplayString(_ctx.currentPetInfo.petRemark || "无特殊过敏史"),
- 1
- /* TEXT */
- )
- ])
- ]),
- _ctx.currentPetInfo.petTags && _ctx.currentPetInfo.petTags.length > 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "pm-tags-row"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.currentPetInfo.petTags, (tag, ti) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "pm-tag-chip",
- key: ti
- }, [
- vue.createElementVNode(
- "text",
- { class: "pm-tag-chip-text" },
- vue.toDisplayString(tag),
- 1
- /* TEXT */
- )
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("view", { class: "pm-log-section" }, [
- vue.createElementVNode("view", { class: "pm-log-header" }, [
- vue.createElementVNode("view", { style: { "width": "6rpx", "height": "28rpx", "background": "#FF9800", "border-radius": "3rpx", "margin-right": "12rpx" } }),
- vue.createElementVNode("text", { class: "pm-log-section-title" }, "备注日志")
- ]),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.currentPetInfo.petLogs, (log, lIndex) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "pm-log-item",
- key: lIndex
- }, [
- vue.createElementVNode(
- "text",
- { class: "pm-log-date" },
- vue.toDisplayString(log.date),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "pm-log-text" },
- vue.toDisplayString(log.content),
- 1
- /* TEXT */
- ),
- log.recorder !== "系统记录" ? (vue.openBlock(), vue.createElementBlock(
- "text",
- {
- key: 0,
- class: "pm-log-recorder"
- },
- "记录人:" + vue.toDisplayString(log.recorder),
- 1
- /* TEXT */
- )) : (vue.openBlock(), vue.createElementBlock("text", {
- key: 1,
- class: "pm-log-recorder system"
- }, "系统记录"))
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("view", { style: { "height": "30rpx" } })
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.showPetRemarkInput ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "upload-modal-mask",
- onClick: _cache[18] || (_cache[18] = (...args) => _ctx.closePetRemarkInput && _ctx.closePetRemarkInput(...args))
- }, [
- vue.createElementVNode("view", {
- class: "upload-modal-content",
- onClick: _cache[17] || (_cache[17] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "um-header" }, [
- vue.createElementVNode("text", { class: "um-title" }, "添加备注")
- ]),
- vue.createElementVNode("view", { class: "um-body" }, [
- vue.withDirectives(vue.createElementVNode(
- "textarea",
- {
- class: "um-textarea",
- "onUpdate:modelValue": _cache[15] || (_cache[15] = ($event) => _ctx.petRemarkText = $event),
- "auto-height": "",
- placeholder: "请输入宠物备注内容...",
- "placeholder-style": "color:#ccc; font-size:26rpx;"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.petRemarkText]
- ])
- ]),
- vue.createElementVNode("view", { class: "um-footer" }, [
- vue.createElementVNode("button", {
- class: "um-submit-btn active",
- onClick: _cache[16] || (_cache[16] = (...args) => _ctx.submitPetRemark && _ctx.submitPetRemark(...args))
- }, "确认提交")
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.showNavModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 2,
- class: "nav-modal-mask",
- onClick: _cache[24] || (_cache[24] = (...args) => _ctx.closeNavModal && _ctx.closeNavModal(...args))
- }, [
- vue.createElementVNode("view", {
- class: "nav-action-sheet",
- onClick: _cache[23] || (_cache[23] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "nav-sheet-title" }, "选择地图进行导航"),
- vue.createElementVNode("view", {
- class: "nav-sheet-item",
- onClick: _cache[19] || (_cache[19] = ($event) => _ctx.chooseMap("高德"))
- }, "高德地图"),
- vue.createElementVNode("view", {
- class: "nav-sheet-item",
- onClick: _cache[20] || (_cache[20] = ($event) => _ctx.chooseMap("腾讯"))
- }, "腾讯地图"),
- vue.createElementVNode("view", {
- class: "nav-sheet-item",
- onClick: _cache[21] || (_cache[21] = ($event) => _ctx.chooseMap("百度"))
- }, "百度地图"),
- vue.createElementVNode("view", { class: "nav-sheet-gap" }),
- vue.createElementVNode("view", {
- class: "nav-sheet-item cancel",
- onClick: _cache[22] || (_cache[22] = (...args) => _ctx.closeNavModal && _ctx.closeNavModal(...args))
- }, "取消")
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.showUploadModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 3,
- class: "upload-modal-mask",
- onClick: _cache[29] || (_cache[29] = (...args) => _ctx.closeUploadModal && _ctx.closeUploadModal(...args))
- }, [
- vue.createElementVNode("view", {
- class: "upload-modal-content",
- onClick: _cache[28] || (_cache[28] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "um-header" }, [
- vue.createElementVNode(
- "text",
- { class: "um-title" },
- "上传图或视频 (" + vue.toDisplayString(_ctx.modalMediaList.length) + "/5)",
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "um-remark-hint" },
- vue.toDisplayString(_ctx.currentTaskDesc),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "um-body" }, [
- vue.createElementVNode("view", { class: "um-grid" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.modalMediaList, (img, idx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "um-item",
- key: idx
- }, [
- vue.createElementVNode("image", {
- class: "um-preview",
- src: img.thumb || img.url || img.localPath || img,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- img.mediaType === "video" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "um-video-badge"
- }, [
- vue.createElementVNode("image", {
- class: "play-icon-small",
- src: _imports_8$1
- })
- ])) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("view", {
- class: "um-del",
- onClick: ($event) => _ctx.removeModalMedia(idx)
- }, "×", 8, ["onClick"])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- _ctx.modalMediaList.length < 5 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "um-add",
- onClick: _cache[25] || (_cache[25] = (...args) => _ctx.chooseModalMedia && _ctx.chooseModalMedia(...args))
- }, [
- vue.createElementVNode("image", {
- class: "um-add-icon",
- src: _imports_1$6
- }),
- vue.createElementVNode("text", { class: "um-add-text" }, "拍摄/上传")
- ])) : vue.createCommentVNode("v-if", true)
- ]),
- vue.withDirectives(vue.createElementVNode(
- "textarea",
- {
- class: "um-textarea",
- "onUpdate:modelValue": _cache[26] || (_cache[26] = ($event) => _ctx.modalRemark = $event),
- placeholder: "在此输入备注信息...",
- "placeholder-style": "color:#ccc; font-size:26rpx;"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.modalRemark]
- ])
- ]),
- vue.createElementVNode("view", { class: "um-footer" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["um-submit-btn", { "active": _ctx.modalMediaList.length > 0 }]),
- onClick: _cache[27] || (_cache[27] = (...args) => _ctx.handleConfirmUpload && _ctx.handleConfirmUpload(...args))
- },
- " 确认提交",
- 2
- /* CLASS */
- )
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.showSumModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 4,
- class: "sum-modal-mask",
- onClick: _cache[33] || (_cache[33] = (...args) => _ctx.closeSumModal && _ctx.closeSumModal(...args))
- }, [
- vue.createElementVNode("view", {
- class: "sum-modal-card",
- onClick: _cache[32] || (_cache[32] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "sum-modal-scroll"
- }, [
- vue.createElementVNode("view", { class: "sum-modal-inner" }, [
- vue.createElementVNode("text", { class: "sum-modal-title" }, "宠物护理工作小结"),
- vue.createElementVNode("view", { class: "sum-meta-row" }, [
- vue.createElementVNode("text", { class: "sum-meta-label" }, "日期:"),
- vue.createElementVNode(
- "text",
- { class: "sum-meta-val" },
- vue.toDisplayString(_ctx.sumDate),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "sum-meta-row" }, [
- vue.createElementVNode("text", { class: "sum-meta-label" }, "客户住址:"),
- vue.createElementVNode(
- "text",
- { class: "sum-meta-val" },
- vue.toDisplayString(_ctx.orderDetail.endAddress),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "sum-meta-row" }, [
- vue.createElementVNode("text", { class: "sum-meta-label" }, "宠主姓名:"),
- vue.createElementVNode(
- "text",
- { class: "sum-meta-val" },
- vue.toDisplayString(_ctx.orderDetail.ownerName || "未知"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "sum-section-title" }, "宠物信息"),
- vue.createElementVNode("view", { class: "sum-pet-card" }, [
- vue.createElementVNode("image", {
- class: "sum-pet-avatar",
- src: _ctx.orderDetail.petAvatar,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "sum-pet-info" }, [
- vue.createElementVNode("view", { class: "sum-pet-name-row" }, [
- vue.createElementVNode(
- "text",
- { class: "sum-pet-name" },
- vue.toDisplayString(_ctx.orderDetail.petName || "未知"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "sum-pet-breed" },
- "品种: " + vue.toDisplayString(_ctx.orderDetail.petBreed || "未知"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode(
- "text",
- { class: "sum-pet-remark" },
- vue.toDisplayString(_ctx.orderDetail.petNotes || "暂无备注"),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", { class: "sum-section-title" }, "服务内容记录"),
- vue.withDirectives(vue.createElementVNode(
- "textarea",
- {
- class: "sum-textarea",
- "onUpdate:modelValue": _cache[30] || (_cache[30] = ($event) => _ctx.sumContent = $event),
- "auto-height": "",
- placeholder: "请填写服务内容...",
- "placeholder-style": "color:#ccc"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, _ctx.sumContent]
- ]),
- vue.createElementVNode("view", { class: "sum-sign-row" }, [
- vue.createElementVNode("text", { class: "sum-sign-label" }, "护宠师签名:"),
- vue.createElementVNode(
- "text",
- { class: "sum-sign-val" },
- vue.toDisplayString(_ctx.sumSigner),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { style: { "height": "20rpx" } })
- ])
- ]),
- vue.createElementVNode("view", { class: "sum-footer" }, [
- vue.createElementVNode("button", {
- class: "sum-submit-btn",
- onClick: _cache[31] || (_cache[31] = (...args) => _ctx.submitSumModal && _ctx.submitSumModal(...args))
- }, "提交小结")
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.showAnomalyModal ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 5,
- class: "modal-mask",
- onClick: _cache[36] || (_cache[36] = (...args) => _ctx.closeAnomalyModal && _ctx.closeAnomalyModal(...args))
- }, [
- vue.createElementVNode("view", {
- class: "anomaly-modal-content",
- onClick: _cache[35] || (_cache[35] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "am-header" }, [
- vue.createElementVNode("text", { class: "am-title" }, "历史异常记录"),
- vue.createElementVNode("view", {
- class: "close-icon-btn",
- onClick: _cache[34] || (_cache[34] = (...args) => _ctx.closeAnomalyModal && _ctx.closeAnomalyModal(...args))
- }, "×")
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "am-scroll-list"
- }, [
- _ctx.anomalyList.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "empty-list"
- }, [
- vue.createElementVNode("image", {
- class: "empty-icon",
- src: _imports_9$1,
- mode: "aspectFit"
- }),
- vue.createElementVNode("text", { class: "empty-text" }, "暂无异常记录")
- ])) : vue.createCommentVNode("v-if", true),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(_ctx.anomalyList, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "am-item",
- key: index
- }, [
- vue.createElementVNode("view", { class: "am-item-header" }, [
- vue.createElementVNode(
- "text",
- { class: "am-item-type" },
- vue.toDisplayString(item.typeLabel),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["am-item-status", "status-" + item.status])
- },
- vue.toDisplayString(_ctx.getAnomalyStatusLabel(item.status)),
- 3
- /* TEXT, CLASS */
- )
- ]),
- vue.createElementVNode(
- "text",
- { class: "am-item-content" },
- vue.toDisplayString(item.content),
- 1
- /* TEXT */
- ),
- item.photos && item.photos.length > 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "am-item-photos"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(item.photoUrls, (photoUrl, pIdx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "am-photo-item",
- key: pIdx,
- onClick: ($event) => _ctx.previewMedia(item.photoUrls, pIdx)
- }, [
- !_ctx.isVideo(photoUrl) ? (vue.openBlock(), vue.createElementBlock("image", {
- key: 0,
- class: "am-photo",
- src: photoUrl,
- mode: "aspectFill"
- }, null, 8, ["src"])) : (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "tl-video-placeholder miniaturized"
- }, [
- vue.createElementVNode("view", { class: "tl-play-icon small" }),
- vue.createElementVNode("text", { class: "tl-video-label small" }, "视频")
- ]))
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])) : vue.createCommentVNode("v-if", true),
- item.status !== 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "am-audit-box"
- }, [
- vue.createElementVNode("view", { class: "am-audit-header" }, [
- vue.createElementVNode(
- "text",
- { class: "am-audit-label" },
- vue.toDisplayString(item.status === 1 ? "审核通过" : "驳回理由"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "am-audit-time" },
- vue.toDisplayString(item.auditTime),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode(
- "text",
- { class: "am-audit-remark" },
- vue.toDisplayString(item.auditRemark || "无"),
- 1
- /* TEXT */
- )
- ])) : vue.createCommentVNode("v-if", true)
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true),
- _ctx.videoPlayerShow ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 6,
- class: "video-player-mask",
- onClick: _cache[39] || (_cache[39] = (...args) => _ctx.closeVideoPlayer && _ctx.closeVideoPlayer(...args))
- }, [
- vue.createElementVNode("view", {
- class: "video-player-content",
- onClick: _cache[38] || (_cache[38] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("video", {
- class: "v-player",
- src: _ctx.videoPlayerUrl,
- autoplay: "",
- controls: ""
- }, null, 8, ["src"]),
- vue.createElementVNode("view", {
- class: "v-close",
- onClick: _cache[37] || (_cache[37] = (...args) => _ctx.closeVideoPlayer && _ctx.closeVideoPlayer(...args))
- }, "×")
- ])
- ])) : vue.createCommentVNode("v-if", true)
- ],
- 64
- /* STABLE_FRAGMENT */
- ))
- ]);
- }
- const PagesOrdersDetail = /* @__PURE__ */ _export_sfc(_sfc_main$q, [["render", _sfc_render$p], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/orders/detail.vue"]]);
- const _sfc_main$p = {
- data() {
- return {
- orderId: "",
- // 已选异常类型(dictValue)
- selectedTypeValue: "",
- // 已选异常类型标签(dictLabel,用于显示)
- selectedTypeLabel: "",
- // 异常描述
- anomalyDesc: "",
- // 照片列表(含 url 和 ossId)
- photoList: [],
- // 是否显示类型选择器
- showTypeSheet: false,
- // 异常类型字典列表(从后端获取)
- anomalyTypes: []
- };
- },
- onLoad(options) {
- if (options.orderId) {
- this.orderId = options.orderId;
- }
- this.loadAnomalyTypes();
- },
- computed: {
- // 当前选中的类型显示文本
- selectedType() {
- return this.selectedTypeLabel || "";
- }
- },
- methods: {
- /**
- * 加载异常类型字典数据
- */
- async loadAnomalyTypes() {
- try {
- const res = await getDictDataByType("flf_anamaly_type");
- if (res.data && Array.isArray(res.data)) {
- this.anomalyTypes = res.data.map((item) => ({
- label: item.dictLabel,
- value: item.dictValue,
- dictCode: item.dictCode
- }));
- formatAppLog("log", "at pages/orders/anomaly.vue:136", "异常类型字典:", this.anomalyTypes);
- }
- } catch (err) {
- formatAppLog("error", "at pages/orders/anomaly.vue:139", "获取异常类型字典失败:", err);
- }
- },
- // 打开类型选择器
- openTypeSheet() {
- this.showTypeSheet = true;
- },
- // 关闭类型选择器
- closeTypeSheet() {
- this.showTypeSheet = false;
- },
- // 选择异常类型
- selectType(type) {
- this.selectedTypeValue = type.value;
- this.selectedTypeLabel = type.label;
- this.closeTypeSheet();
- },
- // 选择照片并上传
- choosePhoto() {
- uni.chooseImage({
- count: 5 - this.photoList.length,
- sizeType: ["compressed"],
- sourceType: ["album", "camera"],
- success: async (res) => {
- uni.showLoading({ title: "上传中..." });
- try {
- for (const filePath of res.tempFilePaths) {
- const uploadRes = await uploadFile(filePath);
- if (uploadRes.code === 200) {
- this.photoList.push({
- url: uploadRes.data.url,
- ossId: uploadRes.data.ossId,
- localPath: filePath
- });
- }
- }
- uni.hideLoading();
- } catch (err) {
- uni.hideLoading();
- formatAppLog("error", "at pages/orders/anomaly.vue:178", "上传失败:", err);
- uni.showToast({ title: "上传失败", icon: "none" });
- }
- }
- });
- },
- // 删除照片
- removePhoto(idx) {
- this.photoList.splice(idx, 1);
- },
- // 提交上报
- async submitAnomaly() {
- if (!this.selectedTypeValue) {
- uni.showToast({ title: "请选择异常类型", icon: "none" });
- return;
- }
- if (this.photoList.length === 0) {
- uni.showToast({ title: "请上传现场照片", icon: "none" });
- return;
- }
- const data = {
- orderId: this.orderId,
- type: this.selectedTypeValue,
- content: this.anomalyDesc,
- photos: this.photoList.map((p) => p.ossId)
- };
- try {
- uni.showLoading({ title: "提交中..." });
- await uploadAnamaly(data);
- uni.hideLoading();
- uni.showToast({ title: "上报成功", icon: "success" });
- setTimeout(() => {
- uni.navigateBack();
- }, 1500);
- } catch (err) {
- uni.hideLoading();
- formatAppLog("error", "at pages/orders/anomaly.vue:214", "异常上报失败:", err);
- uni.showToast({ title: "提交失败,请重试", icon: "none" });
- }
- }
- }
- };
- function _sfc_render$o(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "anomaly-container" }, [
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "anomaly-scroll"
- }, [
- vue.createElementVNode("view", { class: "ano-card" }, [
- vue.createElementVNode("view", { class: "ano-section-title" }, [
- vue.createElementVNode("view", { class: "ano-title-bar" }),
- vue.createElementVNode("text", { class: "ano-title-text" }, "异常类型")
- ]),
- vue.createElementVNode("view", {
- class: "ano-type-row",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.openTypeSheet && $options.openTypeSheet(...args))
- }, [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["ano-type-val", { "placeholder": !$options.selectedType }])
- },
- vue.toDisplayString($options.selectedType || "请选择异常类型"),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode("image", {
- class: "ano-right-arrow",
- src: _imports_0$2
- })
- ])
- ]),
- vue.createElementVNode("view", { class: "ano-card" }, [
- vue.createElementVNode("view", { class: "ano-section-title" }, [
- vue.createElementVNode("view", { class: "ano-title-bar" }),
- vue.createElementVNode("text", { class: "ano-title-text" }, "异常描述")
- ]),
- vue.withDirectives(vue.createElementVNode(
- "textarea",
- {
- class: "ano-textarea",
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => $data.anomalyDesc = $event),
- placeholder: "请详细描述现场异常情况...",
- "placeholder-style": "color:#ccc; font-size:28rpx;",
- maxlength: "500"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, $data.anomalyDesc]
- ])
- ]),
- vue.createElementVNode("view", { class: "ano-card" }, [
- vue.createElementVNode("view", { class: "ano-section-title" }, [
- vue.createElementVNode("view", { class: "ano-title-bar" }),
- vue.createElementVNode("text", { class: "ano-title-text" }, "现场照片 (必填,最多5张)")
- ]),
- vue.createElementVNode("view", { class: "ano-photo-grid" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.photoList, (img, idx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "ano-photo-item",
- key: idx
- }, [
- vue.createElementVNode("image", {
- class: "ano-photo-preview",
- src: img.url || img.localPath || img,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", {
- class: "ano-photo-del",
- onClick: ($event) => $options.removePhoto(idx)
- }, "×", 8, ["onClick"])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- $data.photoList.length < 5 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "ano-photo-add",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.choosePhoto && $options.choosePhoto(...args))
- }, [
- vue.createElementVNode("image", {
- class: "ano-add-icon",
- src: _imports_1$6
- }),
- vue.createElementVNode("text", { class: "ano-add-text" }, "上传")
- ])) : vue.createCommentVNode("v-if", true)
- ])
- ]),
- vue.createElementVNode("view", { style: { "height": "160rpx" } })
- ]),
- vue.createElementVNode("view", { class: "ano-footer" }, [
- vue.createElementVNode("button", {
- class: "ano-submit-btn",
- onClick: _cache[3] || (_cache[3] = (...args) => $options.submitAnomaly && $options.submitAnomaly(...args))
- }, "提交上报")
- ]),
- $data.showTypeSheet ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "ano-sheet-mask",
- onClick: _cache[6] || (_cache[6] = (...args) => $options.closeTypeSheet && $options.closeTypeSheet(...args))
- }, [
- vue.createElementVNode("view", {
- class: "ano-sheet",
- onClick: _cache[5] || (_cache[5] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("text", { class: "ano-sheet-title" }, "选择异常类型"),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "ano-sheet-list"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.anomalyTypes, (type, idx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "ano-sheet-item",
- key: idx,
- onClick: ($event) => $options.selectType(type)
- }, [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["ano-sheet-item-text", { "selected": $data.selectedTypeValue === type.value }])
- },
- vue.toDisplayString(type.label),
- 3
- /* TEXT, CLASS */
- ),
- $data.selectedTypeValue === type.value ? (vue.openBlock(), vue.createElementBlock("image", {
- key: 0,
- class: "ano-check-icon",
- src: _imports_0$2
- })) : vue.createCommentVNode("v-if", true)
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("view", {
- class: "ano-sheet-cancel",
- onClick: _cache[4] || (_cache[4] = (...args) => $options.closeTypeSheet && $options.closeTypeSheet(...args))
- }, "取消")
- ])
- ])) : vue.createCommentVNode("v-if", true)
- ]);
- }
- const PagesOrdersAnomaly = /* @__PURE__ */ _export_sfc(_sfc_main$p, [["render", _sfc_render$o], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/orders/anomaly.vue"]]);
- const _sfc_main$o = {
- data() {
- return {
- tabs: ["全部", "已完成", "已拒绝"],
- activeTab: 0,
- orders: [
- {
- orderType: 1,
- typeName: "接送",
- typeIcon: "/static/icons/car.svg",
- status: "完成",
- finishTime: "2026/02/03 14:30",
- serviceTime: "2026/02/10 10:00",
- petName: "哈士奇宝宝",
- petBreed: "哈士奇",
- petAvatar: "/static/dog.png",
- price: "20.00",
- startName: "武汉大学宠物店",
- startAddr: "武汉市洪山区珞喻路458号",
- endName: "张** 189****8451",
- endAddr: "武汉市武昌区新区大道凤凰广场A座",
- serviceNote: ""
- },
- {
- orderType: 2,
- typeName: "喂遛",
- typeIcon: "/static/icons/walk.svg",
- status: "完成",
- finishTime: "2026/02/03 15:00",
- serviceTime: "2026/02/11 14:00",
- petName: "金毛",
- petBreed: "金毛寻回犬",
- petAvatar: "/static/dog.png",
- price: "35.00",
- startName: "",
- startAddr: "",
- endName: "王女士 138****1234",
- endAddr: "武汉市江汉区泛海国际居住区",
- serviceNote: "需自带牵引绳,遛弯30分钟。"
- },
- {
- orderType: 3,
- typeName: "洗护",
- typeIcon: "/static/icons/wash.svg",
- status: "拒绝",
- finishTime: "2026/02/03 09:30",
- serviceTime: "2026/02/12 09:30",
- petName: "Mimi",
- petBreed: "布偶猫",
- petAvatar: "/static/dog.png",
- price: "50.00",
- startName: "",
- startAddr: "",
- endName: "赵先生 159****9876",
- endAddr: "武汉市汉阳区钟家村",
- serviceNote: "上门洗澡,剪指甲。"
- }
- ]
- };
- },
- computed: {
- filteredOrders() {
- if (this.activeTab === 0)
- return this.orders;
- if (this.activeTab === 1)
- return this.orders.filter((o) => o.status === "完成");
- return this.orders.filter((o) => o.status === "拒绝");
- }
- },
- methods: {
- switchTab(idx) {
- this.activeTab = idx;
- }
- }
- };
- function _sfc_render$n(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "stats-banner" }, [
- vue.createElementVNode("view", { class: "banner-item" }, [
- vue.createElementVNode("text", { class: "banner-num" }, "2546"),
- vue.createElementVNode("text", { class: "banner-label" }, "累计接单")
- ]),
- vue.createElementVNode("view", { class: "banner-item" }, [
- vue.createElementVNode("text", { class: "banner-num" }, "10"),
- vue.createElementVNode("text", { class: "banner-label" }, "累计拒单")
- ]),
- vue.createElementVNode("view", { class: "banner-item" }, [
- vue.createElementVNode("text", { class: "banner-num" }, "10"),
- vue.createElementVNode("text", { class: "banner-label" }, "奖励单量")
- ]),
- vue.createElementVNode("view", { class: "banner-item" }, [
- vue.createElementVNode("text", { class: "banner-num" }, "10"),
- vue.createElementVNode("text", { class: "banner-label" }, "惩罚单量")
- ]),
- vue.createElementVNode("view", { class: "banner-item" }, [
- vue.createElementVNode("text", { class: "banner-num" }, [
- vue.createTextVNode("158"),
- vue.createElementVNode("text", { class: "banner-unit" }, "天")
- ]),
- vue.createElementVNode("text", { class: "banner-label" }, "服务时长")
- ])
- ]),
- vue.createElementVNode("view", { class: "tab-bar" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.tabs, (tab, idx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: vue.normalizeClass(["tab-item", { active: $data.activeTab === idx }]),
- key: idx,
- onClick: ($event) => $options.switchTab(idx)
- }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(tab),
- 1
- /* TEXT */
- ),
- $data.activeTab === idx ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ], 10, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "order-scroll"
- }, [
- vue.createElementVNode("view", { style: { "height": "16rpx" } }),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($options.filteredOrders, (order, idx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "order-card",
- key: idx
- }, [
- vue.createElementVNode("view", { class: "card-header" }, [
- vue.createElementVNode("view", { class: "type-badge" }, [
- vue.createElementVNode("image", {
- class: "type-icon",
- src: order.typeIcon
- }, null, 8, ["src"]),
- vue.createElementVNode(
- "text",
- { class: "type-text" },
- vue.toDisplayString(order.typeName),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["status-text", order.status === "完成" ? "green" : "red"])
- },
- vue.toDisplayString(order.status === "完成" ? "完成:" : "拒绝:") + vue.toDisplayString(order.finishTime),
- 3
- /* TEXT, CLASS */
- )
- ]),
- vue.createElementVNode(
- "text",
- { class: "service-time" },
- "服务时间:" + vue.toDisplayString(order.serviceTime),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("view", { class: "pet-card" }, [
- vue.createElementVNode("image", {
- class: "pet-avatar",
- src: order.petAvatar,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "pet-info" }, [
- vue.createElementVNode(
- "text",
- { class: "pet-name" },
- vue.toDisplayString(order.petName),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "pet-breed" },
- "品种: " + vue.toDisplayString(order.petBreed),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode(
- "text",
- { class: "pet-price" },
- "¥" + vue.toDisplayString(order.price),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "route-info" }, [
- order.orderType === 1 ? (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 0 },
- [
- vue.createElementVNode("view", { class: "route-item" }, [
- vue.createElementVNode("view", { class: "icon-circle pickup" }, "取"),
- vue.createElementVNode("view", { class: "route-connector" }),
- vue.createElementVNode("view", { class: "address-box" }, [
- vue.createElementVNode(
- "text",
- { class: "addr-title" },
- vue.toDisplayString(order.startName),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "addr-desc" },
- vue.toDisplayString(order.startAddr),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", { class: "route-item" }, [
- vue.createElementVNode("view", { class: "icon-circle deliver" }, "送"),
- vue.createElementVNode("view", { class: "address-box" }, [
- vue.createElementVNode(
- "text",
- { class: "addr-title" },
- vue.toDisplayString(order.endName),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "addr-desc" },
- vue.toDisplayString(order.endAddr),
- 1
- /* TEXT */
- )
- ])
- ])
- ],
- 64
- /* STABLE_FRAGMENT */
- )) : (vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- { key: 1 },
- [
- vue.createElementVNode("view", { class: "route-item" }, [
- vue.createElementVNode("view", { class: "icon-circle service" }, "服"),
- vue.createElementVNode("view", { class: "address-box" }, [
- vue.createElementVNode(
- "text",
- { class: "addr-title" },
- vue.toDisplayString(order.endName),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "addr-desc" },
- vue.toDisplayString(order.endAddr),
- 1
- /* TEXT */
- )
- ])
- ]),
- order.serviceNote ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "service-note-row"
- }, [
- vue.createElementVNode(
- "text",
- { class: "service-note-text" },
- "服务内容:" + vue.toDisplayString(order.serviceNote),
- 1
- /* TEXT */
- )
- ])) : vue.createCommentVNode("v-if", true)
- ],
- 64
- /* STABLE_FRAGMENT */
- ))
- ])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- $options.filteredOrders.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "empty-state"
- }, [
- vue.createElementVNode("text", { class: "empty-text" }, "暂无相关订单")
- ])) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("view", { style: { "height": "40rpx" } })
- ])
- ]);
- }
- const PagesMineOrderStats = /* @__PURE__ */ _export_sfc(_sfc_main$o, [["render", _sfc_render$n], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/order-stats.vue"]]);
- const _sfc_main$n = {
- data() {
- return {
- tabs: ["全部", "奖励", "惩罚"],
- activeTab: 0,
- selectedYear: 2026,
- selectedMonth: 2,
- // 月份选择器状态
- showMonthPicker: false,
- pickerYear: 2026,
- pickerMonth: 2,
- years: [2021, 2022, 2023, 2024, 2025, 2026],
- months: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12],
- yearScrollTop: 0,
- monthScrollTop: 0,
- // 奖惩记录列表
- records: [
- { date: "09-01", title: "单量奖励", desc: "超140单", amount: 560, status: "待入账", statusClass: "pending", type: "reward" },
- { date: "08-01", title: "单量奖励", desc: "超470单", amount: 2050, status: "已入账", statusClass: "credited", type: "reward" },
- { date: "09-02", title: "超时扣款", desc: "订单#T982 超时30分钟", amount: -15, status: "已扣款", statusClass: "deducted", type: "penalty" },
- { date: "09-05", title: "高温补贴", desc: "8月份高温天气补贴", amount: 300, status: "已入账", statusClass: "credited", type: "reward" }
- ]
- };
- },
- computed: {
- filteredList() {
- if (this.activeTab === 0)
- return this.records;
- if (this.activeTab === 1)
- return this.records.filter((r) => r.type === "reward");
- return this.records.filter((r) => r.type === "penalty");
- }
- },
- methods: {
- switchTab(idx) {
- this.activeTab = idx;
- },
- openMonthPicker() {
- this.pickerYear = this.selectedYear;
- this.pickerMonth = this.selectedMonth;
- this.showMonthPicker = true;
- },
- closeMonthPicker() {
- this.showMonthPicker = false;
- },
- confirmMonthPicker() {
- this.selectedYear = this.pickerYear;
- this.selectedMonth = this.pickerMonth;
- this.closeMonthPicker();
- },
- goToAll() {
- uni.navigateTo({ url: "/pages/mine/rewards-all" });
- }
- }
- };
- function _sfc_render$m(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "top-banner" }, [
- vue.createElementVNode("view", {
- class: "month-btn",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.openMonthPicker && $options.openMonthPicker(...args))
- }, [
- vue.createElementVNode(
- "text",
- { class: "month-text" },
- vue.toDisplayString($data.selectedYear) + "年" + vue.toDisplayString($data.selectedMonth) + "月 ▾",
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "stats-grid" }, [
- vue.createElementVNode("view", { class: "stats-cell" }, [
- vue.createElementVNode("text", { class: "stats-label" }, "奖励订单"),
- vue.createElementVNode("text", { class: "stats-num" }, [
- vue.createTextVNode("3"),
- vue.createElementVNode("text", { class: "stats-unit" }, "单")
- ]),
- vue.createElementVNode("view", { class: "stats-divider" }),
- vue.createElementVNode("text", { class: "stats-sub" }, "累计 1258单")
- ]),
- vue.createElementVNode("view", { class: "stats-cell" }, [
- vue.createElementVNode("text", { class: "stats-label" }, "惩罚订单"),
- vue.createElementVNode("text", { class: "stats-num" }, [
- vue.createTextVNode("1"),
- vue.createElementVNode("text", { class: "stats-unit" }, "单")
- ]),
- vue.createElementVNode("view", { class: "stats-divider" }),
- vue.createElementVNode("text", { class: "stats-sub" }, "累计 12单")
- ]),
- vue.createElementVNode("view", { class: "stats-cell" }, [
- vue.createElementVNode("text", { class: "stats-label" }, "奖励金额"),
- vue.createElementVNode("text", { class: "stats-num reward-num" }, "2910.00"),
- vue.createElementVNode("view", { class: "stats-divider" }),
- vue.createElementVNode("text", { class: "stats-sub" }, "累计 45800.00")
- ]),
- vue.createElementVNode("view", { class: "stats-cell" }, [
- vue.createElementVNode("text", { class: "stats-label" }, "惩罚金额"),
- vue.createElementVNode("text", { class: "stats-num penalty-num" }, "-15.00"),
- vue.createElementVNode("view", { class: "stats-divider" }),
- vue.createElementVNode("text", { class: "stats-sub" }, "累计 350.00")
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "list-header" }, [
- vue.createElementVNode("view", { class: "tab-bar" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.tabs, (tab, idx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: vue.normalizeClass(["tab-item", { active: $data.activeTab === idx }]),
- key: idx,
- onClick: ($event) => $options.switchTab(idx)
- }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(tab),
- 1
- /* TEXT */
- ),
- $data.activeTab === idx ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ], 10, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("view", {
- class: "view-all-btn",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.goToAll && $options.goToAll(...args))
- }, [
- vue.createElementVNode("text", { class: "view-all-text" }, "查看全部 ›")
- ])
- ]),
- vue.createElementVNode("view", { class: "record-list" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($options.filteredList, (item, idx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "record-item",
- key: idx
- }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["ri-icon", item.amount > 0 ? "ri-reward" : "ri-penalty"])
- },
- [
- vue.createElementVNode("text", { class: "ri-icon-text" }, "¥")
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode("view", { class: "ri-content" }, [
- vue.createElementVNode("view", { class: "ri-title-row" }, [
- vue.createElementVNode(
- "text",
- { class: "ri-date" },
- vue.toDisplayString(item.date),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "ri-title" },
- vue.toDisplayString(item.title),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode(
- "text",
- { class: "ri-desc" },
- vue.toDisplayString(item.desc),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "ri-right" }, [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["ri-amount", item.amount > 0 ? "positive" : "negative"])
- },
- vue.toDisplayString(item.amount > 0 ? "+" : "") + vue.toDisplayString(item.amount.toFixed(2)),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["ri-status", item.statusClass])
- },
- vue.toDisplayString(item.status),
- 3
- /* TEXT, CLASS */
- )
- ])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("text", { class: "more-hint" }, "更多记录请点击上方的查看全部")
- ]),
- $data.showMonthPicker ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "picker-mask",
- onClick: _cache[7] || (_cache[7] = (...args) => $options.closeMonthPicker && $options.closeMonthPicker(...args))
- }, [
- vue.createElementVNode("view", {
- class: "picker-sheet",
- onClick: _cache[6] || (_cache[6] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "picker-header" }, [
- vue.createElementVNode("text", {
- class: "picker-cancel",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.closeMonthPicker && $options.closeMonthPicker(...args))
- }, "取消"),
- vue.createElementVNode("text", { class: "picker-title" }, "选择时间"),
- vue.createElementVNode("text", {
- class: "picker-confirm",
- onClick: _cache[3] || (_cache[3] = (...args) => $options.confirmMonthPicker && $options.confirmMonthPicker(...args))
- }, "确定")
- ]),
- vue.createElementVNode("view", { class: "picker-body" }, [
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "picker-column",
- "scroll-top": $data.yearScrollTop,
- onScroll: _cache[4] || (_cache[4] = (...args) => _ctx.onYearScroll && _ctx.onYearScroll(...args))
- }, [
- vue.createElementVNode("view", { style: { "height": "80rpx" } }),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.years, (year) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: vue.normalizeClass(["picker-col-item", { "picker-selected": $data.pickerYear === year }]),
- key: year,
- onClick: ($event) => $data.pickerYear = year
- }, vue.toDisplayString(year) + "年", 11, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("view", { style: { "height": "80rpx" } })
- ], 40, ["scroll-top"]),
- vue.createElementVNode("view", { class: "picker-highlight" }),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "picker-column",
- "scroll-top": $data.monthScrollTop,
- onScroll: _cache[5] || (_cache[5] = (...args) => _ctx.onMonthScroll && _ctx.onMonthScroll(...args))
- }, [
- vue.createElementVNode("view", { style: { "height": "80rpx" } }),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.months, (month) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: vue.normalizeClass(["picker-col-item", { "picker-selected": $data.pickerMonth === month }]),
- key: month,
- onClick: ($event) => $data.pickerMonth = month
- }, vue.toDisplayString(month) + "月", 11, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("view", { style: { "height": "80rpx" } })
- ], 40, ["scroll-top"])
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true)
- ]);
- }
- const PagesMineRewards = /* @__PURE__ */ _export_sfc(_sfc_main$n, [["render", _sfc_render$m], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/rewards.vue"]]);
- const _sfc_main$m = {
- data() {
- return {
- tabs: ["全部", "奖励", "惩罚"],
- activeTab: 0,
- // 所有完整记录(按月分组)
- allGroups: [
- {
- month: 9,
- credited: 30,
- pending: 0,
- items: [
- { date: "09-24", title: "高温补贴", desc: "9月份高温天气补贴", amount: 30, status: "已入账", statusClass: "credited", type: "reward" }
- ]
- },
- {
- month: 8,
- credited: 2610,
- pending: 0,
- items: [
- { date: "08-01", title: "单量奖励", desc: "超140单", amount: 560, status: "已入账", statusClass: "credited", type: "reward" },
- { date: "07-01", title: "单量奖励", desc: "超470单", amount: 2050, status: "已入账", statusClass: "credited", type: "reward" }
- ]
- },
- {
- month: 7,
- credited: 0,
- pending: 0,
- items: [
- { date: "07-15", title: "超时扣款", desc: "订单#T98211 超时30分钟", amount: -15, status: "已扣款", statusClass: "deducted", type: "penalty" },
- { date: "07-20", title: "客诉扣款", desc: "订单#T98222 餐品遗漏", amount: -50, status: "已扣款", statusClass: "deducted", type: "penalty" }
- ]
- }
- ]
- };
- },
- computed: {
- filteredGroups() {
- if (this.activeTab === 0)
- return this.allGroups;
- const typeKey = this.activeTab === 1 ? "reward" : "penalty";
- return this.allGroups.map((g) => ({
- ...g,
- items: g.items.filter((i) => i.type === typeKey)
- })).filter((g) => g.items.length > 0);
- }
- },
- methods: {
- switchTab(idx) {
- this.activeTab = idx;
- }
- }
- };
- function _sfc_render$l(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "tab-bar" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.tabs, (tab, idx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: vue.normalizeClass(["tab-item", { active: $data.activeTab === idx }]),
- key: idx,
- onClick: ($event) => $options.switchTab(idx)
- }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(tab),
- 1
- /* TEXT */
- ),
- $data.activeTab === idx ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ], 10, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "main-scroll"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($options.filteredGroups, (group, gIdx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- key: gIdx,
- class: "month-group"
- }, [
- vue.createElementVNode("view", { class: "month-header" }, [
- vue.createElementVNode(
- "text",
- { class: "month-title" },
- vue.toDisplayString(group.month) + "月",
- 1
- /* TEXT */
- ),
- vue.createElementVNode("view", { class: "month-summary" }, [
- vue.createElementVNode(
- "text",
- { class: "month-sum-text" },
- "已入账¥" + vue.toDisplayString(group.credited.toFixed(2)),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "month-sum-text" },
- " 待入账¥" + vue.toDisplayString(group.pending.toFixed(2)),
- 1
- /* TEXT */
- )
- ])
- ]),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(group.items, (item, rIdx) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "record-item",
- key: rIdx
- }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["ri-icon", item.amount > 0 ? "ri-reward" : "ri-penalty"])
- },
- [
- vue.createElementVNode("text", { class: "ri-icon-text" }, "¥")
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode("view", { class: "ri-content" }, [
- vue.createElementVNode("view", { class: "ri-title-row" }, [
- vue.createElementVNode(
- "text",
- { class: "ri-date" },
- vue.toDisplayString(item.date),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "ri-title" },
- vue.toDisplayString(item.title),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode(
- "text",
- { class: "ri-desc" },
- vue.toDisplayString(item.desc),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "ri-right" }, [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["ri-amount", item.amount > 0 ? "positive" : "negative"])
- },
- vue.toDisplayString(item.amount > 0 ? "+" : "") + vue.toDisplayString(item.amount.toFixed(2)),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["ri-status", item.statusClass])
- },
- vue.toDisplayString(item.status),
- 3
- /* TEXT, CLASS */
- )
- ])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("view", { style: { "height": "40rpx" } })
- ])
- ]);
- }
- const PagesMineRewardsAll = /* @__PURE__ */ _export_sfc(_sfc_main$m, [["render", _sfc_render$l], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/rewards-all.vue"]]);
- const logic = {
- components: {
- customTabbar
- },
- data() {
- return {
- showServicePopup: false,
- showLogoutPopup: false,
- profile: null,
- profileLoading: false
- };
- },
- onShow() {
- uni.hideTabBar();
- if (isLoggedIn()) {
- this.loadProfile();
- }
- },
- methods: {
- async loadProfile() {
- if (this.profileLoading)
- return;
- this.profileLoading = true;
- try {
- const res = await getMyProfile();
- this.profile = res.data || null;
- } catch (err) {
- formatAppLog("error", "at pages/mine/logic.js:32", "获取个人信息失败:", err);
- } finally {
- this.profileLoading = false;
- }
- },
- navToSettings() {
- uni.navigateTo({
- url: "/pages/mine/settings/index"
- });
- },
- navToProfile() {
- uni.navigateTo({
- url: "/pages/mine/settings/profile/index"
- });
- },
- navToLevel() {
- uni.navigateTo({
- url: "/pages/mine/level/index"
- });
- },
- navToNotification() {
- uni.navigateTo({
- url: "/pages/mine/message/index"
- });
- },
- navToWallet() {
- uni.navigateTo({
- url: "/pages/mine/wallet/index"
- });
- },
- navToPoints() {
- uni.navigateTo({
- url: "/pages/mine/points/index"
- });
- },
- navToOrderStats() {
- uni.navigateTo({
- url: "/pages/mine/order-stats"
- });
- },
- navToRewards() {
- uni.navigateTo({
- url: "/pages/mine/rewards"
- });
- },
- openServicePopup() {
- this.showServicePopup = true;
- },
- closeServicePopup() {
- this.showServicePopup = false;
- },
- previewQRCode() {
- uni.previewImage({
- urls: ["/static/logo.png"]
- });
- },
- openOnlineService() {
- uni.showToast({
- title: "正在跳转企业微信客服...",
- icon: "none"
- });
- },
- callServicePhone() {
- uni.makePhoneCall({
- phoneNumber: "400-123-4567"
- });
- },
- logout() {
- this.showLogoutPopup = true;
- },
- cancelLogout() {
- this.showLogoutPopup = false;
- },
- async confirmLogout() {
- this.showLogoutPopup = false;
- try {
- await logout();
- } catch (e) {
- }
- clearAuth();
- uni.reLaunch({
- url: "/pages/login/login"
- });
- }
- }
- };
- const _imports_0$1 = "/static/icons/motorbike.svg";
- const _imports_1$5 = "/static/icons/location.svg";
- const _imports_0 = "/static/icons/chevron_right_dark.svg";
- const _imports_3$1 = "/static/icons/calendar.svg";
- const _imports_4 = "/static/icons/settings.svg";
- const _imports_1$4 = "/static/icons/crown.svg";
- const _imports_6 = "/static/icons/chevron_right_gold.svg";
- const _imports_3 = "/static/icons/chevron_right.svg";
- const _imports_8 = "/static/icons/bell_linear.svg";
- const _imports_9 = "/static/icons/money_linear.svg";
- const _imports_10 = "/static/icons/headset_linear.svg";
- const _imports_11 = "/static/icons/close_gray.svg";
- const _imports_13 = "/static/icons/headset_green.svg";
- const _imports_15 = "/static/icons/phone_green.svg";
- const _sfc_main$l = {
- ...logic
- };
- function _sfc_render$k(_ctx, _cache, $props, $setup, $data, $options) {
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n;
- const _component_custom_tabbar = vue.resolveComponent("custom-tabbar");
- return vue.openBlock(), vue.createElementBlock(
- vue.Fragment,
- null,
- [
- vue.createElementVNode("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "nav-bg" }, [
- vue.createElementVNode("view", { class: "bg-circle-1" }),
- vue.createElementVNode("view", { class: "bg-circle-2" })
- ]),
- vue.createElementVNode("view", { class: "header-section" }, [
- vue.createElementVNode("view", { class: "title-bar" }, "个人中心"),
- vue.createElementVNode("view", {
- class: "user-card",
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.navToProfile && _ctx.navToProfile(...args))
- }, [
- vue.createElementVNode("image", {
- class: "avatar",
- src: ((_a = _ctx.profile) == null ? void 0 : _a.avatarUrl) || "/static/touxiang.png",
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "info-content" }, [
- vue.createElementVNode("view", { class: "name-row" }, [
- vue.createElementVNode(
- "text",
- { class: "name" },
- vue.toDisplayString(((_b = _ctx.profile) == null ? void 0 : _b.name) || "未登录"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("view", { class: "tags" }, [
- ((_c = _ctx.profile) == null ? void 0 : _c.status) === "0" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tag green"
- }, "接单中")) : ((_d = _ctx.profile) == null ? void 0 : _d.status) === "1" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "tag green"
- }, "休息中")) : ((_e = _ctx.profile) == null ? void 0 : _e.status) === "2" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 2,
- class: "tag",
- style: { "background": "#eee", "color": "#999" }
- }, "已禁用")) : vue.createCommentVNode("v-if", true),
- ((_f = _ctx.profile) == null ? void 0 : _f.workType) === "full_time" ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 3,
- class: "tag blue"
- }, "全职")) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("image", {
- class: "bike-icon",
- src: _imports_0$1
- })
- ])
- ]),
- vue.createElementVNode("view", { class: "detail-row" }, [
- vue.createElementVNode("image", {
- class: "small-icon",
- src: _imports_1$5
- }),
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(((_g = _ctx.profile) == null ? void 0 : _g.stationName) || ((_h = _ctx.profile) == null ? void 0 : _h.cityName) || "暂无站点"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("image", {
- class: "arrow-icon-small",
- src: _imports_0
- })
- ]),
- vue.createElementVNode("view", { class: "detail-row" }, [
- vue.createElementVNode("image", {
- class: "small-icon",
- src: _imports_3$1
- }),
- vue.createElementVNode(
- "text",
- null,
- "已注册" + vue.toDisplayString(((_i = _ctx.profile) == null ? void 0 : _i.registerDays) || 0) + "天",
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("image", {
- class: "settings-icon",
- src: _imports_4,
- onClick: _cache[0] || (_cache[0] = vue.withModifiers((...args) => _ctx.navToSettings && _ctx.navToSettings(...args), ["stop"]))
- })
- ]),
- vue.createElementVNode("view", { class: "vip-card" }, [
- vue.createElementVNode("view", { class: "vip-left" }, [
- vue.createElementVNode("image", {
- class: "vip-icon",
- src: _imports_1$4
- }),
- vue.createElementVNode("view", { class: "vip-text" }, [
- vue.createElementVNode(
- "text",
- { class: "vip-title" },
- vue.toDisplayString(((_j = _ctx.profile) == null ? void 0 : _j.levelName) || "普通履约者"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "vip-desc" },
- vue.toDisplayString(((_k = _ctx.profile) == null ? void 0 : _k.levelDesc) || "完成更多订单即可升级"),
- 1
- /* TEXT */
- )
- ])
- ]),
- vue.createElementVNode("view", {
- class: "vip-btn",
- onClick: _cache[2] || (_cache[2] = (...args) => _ctx.navToLevel && _ctx.navToLevel(...args))
- }, [
- vue.createElementVNode("text", null, "查看权益"),
- vue.createElementVNode("image", {
- class: "arrow-icon-small",
- src: _imports_6
- })
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "stats-panel" }, [
- vue.createElementVNode("view", {
- class: "stat-item",
- onClick: _cache[3] || (_cache[3] = (...args) => _ctx.navToWallet && _ctx.navToWallet(...args))
- }, [
- vue.createElementVNode("view", { class: "stat-header" }, [
- vue.createElementVNode("view", { class: "red-bar" }),
- vue.createElementVNode("text", { class: "label" }, "我的钱包"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ]),
- vue.createElementVNode("view", { class: "stat-value" }, [
- vue.createElementVNode(
- "text",
- { class: "num" },
- vue.toDisplayString(((_l = _ctx.profile) == null ? void 0 : _l.balance) ? (_ctx.profile.balance / 100).toFixed(2) : "0.00"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", { class: "unit" }, "元")
- ]),
- vue.createElementVNode("text", { class: "sub-text" }, "账户余额")
- ]),
- vue.createElementVNode("view", { class: "divider" }),
- vue.createElementVNode("view", {
- class: "stat-item",
- onClick: _cache[4] || (_cache[4] = (...args) => _ctx.navToOrderStats && _ctx.navToOrderStats(...args))
- }, [
- vue.createElementVNode("view", { class: "stat-header" }, [
- vue.createElementVNode("view", { class: "green-bar" }),
- vue.createElementVNode("text", { class: "label" }, "订单统计"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ]),
- vue.createElementVNode("view", { class: "stat-value" }, [
- vue.createElementVNode(
- "text",
- { class: "num" },
- vue.toDisplayString(((_m = _ctx.profile) == null ? void 0 : _m.orderCount) || 0),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", { class: "unit" }, "单")
- ]),
- vue.createElementVNode("text", { class: "sub-text" }, "累计服务单量")
- ]),
- vue.createElementVNode("view", { class: "divider" }),
- vue.createElementVNode("view", {
- class: "stat-item",
- onClick: _cache[5] || (_cache[5] = (...args) => _ctx.navToPoints && _ctx.navToPoints(...args))
- }, [
- vue.createElementVNode("view", { class: "stat-header" }, [
- vue.createElementVNode("view", { class: "orange-bar" }),
- vue.createElementVNode("text", { class: "label" }, "我的积分"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ]),
- vue.createElementVNode("view", { class: "stat-value" }, [
- vue.createElementVNode(
- "text",
- { class: "num" },
- vue.toDisplayString(((_n = _ctx.profile) == null ? void 0 : _n.points) || 0),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("text", { class: "unit" }, "分")
- ]),
- vue.createElementVNode("text", { class: "sub-text" }, "可兑换权益")
- ])
- ]),
- vue.createElementVNode("view", { class: "menu-list" }, [
- vue.createElementVNode("view", {
- class: "menu-item",
- onClick: _cache[6] || (_cache[6] = (...args) => _ctx.navToNotification && _ctx.navToNotification(...args))
- }, [
- vue.createElementVNode("image", {
- class: "menu-icon",
- src: _imports_8
- }),
- vue.createElementVNode("text", { class: "menu-text" }, "消息中心"),
- vue.createElementVNode("view", { class: "menu-right" }, [
- vue.createElementVNode("view", { class: "red-dot" }),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", {
- class: "menu-item",
- onClick: _cache[7] || (_cache[7] = (...args) => _ctx.navToRewards && _ctx.navToRewards(...args))
- }, [
- vue.createElementVNode("image", {
- class: "menu-icon",
- src: _imports_9
- }),
- vue.createElementVNode("text", { class: "menu-text" }, "我的奖惩"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ]),
- vue.createElementVNode("view", {
- class: "menu-item",
- onClick: _cache[8] || (_cache[8] = (...args) => _ctx.openServicePopup && _ctx.openServicePopup(...args))
- }, [
- vue.createElementVNode("image", {
- class: "menu-icon",
- src: _imports_10
- }),
- vue.createElementVNode("text", { class: "menu-text" }, "联系客服"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", {
- class: "logout-btn",
- onClick: _cache[9] || (_cache[9] = (...args) => _ctx.logout && _ctx.logout(...args))
- }, "退出登录"),
- vue.createElementVNode("view", { class: "dev-tip" }, "本APP部分功能开发当中,请只进行修改个人信息、修改设置、完成订单流程操作"),
- _ctx.showServicePopup ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "service-popup-mask",
- onClick: _cache[15] || (_cache[15] = (...args) => _ctx.closeServicePopup && _ctx.closeServicePopup(...args))
- }, [
- vue.createElementVNode("view", {
- class: "service-popup",
- onClick: _cache[14] || (_cache[14] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "service-header" }, [
- vue.createElementVNode("text", { class: "service-title" }, "联系客服"),
- vue.createElementVNode("image", {
- class: "close-icon",
- src: _imports_11,
- onClick: _cache[10] || (_cache[10] = (...args) => _ctx.closeServicePopup && _ctx.closeServicePopup(...args))
- })
- ]),
- vue.createElementVNode("view", { class: "qr-section" }, [
- vue.createElementVNode("text", { class: "qr-title" }, "客服二维码"),
- vue.createElementVNode("image", {
- class: "qr-img",
- src: _imports_1$8,
- onClick: _cache[11] || (_cache[11] = (...args) => _ctx.previewQRCode && _ctx.previewQRCode(...args))
- }),
- vue.createElementVNode("text", { class: "qr-desc" }, "点击查看大图")
- ]),
- vue.createElementVNode("view", { class: "service-list" }, [
- vue.createElementVNode("view", {
- class: "service-row",
- onClick: _cache[12] || (_cache[12] = (...args) => _ctx.openOnlineService && _ctx.openOnlineService(...args))
- }, [
- vue.createElementVNode("image", {
- class: "service-row-icon",
- src: _imports_13
- }),
- vue.createElementVNode("view", { class: "service-info" }, [
- vue.createElementVNode("text", { class: "service-name" }, "在线客服"),
- vue.createElementVNode("text", { class: "service-desc" }, "企业微信专属客服在线解答")
- ]),
- vue.createElementVNode("image", {
- class: "arrow-icon-small",
- src: _imports_3
- })
- ]),
- vue.createElementVNode("view", { class: "service-row" }, [
- vue.createElementVNode("image", {
- class: "service-row-icon",
- src: _imports_14
- }),
- vue.createElementVNode("view", { class: "service-info" }, [
- vue.createElementVNode("text", { class: "service-name" }, "客服电话"),
- vue.createElementVNode("text", { class: "service-desc" }, "400-123-4567")
- ]),
- vue.createElementVNode("view", {
- class: "call-btn",
- onClick: _cache[13] || (_cache[13] = (...args) => _ctx.callServicePhone && _ctx.callServicePhone(...args))
- }, [
- vue.createElementVNode("image", {
- class: "phone-icon-small",
- src: _imports_15
- }),
- vue.createElementVNode("text", null, "拨打")
- ])
- ])
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["logout-popup-mask", { "show": _ctx.showLogoutPopup }]),
- onClick: _cache[19] || (_cache[19] = (...args) => _ctx.cancelLogout && _ctx.cancelLogout(...args)),
- onTouchmove: _cache[20] || (_cache[20] = vue.withModifiers(() => {
- }, ["stop", "prevent"]))
- },
- [
- vue.createElementVNode("view", {
- class: "popup-modal",
- onClick: _cache[18] || (_cache[18] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("text", { class: "popup-title" }, "退出登录"),
- vue.createElementVNode("text", { class: "popup-desc" }, "确定要退出当前账号吗?\\n退出后需要重新登录才能使用完整功能。"),
- vue.createElementVNode("view", { class: "popup-actions" }, [
- vue.createElementVNode("view", {
- class: "popup-btn cancel",
- onClick: _cache[16] || (_cache[16] = (...args) => _ctx.cancelLogout && _ctx.cancelLogout(...args))
- }, "取消"),
- vue.createElementVNode("view", {
- class: "popup-btn confirm",
- onClick: _cache[17] || (_cache[17] = (...args) => _ctx.confirmLogout && _ctx.confirmLogout(...args))
- }, "确定")
- ])
- ])
- ],
- 34
- /* CLASS, NEED_HYDRATION */
- )
- ]),
- vue.createVNode(_component_custom_tabbar, { currentPath: "pages/mine/index" })
- ],
- 64
- /* STABLE_FRAGMENT */
- );
- }
- const PagesMineIndex = /* @__PURE__ */ _export_sfc(_sfc_main$l, [["render", _sfc_render$k], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/index.vue"]]);
- const _sfc_main$k = {
- data() {
- return {};
- },
- methods: {
- navBack() {
- uni.navigateBack({
- delta: 1
- });
- },
- navTo(type) {
- let url = "";
- switch (type) {
- case "profile":
- url = "/pages/mine/settings/profile/index";
- break;
- case "auth":
- url = "/pages/mine/settings/auth/index";
- break;
- case "bank":
- url = "/pages/mine/settings/bank/index";
- break;
- case "security":
- url = "/pages/mine/settings/security/index";
- break;
- case "push":
- url = "/pages/mine/settings/notification/index";
- break;
- case "about":
- url = "/pages/mine/settings/about/index";
- break;
- default:
- formatAppLog("log", "at pages/mine/settings/index.vue:104", "Navigate to:", type);
- return;
- }
- uni.navigateTo({ url });
- },
- clearCache() {
- uni.showToast({ title: "缓存已清理", icon: "none" });
- }
- }
- };
- function _sfc_render$j(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "设置"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "group-card" }, [
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[1] || (_cache[1] = ($event) => $options.navTo("profile"))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "个人资料"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ]),
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[2] || (_cache[2] = ($event) => $options.navTo("auth"))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "认证信息"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ]),
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[3] || (_cache[3] = ($event) => $options.navTo("bank"))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "银行卡信息"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode("view", { class: "tag-status" }, "已完善"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", {
- class: "list-item no-border",
- onClick: _cache[4] || (_cache[4] = ($event) => $options.navTo("security"))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "账号与安全"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", { class: "group-card" }, [
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[5] || (_cache[5] = ($event) => $options.navTo("push"))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "推送通知"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode("text", { class: "item-value" }, "部分开启"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", { class: "list-item" }, [
- vue.createElementVNode("view", { class: "item-row-left" }, [
- vue.createElementVNode("text", { class: "item-title" }, "位置上报"),
- vue.createElementVNode("text", { class: "item-subtitle" }, "每隔20分钟自动上报位置")
- ]),
- vue.createElementVNode("switch", {
- checked: "",
- color: "#FF5722",
- style: { "transform": "scale(0.8)" }
- })
- ]),
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[6] || (_cache[6] = (...args) => $options.clearCache && $options.clearCache(...args))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "清理缓存"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode("text", { class: "item-value" }, "105.14MB"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", {
- class: "list-item no-border",
- onClick: _cache[7] || (_cache[7] = ($event) => $options.navTo("about"))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "关于我们"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode("text", { class: "item-value" }, "v2.0.6"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ])
- ])
- ]);
- }
- const PagesMineSettingsIndex = /* @__PURE__ */ _export_sfc(_sfc_main$k, [["render", _sfc_render$j], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/index.vue"]]);
- const _sfc_main$j = {
- data() {
- return {
- userInfo: {
- name: "",
- workType: "",
- workStatus: "",
- city: "",
- avatar: "/static/touxiang.png",
- stationName: ""
- },
- isStatusPickerShow: false,
- isCityPickerShow: false,
- // 城市级联选择器(与我要加入页面一致)
- selectStep: 0,
- selectedPathway: [],
- currentCityList: [],
- selectedCityId: null
- };
- },
- onLoad() {
- this.loadUserInfo();
- uni.$on("updateName", (newName) => {
- this.userInfo.name = newName;
- });
- },
- onUnload() {
- uni.$off("updateName");
- },
- methods: {
- // 加载用户信息 @author steelwei
- async loadUserInfo() {
- uni.showLoading({ title: "加载中..." });
- try {
- const res = await getMyProfile();
- if (res.code === 200) {
- const data = res.data;
- this.userInfo = {
- name: data.realName || data.name,
- workType: data.workType === "full_time" ? "全职" : "兼职",
- workStatus: this.formatStatus(data.status),
- city: data.cityName || "",
- avatar: data.avatarUrl || "/static/touxiang.png",
- stationName: data.stationName || "未分配站点"
- };
- } else {
- uni.showToast({ title: res.msg || "加载失败", icon: "none" });
- }
- } catch (error) {
- formatAppLog("error", "at pages/mine/settings/profile/index.vue:173", "加载用户信息失败:", error);
- uni.showToast({ title: "网络错误", icon: "none" });
- } finally {
- uni.hideLoading();
- }
- },
- // 格式化状态 @author steelwei
- formatStatus(status) {
- const statusMap = {
- "busy": "接单中",
- "resting": "休息中",
- "disabled": "已禁用"
- };
- return statusMap[status] || status;
- },
- navBack() {
- uni.navigateBack({ delta: 1 });
- },
- // 修改头像 @author steelwei
- changeAvatar() {
- uni.chooseImage({
- count: 1,
- success: async (res) => {
- const tempFilePath = res.tempFilePaths[0];
- uni.showLoading({ title: "上传中..." });
- try {
- const uploadRes = await uploadFile(tempFilePath);
- if (uploadRes.code === 200) {
- const { url, ossId } = uploadRes.data;
- const result = await updateAvatar(ossId);
- if (result.code === 200) {
- this.userInfo.avatar = url;
- uni.showToast({ title: "修改成功", icon: "success" });
- } else {
- uni.showToast({ title: result.msg || "修改失败", icon: "none" });
- }
- }
- } catch (error) {
- formatAppLog("error", "at pages/mine/settings/profile/index.vue:218", "修改头像失败:", error);
- uni.showToast({ title: "上传失败", icon: "none" });
- } finally {
- uni.hideLoading();
- }
- }
- });
- },
- editName() {
- uni.navigateTo({
- url: `/pages/mine/settings/profile/edit-name?name=${this.userInfo.name}`
- });
- },
- showStatusPicker() {
- this.isStatusPickerShow = true;
- },
- closeStatusPicker() {
- this.isStatusPickerShow = false;
- },
- // 选择状态 @author steelwei
- async selectStatus(statusText) {
- const statusMap = {
- "接单中": "busy",
- "休息中": "resting"
- };
- const status = statusMap[statusText];
- try {
- const res = await updateStatus(status);
- if (res.code === 200) {
- this.userInfo.workStatus = statusText;
- uni.showToast({ title: "状态已更新", icon: "success" });
- } else {
- uni.showToast({ title: res.msg || "修改失败", icon: "none" });
- }
- } catch (error) {
- formatAppLog("error", "at pages/mine/settings/profile/index.vue:258", "修改状态失败:", error);
- uni.showToast({ title: "网络错误", icon: "none" });
- } finally {
- this.closeStatusPicker();
- }
- },
- // 城市级联选择器(与我要加入页面一致) @author steelwei
- async showCityPicker() {
- this.isCityPickerShow = true;
- if (this.selectedPathway.length === 0) {
- await this.resetCityPicker();
- }
- },
- async resetCityPicker() {
- this.selectStep = 0;
- this.selectedPathway = [];
- await this.loadAreaChildren(0);
- },
- closeCityPicker() {
- this.isCityPickerShow = false;
- },
- async loadAreaChildren(parentId) {
- try {
- const res = await getAreaChildren(parentId);
- this.currentCityList = (res.data || []).filter((item) => item.type !== 2).map((item) => ({
- id: item.id,
- name: item.name,
- type: item.type,
- parentId: item.parentId
- }));
- } catch (err) {
- formatAppLog("error", "at pages/mine/settings/profile/index.vue:293", "加载区域数据失败:", err);
- this.currentCityList = [];
- }
- },
- async selectCityItem(item) {
- this.selectedPathway[this.selectStep] = item;
- if (item.type === 0) {
- this.selectStep++;
- this.selectedPathway = this.selectedPathway.slice(0, this.selectStep);
- await this.loadAreaChildren(item.id);
- if (this.currentCityList.length === 0) {
- this.selectedCityId = item.id;
- this.confirmCity();
- }
- } else {
- this.selectedCityId = item.id;
- this.confirmCity();
- }
- },
- async jumpToStep(step) {
- this.selectStep = step;
- if (step === 0) {
- await this.loadAreaChildren(0);
- } else {
- const parent = this.selectedPathway[step - 1];
- if (parent) {
- await this.loadAreaChildren(parent.id);
- }
- }
- },
- // 确认城市选择 @author steelwei
- async confirmCity() {
- if (this.selectedPathway.length === 0) {
- uni.showToast({ title: "请选择城市", icon: "none" });
- return;
- }
- const cityName = this.selectedPathway.map((i) => i.name).join(" ");
- const cityCode = String(this.selectedCityId);
- try {
- const res = await updateCity(cityCode, cityName);
- if (res.code === 200) {
- this.userInfo.city = cityName;
- uni.showToast({ title: "修改成功", icon: "success" });
- this.closeCityPicker();
- this.selectedPathway = [];
- } else {
- uni.showToast({ title: res.msg || "修改失败", icon: "none" });
- }
- } catch (error) {
- formatAppLog("error", "at pages/mine/settings/profile/index.vue:346", "修改城市失败:", error);
- uni.showToast({ title: "网络错误", icon: "none" });
- }
- }
- }
- };
- function _sfc_render$i(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "个人资料"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "group-card" }, [
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.changeAvatar && $options.changeAvatar(...args))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "头像"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode("image", {
- class: "user-avatar",
- src: $data.userInfo.avatar,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.editName && $options.editName(...args))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "真实姓名"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode(
- "text",
- { class: "item-value" },
- vue.toDisplayString($data.userInfo.name),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "group-card" }, [
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[3] || (_cache[3] = (...args) => $options.showStatusPicker && $options.showStatusPicker(...args))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "工作状态"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode(
- "text",
- { class: "item-value-black" },
- vue.toDisplayString($data.userInfo.workStatus),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "group-card" }, [
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[4] || (_cache[4] = (...args) => $options.showCityPicker && $options.showCityPicker(...args))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "工作城市"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode(
- "text",
- { class: "item-value" },
- vue.toDisplayString($data.userInfo.city),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", { class: "list-item no-border" }, [
- vue.createElementVNode("text", { class: "item-title" }, "所属站点"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode(
- "text",
- { class: "item-value" },
- vue.toDisplayString($data.userInfo.stationName || "未分配站点"),
- 1
- /* TEXT */
- )
- ])
- ])
- ]),
- $data.isStatusPickerShow ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "popup-mask",
- onClick: _cache[9] || (_cache[9] = (...args) => $options.closeStatusPicker && $options.closeStatusPicker(...args))
- }, [
- vue.createElementVNode("view", {
- class: "popup-content",
- onClick: _cache[8] || (_cache[8] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "popup-title" }, "选择工作状态"),
- vue.createElementVNode("view", {
- class: "popup-item",
- onClick: _cache[5] || (_cache[5] = ($event) => $options.selectStatus("接单中"))
- }, "接单中"),
- vue.createElementVNode("view", {
- class: "popup-item",
- onClick: _cache[6] || (_cache[6] = ($event) => $options.selectStatus("休息中"))
- }, "休息中"),
- vue.createElementVNode("view", {
- class: "popup-cancel",
- onClick: _cache[7] || (_cache[7] = (...args) => $options.closeStatusPicker && $options.closeStatusPicker(...args))
- }, "取消")
- ])
- ])) : vue.createCommentVNode("v-if", true),
- $data.isCityPickerShow ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "popup-mask",
- onClick: _cache[13] || (_cache[13] = (...args) => $options.closeCityPicker && $options.closeCityPicker(...args))
- }, [
- vue.createElementVNode("view", {
- class: "popup-content",
- onClick: _cache[12] || (_cache[12] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "popup-header-row" }, [
- vue.createElementVNode("text", {
- class: "popup-btn-cancel",
- onClick: _cache[10] || (_cache[10] = (...args) => $options.closeCityPicker && $options.closeCityPicker(...args))
- }, "取消"),
- vue.createElementVNode("text", { class: "popup-title-text" }, "请选择工作城市"),
- vue.createElementVNode("text", {
- class: "popup-btn-confirm",
- onClick: _cache[11] || (_cache[11] = (...args) => $options.confirmCity && $options.confirmCity(...args))
- }, "确定")
- ]),
- vue.createElementVNode("view", { class: "picker-body" }, [
- vue.createElementVNode("view", { class: "timeline-area" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.selectedPathway, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "timeline-item",
- key: index,
- onClick: ($event) => $options.jumpToStep(index)
- }, [
- vue.createElementVNode("view", { class: "timeline-dot" }),
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(item.name),
- 1
- /* TEXT */
- )
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- $data.selectStep === $data.selectedPathway.length ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "timeline-item active"
- }, [
- vue.createElementVNode("view", { class: "timeline-dot" }),
- vue.createElementVNode("text", null, "请选择")
- ])) : vue.createCommentVNode("v-if", true)
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "list-area"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.currentCityList, (item) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "list-item",
- key: item.id,
- onClick: ($event) => $options.selectCityItem(item)
- }, vue.toDisplayString(item.name), 9, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- $data.currentCityList.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- style: { "padding": "20rpx", "color": "#999" }
- }, " 无数据 ")) : vue.createCommentVNode("v-if", true)
- ])
- ])
- ])
- ])) : vue.createCommentVNode("v-if", true)
- ]);
- }
- const PagesMineSettingsProfileIndex = /* @__PURE__ */ _export_sfc(_sfc_main$j, [["render", _sfc_render$i], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/profile/index.vue"]]);
- const _sfc_main$i = {
- data() {
- return {
- authInfo: {
- realName: "",
- idCard: "",
- idCardFront: "",
- idCardBack: "",
- serviceTypes: [],
- authId: false,
- authQual: false,
- pendingAudit: false,
- qualImages: []
- }
- };
- },
- onLoad() {
- this.loadAuthInfo();
- },
- methods: {
- navBack() {
- uni.navigateBack({
- delta: 1
- });
- },
- async loadAuthInfo() {
- try {
- const res = await getAuthInfo();
- if (res.code === 200 && res.data) {
- this.authInfo = {
- realName: res.data.realName || "",
- idCard: res.data.idCard || "",
- idCardFront: res.data.idCardFrontUrl || "",
- idCardBack: res.data.idCardBackUrl || "",
- serviceTypes: res.data.serviceTypeList || [],
- authId: res.data.authId || false,
- authQual: res.data.authQual || false,
- pendingAudit: res.data.pendingAudit || false,
- qualImages: res.data.qualImageUrls ? res.data.qualImageUrls.split(",").filter(Boolean) : []
- };
- }
- } catch (e) {
- formatAppLog("error", "at pages/mine/settings/auth/index.vue:133", "加载认证信息失败", e);
- uni.showToast({ title: "加载失败", icon: "none" });
- }
- },
- maskIdCard(idCard) {
- if (!idCard || idCard.length < 8)
- return idCard;
- return idCard.substring(0, 4) + "**********" + idCard.substring(idCard.length - 4);
- },
- editAuth() {
- uni.showModal({
- title: "提示",
- content: "修改认证信息需要重新审核,审核期间无法接单,确定要继续吗?",
- success: (res) => {
- if (res.confirm) {
- uni.navigateTo({
- url: "/pages/mine/settings/auth/edit"
- });
- }
- }
- });
- }
- }
- };
- function _sfc_render$h(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "认证信息"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "card" }, [
- vue.createElementVNode("view", { class: "section-header" }, [
- vue.createElementVNode("view", { class: "orange-bar" }),
- vue.createElementVNode("text", { class: "section-title" }, "身份认证"),
- $data.authInfo.pendingAudit ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tag-orange"
- }, "认证中")) : $data.authInfo.authId ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "tag-green"
- }, "已认证")) : (vue.openBlock(), vue.createElementBlock("view", {
- key: 2,
- class: "tag-gray"
- }, "未认证"))
- ]),
- vue.createElementVNode("view", { class: "info-row" }, [
- vue.createElementVNode("text", { class: "label" }, "真实姓名"),
- vue.createElementVNode(
- "text",
- { class: "value" },
- vue.toDisplayString($data.authInfo.realName || "未设置"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "info-row" }, [
- vue.createElementVNode("text", { class: "label" }, "证件号码"),
- vue.createElementVNode(
- "text",
- { class: "value" },
- vue.toDisplayString($options.maskIdCard($data.authInfo.idCard) || "未设置"),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "id-card-row" }, [
- $data.authInfo.idCardFront ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "id-card-box green-bg"
- }, [
- vue.createElementVNode("image", {
- class: "id-card-img",
- src: $data.authInfo.idCardFront,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "corner-tag" }, "人像面")
- ])) : (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "id-card-box green-bg"
- }, [
- vue.createElementVNode("text", { class: "id-text" }, "ID Front"),
- vue.createElementVNode("view", { class: "corner-tag" }, "人像面")
- ])),
- $data.authInfo.idCardBack ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 2,
- class: "id-card-box green-bg"
- }, [
- vue.createElementVNode("image", {
- class: "id-card-img",
- src: $data.authInfo.idCardBack,
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", { class: "corner-tag" }, "国徽面")
- ])) : (vue.openBlock(), vue.createElementBlock("view", {
- key: 3,
- class: "id-card-box green-bg"
- }, [
- vue.createElementVNode("text", { class: "id-text" }, "ID Back"),
- vue.createElementVNode("view", { class: "corner-tag" }, "国徽面")
- ]))
- ])
- ]),
- vue.createElementVNode("view", { class: "card" }, [
- vue.createElementVNode("view", { class: "section-header" }, [
- vue.createElementVNode("view", { class: "orange-bar" }),
- vue.createElementVNode("text", { class: "section-title" }, "服务类型")
- ]),
- vue.createElementVNode("view", { class: "tags-row" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.authInfo.serviceTypes, (type, index) => {
- return vue.openBlock(), vue.createElementBlock(
- "view",
- {
- class: "service-tag",
- key: index
- },
- vue.toDisplayString(type),
- 1
- /* TEXT */
- );
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- $data.authInfo.serviceTypes.length === 0 ? (vue.openBlock(), vue.createElementBlock("text", {
- key: 0,
- class: "empty-text"
- }, "暂无服务类型")) : vue.createCommentVNode("v-if", true)
- ])
- ]),
- vue.createElementVNode("view", { class: "card" }, [
- vue.createElementVNode("view", { class: "section-header" }, [
- vue.createElementVNode("view", { class: "orange-bar" }),
- vue.createElementVNode("text", { class: "section-title" }, "资质证书")
- ]),
- vue.createElementVNode(
- "text",
- { class: "sub-title" },
- vue.toDisplayString($data.authInfo.authQual ? "已认证" : "未认证"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("view", { class: "cert-row" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.authInfo.qualImages, (img, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "cert-box yellow-bg",
- key: index
- }, [
- vue.createElementVNode("image", {
- class: "cert-img",
- src: img,
- mode: "aspectFill"
- }, null, 8, ["src"])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- $data.authInfo.qualImages.length === 0 ? (vue.openBlock(), vue.createElementBlock("text", {
- key: 0,
- class: "empty-text"
- }, "暂无资质证书")) : vue.createCommentVNode("v-if", true)
- ])
- ]),
- vue.createElementVNode("view", { class: "bottom-btn-area" }, [
- $data.authInfo.pendingAudit ? (vue.openBlock(), vue.createElementBlock("button", {
- key: 0,
- class: "action-btn disabled",
- disabled: ""
- }, "认证审核中...")) : (vue.openBlock(), vue.createElementBlock("button", {
- key: 1,
- class: "action-btn",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.editAuth && $options.editAuth(...args))
- }, "修改认证信息")),
- $data.authInfo.pendingAudit ? (vue.openBlock(), vue.createElementBlock("text", {
- key: 2,
- class: "tips"
- }, "认证信息正在审核中,请耐心等待")) : (vue.openBlock(), vue.createElementBlock("text", {
- key: 3,
- class: "tips"
- }, "修改认证信息需要重新审核,审核期间无法接单"))
- ])
- ]);
- }
- const PagesMineSettingsAuthIndex = /* @__PURE__ */ _export_sfc(_sfc_main$i, [["render", _sfc_render$h], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/auth/index.vue"]]);
- const _sfc_main$h = {
- data() {
- return {
- idCardFront: "",
- idCardBack: "",
- idCardFrontOssId: "",
- idCardBackOssId: "",
- serviceOptions: [],
- selectedServices: [],
- qualifications: {},
- qualOssIds: {}
- };
- },
- async onLoad() {
- await this.loadServiceOptions();
- this.loadAuthInfo();
- },
- methods: {
- async loadServiceOptions() {
- try {
- const res = await getServiceTypes();
- this.serviceOptions = (res.data || []).map((item) => ({
- id: String(item.id),
- name: item.name
- }));
- } catch (e) {
- formatAppLog("error", "at pages/mine/settings/auth/edit.vue:134", "加载服务类型失败", e);
- }
- },
- async loadAuthInfo() {
- try {
- uni.showLoading({ title: "加载中..." });
- const res = await getAuthInfo();
- if (res.code === 200 && res.data) {
- this.idCardFront = res.data.idCardFrontUrl || "";
- this.idCardBack = res.data.idCardBackUrl || "";
- this.idCardFrontOssId = res.data.idCardFront || "";
- this.idCardBackOssId = res.data.idCardBack || "";
- let serviceIds = [];
- if (res.data.serviceTypes) {
- serviceIds = [...new Set(
- String(res.data.serviceTypes).replace(/[\[\]"']/g, "").split(",").map((s) => s.trim()).filter((id) => id && id !== "0" && id !== "null" && id !== "undefined")
- )];
- }
- this.selectedServices = serviceIds;
- const qualUrlList = res.data.qualImageUrls ? res.data.qualImageUrls.split(",").filter(Boolean) : [];
- const qualOssIdList = res.data.qualImages ? res.data.qualImages.replace(/[\[\]"]/g, "").split(",").map((s) => s.trim()).filter(Boolean) : [];
- const validNames = serviceIds.map((sid) => this.getServiceName(sid)).filter(Boolean);
- validNames.forEach((name, idx) => {
- const start = Math.floor(idx * qualUrlList.length / validNames.length);
- const end = Math.floor((idx + 1) * qualUrlList.length / validNames.length);
- this.$set(this.qualifications, name, qualUrlList.slice(start, end));
- this.$set(this.qualOssIds, name, qualOssIdList.slice(start, end));
- });
- }
- uni.hideLoading();
- } catch (e) {
- uni.hideLoading();
- formatAppLog("error", "at pages/mine/settings/auth/edit.vue:176", "加载认证信息失败", e);
- uni.showToast({ title: "加载失败", icon: "none" });
- }
- },
- navBack() {
- uni.navigateBack({ delta: 1 });
- },
- chooseImage(side) {
- uni.chooseImage({
- count: 1,
- sizeType: ["compressed"],
- sourceType: ["album", "camera"],
- success: async (res) => {
- const tempPath = res.tempFilePaths[0];
- if (side === "front") {
- this.idCardFront = tempPath;
- } else {
- this.idCardBack = tempPath;
- }
- try {
- uni.showLoading({ title: "上传中..." });
- const uploadRes = await uploadFile(tempPath);
- if (side === "front") {
- this.idCardFrontOssId = uploadRes.data.ossId;
- } else {
- this.idCardBackOssId = uploadRes.data.ossId;
- }
- uni.hideLoading();
- uni.showToast({ title: "上传成功", icon: "success" });
- } catch (err) {
- uni.hideLoading();
- formatAppLog("error", "at pages/mine/settings/auth/edit.vue:208", "上传身份证图片失败:", err);
- uni.showToast({ title: "上传失败", icon: "none" });
- }
- }
- });
- },
- deleteImage(side) {
- if (side === "front") {
- this.idCardFront = "";
- this.idCardFrontOssId = "";
- } else {
- this.idCardBack = "";
- this.idCardBackOssId = "";
- }
- },
- getServiceName(serviceId) {
- const found = this.serviceOptions.find((s) => String(s.id) === String(serviceId));
- return found ? found.name : "";
- },
- toggleService(service) {
- const index = this.selectedServices.indexOf(service.id);
- if (index > -1) {
- this.selectedServices.splice(index, 1);
- this.$delete(this.qualifications, service.name);
- this.$delete(this.qualOssIds, service.name);
- } else {
- this.selectedServices.push(service.id);
- this.$set(this.qualifications, service.name, []);
- this.$set(this.qualOssIds, service.name, []);
- }
- this.$forceUpdate();
- },
- chooseQualImage(service) {
- uni.chooseImage({
- count: 9,
- sizeType: ["compressed"],
- sourceType: ["album", "camera"],
- success: async (res) => {
- if (!this.qualifications[service]) {
- this.qualifications[service] = [];
- this.qualOssIds[service] = [];
- }
- for (const tempPath of res.tempFilePaths) {
- this.qualifications[service].push(tempPath);
- this.$forceUpdate();
- try {
- uni.showLoading({ title: "上传中..." });
- const uploadRes = await uploadFile(tempPath);
- this.qualOssIds[service].push(uploadRes.data.ossId);
- uni.hideLoading();
- } catch (err) {
- uni.hideLoading();
- formatAppLog("error", "at pages/mine/settings/auth/edit.vue:262", "上传资质图片失败:", err);
- }
- }
- }
- });
- },
- deleteQualImage(service, index) {
- this.qualifications[service].splice(index, 1);
- if (this.qualOssIds[service]) {
- this.qualOssIds[service].splice(index, 1);
- }
- this.$forceUpdate();
- },
- previewImage(service, index) {
- uni.previewImage({
- urls: this.qualifications[service],
- current: index
- });
- },
- async submitAuth() {
- if (!this.idCardFront || !this.idCardBack) {
- uni.showToast({ title: "请上传身份证正反面", icon: "none" });
- return;
- }
- if (this.selectedServices.length === 0) {
- uni.showToast({ title: "请选择服务类型", icon: "none" });
- return;
- }
- for (const serviceId of this.selectedServices) {
- const name = this.getServiceName(serviceId);
- if (!this.qualifications[name] || this.qualifications[name].length === 0) {
- uni.showToast({ title: `请上传${name}资质`, icon: "none" });
- return;
- }
- }
- uni.showModal({
- title: "提示",
- content: "修改认证信息需要重新审核,审核期间无法接单,确定要继续吗?",
- success: (res) => {
- if (res.confirm) {
- this.doSubmit();
- }
- }
- });
- },
- async doSubmit() {
- const allQualOssIds = [];
- Object.values(this.qualOssIds).forEach((ids) => {
- allQualOssIds.push(...ids);
- });
- const submitData = {
- idCardFront: this.idCardFrontOssId,
- idCardBack: this.idCardBackOssId,
- serviceTypes: this.selectedServices.join(","),
- // 逗号分隔的服务类型ID
- qualifications: allQualOssIds.join(",")
- // 逗号分隔的资质图片OSS ID
- };
- try {
- uni.showLoading({ title: "提交中..." });
- await updateAuthInfo(submitData);
- uni.hideLoading();
- uni.showToast({ title: "提交成功,等待审核", icon: "success", duration: 1500 });
- setTimeout(() => {
- uni.navigateBack({ delta: 1 });
- }, 1500);
- } catch (err) {
- uni.hideLoading();
- formatAppLog("error", "at pages/mine/settings/auth/edit.vue:333", "提交失败:", err);
- uni.showToast({ title: "提交失败", icon: "none" });
- }
- }
- }
- };
- function _sfc_render$g(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "edit-auth-container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "修改认证信息"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "warning-tip" }, [
- vue.createElementVNode("text", { class: "warning-icon" }, "⚠"),
- vue.createElementVNode("text", { class: "warning-text" }, "若修改认证信息,将在审核通过后生效")
- ]),
- vue.createElementVNode("view", { class: "section-card" }, [
- vue.createElementVNode("view", { class: "section-title" }, "身份认证"),
- vue.createElementVNode("text", { class: "section-subtitle" }, "点击图片修改"),
- vue.createElementVNode("view", { class: "id-card-row" }, [
- vue.createElementVNode("view", {
- class: "id-card-upload",
- onClick: _cache[2] || (_cache[2] = ($event) => $options.chooseImage("front"))
- }, [
- $data.idCardFront ? (vue.openBlock(), vue.createElementBlock("image", {
- key: 0,
- src: $data.idCardFront,
- class: "id-card-img",
- mode: "aspectFill"
- }, null, 8, ["src"])) : (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "id-card-placeholder"
- }, [
- vue.createElementVNode("text", { class: "placeholder-text" }, "ID Front")
- ])),
- $data.idCardFront ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 2,
- class: "delete-btn",
- onClick: _cache[1] || (_cache[1] = vue.withModifiers(($event) => $options.deleteImage("front"), ["stop"]))
- }, "×")) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("view", { class: "corner-tag" }, "人像面")
- ]),
- vue.createElementVNode("view", {
- class: "id-card-upload",
- onClick: _cache[4] || (_cache[4] = ($event) => $options.chooseImage("back"))
- }, [
- $data.idCardBack ? (vue.openBlock(), vue.createElementBlock("image", {
- key: 0,
- src: $data.idCardBack,
- class: "id-card-img",
- mode: "aspectFill"
- }, null, 8, ["src"])) : (vue.openBlock(), vue.createElementBlock("view", {
- key: 1,
- class: "id-card-placeholder"
- }, [
- vue.createElementVNode("text", { class: "placeholder-text" }, "ID Back")
- ])),
- $data.idCardBack ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 2,
- class: "delete-btn",
- onClick: _cache[3] || (_cache[3] = vue.withModifiers(($event) => $options.deleteImage("back"), ["stop"]))
- }, "×")) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("view", { class: "corner-tag" }, "国徽面")
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "section-card" }, [
- vue.createElementVNode("view", { class: "section-title" }, "服务类型"),
- vue.createElementVNode("text", { class: "section-subtitle" }, "可多选"),
- vue.createElementVNode("view", { class: "service-list" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.serviceOptions, (service, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "service-item",
- key: service.id,
- onClick: ($event) => $options.toggleService(service)
- }, [
- vue.createElementVNode(
- "text",
- { class: "service-name" },
- vue.toDisplayString(service.name),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["check-icon", { active: $data.selectedServices.map(String).includes(String(service.id)) }])
- },
- [
- $data.selectedServices.map(String).includes(String(service.id)) ? (vue.openBlock(), vue.createElementBlock("text", { key: 0 }, "✓")) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- )
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ]),
- vue.createElementVNode("view", { class: "section-card" }, [
- vue.createElementVNode("view", { class: "section-title" }, "资质证书"),
- vue.createElementVNode("text", { class: "section-subtitle" }, "请上传对应服务的资质"),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.selectedServices, (serviceId, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- key: serviceId,
- class: "qual-section"
- }, [
- vue.createElementVNode(
- "text",
- { class: "qual-title" },
- vue.toDisplayString($options.getServiceName(serviceId)) + "资质",
- 1
- /* TEXT */
- ),
- vue.createElementVNode("view", { class: "qual-upload-row" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.qualifications[$options.getServiceName(serviceId)], (img, imgIndex) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "qual-item",
- key: imgIndex,
- onClick: ($event) => $options.previewImage($options.getServiceName(serviceId), imgIndex)
- }, [
- vue.createElementVNode("image", {
- src: img,
- class: "qual-img",
- mode: "aspectFill"
- }, null, 8, ["src"]),
- vue.createElementVNode("view", {
- class: "delete-btn",
- onClick: vue.withModifiers(($event) => $options.deleteQualImage($options.getServiceName(serviceId), imgIndex), ["stop"])
- }, "×", 8, ["onClick"])
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("view", {
- class: "qual-upload-btn",
- onClick: ($event) => $options.chooseQualImage($options.getServiceName(serviceId))
- }, [
- vue.createElementVNode("text", { class: "plus-icon" }, "+")
- ], 8, ["onClick"])
- ])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- $data.selectedServices.length === 0 ? (vue.openBlock(), vue.createElementBlock("text", {
- key: 0,
- class: "empty-hint"
- }, "请先选择服务类型")) : vue.createCommentVNode("v-if", true)
- ]),
- vue.createElementVNode("view", { class: "bottom-btn-area" }, [
- vue.createElementVNode("button", {
- class: "submit-btn",
- onClick: _cache[5] || (_cache[5] = (...args) => $options.submitAuth && $options.submitAuth(...args))
- }, "提交审核")
- ])
- ]);
- }
- const PagesMineSettingsAuthEdit = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["render", _sfc_render$g], ["__scopeId", "data-v-10d0f207"], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/auth/edit.vue"]]);
- const _imports_1$3 = "/static/icons/shield.svg";
- const _sfc_main$g = {
- data() {
- return {
- hasShieldIcon: false
- // 如果没有盾牌图标资源,暂时隐藏或用文字代替
- };
- },
- methods: {
- navBack() {
- uni.navigateBack({
- delta: 1
- });
- },
- editBank() {
- uni.showToast({ title: "跳转修改银行卡页", icon: "none" });
- }
- }
- };
- function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "银行卡信息"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "bank-card" }, [
- vue.createElementVNode("view", { class: "card-top" }, [
- vue.createElementVNode("view", { class: "bank-info" }, [
- vue.createElementVNode("view", { class: "bank-icon-circle" }, [
- vue.createElementVNode("text", { class: "bank-icon-text" }, "招")
- ]),
- vue.createElementVNode("text", { class: "bank-name" }, "招商银行")
- ]),
- vue.createElementVNode("view", { class: "card-type" }, "储蓄卡")
- ]),
- vue.createElementVNode("view", { class: "card-number" }, "622588******1234"),
- vue.createElementVNode("view", { class: "card-bg-circle" })
- ]),
- vue.createElementVNode("button", {
- class: "action-btn",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.editBank && $options.editBank(...args))
- }, "修改银行卡信息"),
- vue.createElementVNode("view", { class: "security-tip" }, [
- $data.hasShieldIcon ? (vue.openBlock(), vue.createElementBlock("image", {
- key: 0,
- class: "shield-icon",
- src: _imports_1$3
- })) : vue.createCommentVNode("v-if", true),
- vue.createElementVNode("text", null, "信息已加密,仅用于收入发放")
- ])
- ]);
- }
- const PagesMineSettingsBankIndex = /* @__PURE__ */ _export_sfc(_sfc_main$g, [["render", _sfc_render$f], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/bank/index.vue"]]);
- const _sfc_main$f = {
- data() {
- return {
- phone: "",
- hasPassword: false
- };
- },
- onLoad() {
- this.loadProfile();
- },
- methods: {
- navBack() {
- uni.navigateBack({
- delta: 1
- });
- },
- async loadProfile() {
- try {
- const res = await getMyProfile();
- if (res.code === 200 && res.data) {
- this.phone = res.data.phone || "";
- this.hasPassword = !!res.data.hasPassword;
- }
- } catch (e) {
- formatAppLog("error", "at pages/mine/settings/security/index.vue:68", "加载个人信息失败", e);
- }
- },
- maskPhone(phone) {
- if (!phone || phone.length < 11)
- return phone;
- return phone.substring(0, 3) + "****" + phone.substring(7);
- },
- changeMobile() {
- uni.navigateTo({
- url: "/pages/mine/settings/security/change-phone"
- });
- },
- changePassword() {
- uni.navigateTo({
- url: "/pages/mine/settings/security/change-password"
- });
- },
- async deleteAccount() {
- uni.showModal({
- title: "警示",
- content: "注销账号后将无法恢复,确定要继续吗?",
- success: async (res) => {
- if (res.confirm) {
- try {
- const result = await deleteAccount();
- if (result.code === 200) {
- uni.showToast({ title: "账号已注销", icon: "success" });
- setTimeout(() => {
- uni.reLaunch({ url: "/pages/login/login" });
- }, 1500);
- } else {
- uni.showToast({ title: result.msg || "注销失败", icon: "none" });
- }
- } catch (e) {
- formatAppLog("error", "at pages/mine/settings/security/index.vue:102", "注销账号失败", e);
- uni.showToast({ title: "注销失败", icon: "none" });
- }
- }
- }
- });
- }
- }
- };
- function _sfc_render$e(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "账号与安全"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "section-title-security" }, "安全设置"),
- vue.createElementVNode("view", { class: "group-card" }, [
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.changeMobile && $options.changeMobile(...args))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "手机号"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode(
- "text",
- { class: "item-value" },
- vue.toDisplayString($options.maskPhone($data.phone) || "未设置"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", {
- class: "list-item",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.changePassword && $options.changePassword(...args))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "登录密码"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode(
- "text",
- { class: "item-value" },
- vue.toDisplayString($data.hasPassword ? "已设置" : "未设置"),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "section-title-security" }, "高级设置"),
- vue.createElementVNode("view", { class: "group-card" }, [
- vue.createElementVNode("view", {
- class: "list-item no-border",
- onClick: _cache[3] || (_cache[3] = (...args) => $options.deleteAccount && $options.deleteAccount(...args))
- }, [
- vue.createElementVNode("text", { class: "item-title" }, "注销账号"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ])
- ]);
- }
- const PagesMineSettingsSecurityIndex = /* @__PURE__ */ _export_sfc(_sfc_main$f, [["render", _sfc_render$e], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/security/index.vue"]]);
- const _sfc_main$e = {
- data() {
- return {
- name: ""
- };
- },
- onLoad(options) {
- if (options.name) {
- this.name = decodeURIComponent(options.name);
- }
- },
- methods: {
- navBack() {
- uni.navigateBack({ delta: 1 });
- },
- // 提交修改 @author steelwei
- async submitChange() {
- if (!this.name || !this.name.trim()) {
- uni.showToast({ title: "请输入姓名", icon: "none" });
- return;
- }
- if (this.name.trim().length < 2) {
- uni.showToast({ title: "姓名至少2个字符", icon: "none" });
- return;
- }
- uni.showLoading({ title: "提交中..." });
- try {
- const res = await updateName(this.name.trim());
- if (res.code === 200) {
- uni.showToast({
- title: "修改成功",
- icon: "success",
- duration: 2e3
- });
- uni.$emit("updateName", this.name.trim());
- setTimeout(() => {
- uni.navigateBack({ delta: 1 });
- }, 2e3);
- } else {
- uni.showToast({
- title: res.msg || "修改失败",
- icon: "none"
- });
- }
- } catch (error) {
- formatAppLog("error", "at pages/mine/settings/profile/edit-name.vue:94", "修改姓名失败:", error);
- uni.showToast({ title: "网络错误", icon: "none" });
- } finally {
- uni.hideLoading();
- }
- }
- }
- };
- function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "修改姓名"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "form-card" }, [
- vue.createElementVNode("view", { class: "form-item no-border" }, [
- vue.createElementVNode("text", { class: "form-label" }, "真实姓名"),
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "form-input",
- type: "text",
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => $data.name = $event),
- placeholder: "请输入真实姓名",
- "placeholder-class": "placeholder",
- maxlength: "20"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, $data.name]
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "btn-area" }, [
- vue.createElementVNode("button", {
- class: "submit-btn",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.submitChange && $options.submitChange(...args))
- }, "确认修改")
- ]),
- vue.createElementVNode("view", { class: "tips" }, [
- vue.createElementVNode("text", { class: "tips-text" }, "• 请输入您的真实姓名"),
- vue.createElementVNode("text", { class: "tips-text" }, "• 姓名将用于实名认证和订单服务")
- ])
- ]);
- }
- const PagesMineSettingsProfileEditName = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["render", _sfc_render$d], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/profile/edit-name.vue"]]);
- const _sfc_main$d = {
- data() {
- return {
- oldPassword: "",
- newPassword: "",
- confirmPassword: ""
- };
- },
- methods: {
- navBack() {
- uni.navigateBack({ delta: 1 });
- },
- // 提交修改 @author steelwei
- async submitChange() {
- if (!this.oldPassword) {
- uni.showToast({ title: "请输入旧密码", icon: "none" });
- return;
- }
- if (!this.newPassword) {
- uni.showToast({ title: "请输入新密码", icon: "none" });
- return;
- }
- if (this.newPassword.length < 6 || this.newPassword.length > 20) {
- uni.showToast({ title: "密码长度为6-20位", icon: "none" });
- return;
- }
- if (this.newPassword !== this.confirmPassword) {
- uni.showToast({ title: "两次密码输入不一致", icon: "none" });
- return;
- }
- uni.showLoading({ title: "提交中..." });
- try {
- const res = await updatePassword(this.oldPassword, this.newPassword);
- if (res.code === 200) {
- uni.showToast({
- title: "修改成功",
- icon: "success",
- duration: 2e3
- });
- setTimeout(() => {
- uni.navigateBack({ delta: 1 });
- }, 2e3);
- } else {
- uni.showToast({
- title: res.msg || "修改失败",
- icon: "none"
- });
- }
- } catch (error) {
- formatAppLog("error", "at pages/mine/settings/security/change-password.vue:109", "修改密码失败:", error);
- uni.showToast({ title: "网络错误", icon: "none" });
- } finally {
- uni.hideLoading();
- }
- }
- }
- };
- function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "修改密码"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "form-card" }, [
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "form-label" }, "旧密码"),
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "form-input",
- type: "password",
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => $data.oldPassword = $event),
- placeholder: "请输入旧密码",
- "placeholder-class": "placeholder"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, $data.oldPassword]
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "form-label" }, "新密码"),
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "form-input",
- type: "password",
- "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => $data.newPassword = $event),
- placeholder: "请输入新密码(6-20位)",
- "placeholder-class": "placeholder"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, $data.newPassword]
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item no-border" }, [
- vue.createElementVNode("text", { class: "form-label" }, "确认密码"),
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "form-input",
- type: "password",
- "onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => $data.confirmPassword = $event),
- placeholder: "请再次输入新密码",
- "placeholder-class": "placeholder"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, $data.confirmPassword]
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "btn-area" }, [
- vue.createElementVNode("button", {
- class: "submit-btn",
- onClick: _cache[4] || (_cache[4] = (...args) => $options.submitChange && $options.submitChange(...args))
- }, "确认修改")
- ])
- ]);
- }
- const PagesMineSettingsSecurityChangePassword = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["render", _sfc_render$c], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/security/change-password.vue"]]);
- const _sfc_main$c = {
- data() {
- return {
- phone: "",
- code: "",
- countdown: 0,
- timer: null
- };
- },
- onUnload() {
- if (this.timer) {
- clearInterval(this.timer);
- }
- },
- methods: {
- navBack() {
- uni.navigateBack({ delta: 1 });
- },
- // 发送验证码 @author steelwei
- sendCode() {
- if (!this.phone) {
- uni.showToast({ title: "请输入手机号", icon: "none" });
- return;
- }
- if (!/^1[3-9]\d{9}$/.test(this.phone)) {
- uni.showToast({ title: "手机号格式不正确", icon: "none" });
- return;
- }
- uni.showToast({ title: "验证码已发送", icon: "success" });
- this.countdown = 60;
- this.timer = setInterval(() => {
- this.countdown--;
- if (this.countdown <= 0) {
- clearInterval(this.timer);
- }
- }, 1e3);
- },
- // 提交修改 @author steelwei
- async submitChange() {
- if (!this.phone) {
- uni.showToast({ title: "请输入手机号", icon: "none" });
- return;
- }
- if (!/^1[3-9]\d{9}$/.test(this.phone)) {
- uni.showToast({ title: "手机号格式不正确", icon: "none" });
- return;
- }
- if (!this.code) {
- uni.showToast({ title: "请输入验证码", icon: "none" });
- return;
- }
- uni.showLoading({ title: "提交中..." });
- try {
- const res = await updatePhone(this.phone, this.code);
- if (res.code === 200) {
- uni.showToast({
- title: "修改成功",
- icon: "success",
- duration: 2e3
- });
- setTimeout(() => {
- uni.navigateBack({ delta: 1 });
- }, 2e3);
- } else {
- uni.showToast({
- title: res.msg || "修改失败",
- icon: "none"
- });
- }
- } catch (error) {
- formatAppLog("error", "at pages/mine/settings/security/change-phone.vue:139", "修改手机号失败:", error);
- uni.showToast({ title: "网络错误", icon: "none" });
- } finally {
- uni.hideLoading();
- }
- }
- }
- };
- function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "修改手机号"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "form-card" }, [
- vue.createElementVNode("view", { class: "form-item" }, [
- vue.createElementVNode("text", { class: "form-label" }, "新手机号"),
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "form-input",
- type: "number",
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => $data.phone = $event),
- placeholder: "请输入新手机号",
- "placeholder-class": "placeholder",
- maxlength: "11"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, $data.phone]
- ])
- ]),
- vue.createElementVNode("view", { class: "form-item no-border" }, [
- vue.createElementVNode("text", { class: "form-label" }, "验证码"),
- vue.withDirectives(vue.createElementVNode(
- "input",
- {
- class: "form-input",
- type: "number",
- "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => $data.code = $event),
- placeholder: "请输入验证码",
- "placeholder-class": "placeholder",
- maxlength: "6"
- },
- null,
- 512
- /* NEED_PATCH */
- ), [
- [vue.vModelText, $data.code]
- ]),
- vue.createElementVNode("button", {
- class: "code-btn",
- disabled: $data.countdown > 0,
- onClick: _cache[3] || (_cache[3] = (...args) => $options.sendCode && $options.sendCode(...args))
- }, vue.toDisplayString($data.countdown > 0 ? `${$data.countdown}s` : "获取验证码"), 9, ["disabled"])
- ])
- ]),
- vue.createElementVNode("view", { class: "btn-area" }, [
- vue.createElementVNode("button", {
- class: "submit-btn",
- onClick: _cache[4] || (_cache[4] = (...args) => $options.submitChange && $options.submitChange(...args))
- }, "确认修改")
- ]),
- vue.createElementVNode("view", { class: "tips" }, [
- vue.createElementVNode("text", { class: "tips-text" }, "• 修改手机号后,新手机号将作为登录账号"),
- vue.createElementVNode("text", { class: "tips-text" }, "• 请确保新手机号可以正常接收短信")
- ])
- ]);
- }
- const PagesMineSettingsSecurityChangePhone = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["render", _sfc_render$b], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/security/change-phone.vue"]]);
- const _sfc_main$b = {
- data() {
- return {};
- },
- methods: {
- navBack() {
- uni.navigateBack({
- delta: 1
- });
- },
- switchChange(type, e) {
- formatAppLog("log", "at pages/mine/settings/notification/index.vue:41", "switch change", type, e.detail.value);
- }
- }
- };
- function _sfc_render$a(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "推送通知设置"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "group-card" }, [
- vue.createElementVNode("view", { class: "list-item" }, [
- vue.createElementVNode("text", { class: "item-title" }, "系统消息通知"),
- vue.createElementVNode(
- "switch",
- {
- checked: "",
- color: "#FF5722",
- style: { "transform": "scale(0.8)" },
- onChange: _cache[1] || (_cache[1] = ($event) => $options.switchChange("system", $event))
- },
- null,
- 32
- /* NEED_HYDRATION */
- )
- ]),
- vue.createElementVNode("view", { class: "list-item no-border" }, [
- vue.createElementVNode("text", { class: "item-title" }, "订单消息通知"),
- vue.createElementVNode(
- "switch",
- {
- checked: "",
- color: "#FF5722",
- style: { "transform": "scale(0.8)" },
- onChange: _cache[2] || (_cache[2] = ($event) => $options.switchChange("order", $event))
- },
- null,
- 32
- /* NEED_HYDRATION */
- )
- ])
- ]),
- vue.createElementVNode("text", { class: "tips-text" }, "关闭通知后将收不到消息通知推送")
- ]);
- }
- const PagesMineSettingsNotificationIndex = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["render", _sfc_render$a], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/notification/index.vue"]]);
- const _sfc_main$a = {
- data() {
- return {};
- },
- methods: {
- navBack() {
- uni.navigateBack({
- delta: 1
- });
- }
- }
- };
- function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "关于我们"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "logo-area" }, [
- vue.createElementVNode("image", {
- class: "app-logo",
- src: _imports_1$8,
- mode: "aspectFit"
- }),
- vue.createElementVNode("text", { class: "app-name" }, "履约者APP"),
- vue.createElementVNode("text", { class: "app-version" }, "Version 2.0.6")
- ]),
- vue.createElementVNode("view", { class: "group-card" }, [
- vue.createElementVNode("view", { class: "list-item" }, [
- vue.createElementVNode("text", { class: "item-title" }, "服务协议"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ]),
- vue.createElementVNode("view", { class: "list-item" }, [
- vue.createElementVNode("text", { class: "item-title" }, "隐私政策"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ]),
- vue.createElementVNode("view", { class: "list-item no-border" }, [
- vue.createElementVNode("text", { class: "item-title" }, "版本更新"),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode("view", { class: "badge-yellow" }, "1"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ])
- ])
- ]);
- }
- const PagesMineSettingsAboutIndex = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["render", _sfc_render$9], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/settings/about/index.vue"]]);
- const _imports_1$2 = "/static/icons/wallet_white.svg";
- const _imports_2$2 = "/static/icons/arrow_right_gray.svg";
- const _sfc_main$9 = {
- data() {
- return {
- currentTab: 0,
- list: [
- {
- title: "订单服务费用",
- desc: "订单 T1002839 完成结算",
- time: "2026-02-03 14:30",
- amount: "20.00",
- type: "income",
- tag: "订单"
- },
- {
- title: "奖励费用",
- desc: "早高峰冲单奖励",
- time: "2026-02-03 10:00",
- amount: "15.00",
- type: "income",
- tag: "奖励"
- },
- {
- title: "惩罚金额",
- desc: "超时送达扣款",
- time: "2026-02-02 18:20",
- amount: "-10.00",
- type: "expense",
- tag: "惩罚"
- },
- {
- title: "后台转账",
- desc: "2026年1月工资发放",
- time: "2026-02-01 09:00",
- amount: "3500.00",
- type: "income",
- tag: "工资"
- }
- ]
- };
- },
- computed: {
- displayList() {
- if (this.currentTab === 0)
- return this.list;
- if (this.currentTab === 1)
- return this.list.filter((item) => item.type === "income");
- if (this.currentTab === 2)
- return this.list.filter((item) => item.type === "expense");
- return [];
- }
- },
- methods: {
- navBack() {
- uni.navigateBack();
- },
- navToBill() {
- uni.navigateTo({
- url: "/pages/mine/wallet/bill"
- });
- },
- switchTab(index) {
- this.currentTab = index;
- }
- }
- };
- function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "nav-bar" }, [
- vue.createElementVNode("view", {
- class: "nav-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0
- })
- ]),
- vue.createElementVNode("text", { class: "nav-title" }, "我的钱包"),
- vue.createElementVNode("view", { class: "nav-right" })
- ]),
- vue.createElementVNode("view", { class: "wallet-card" }, [
- vue.createElementVNode("view", { class: "bg-circle big" }),
- vue.createElementVNode("view", { class: "bg-circle small" }),
- vue.createElementVNode("view", { class: "card-content" }, [
- vue.createElementVNode("view", { class: "card-top" }, [
- vue.createElementVNode("view", { class: "app-info" }, [
- vue.createElementVNode("image", {
- class: "app-logo",
- src: _imports_1$2,
- mode: "aspectFit"
- }),
- vue.createElementVNode("text", { class: "app-name" }, "履约者APP")
- ]),
- vue.createElementVNode("view", {
- class: "bill-btn",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.navToBill && $options.navToBill(...args))
- }, [
- vue.createElementVNode("text", null, "账单")
- ])
- ]),
- vue.createElementVNode("view", { class: "balance-container" }, [
- vue.createElementVNode("view", { class: "balance-main" }, [
- vue.createElementVNode("text", { class: "balance-label" }, "账户余额 (元)"),
- vue.createElementVNode("text", { class: "balance-num" }, "2575.00")
- ]),
- vue.createElementVNode("view", { class: "balance-pending" }, [
- vue.createElementVNode("text", { class: "pending-label" }, "待入账 (元)"),
- vue.createElementVNode("text", { class: "pending-num" }, "580.00")
- ])
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "record-container" }, [
- vue.createElementVNode("view", { class: "record-header" }, [
- vue.createElementVNode("text", { class: "header-title" }, "最近账户余额变动记录"),
- vue.createElementVNode("view", {
- class: "header-more",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.navToBill && $options.navToBill(...args))
- }, [
- vue.createElementVNode("text", null, "查看全部"),
- vue.createElementVNode("image", {
- class: "more-icon",
- src: _imports_2$2
- })
- ])
- ]),
- vue.createElementVNode("view", { class: "tabs-row" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 0 }]),
- onClick: _cache[3] || (_cache[3] = ($event) => $options.switchTab(0))
- },
- [
- vue.createElementVNode("text", null, "全部"),
- $data.currentTab === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 1 }]),
- onClick: _cache[4] || (_cache[4] = ($event) => $options.switchTab(1))
- },
- [
- vue.createElementVNode("text", null, "收入"),
- $data.currentTab === 1 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 2 }]),
- onClick: _cache[5] || (_cache[5] = ($event) => $options.switchTab(2))
- },
- [
- vue.createElementVNode("text", null, "支出"),
- $data.currentTab === 2 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- )
- ]),
- vue.createElementVNode("view", { class: "record-list" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($options.displayList, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "list-item",
- key: index
- }, [
- vue.createElementVNode("view", { class: "item-left" }, [
- vue.createElementVNode(
- "text",
- { class: "item-title" },
- vue.toDisplayString(item.title),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "item-desc" },
- vue.toDisplayString(item.desc),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "item-time" },
- vue.toDisplayString(item.time),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["item-amount", { income: item.type === "income", expense: item.type === "expense" }])
- },
- vue.toDisplayString(item.type === "income" ? "+" : "") + vue.toDisplayString(item.amount),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode("view", { class: "item-tag" }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(item.tag),
- 1
- /* TEXT */
- )
- ])
- ])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ])
- ]);
- }
- const PagesMineWalletIndex = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render$8], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/wallet/index.vue"]]);
- const _sfc_main$8 = {
- data() {
- return {
- currentTab: 0,
- // 模拟数据结构
- groups: [
- {
- month: "2月 2026",
- income: "35.00",
- expense: "10.00",
- items: [
- {
- title: "订单服务费用",
- desc: "订单完成",
- time: "02-03 14:30",
- amount: "20.00",
- type: "income",
- tag: "订单"
- },
- {
- title: "奖励费用",
- desc: "早高峰奖励",
- // shortened to match ui better
- time: "02-03 10:00",
- amount: "15.00",
- type: "income",
- tag: "奖励"
- },
- {
- title: "惩罚金额",
- desc: "超时送达",
- time: "02-02 18:20",
- amount: "-10.00",
- type: "expense",
- tag: "惩罚"
- }
- ]
- },
- {
- month: "1月 2026",
- income: "3500.00",
- expense: "100.00",
- items: [
- {
- title: "后台转账",
- desc: "1月工资发放",
- time: "01-31 09:00",
- amount: "3500.00",
- type: "income",
- tag: "工资"
- },
- {
- title: "装备扣款",
- desc: "装备费用",
- time: "01-15 10:00",
- amount: "-100.00",
- type: "expense",
- tag: "扣款"
- }
- ]
- }
- ]
- };
- },
- computed: {
- displayGroups() {
- if (this.currentTab === 0)
- return this.groups;
- return this.groups.map((group) => {
- const filteredItems = group.items.filter((item) => {
- const type = this.currentTab === 1 ? "income" : "expense";
- return item.type === type;
- });
- return {
- ...group,
- items: filteredItems
- };
- }).filter((group) => group.items.length > 0);
- }
- },
- methods: {
- navBack() {
- uni.navigateBack();
- },
- switchTab(index) {
- this.currentTab = index;
- }
- }
- };
- function _sfc_render$7(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "nav-bar" }, [
- vue.createElementVNode("view", {
- class: "nav-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0
- })
- ]),
- vue.createElementVNode("text", { class: "nav-title" }, "账单明细"),
- vue.createElementVNode("view", { class: "nav-right" })
- ]),
- vue.createElementVNode("view", { class: "content-area" }, [
- vue.createElementVNode("view", { class: "tabs-row" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 0 }]),
- onClick: _cache[1] || (_cache[1] = ($event) => $options.switchTab(0))
- },
- [
- vue.createElementVNode("text", null, "全部"),
- $data.currentTab === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 1 }]),
- onClick: _cache[2] || (_cache[2] = ($event) => $options.switchTab(1))
- },
- [
- vue.createElementVNode("text", null, "收入"),
- $data.currentTab === 1 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 2 }]),
- onClick: _cache[3] || (_cache[3] = ($event) => $options.switchTab(2))
- },
- [
- vue.createElementVNode("text", null, "支出"),
- $data.currentTab === 2 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- )
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "bill-list"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($options.displayGroups, (group, gIndex) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- key: gIndex,
- class: "month-group"
- }, [
- vue.createElementVNode("view", { class: "group-header" }, [
- vue.createElementVNode(
- "text",
- { class: "month-title" },
- vue.toDisplayString(group.month),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "month-summary" },
- "收入 ¥" + vue.toDisplayString(group.income) + " 支出 ¥" + vue.toDisplayString(group.expense),
- 1
- /* TEXT */
- )
- ]),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(group.items, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "list-item",
- key: index
- }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["item-icon-box", item.type])
- },
- [
- vue.createElementVNode(
- "text",
- { class: "item-icon-symbol" },
- vue.toDisplayString(item.type === "income" ? "+" : "-"),
- 1
- /* TEXT */
- )
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode("view", { class: "item-center" }, [
- vue.createElementVNode(
- "text",
- { class: "item-title" },
- vue.toDisplayString(item.title),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "item-desc" },
- vue.toDisplayString(item.time) + " " + vue.toDisplayString(item.desc),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["item-amount", { income: item.type === "income", expense: item.type === "expense" }])
- },
- vue.toDisplayString(item.type === "income" ? "+" : "") + vue.toDisplayString(item.amount),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode("view", { class: "item-tag" }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(item.tag),
- 1
- /* TEXT */
- )
- ])
- ])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("view", { class: "list-padding-bottom" })
- ])
- ])
- ]);
- }
- const PagesMineWalletBill = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["render", _sfc_render$7], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/wallet/bill.vue"]]);
- const _sfc_main$7 = {
- data() {
- return {
- currentIndex: 2,
- // 默认选中 L3
- levels: [
- {
- id: "L1",
- name: "青铜履约者",
- score: "需成长值 0",
- isCurrent: false,
- benefits: [
- { name: "新手任务", desc: "完成新手任务可获得额外奖励", icon: "/static/icons/reward.svg" }
- ]
- },
- {
- id: "L2",
- name: "白银履约者",
- score: "需成长值 200",
- isCurrent: false,
- benefits: [
- { name: "新手任务", desc: "完成新手任务可获得额外奖励", icon: "/static/icons/reward.svg" },
- { name: "优先派单", desc: "系统将优先为您派送附近的优质订单", icon: "" }
- ]
- },
- {
- id: "L3",
- name: "黄金履约者",
- score: "需成长值 500",
- isCurrent: true,
- benefits: [
- { name: "极速提现", desc: "提现申请 2 小时内极速到账,无需等待。", icon: "" },
- { name: "晋升奖励", desc: "晋升等级可获得现金红包奖励。", icon: "/static/icons/reward.svg" },
- { name: "优先派单", desc: "系统将优先为您派送附近的优质订单。", icon: "" }
- ]
- },
- {
- id: "L4",
- name: "钻石履约者",
- score: "需成长值 2000",
- isCurrent: false,
- benefits: [
- { name: "专属客服", desc: "享受 7x24 小时专属客服通道。", icon: "/static/icons/service.svg" },
- { name: "生日礼包", desc: "生日当天获赠专属礼包。", icon: "/static/icons/reward.svg" },
- { name: "装备免费换", desc: "每年可免费更换一套履约装备。", icon: "" },
- { name: "医疗互助", desc: "享受平台提供的医疗互助保障。", icon: "" }
- ]
- }
- ],
- isPopupShow: false,
- currentBenefit: null
- };
- },
- computed: {
- currentLevel() {
- return this.levels[this.currentIndex];
- }
- },
- methods: {
- navBack() {
- uni.navigateBack({
- delta: 1
- });
- },
- swiperChange(e) {
- this.currentIndex = e.detail.current;
- },
- changeLevel(index) {
- this.currentIndex = index;
- },
- showBenefitDetail(benefit) {
- this.currentBenefit = benefit;
- this.isPopupShow = true;
- },
- closePopup() {
- this.isPopupShow = false;
- }
- }
- };
- function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "custom-header" }, [
- vue.createElementVNode("view", {
- class: "header-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "header-title" }, "履约者等级权益"),
- vue.createElementVNode("view", { class: "header-right" })
- ]),
- vue.createElementVNode("view", { class: "header-placeholder" }),
- vue.createElementVNode("view", { class: "swiper-container" }, [
- vue.createElementVNode("swiper", {
- class: "level-swiper",
- "previous-margin": "80rpx",
- "next-margin": "80rpx",
- current: $data.currentIndex,
- onChange: _cache[1] || (_cache[1] = (...args) => $options.swiperChange && $options.swiperChange(...args))
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.levels, (level, index) => {
- return vue.openBlock(), vue.createElementBlock("swiper-item", {
- key: index,
- onClick: ($event) => $options.changeLevel(index)
- }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["level-card", "level-card-" + (index + 1)]),
- style: vue.normalizeStyle({ transform: $data.currentIndex === index ? "scale(1)" : "scale(0.9)" })
- },
- [
- vue.createElementVNode("view", { class: "card-content" }, [
- vue.createElementVNode("view", { class: "card-header" }, [
- vue.createElementVNode(
- "view",
- { class: "level-badge" },
- vue.toDisplayString(level.id),
- 1
- /* TEXT */
- ),
- level.isCurrent ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "current-badge"
- }, "当前等级")) : vue.createCommentVNode("v-if", true)
- ]),
- vue.createElementVNode(
- "text",
- { class: "level-name" },
- vue.toDisplayString(level.name),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "level-score" },
- vue.toDisplayString(level.score),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("image", {
- class: "crown-overlay",
- src: _imports_1$4,
- mode: "aspectFit"
- })
- ])
- ],
- 6
- /* CLASS, STYLE */
- )
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ], 40, ["current"]),
- vue.createElementVNode("view", { class: "swiper-dots" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($data.levels, (item, index) => {
- return vue.openBlock(), vue.createElementBlock(
- "view",
- {
- class: vue.normalizeClass(["dot", { active: $data.currentIndex === index }]),
- key: index
- },
- null,
- 2
- /* CLASS */
- );
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ]),
- vue.createElementVNode("view", { class: "benefits-title-row" }, [
- vue.createElementVNode(
- "text",
- { class: "benefits-title" },
- vue.toDisplayString($options.currentLevel.id) + " 专属权益",
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "benefits-count" },
- "(" + vue.toDisplayString($options.currentLevel.benefits.length) + ")",
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "benefits-grid" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($options.currentLevel.benefits, (benefit, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "benefit-item",
- key: index,
- onClick: ($event) => $options.showBenefitDetail(benefit)
- }, [
- vue.createElementVNode("view", { class: "benefit-icon-wrapper" }, [
- benefit.icon ? (vue.openBlock(), vue.createElementBlock("image", {
- key: 0,
- class: "benefit-icon",
- src: benefit.icon,
- mode: "aspectFit"
- }, null, 8, ["src"])) : (vue.openBlock(), vue.createElementBlock(
- "view",
- {
- key: 1,
- class: "benefit-icon-placeholder"
- },
- vue.toDisplayString(benefit.name[0]),
- 1
- /* TEXT */
- ))
- ]),
- vue.createElementVNode(
- "text",
- { class: "benefit-name" },
- vue.toDisplayString(benefit.name),
- 1
- /* TEXT */
- )
- ], 8, ["onClick"]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["popup-mask", { "show": $data.isPopupShow }]),
- onClick: _cache[4] || (_cache[4] = (...args) => $options.closePopup && $options.closePopup(...args)),
- onTouchmove: _cache[5] || (_cache[5] = vue.withModifiers(() => {
- }, ["stop", "prevent"]))
- },
- [
- vue.createElementVNode("view", {
- class: "popup-modal",
- onClick: _cache[3] || (_cache[3] = vue.withModifiers(() => {
- }, ["stop"]))
- }, [
- vue.createElementVNode("view", { class: "popup-icon-wrapper" }, [
- $data.currentBenefit && $data.currentBenefit.icon ? (vue.openBlock(), vue.createElementBlock("image", {
- key: 0,
- class: "benefit-icon-large",
- src: $data.currentBenefit.icon,
- mode: "aspectFit"
- }, null, 8, ["src"])) : (vue.openBlock(), vue.createElementBlock(
- "view",
- {
- key: 1,
- class: "benefit-icon-placeholder-large"
- },
- vue.toDisplayString($data.currentBenefit ? $data.currentBenefit.name[0] : ""),
- 1
- /* TEXT */
- ))
- ]),
- vue.createElementVNode(
- "text",
- { class: "popup-title" },
- vue.toDisplayString($data.currentBenefit ? $data.currentBenefit.name : ""),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "popup-desc" },
- vue.toDisplayString($data.currentBenefit ? $data.currentBenefit.desc : ""),
- 1
- /* TEXT */
- ),
- vue.createElementVNode("button", {
- class: "popup-btn",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.closePopup && $options.closePopup(...args))
- }, "我知道了")
- ])
- ],
- 34
- /* CLASS, NEED_HYDRATION */
- )
- ]);
- }
- const PagesMineLevelIndex = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["render", _sfc_render$6], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/level/index.vue"]]);
- const _imports_1$1 = "/static/icons/icon_order_msg.svg";
- const _imports_2$1 = "/static/icons/icon_system_msg.svg";
- const _sfc_main$6 = {
- data() {
- return {};
- },
- methods: {
- navBack() {
- uni.navigateBack();
- },
- navToOrderMsg() {
- uni.navigateTo({
- url: "/pages/mine/message/order"
- });
- },
- navToSystemMsg() {
- uni.navigateTo({
- url: "/pages/mine/message/system"
- });
- }
- }
- };
- function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "nav-bar" }, [
- vue.createElementVNode("view", {
- class: "nav-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "nav-title" }, "消息中心"),
- vue.createElementVNode("view", { class: "nav-right" }, [
- vue.createElementVNode("view", { class: "more-dots" }, [
- vue.createElementVNode("view", { class: "dot" }),
- vue.createElementVNode("view", { class: "dot" }),
- vue.createElementVNode("view", { class: "dot" })
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "nav-placeholder" }),
- vue.createElementVNode("view", { class: "message-list" }, [
- vue.createElementVNode("view", {
- class: "message-item",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.navToOrderMsg && $options.navToOrderMsg(...args))
- }, [
- vue.createElementVNode("view", { class: "icon-wrapper" }, [
- vue.createElementVNode("image", {
- class: "msg-icon",
- src: _imports_1$1
- }),
- vue.createElementVNode("view", { class: "red-dot-badge" })
- ]),
- vue.createElementVNode("view", { class: "content-wrapper" }, [
- vue.createElementVNode("view", { class: "top-row" }, [
- vue.createElementVNode("text", { class: "msg-title" }, "订单消息"),
- vue.createElementVNode("text", { class: "msg-time" }, "5分钟前")
- ]),
- vue.createElementVNode("text", { class: "msg-preview" }, "你收到一个站长手动派单的新订单")
- ])
- ]),
- vue.createElementVNode("view", {
- class: "message-item",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.navToSystemMsg && $options.navToSystemMsg(...args))
- }, [
- vue.createElementVNode("view", { class: "icon-wrapper" }, [
- vue.createElementVNode("image", {
- class: "msg-icon",
- src: _imports_2$1
- })
- ]),
- vue.createElementVNode("view", { class: "content-wrapper" }, [
- vue.createElementVNode("view", { class: "top-row" }, [
- vue.createElementVNode("text", { class: "msg-title" }, "系统消息"),
- vue.createElementVNode("text", { class: "msg-time" }, "7天前")
- ]),
- vue.createElementVNode("text", { class: "msg-preview" }, "你的健康证明认证审核已通过。")
- ])
- ])
- ])
- ]);
- }
- const PagesMineMessageIndex = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["render", _sfc_render$5], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/message/index.vue"]]);
- const _sfc_main$5 = {
- methods: {
- navBack() {
- uni.navigateBack();
- }
- }
- };
- function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "nav-bar" }, [
- vue.createElementVNode("view", {
- class: "nav-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "nav-title" }, "订单消息"),
- vue.createElementVNode("view", { class: "nav-right" })
- ]),
- vue.createElementVNode("view", { class: "nav-placeholder" }),
- vue.createElementVNode("view", { class: "msg-group" }, [
- vue.createElementVNode("view", { class: "date-label" }, "2099-12-28"),
- vue.createElementVNode("view", { class: "msg-card" }, [
- vue.createElementVNode("view", { class: "card-header" }, [
- vue.createElementVNode("text", { class: "card-title" }, "站长手动派单"),
- vue.createElementVNode("view", { class: "red-dot" })
- ]),
- vue.createElementVNode("view", { class: "card-body" }, [
- vue.createElementVNode("text", { class: "msg-text" }, "你收到一个新订单,请及时查看并接单。")
- ]),
- vue.createElementVNode("view", { class: "card-footer" }, [
- vue.createElementVNode("text", { class: "order-id" }, "订单: 2099091503521"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", { class: "msg-card" }, [
- vue.createElementVNode("view", { class: "card-header" }, [
- vue.createElementVNode("text", { class: "card-title" }, "系统自动派单")
- ]),
- vue.createElementVNode("view", { class: "card-body" }, [
- vue.createElementVNode("text", { class: "msg-text" }, "你收到一个新订单,请及时查看并接单。")
- ]),
- vue.createElementVNode("view", { class: "card-footer" }, [
- vue.createElementVNode("text", { class: "order-id" }, "订单: 2099091503523"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "msg-group" }, [
- vue.createElementVNode("view", { class: "date-label" }, "2099-12-27"),
- vue.createElementVNode("view", { class: "msg-card" }, [
- vue.createElementVNode("view", { class: "card-header" }, [
- vue.createElementVNode("text", { class: "card-title" }, "系统取消派单")
- ]),
- vue.createElementVNode("view", { class: "card-body" }, [
- vue.createElementVNode("text", { class: "msg-text" }, "订单由于超时未接单已被系统取消。")
- ]),
- vue.createElementVNode("view", { class: "card-footer" }, [
- vue.createElementVNode("text", { class: "order-id" }, "订单: 2099091503111"),
- vue.createElementVNode("image", {
- class: "arrow-icon",
- src: _imports_3
- })
- ])
- ])
- ])
- ]);
- }
- const PagesMineMessageOrder = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["render", _sfc_render$4], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/message/order.vue"]]);
- const _sfc_main$4 = {
- methods: {
- navBack() {
- uni.navigateBack();
- },
- navToDetail() {
- uni.navigateTo({
- url: "/pages/mine/message/detail"
- });
- }
- }
- };
- function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "nav-bar" }, [
- vue.createElementVNode("view", {
- class: "nav-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "nav-title" }, "系统消息"),
- vue.createElementVNode("view", { class: "nav-right" })
- ]),
- vue.createElementVNode("view", { class: "nav-placeholder" }),
- vue.createElementVNode("view", { class: "sys-msg-list" }, [
- vue.createElementVNode("view", { class: "date-label" }, "2023-11-01"),
- vue.createElementVNode("view", {
- class: "sys-card",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.navToDetail && $options.navToDetail(...args))
- }, [
- vue.createElementVNode("view", { class: "sys-header" }, [
- vue.createElementVNode("text", { class: "sys-title" }, "账号审核通过"),
- vue.createElementVNode("view", { class: "red-dot" })
- ]),
- vue.createElementVNode("view", { class: "sys-content" }, [
- vue.createElementVNode("text", { class: "sys-text" }, "恭喜,您的健康证已通过审核,现在可以开始接单了。")
- ]),
- vue.createElementVNode("view", { class: "sys-footer" }, [
- vue.createElementVNode("text", { class: "sys-time" }, "10:00"),
- vue.createElementVNode("view", { class: "check-more" }, [
- vue.createElementVNode("text", null, "查看详情"),
- vue.createElementVNode("image", {
- class: "arrow-icon-small",
- src: _imports_3
- })
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "sys-card" }, [
- vue.createElementVNode("view", { class: "sys-header" }, [
- vue.createElementVNode("text", { class: "sys-title" }, "活动奖励到账")
- ]),
- vue.createElementVNode("view", { class: "sys-content" }, [
- vue.createElementVNode("text", { class: "sys-text" }, "您参与的“新手启航”活动奖励金 ¥50 已发放到您的账户。")
- ]),
- vue.createElementVNode("view", { class: "sys-footer" }, [
- vue.createElementVNode("text", { class: "sys-time" }, "09:15"),
- vue.createElementVNode("view", { class: "check-more" }, [
- vue.createElementVNode("text", null, "查看详情"),
- vue.createElementVNode("image", {
- class: "arrow-icon-small",
- src: _imports_3
- })
- ])
- ])
- ]),
- vue.createElementVNode("view", { class: "date-label" }, "2023-10-30"),
- vue.createElementVNode("view", { class: "sys-card" }, [
- vue.createElementVNode("view", { class: "sys-header" }, [
- vue.createElementVNode("text", { class: "sys-title" }, "系统维护通知")
- ]),
- vue.createElementVNode("view", { class: "sys-content" }, [
- vue.createElementVNode("text", { class: "sys-text" }, "平台将于 11月5日 凌晨 02:00-04:00 进行系统维护,届时将无法接单。")
- ]),
- vue.createElementVNode("view", { class: "sys-footer" }, [
- vue.createElementVNode("text", { class: "sys-time" }, "18:30"),
- vue.createElementVNode("view", { class: "check-more" }, [
- vue.createElementVNode("text", null, "查看详情"),
- vue.createElementVNode("image", {
- class: "arrow-icon-small",
- src: _imports_3
- })
- ])
- ])
- ])
- ])
- ]);
- }
- const PagesMineMessageSystem = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["render", _sfc_render$3], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/message/system.vue"]]);
- const _sfc_main$3 = {
- methods: {
- navBack() {
- uni.navigateBack();
- }
- }
- };
- function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "nav-bar" }, [
- vue.createElementVNode("view", {
- class: "nav-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0,
- style: { "transform": "rotate(180deg)" }
- })
- ]),
- vue.createElementVNode("text", { class: "nav-title" }, "消息详情"),
- vue.createElementVNode("view", { class: "nav-right" })
- ]),
- vue.createElementVNode("view", { class: "nav-placeholder" }),
- vue.createElementVNode("view", { class: "detail-content" }, [
- vue.createElementVNode("text", { class: "detail-title" }, "账号审核通过"),
- vue.createElementVNode("text", { class: "detail-time" }, "2023-11-01 10:00"),
- vue.createElementVNode("view", { class: "detail-body" }, [
- vue.createElementVNode("text", null, "尊敬的用户,您的健康认证资料已通过平台审核。作为履约者,您现在可以正常接收并处理订单。请确保您熟读平台规则,遵守交通法规,安全配送。祝您工作愉快!")
- ]),
- vue.createElementVNode("view", { class: "detail-footer" }, [
- vue.createElementVNode("view", { class: "divider" }),
- vue.createElementVNode("text", { class: "footer-text" }, "如有疑问,请咨询在线客服。")
- ])
- ])
- ]);
- }
- const PagesMineMessageDetail = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["render", _sfc_render$2], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/message/detail.vue"]]);
- const _imports_1 = "/static/icons/diamond_white.svg";
- const _imports_2 = "/static/icons/star_decor.svg";
- const _sfc_main$2 = {
- data() {
- return {
- currentTab: 0,
- list: [
- {
- title: "订单完成奖励",
- desc: "订单 T1002839 完成",
- time: "2026-02-05 18:42",
- amount: "10",
- type: "income",
- tag: "订单"
- },
- {
- title: "好评奖励",
- desc: "获得五星好评",
- time: "2026-02-05 19:00",
- amount: "5",
- type: "income",
- tag: "奖励"
- },
- {
- title: "超时扣分",
- desc: "订单 T1002830 超时送达",
- time: "2026-02-04 10:20",
- amount: "-10",
- type: "expense",
- tag: "惩罚"
- }
- ]
- };
- },
- computed: {
- displayList() {
- if (this.currentTab === 0)
- return this.list;
- const type = this.currentTab === 1 ? "income" : "expense";
- return this.list.filter((item) => item.type === type);
- }
- },
- methods: {
- navBack() {
- uni.navigateBack();
- },
- navToDetail() {
- uni.navigateTo({
- url: "/pages/mine/points/detail"
- });
- },
- navToEquity() {
- },
- switchTab(index) {
- this.currentTab = index;
- }
- }
- };
- function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "nav-bar" }, [
- vue.createElementVNode("view", {
- class: "nav-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0
- })
- ]),
- vue.createElementVNode("text", { class: "nav-title" }, "我的积分"),
- vue.createElementVNode("view", { class: "nav-right" })
- ]),
- vue.createElementVNode("view", { class: "points-card" }, [
- vue.createElementVNode("view", { class: "card-header" }, [
- vue.createElementVNode("view", {
- class: "equity-btn",
- onClick: _cache[1] || (_cache[1] = (...args) => $options.navToEquity && $options.navToEquity(...args))
- }, [
- vue.createElementVNode("image", {
- class: "equity-icon",
- src: _imports_1
- }),
- vue.createElementVNode("text", null, "积分权益")
- ]),
- vue.createElementVNode("view", {
- class: "detail-link",
- onClick: _cache[2] || (_cache[2] = (...args) => $options.navToDetail && $options.navToDetail(...args))
- }, [
- vue.createElementVNode("text", null, "明细")
- ])
- ]),
- vue.createElementVNode("view", { class: "card-body" }, [
- vue.createElementVNode("text", { class: "label" }, "当前积分"),
- vue.createElementVNode("text", { class: "value" }, "1200")
- ]),
- vue.createElementVNode("image", {
- class: "bg-decor",
- src: _imports_2,
- mode: "aspectFit"
- })
- ]),
- vue.createElementVNode("view", { class: "record-container" }, [
- vue.createElementVNode("view", { class: "record-header" }, [
- vue.createElementVNode("text", { class: "header-title" }, "最近积分变动"),
- vue.createElementVNode("view", {
- class: "header-more",
- onClick: _cache[3] || (_cache[3] = (...args) => $options.navToDetail && $options.navToDetail(...args))
- }, [
- vue.createElementVNode("text", null, "查看全部"),
- vue.createElementVNode("image", {
- class: "more-icon",
- src: _imports_3
- })
- ])
- ]),
- vue.createElementVNode("view", { class: "tabs-row" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 0 }]),
- onClick: _cache[4] || (_cache[4] = ($event) => $options.switchTab(0))
- },
- [
- vue.createElementVNode("text", null, "全部"),
- $data.currentTab === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 1 }]),
- onClick: _cache[5] || (_cache[5] = ($event) => $options.switchTab(1))
- },
- [
- vue.createElementVNode("text", null, "获取"),
- $data.currentTab === 1 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 2 }]),
- onClick: _cache[6] || (_cache[6] = ($event) => $options.switchTab(2))
- },
- [
- vue.createElementVNode("text", null, "扣减"),
- $data.currentTab === 2 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- )
- ]),
- vue.createElementVNode("view", { class: "record-list" }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($options.displayList, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "list-item",
- key: index
- }, [
- vue.createElementVNode("view", { class: "item-left" }, [
- vue.createElementVNode(
- "text",
- { class: "item-title" },
- vue.toDisplayString(item.title),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "item-desc" },
- vue.toDisplayString(item.desc),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "item-time" },
- vue.toDisplayString(item.time),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["item-amount", { income: item.type === "income", expense: item.type === "expense" }])
- },
- vue.toDisplayString(item.type === "income" ? "+" : "") + vue.toDisplayString(item.amount),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode("view", { class: "item-tag" }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(item.tag),
- 1
- /* TEXT */
- )
- ])
- ])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ])
- ])
- ]);
- }
- const PagesMinePointsIndex = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["render", _sfc_render$1], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/points/index.vue"]]);
- const _sfc_main$1 = {
- data() {
- return {
- currentTab: 0,
- // 模拟数据结构
- groups: [
- {
- month: "2月 2026",
- income: "15",
- expense: "10",
- items: [
- {
- title: "订单完成奖励",
- desc: "订单完成",
- time: "02-05 18:42",
- amount: "10",
- type: "income",
- tag: "订单"
- },
- {
- title: "好评奖励",
- desc: "五星好评",
- time: "02-05 19:00",
- amount: "5",
- type: "income",
- tag: "奖励"
- },
- {
- title: "超时扣分",
- desc: "订单超时",
- time: "02-04 10:20",
- amount: "-10",
- type: "expense",
- tag: "惩罚"
- }
- ]
- },
- {
- month: "1月 2026",
- income: "100",
- expense: "0",
- items: [
- {
- title: "新用户奖励",
- desc: "注册赠送",
- time: "01-10 09:00",
- amount: "100",
- type: "income",
- tag: "系统"
- }
- ]
- }
- ]
- };
- },
- computed: {
- displayGroups() {
- if (this.currentTab === 0)
- return this.groups;
- return this.groups.map((group) => {
- const filteredItems = group.items.filter((item) => {
- const type = this.currentTab === 1 ? "income" : "expense";
- return item.type === type;
- });
- return {
- ...group,
- items: filteredItems
- };
- }).filter((group) => group.items.length > 0);
- }
- },
- methods: {
- navBack() {
- uni.navigateBack();
- },
- switchTab(index) {
- this.currentTab = index;
- }
- }
- };
- function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
- return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [
- vue.createElementVNode("view", { class: "nav-bar" }, [
- vue.createElementVNode("view", {
- class: "nav-left",
- onClick: _cache[0] || (_cache[0] = (...args) => $options.navBack && $options.navBack(...args))
- }, [
- vue.createElementVNode("image", {
- class: "back-icon",
- src: _imports_0
- })
- ]),
- vue.createElementVNode("text", { class: "nav-title" }, "积分明细"),
- vue.createElementVNode("view", { class: "nav-right" })
- ]),
- vue.createElementVNode("view", { class: "content-area" }, [
- vue.createElementVNode("view", { class: "tabs-row" }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 0 }]),
- onClick: _cache[1] || (_cache[1] = ($event) => $options.switchTab(0))
- },
- [
- vue.createElementVNode("text", null, "全部"),
- $data.currentTab === 0 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 1 }]),
- onClick: _cache[2] || (_cache[2] = ($event) => $options.switchTab(1))
- },
- [
- vue.createElementVNode("text", null, "获取"),
- $data.currentTab === 1 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["tab-item", { active: $data.currentTab === 2 }]),
- onClick: _cache[3] || (_cache[3] = ($event) => $options.switchTab(2))
- },
- [
- vue.createElementVNode("text", null, "扣减"),
- $data.currentTab === 2 ? (vue.openBlock(), vue.createElementBlock("view", {
- key: 0,
- class: "tab-line"
- })) : vue.createCommentVNode("v-if", true)
- ],
- 2
- /* CLASS */
- )
- ]),
- vue.createElementVNode("scroll-view", {
- "scroll-y": "",
- class: "bill-list"
- }, [
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList($options.displayGroups, (group, gIndex) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- key: gIndex,
- class: "month-group"
- }, [
- vue.createElementVNode("view", { class: "group-header" }, [
- vue.createElementVNode(
- "text",
- { class: "month-title" },
- vue.toDisplayString(group.month),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "month-summary" },
- "获取 " + vue.toDisplayString(group.income) + " 扣减 " + vue.toDisplayString(group.expense),
- 1
- /* TEXT */
- )
- ]),
- (vue.openBlock(true), vue.createElementBlock(
- vue.Fragment,
- null,
- vue.renderList(group.items, (item, index) => {
- return vue.openBlock(), vue.createElementBlock("view", {
- class: "list-item",
- key: index
- }, [
- vue.createElementVNode(
- "view",
- {
- class: vue.normalizeClass(["item-icon-box", item.type])
- },
- [
- vue.createElementVNode(
- "text",
- { class: "item-icon-symbol" },
- vue.toDisplayString(item.type === "income" ? "+" : "-"),
- 1
- /* TEXT */
- )
- ],
- 2
- /* CLASS */
- ),
- vue.createElementVNode("view", { class: "item-center" }, [
- vue.createElementVNode(
- "text",
- { class: "item-title" },
- vue.toDisplayString(item.title),
- 1
- /* TEXT */
- ),
- vue.createElementVNode(
- "text",
- { class: "item-desc" },
- vue.toDisplayString(item.time) + " " + vue.toDisplayString(item.desc),
- 1
- /* TEXT */
- )
- ]),
- vue.createElementVNode("view", { class: "item-right" }, [
- vue.createElementVNode(
- "text",
- {
- class: vue.normalizeClass(["item-amount", { income: item.type === "income", expense: item.type === "expense" }])
- },
- vue.toDisplayString(item.type === "income" ? "+" : "") + vue.toDisplayString(item.amount),
- 3
- /* TEXT, CLASS */
- ),
- vue.createElementVNode("view", { class: "item-tag" }, [
- vue.createElementVNode(
- "text",
- null,
- vue.toDisplayString(item.tag),
- 1
- /* TEXT */
- )
- ])
- ])
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- ))
- ]);
- }),
- 128
- /* KEYED_FRAGMENT */
- )),
- vue.createElementVNode("view", { class: "list-padding-bottom" })
- ])
- ])
- ]);
- }
- const PagesMinePointsDetail = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render], ["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/pages/mine/points/detail.vue"]]);
- __definePage("pages/login/login", PagesLoginLogin);
- __definePage("pages/recruit/landing", PagesRecruitLanding);
- __definePage("pages/recruit/form", PagesRecruitForm);
- __definePage("pages/recruit/auth", PagesRecruitAuth);
- __definePage("pages/recruit/qualifications", PagesRecruitQualifications);
- __definePage("pages/recruit/success", PagesRecruitSuccess);
- __definePage("pages/login/reset-pwd-verify", PagesLoginResetPwdVerify);
- __definePage("pages/login/reset-pwd-set", PagesLoginResetPwdSet);
- __definePage("pages/home/index", PagesHomeIndex);
- __definePage("pages/home/work-status", PagesHomeWorkStatus);
- __definePage("pages/orders/index", PagesOrdersIndex);
- __definePage("pages/orders/detail", PagesOrdersDetail);
- __definePage("pages/orders/anomaly", PagesOrdersAnomaly);
- __definePage("pages/mine/order-stats", PagesMineOrderStats);
- __definePage("pages/mine/rewards", PagesMineRewards);
- __definePage("pages/mine/rewards-all", PagesMineRewardsAll);
- __definePage("pages/mine/index", PagesMineIndex);
- __definePage("pages/mine/settings/index", PagesMineSettingsIndex);
- __definePage("pages/mine/settings/profile/index", PagesMineSettingsProfileIndex);
- __definePage("pages/mine/settings/auth/index", PagesMineSettingsAuthIndex);
- __definePage("pages/mine/settings/auth/edit", PagesMineSettingsAuthEdit);
- __definePage("pages/mine/settings/bank/index", PagesMineSettingsBankIndex);
- __definePage("pages/mine/settings/security/index", PagesMineSettingsSecurityIndex);
- __definePage("pages/mine/settings/profile/edit-name", PagesMineSettingsProfileEditName);
- __definePage("pages/mine/settings/security/change-password", PagesMineSettingsSecurityChangePassword);
- __definePage("pages/mine/settings/security/change-phone", PagesMineSettingsSecurityChangePhone);
- __definePage("pages/mine/settings/notification/index", PagesMineSettingsNotificationIndex);
- __definePage("pages/mine/settings/about/index", PagesMineSettingsAboutIndex);
- __definePage("pages/mine/wallet/index", PagesMineWalletIndex);
- __definePage("pages/mine/wallet/bill", PagesMineWalletBill);
- __definePage("pages/mine/level/index", PagesMineLevelIndex);
- __definePage("pages/mine/message/index", PagesMineMessageIndex);
- __definePage("pages/mine/message/order", PagesMineMessageOrder);
- __definePage("pages/mine/message/system", PagesMineMessageSystem);
- __definePage("pages/mine/message/detail", PagesMineMessageDetail);
- __definePage("pages/mine/points/index", PagesMinePointsIndex);
- __definePage("pages/mine/points/detail", PagesMinePointsDetail);
- const _sfc_main = {
- onLaunch: function() {
- formatAppLog("log", "at App.vue:6", "App Launch");
- if (isLoggedIn()) {
- uni.switchTab({
- url: "/pages/home/index"
- });
- }
- },
- onShow: function() {
- formatAppLog("log", "at App.vue:15", "App Show");
- },
- onHide: function() {
- formatAppLog("log", "at App.vue:18", "App Hide");
- }
- };
- const App = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "E:/CodeProjects/Cursor/pet-system-fulfiller-app/App.vue"]]);
- function createApp() {
- const app = vue.createVueApp(App);
- return {
- app
- };
- }
- const { app: __app__, Vuex: __Vuex__, Pinia: __Pinia__ } = createApp();
- uni.Vuex = __Vuex__;
- uni.Pinia = __Pinia__;
- __app__.provide("__globalStyles", __uniConfig.styles);
- __app__._component.mpType = "app";
- __app__._component.render = () => {
- };
- __app__.mount("#app");
- })(Vue);
|