orderDetail.vue 54 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856
  1. <template>
  2. <view class="all-container">
  3. <view class="bg"></view>
  4. <zj-page-layout
  5. :isScroll="true"
  6. :hasFooter="true"
  7. :refresherTriggered="refresherTriggered"
  8. @refresherrefresh="refresherrefresh"
  9. >
  10. <!-- 状态 -->
  11. <view class="status-container">
  12. <view class="status" @tap="openFeedback"
  13. >{{ detail ? detail.orderStatusText : '' }}<text class="iconfont icon-jinru"></text
  14. ></view>
  15. <view class="time" v-if="detail && detail.appointmentTime"
  16. >已预约 {{ detail.appointmentTime.slice(0, 10) }}</view
  17. >
  18. </view>
  19. <!-- tab栏 -->
  20. <view class="tab-container">
  21. <u-tabs :scrollable="true" :list="tabList" :current="curTab - 1" @click="changeTab" itemStyle="height: 36px;">
  22. </u-tabs>
  23. </view>
  24. <view class="content-container" v-if="detail">
  25. <!-- 基本信息 -->
  26. <block v-if="~[1].indexOf(curTab)">
  27. <view class="user-container card">
  28. <view class="top">
  29. <view class="type">
  30. <view class="left">{{ detail.orderSmallTypeText ? detail.orderSmallTypeText.slice(0, 2) : '' }}</view>
  31. <view v-if="detail && orderStatus_v !== 'DQD'" class="right" @tap="copyData()">复制</view>
  32. </view>
  33. <view class="user">{{ detail.userName }} {{ detail.userMobile }}</view>
  34. <view class="address">
  35. <view class="text"
  36. >{{ detail.province }}{{ detail.city }}{{ detail.area }}{{ detail.street
  37. }}{{ detail.address || detail.gpsAddress }}
  38. </view>
  39. <view
  40. v-if="detail && orderStatus_v !== 'DQD'"
  41. class="ctrl"
  42. @tap.stop="
  43. $openLocation({
  44. lat: detail.lat,
  45. lng: detail.lng,
  46. address: detail.address || detail.gpsAddress
  47. })
  48. "
  49. ><text class="iconfont icon-daohang"></text>导航</view
  50. >
  51. </view>
  52. </view>
  53. <view class="bottom" v-if="detail && orderStatus_v !== 'DQD'">
  54. <view class="it" @tap="$callPhone(detail.userMobile)"
  55. ><text class="iconfont icon-call"></text>联系电话1</view
  56. >
  57. <view class="it" @tap="$callPhone(detail.userMobile2 || detail.userMobile)"
  58. ><text class="iconfont icon-call"></text>联系电话2</view
  59. >
  60. </view>
  61. </view>
  62. <!-- 商品信息 -->
  63. <view class="goods-container card mt30">
  64. <view class="common-title">商品信息</view>
  65. <view class="item" v-for="(item, index) in detail.pgOrderProducts" :key="index">
  66. <view class="main">
  67. <image :src="item.imgUrl ? item.imgUrl : require('@/static/images/logo.png')" mode="aspectFill"></image>
  68. <view class="info">
  69. <view class="name">
  70. <view class="left" v-if="detail.isZl">{{ item.mainName || '' }}</view>
  71. <view class="left" v-else>{{ item.smallName || '' }} {{ item.productName || '' }}</view>
  72. <view class="right">x{{ item.num }}</view>
  73. </view>
  74. <view class="tags" v-if="!detail.isZl">
  75. <view class="it">{{ item.brandName }}</view>
  76. <!-- <view class="it">家用空调</view> -->
  77. </view>
  78. </view>
  79. </view>
  80. <!-- <view class="images" v-if="isOpenGoods">
  81. <view class="it" v-if="item.insideImg">
  82. <image :src="imageUrl + item.insideImg" mode="aspectFill"
  83. @tap="prevImg(item.insideImg)"></image>
  84. <view class="text">内机</view>
  85. </view>
  86. <view class="it" v-if="item.outImg">
  87. <image :src="imageUrl + item.outImg" mode="aspectFill" @tap="prevImg(item.outImg)">
  88. </image>
  89. <view class="text">外机</view>
  90. </view>
  91. <block v-if="item.partImgs">
  92. <view class="it" v-for="(it, idx) in item.partImgs.split(',')" :key="idx">
  93. <image :src="imageUrl + it" mode="aspectFill" @tap="() => prevImg(it)"></image>
  94. <view class="text">配件</view>
  95. </view>
  96. </block>
  97. </view> -->
  98. </view>
  99. <!-- <view class="ctrl" @tap="isOpenGoods = !isOpenGoods">
  100. <text>{{ isOpenGoods ? '收起' : '查看更多' }}</text>
  101. <text class="iconfont icon-left" :class="isOpenGoods ? 'is' : ''"></text>
  102. </view> -->
  103. </view>
  104. <!-- 订单信息 -->
  105. <view class="info-container card mt30" v-if="detail.saleOrderId && !detail.pgIncreId">
  106. <view class="common-title">订单信息</view>
  107. <view>
  108. <view class="row">
  109. <view class="label">订单编号</view>
  110. <view class="value">{{ detail.saleOrderId }}</view>
  111. <view v-if="detail && orderStatus_v !== 'DQD'" class="ctrl" @tap="$copy(detail.saleOrderId)">复制</view>
  112. </view>
  113. <view class="row">
  114. <view class="label">下单时间</view>
  115. <view class="value">{{ detail.saleCreateTime || '' }}</view>
  116. </view>
  117. <view class="row">
  118. <view class="label">订单金额</view>
  119. <view class="value">¥{{ detail.saleTotalAmount | priceFilter }}</view>
  120. </view>
  121. <view class="row">
  122. <view class="label">订单备注</view>
  123. <view class="value">{{ detail.saleRemark || '' }}</view>
  124. </view>
  125. </view>
  126. </view>
  127. <view class="info-container card mt30" v-if="detail.pgIncreId && increDetail">
  128. <view class="common-title">产品信息</view>
  129. <view class="row">
  130. <view class="label">服务类型</view>
  131. <view class="value">延保</view>
  132. </view>
  133. <view class="row">
  134. <view class="label">产品品牌</view>
  135. <view class="value">{{ increDetail.brandName }}</view>
  136. </view>
  137. <view class="row">
  138. <view class="label">产品大类</view>
  139. <view class="value">{{ increDetail.mainName }}</view>
  140. </view>
  141. <view class="row">
  142. <view class="label">服务内容</view>
  143. <view class="value">{{ increDetail.increContent }}</view>
  144. </view>
  145. </view>
  146. <view class="info-container card mt30" v-if="detail.pgIncreId && increDetail">
  147. <view class="common-title">产品凭证</view>
  148. <view class="row">
  149. <view class="label">内机条码</view>
  150. <view class="value">{{ increDetail.insideCode }}</view>
  151. </view>
  152. <view class="imgs">
  153. <!-- 内机条码 -->
  154. <view class="it">
  155. <block>
  156. <image mode="aspectFill" :src="increDetail.insideCodeImg" @tap="prevImg(increDetail.insideCodeImg)">
  157. </image>
  158. </block>
  159. <view class="name">内机条码</view>
  160. </view>
  161. <!-- 机器铭牌 -->
  162. <view class="it">
  163. <block>
  164. <image mode="aspectFill" :src="increDetail.machineImg" @tap="prevImg(increDetail.machineImg)">
  165. </image>
  166. </block>
  167. <view class="name">机器铭牌<br />(含出厂日期)</view>
  168. </view>
  169. <!-- 购机凭证 -->
  170. <view class="it">
  171. <block>
  172. <image mode="aspectFill" :src="increDetail.buyCertImg" @tap="prevImg(increDetail.buyCertImg)">
  173. </image>
  174. </block>
  175. <view class="name">购机凭证</view>
  176. </view>
  177. </view>
  178. </view>
  179. <!-- 延保订单信息 -->
  180. <view class="info-container card mt30" v-if="detail.pgIncreId && increDetail">
  181. <view class="common-title">订单信息</view>
  182. <view>
  183. <view class="row">
  184. <view class="label">订单编号</view>
  185. <view class="value">{{ increDetail.id }}</view>
  186. <view v-if="detail && orderStatus_v !== 'DQD'" class="ctrl" @tap="$copy(increDetail.id)">复制</view>
  187. </view>
  188. <view class="row">
  189. <view class="label">下单时间</view>
  190. <view class="value">{{ increDetail.createTime || '' }}</view>
  191. </view>
  192. <view class="row">
  193. <view class="label">订单金额</view>
  194. <view class="value">¥{{ increDetail.amount }}</view>
  195. </view>
  196. <view class="row">
  197. <view class="label">订单备注</view>
  198. <view class="value">{{ detail.remark || '' }}</view>
  199. </view>
  200. </view>
  201. </view>
  202. <!-- 服务信息 -->
  203. <view class="info-container card mt30">
  204. <view class="common-title">服务信息</view>
  205. <view>
  206. <view class="row">
  207. <view class="label">工单编号</view>
  208. <view class="value">{{ detail.id }}</view>
  209. <view v-if="detail && orderStatus_v !== 'DQD'" class="ctrl" @tap="$copy(detail.id)">复制</view>
  210. </view>
  211. <view class="row">
  212. <view class="label">下单时间</view>
  213. <view class="value">{{ detail.createTime }}</view>
  214. </view>
  215. <view class="row">
  216. <view class="label">接单时间</view>
  217. <view class="value">{{ detail.workerReceTime || '' }}</view>
  218. </view>
  219. <view class="row">
  220. <view class="label">主工程师</view>
  221. <view class="value">{{ detail.workerName }} {{ detail.workerMobile }}</view>
  222. <view v-if="detail && orderStatus_v !== 'DQD'" class="ctrl" @tap="$callPhone(detail.workerMobile)"
  223. ><text class="iconfont icon-call"></text
  224. ></view>
  225. </view>
  226. <view class="row" v-for="(item, index) in detail.pgOrderWorkers.filter(o => !o.isMaster)" :key="index">
  227. <view class="label">辅工程师</view>
  228. <view class="value">{{ item.workerName }} {{ item.workerMobile }}</view>
  229. <view v-if="detail && orderStatus_v !== 'DQD'" class="ctrl" @tap="$callPhone(item.workerMobile)"
  230. ><text class="iconfont icon-call"></text
  231. ></view>
  232. </view>
  233. <view class="row">
  234. <view class="label">下单渠道</view>
  235. <view class="value">{{ detail.orderChannelText || '' }}</view>
  236. </view>
  237. <view class="row">
  238. <view class="label">订单备注</view>
  239. <view class="value">{{ detail.remark || '' }}</view>
  240. </view>
  241. </view>
  242. </view>
  243. <!-- 建单信息 -->
  244. <view class="info-container card mt30">
  245. <view class="common-title">建单信息</view>
  246. <view>
  247. <view class="row">
  248. <view class="label">建单人名</view>
  249. <view class="value">{{ detail.createBy || '' }}</view>
  250. </view>
  251. <view class="row">
  252. <view class="label">下单网点</view>
  253. <view class="value">{{ detail.websitName || '' }}</view>
  254. </view>
  255. </view>
  256. </view>
  257. <!-- v-if="[3, 42].includes(detail.saleType)" -->
  258. <template>
  259. <view class="mt30" v-if="!oldData">
  260. <u-button plain type="primary" text="申请难度费用" @tap="toNandufysq()"></u-button>
  261. </view>
  262. <view class="mt30" v-else-if="oldData.status == 2">
  263. <u-button plain type="primary" text="重新申请难度费用" @tap="toNandufysq()"></u-button>
  264. </view>
  265. <view class="mt30" v-else>
  266. <u-button plain type="primary" text="查看难度费用" @tap="toNandufysq()"></u-button>
  267. </view>
  268. </template>
  269. <!-- -->
  270. <!-- -->
  271. <!-- -->
  272. <!-- -->
  273. <!-- -->
  274. </block>
  275. <!-- 服务信息 -->
  276. <block v-if="~[2].indexOf(curTab)">
  277. <!-- 过程反馈 -->
  278. <view class="feedback-container card">
  279. <view class="common-title2">
  280. <view class="title">过程反馈</view>
  281. <view v-if="detail && orderStatus_v !== 'DQD'" class="right" @tap="toFeedbackList"
  282. >查看全部<text class="iconfont icon-jinru"></text>
  283. </view>
  284. </view>
  285. <view class="list" v-if="detail.lastOperator">
  286. <view class="item">
  287. <u-avatar
  288. :text="detail.lastOperatorWebsit ? detail.lastOperatorWebsit.slice(0, 1) : 'A'"
  289. fontSize="18"
  290. randomBgColor
  291. ></u-avatar>
  292. <view class="main">
  293. <view class="name">{{ detail.lastOperatorWebsit || '' }}</view>
  294. <view class="time">{{ detail.lastOperatorTime || '' }}</view>
  295. <view class="content">{{ detail.lastOperator || '' }}</view>
  296. </view>
  297. </view>
  298. </view>
  299. <Loading :type="3" :loadStatus="2" :isLoadAnimation="false" v-else />
  300. </view>
  301. <!-- 预约信息 -->
  302. <view class="info-container card mt30" v-if="detail && detail.appointmentTime">
  303. <view class="common-title">预约信息</view>
  304. <view>
  305. <view class="row">
  306. <view class="label">预约时间</view>
  307. <view class="value">{{ detail.appointmentTime.slice(0, 10) }}</view>
  308. </view>
  309. <view class="row">
  310. <view class="label">预约备注</view>
  311. <view class="value">{{ detail.changeRemark || detail.appointmentRemark }}</view>
  312. </view>
  313. </view>
  314. </view>
  315. <!-- 完工信息 -->
  316. <view class="info-container card mt30" v-if="detail && (orderStatus_v == 'YWG' || orderStatus_v == 'YJS')">
  317. <view class="common-title2">
  318. <view class="title">完工信息</view>
  319. <view v-if="detail && orderStatus_v !== 'DQD'" class="right" @tap="toOverDetail"
  320. >查看更多<text class="iconfont icon-jinru"></text
  321. ></view>
  322. </view>
  323. <view>
  324. <view class="row">
  325. <view class="label">完工时间</view>
  326. <view class="value">{{ detail.overTime || detail.websitOverTime || '' }}</view>
  327. </view>
  328. <view class="row">
  329. <view class="label">完工地点</view>
  330. <view class="value"
  331. >{{ detail.province }}{{ detail.city }}{{ detail.area }}{{ detail.street }}{{ detail.address }}
  332. </view>
  333. </view>
  334. </view>
  335. </view>
  336. </block>
  337. <!-- 电子支付 -->
  338. <block v-if="~[3].indexOf(curTab)">
  339. <block v-if="detail.rpProjectRepairId">
  340. <view class="product-container card" v-for="(item, index) in payList" :key="index">
  341. <view class="row">
  342. <view class="label">支付单号</view>
  343. <view class="value">{{ item.orderId }}</view>
  344. </view>
  345. <view class="row">
  346. <view class="label">支付状态</view>
  347. <view class="value" style="color: red">{{ item.examineStatus | examineStatusFilter }}</view>
  348. </view>
  349. <view class="common-title mt30">产品信息</view>
  350. <view class="product">
  351. <view
  352. class="it"
  353. v-for="(it, idx) in item.rpMaterialOrderItems.filter(
  354. o => o.chargeType == 'ACC' || o.chargeType == 'MCC'
  355. )"
  356. :key="idx"
  357. >
  358. <view class="name"
  359. >{{ it.goodsName }}<text>×{{ it.num }}</text></view
  360. >
  361. <view class="price">¥{{ it.totalAmount.toFixed(2) }}</view>
  362. </view>
  363. <view class="total">
  364. <view class="text">合计:</view>
  365. <view class="price"
  366. >¥{{
  367. [
  368. 0,
  369. 0,
  370. 0,
  371. ...item.rpMaterialOrderItems
  372. .filter(o => o.chargeType == 'ACC' || o.chargeType == 'MCC')
  373. .map(val => val.totalAmount)
  374. ]
  375. .reduce((a, b) => (a * 100 + b * 100) / 100, 0)
  376. .toFixed(2)
  377. }}</view
  378. >
  379. </view>
  380. </view>
  381. <view class="common-title mt30">服务费用</view>
  382. <view class="product">
  383. <view
  384. class="it"
  385. v-for="(it, idx) in item.rpMaterialOrderItems.filter(o => o.chargeType == 'SERV')"
  386. :key="idx"
  387. >
  388. <view class="name">{{ it.goodsName }}</view>
  389. <view class="price">¥{{ it.totalAmount.toFixed(2) }}</view>
  390. </view>
  391. <view class="total">
  392. <view class="text">合计:</view>
  393. <view class="price"
  394. >¥{{
  395. [
  396. 0,
  397. 0,
  398. 0,
  399. ...item.rpMaterialOrderItems.filter(o => o.chargeType == 'SERV').map(val => val.totalAmount)
  400. ]
  401. .reduce((a, b) => (a * 100 + b * 100) / 100, 0)
  402. .toFixed(2)
  403. }}</view
  404. >
  405. </view>
  406. </view>
  407. <view class="bottom">
  408. <view class="left">订单总金额</view>
  409. <view class="right">
  410. <view class="text">合计:</view>
  411. <view class="price"
  412. >¥{{
  413. [
  414. 0,
  415. 0,
  416. 0,
  417. ...item.rpMaterialOrderItems.filter(o => o.chargeType == 'SERV').map(val => val.totalAmount),
  418. ...item.rpMaterialOrderItems
  419. .filter(o => o.chargeType == 'ACC' || o.chargeType == 'MCC')
  420. .map(val => val.totalAmount)
  421. ]
  422. .reduce((a, b) => (a * 100 + b * 100) / 100, 0)
  423. .toFixed(2)
  424. }}</view
  425. >
  426. </view>
  427. </view>
  428. <view class="row mt30">
  429. <view class="label">操作人员</view>
  430. <view class="value">{{ item.createBy }}</view>
  431. </view>
  432. <view class="row mt20">
  433. <view class="label">订单备注</view>
  434. <view class="value">{{ item.remark }}</view>
  435. </view>
  436. </view>
  437. </block>
  438. <block v-else>
  439. <view class="product-container card" v-for="(item, index) in payList" :key="index">
  440. <view class="common-title mt30">支付费用{{ index + 1 }}</view>
  441. <view class="row">
  442. <view class="label">支付单号</view>
  443. <view class="value">{{ item.orderId }}</view>
  444. </view>
  445. <view class="row">
  446. <view class="label">支付状态</view>
  447. <view
  448. class="value"
  449. :style="{ color: item.payStatus == 'WAIT' ? 'red' : item.payStatus == 'PAID' ? 'blue' : '' }"
  450. >{{ item.payStatus | payStatusFilter }}</view
  451. >
  452. </view>
  453. <view class="common-title mt30">产品信息</view>
  454. <view class="product">
  455. <view
  456. class="it"
  457. v-for="(it, idx) in item.workerOrderItems.filter(o => o.chargeType == 'ACC' || o.chargeType == 'MCC')"
  458. :key="idx"
  459. >
  460. <view class="name"
  461. >{{ it.goodsName }}<text>×{{ it.num }}</text></view
  462. >
  463. <view class="price">¥{{ it.totalAmount.toFixed(2) }}</view>
  464. </view>
  465. <view class="total">
  466. <view class="text">合计:</view>
  467. <view class="price"
  468. >¥{{
  469. [
  470. 0,
  471. 0,
  472. 0,
  473. ...item.workerOrderItems
  474. .filter(o => o.chargeType == 'ACC' || o.chargeType == 'MCC')
  475. .map(val => val.totalAmount)
  476. ]
  477. .reduce((a, b) => (a * 100 + b * 100) / 100, 0)
  478. .toFixed(2)
  479. }}</view
  480. >
  481. </view>
  482. </view>
  483. <view class="common-title mt30">服务费用</view>
  484. <view class="product">
  485. <view
  486. class="it"
  487. v-for="(it, idx) in item.workerOrderItems.filter(o => o.chargeType == 'SERV')"
  488. :key="idx"
  489. >
  490. <view class="name">{{ it.goodsName }}</view>
  491. <view class="price">¥{{ it.totalAmount.toFixed(2) }}</view>
  492. </view>
  493. <view class="total">
  494. <view class="text">合计:</view>
  495. <view class="price"
  496. >¥{{
  497. [
  498. 0,
  499. 0,
  500. 0,
  501. ...item.workerOrderItems.filter(o => o.chargeType == 'SERV').map(val => val.totalAmount)
  502. ]
  503. .reduce((a, b) => (a * 100 + b * 100) / 100, 0)
  504. .toFixed(2)
  505. }}</view
  506. >
  507. </view>
  508. </view>
  509. <view class="bottom">
  510. <view class="left">订单总金额</view>
  511. <view class="right">
  512. <view class="text">合计:</view>
  513. <view class="price"
  514. >¥{{
  515. [
  516. 0,
  517. 0,
  518. 0,
  519. ...item.workerOrderItems.filter(o => o.chargeType == 'SERV').map(val => val.totalAmount),
  520. ...item.workerOrderItems
  521. .filter(o => o.chargeType == 'ACC' || o.chargeType == 'MCC')
  522. .map(val => val.totalAmount)
  523. ]
  524. .reduce((a, b) => (a * 100 + b * 100) / 100, 0)
  525. .toFixed(2)
  526. }}</view
  527. >
  528. </view>
  529. </view>
  530. <view class="row mt30">
  531. <view class="label">操作人员</view>
  532. <view class="value">{{ item.createBy }}</view>
  533. </view>
  534. <view class="row mt20">
  535. <view class="label">订单备注</view>
  536. <view class="value">{{ item.remark }}</view>
  537. </view>
  538. <view style="height: 20rpx"></view>
  539. <view v-if="item.payStatus == 'WAIT'">
  540. <u-button type="success" text="扫码支付" @click="scanCode(item)">扫码支付</u-button>
  541. </view>
  542. </view>
  543. </block>
  544. <block v-if="payList.length < 1">
  545. <Loading :type="3" :loadStatus="2" showText="暂无电子支付信息" :isLoadAnimation="false" />
  546. </block>
  547. </block>
  548. <!-- 费用结算 -->
  549. <block v-if="~[4].indexOf(curTab)">
  550. <!-- 服务费用 -->
  551. <view class="info-container card mt30" v-for="(item, index) in settleList" :key="index">
  552. <block v-if="item.settleNormType !== 'OTHER'">
  553. <view class="common-title2">
  554. <view class="title">服务费用{{ index + 1 }}</view>
  555. <view class="right">{{ orderStatus_v == 'YJS' ? '已结算' : '结算中' }}</view>
  556. </view>
  557. <view>
  558. <view class="row">
  559. <view class="label">产品大类</view>
  560. <view class="value">{{ item.mainName || '' }}</view>
  561. </view>
  562. <view class="row">
  563. <view class="label">产品小类</view>
  564. <view class="value">{{ item.smallName || '' }}</view>
  565. </view>
  566. <view class="row">
  567. <view class="label">机型名称</view>
  568. <view class="value">{{ item.goodsName || '' }}</view>
  569. </view>
  570. <!-- <view class="row">
  571. <view class="label">收费标准</view>
  572. <view class="value">¥{{ item.normAmount | priceFilter }}</view>
  573. </view> -->
  574. <view class="row">
  575. <view class="label">数&emsp;&emsp;量</view>
  576. <view class="value">{{ item.settleNum || '' }}</view>
  577. </view>
  578. <view class="row">
  579. <view class="label">结算金额</view>
  580. <view class="value" v-if="orderStatus_v == 'YJS'">¥{{ item.workerSettleAmount | priceFilter }}</view>
  581. <view class="value" v-else>-</view>
  582. </view>
  583. </view>
  584. </block>
  585. <block v-else>
  586. <view class="common-title2">
  587. <view class="title">其他费用</view>
  588. <view class="right">{{ orderStatus_v == 'YJS' ? '已结算' : '结算中' }}</view>
  589. </view>
  590. <view>
  591. <view class="row">
  592. <view class="label">类&emsp;&emsp;型</view>
  593. <view class="value">{{ item.typeName || '' }}</view>
  594. </view>
  595. <view class="row">
  596. <view class="label">规&emsp;&emsp;格</view>
  597. <view class="value">{{ item.label || '' }}</view>
  598. </view>
  599. <!-- <view class="row">
  600. <view class="label">单&emsp;&emsp;价</view>
  601. <view class="value">¥{{ item.normAmount | priceFilter }}</view>
  602. </view> -->
  603. <view class="row">
  604. <view class="label">数&emsp;&emsp;量</view>
  605. <view class="value">{{ item.settleNum || '' }}</view>
  606. </view>
  607. <view class="row">
  608. <view class="label">结算金额</view>
  609. <view class="value" v-if="orderStatus_v == 'YJS'">¥{{ item.workerSettleAmount | priceFilter }}</view>
  610. <view class="value" v-else>-</view>
  611. </view>
  612. </view>
  613. </block>
  614. </view>
  615. <block v-if="settleList.length < 1">
  616. <Loading :type="3" :loadStatus="2" showText="暂无员工结算信息" :isLoadAnimation="false" />
  617. </block>
  618. </block>
  619. </view>
  620. <Loading :type="3" :loadStatus="loadStatus" :isLoadAnimation="false" />
  621. <template slot="footer">
  622. <view class="bottom-container" v-if="detail">
  623. <!-- 总部下载 -->
  624. <u-button
  625. v-if="ZONGBUXIAZAI(detail, userInfo)"
  626. type="primary"
  627. text="总部下载"
  628. @tap="ZONGBUXIAZAIFUNC(detail, userInfo)"
  629. ></u-button>
  630. <!-- 接单 -->
  631. <u-button v-if="JIEDAN(detail, userInfo)" type="primary" text="接单" @tap="actionReceive()"></u-button>
  632. <!-- 待抢单 -->
  633. <u-button v-if="QIANGDAN(detail, userInfo)" type="primary" text="抢单" @tap="qdOrder(detail)"></u-button>
  634. <!-- 配件申请 -->
  635. <u-button
  636. v-if="PEIJIANSHENQING(detail, userInfo)"
  637. plain
  638. type="primary"
  639. text="配件申请"
  640. @tap="toPartsApply()"
  641. ></u-button>
  642. <!-- 变更小工 -->
  643. <u-button
  644. v-if="BIANGENGXIAOGONG(detail, userInfo)"
  645. plain
  646. type="primary"
  647. text="变更小工"
  648. @tap="biangengxiaogong()"
  649. ></u-button>
  650. <!-- 辅材收费 ok-->
  651. <u-button
  652. plain
  653. type="primary"
  654. text="辅材收费"
  655. @tap="toCharge('M')"
  656. v-if="FUCAISHOUFEI(detail, userInfo)"
  657. ></u-button>
  658. <!-- 配件收费 ok-->
  659. <u-button
  660. plain
  661. type="primary"
  662. text="配件收费"
  663. @tap="toCharge('P')"
  664. v-if="PEIJIANSHOUFEI(detail, userInfo)"
  665. ></u-button>
  666. <!-- 过程反馈 ok-->
  667. <u-button
  668. v-if="GUOCHENFANKUI(detail, userInfo)"
  669. type="primary"
  670. text="过程反馈"
  671. @tap="toFeedback()"
  672. ></u-button>
  673. <!-- <block v-if="orderStatus_v == 'DJD'">
  674. <u-button
  675. plain
  676. type="primary"
  677. text="取消加急"
  678. @tap="actionUrgent(false)"
  679. v-if="detail.pgOrderFlags && detail.pgOrderFlags.some(o => o.tag == 'JIA_JI')"
  680. ></u-button>
  681. <u-button plain type="primary" text="加急" @tap="actionUrgent(true)" v-else></u-button>
  682. </block> -->
  683. </view>
  684. </template>
  685. </zj-page-layout>
  686. <selectionWorkers
  687. v-if="item"
  688. :title="title"
  689. :detail="item"
  690. :type="selectionWorkersType"
  691. :callback="callback"
  692. @close="
  693. () => {
  694. item = null
  695. selectionWorkersType = null
  696. callback = null
  697. }
  698. "
  699. />
  700. <u-popup :show="isShowFeedback" @close="isShowFeedback = false" closeable round="10">
  701. <view class="feedback-dialog">
  702. <view class="title">服务路由</view>
  703. <view class="content">
  704. <logistics :logisticsData="feedbackList"></logistics>
  705. </view>
  706. </view>
  707. </u-popup>
  708. <zhifutanchuan
  709. v-if="state > 0"
  710. :detail="detail_zf"
  711. :orderId="orderId_zf"
  712. :state="state"
  713. @scan="scan"
  714. @back="back"
  715. @offTiming="offTiming"
  716. />
  717. </view>
  718. </template>
  719. <script>
  720. import zjDialogPicker from '@/components/zj-dialog/zj-dialog-picker.vue'
  721. import Logistics from '@/components/logistics2/common-logistics.vue'
  722. import selectionWorkers from '@/components/selectionWorkers.vue'
  723. import zhifutanchuan from '@/components/zhifutanchuan.vue'
  724. import { wxScanCode } from '@/common/utils/util.js'
  725. import { getStorage } from '@/common/utils/storage.js'
  726. import orderBtnsShow from './mixins/orderBtnsShow.js'
  727. import orderStatus_v from './mixins/orderStatus_fh.js'
  728. export default {
  729. mixins: [orderBtnsShow],
  730. components: {
  731. zjDialogPicker,
  732. Logistics,
  733. selectionWorkers,
  734. zhifutanchuan
  735. },
  736. filters: {
  737. payStatusFilter(val) {
  738. const MAP = {
  739. CANCEL: '已取消',
  740. WAIT: '待支付',
  741. PAID: '已支付'
  742. }
  743. return MAP[val]
  744. },
  745. examineStatusFilter(val) {
  746. const MAP = {
  747. WAIT: '待审批',
  748. OK: '审批通过',
  749. FAIL: '审批驳回',
  750. NO: '已取消',
  751. PAID: '已现场支付',
  752. NO_PAID: '未支付'
  753. }
  754. return MAP[val]
  755. }
  756. },
  757. data() {
  758. return {
  759. id: null,
  760. imageUrl: this.$imageUrl,
  761. detail: null,
  762. increDetail: null,
  763. loadStatus: 1,
  764. errorText: '',
  765. refresherTriggered: false,
  766. curTab: 1,
  767. tabList: [
  768. { name: '基本信息', value: 1 },
  769. { name: '服务信息', value: 2 },
  770. { name: '电子支付', value: 3 },
  771. { name: '员工结算', value: 4 }
  772. ],
  773. isOpenGoods: false,
  774. payList: [], // 支付信息列表
  775. settleList: [], // 结算列表
  776. isShowFeedback: false,
  777. feedbackList: [],
  778. behavior: '',
  779. selectionWorkersType: '',
  780. item: null,
  781. callback: null,
  782. title: '',
  783. state: 0,
  784. detail_zf: null,
  785. orderId_zf: null,
  786. oldData: null
  787. }
  788. },
  789. computed: {
  790. userInfo() {
  791. return getStorage('user')
  792. },
  793. orderStatus_v() {
  794. return orderStatus_v(this?.detail?.orderStatus, this?.detail)
  795. }
  796. },
  797. async onLoad({ id, behavior }) {
  798. this.id = id
  799. this.behavior = behavior
  800. await this.refreshData()
  801. this.crossPage.$on('refreshWorkorderDetail', async () => {
  802. await this.refreshData()
  803. })
  804. },
  805. onUnload() {
  806. this.crossPage.$off('refreshWorkorderDetail')
  807. },
  808. methods: {
  809. scan() {
  810. this.state = 0
  811. if (this.timeout) {
  812. clearTimeout(this.timeout)
  813. }
  814. this.scanCode()
  815. },
  816. back() {
  817. this.state = 0
  818. if (this.timeout) {
  819. clearTimeout(this.timeout)
  820. }
  821. this.$navToPage(
  822. {
  823. url: `/packageMaterial/pages/index?type=${this.detail_zf.goodsType}`
  824. },
  825. 'reLaunch'
  826. )
  827. },
  828. offTiming() {
  829. if (this.timeout) {
  830. clearTimeout(this.timeout)
  831. }
  832. },
  833. // 扫码
  834. async scanCode(item) {
  835. this.detail_zf = { ...item }
  836. this.orderId_zf = item.orderId
  837. var codeVal = await wxScanCode(['qrCode'])
  838. this.submitData(codeVal)
  839. },
  840. // 下单
  841. submitData(code) {
  842. this.$api
  843. .post('/pay/paid', {
  844. authCode: code,
  845. orderId: this.orderId_zf,
  846. payType: 'WECHAT'
  847. })
  848. .then(res => {
  849. this.detail_zf = res.data
  850. this.orderId_zf = res.data.orderId
  851. if (res.data.payStatus == 'PAID') {
  852. // 支付成功
  853. this.getPayList(() => {
  854. this.state = 2
  855. })
  856. } else {
  857. // 支付失败
  858. this.getPayList(() => {
  859. this.state = 4
  860. })
  861. }
  862. })
  863. .catch(res => {
  864. // 等待支付
  865. var [USERPAYING, orderId] = res.message.split('|')
  866. if (~USERPAYING.indexOf('USERPAYING') && !!orderId) {
  867. this.getPayList(() => {
  868. this.orderId_zf = orderId
  869. if (this.state == 0) {
  870. this.state = 1
  871. }
  872. this.getDetail__()
  873. })
  874. } else {
  875. this.$tips(res.message)
  876. }
  877. })
  878. },
  879. getDetail__(cb) {
  880. this.$api
  881. .post('/pay/getOrder', {
  882. orderId: this.orderId_zf
  883. })
  884. .then(res => {
  885. this.detail_zf = res.data
  886. if (res.data.payStatus == 'PAID') {
  887. this.state = 2
  888. } else {
  889. this.timeout = setTimeout(() => {
  890. this.getDetail__(cb)
  891. }, 1000)
  892. }
  893. cb?.()
  894. })
  895. .catch(res => {})
  896. .finally(res => {})
  897. },
  898. // 触发下拉刷新
  899. async refresherrefresh(e) {
  900. this.refresherTriggered = true
  901. await this.refreshData()
  902. },
  903. async changeTab(e) {
  904. this.curTab = e.value
  905. this.loadStatus = 1
  906. await this.refreshData()
  907. },
  908. async refreshData() {
  909. try {
  910. await this.getDetail()
  911. await this.getSettleList()
  912. if (this.curTab === 1) {
  913. // await this.getDetail();
  914. } else if (this.curTab === 2) {
  915. } else if (this.curTab === 3) {
  916. await this.getPayList()
  917. } else if (this.curTab === 4) {
  918. await this.getSettleList()
  919. }
  920. this.refresherTriggered = false
  921. this.loadStatus = 0
  922. } catch (e) {
  923. this.loadStatus = 2
  924. }
  925. },
  926. // 获取详情
  927. getDetail() {
  928. this.$api
  929. .post('/workerApply/detail', {
  930. orderBaseId: this.id
  931. })
  932. .then(res => {
  933. this.oldData = res.data
  934. })
  935. .catch(res => {})
  936. return new Promise((resolve, reject) => {
  937. this.$api
  938. .post('/pg/order/base/detail', {
  939. orderBaseId: this.id
  940. })
  941. .then(res => {
  942. this.detail = res.data
  943. console.log(res.data)
  944. console.log(
  945. `
  946. 完工时间: ${res.data.overTime}
  947. 工程师编号号: ${this.userInfo.workerNumber}
  948. 网点属性(attr): ${res.data.attr}
  949. 工单类型(orderType): ${res.data.orderType}
  950. 是否4.0(isImportExcel): ${res.data.isImportExcel}
  951. 4.0是否已经接单(isMeet): ${res.data.isMeet}
  952. 原工单状态(orderStatus): ${res.data.orderStatus} ==> 复合状态对应:${(orderStatus => {
  953. if (res.data?.isImportExcel && res.data?.isMeet === false) {
  954. return 'DJD'
  955. }
  956. if (['DYY'].includes(orderStatus)) {
  957. // 待预约
  958. return 'DYY'
  959. } else if (['DQD'].includes(orderStatus)) {
  960. // 待抢单
  961. return 'DQD'
  962. } else if (
  963. [
  964. 'DSHPG',
  965. 'CJ',
  966. 'YPD',
  967. 'DXSPD',
  968. 'DZBPG',
  969. 'DWDSPGP',
  970. 'DXSSPGP',
  971. 'DTJXSSPGP',
  972. 'DZBSPGP',
  973. 'DFZXPD',
  974. 'DFZXSPGP',
  975. 'XSBH',
  976. 'TJXSBH',
  977. 'ZBBH',
  978. 'FZXBH',
  979. 'FL'
  980. ].includes(orderStatus)
  981. ) {
  982. // 待商户派工
  983. return 'DSHPG'
  984. } else if (['DWDPG', 'DWDPD', 'WDBH'].includes(orderStatus)) {
  985. // 待网点派工
  986. return 'DWDPG'
  987. } else if (['DJD'].includes(orderStatus)) {
  988. // 待接单
  989. return 'DJD'
  990. } else if (['FWZ', 'GCSZT', 'BFWG', 'DSM', 'YZP'].includes(orderStatus)) {
  991. // 服务中
  992. return 'FWZ'
  993. } else if (['YCD'].includes(orderStatus)) {
  994. // 异常单
  995. return 'YCD'
  996. } else if (['YWG', 'GCSZX', 'WDWG', 'YWGO'].includes(orderStatus)) {
  997. // 已完工待结算
  998. return 'YWG'
  999. } else if (['YJS', 'LRCD'].includes(orderStatus)) {
  1000. // 已结算
  1001. return 'YJS'
  1002. } else if (['YQX', 'FWZT', 'YCGB', 'FWQX'].includes(orderStatus)) {
  1003. // 已取消
  1004. return 'YQX'
  1005. }
  1006. return ''
  1007. })(res.data.orderStatus)}
  1008. `
  1009. )
  1010. if (
  1011. this.behavior === 'lqdd' &&
  1012. !['DQD'].includes(res.data.orderStatus) &&
  1013. res.data.workerId !== this.$store.state.user.userId
  1014. ) {
  1015. this.$modal({
  1016. title: '提示',
  1017. content: '来晚啦,工单已经被抢走了~',
  1018. confirmText: '知道啦',
  1019. showCancel: false
  1020. })
  1021. .then(() => {
  1022. uni.switchTab({
  1023. url: '/pages/index/index'
  1024. })
  1025. })
  1026. .catch(() => {
  1027. uni.switchTab({
  1028. url: '/pages/index/index'
  1029. })
  1030. })
  1031. }
  1032. if (res.data.pgIncreOrderId) {
  1033. this.getIncreDetail(res.data.pgIncreOrderId)
  1034. }
  1035. resolve(1)
  1036. })
  1037. .catch(res => {
  1038. reject(0)
  1039. })
  1040. })
  1041. },
  1042. getIncreDetail(id) {
  1043. this.$api
  1044. .post('/increConfig/detailIncre', {
  1045. id
  1046. })
  1047. .then(res => {
  1048. this.increDetail = res.data
  1049. })
  1050. },
  1051. copyData() {
  1052. let name = this.detail.userName
  1053. let phone = this.detail.userMobile
  1054. let address = `${this.detail.gpsAddress ? this.detail.gpsAddress + this.detail.address : this.detail.address}`
  1055. this.$copy(`${name},${phone},${address}`)
  1056. },
  1057. async openFeedback() {
  1058. await this.getFeedbackList()
  1059. this.isShowFeedback = true
  1060. },
  1061. getFeedbackList() {
  1062. return new Promise((resolve, reject) => {
  1063. this.$api
  1064. .post('/pg/order/base/operator/list', {
  1065. orderBaseId: this.id
  1066. })
  1067. .then(res => {
  1068. let data = res.data.map(item => {
  1069. return {
  1070. title: item.type,
  1071. time: item.createTime,
  1072. content: item.content,
  1073. imgSrc: item.imgSrc
  1074. }
  1075. })
  1076. this.feedbackList = data
  1077. })
  1078. .finally(res => {
  1079. resolve(1)
  1080. })
  1081. })
  1082. },
  1083. // 获取支付信息
  1084. getPayList(cb) {
  1085. return new Promise((resolve, reject) => {
  1086. let url = ''
  1087. if (this.detail.rpProjectRepairId) {
  1088. url = '/engin/material/detailWorker'
  1089. } else {
  1090. url = '/changeOrder/getOrderList'
  1091. }
  1092. this.$api
  1093. .post(url, {
  1094. workerOrderId: this.id
  1095. })
  1096. .then(async res => {
  1097. this.payList = res.data.map(item => {
  1098. var gengduo = [
  1099. {
  1100. chargeType: 'SERV',
  1101. goodsName: '服务费用',
  1102. totalAmount: item.servicePrice || 0
  1103. },
  1104. {
  1105. chargeType: 'SERV',
  1106. goodsName: '其他费用',
  1107. totalAmount: item.otherPrice || 0
  1108. }
  1109. ]
  1110. if (this.detail.rpProjectRepairId) {
  1111. if (!item.rpMaterialOrderItems) {
  1112. item.rpMaterialOrderItems = []
  1113. }
  1114. item.rpMaterialOrderItems.push(...gengduo)
  1115. } else {
  1116. if (!item.workerOrderItems) {
  1117. item.workerOrderItems = []
  1118. }
  1119. item.workerOrderItems.push(...gengduo)
  1120. }
  1121. return { ...item }
  1122. })
  1123. cb?.()
  1124. resolve(1)
  1125. })
  1126. .catch(res => {
  1127. cb?.()
  1128. reject(0)
  1129. })
  1130. })
  1131. },
  1132. // 获取安装结算
  1133. getSettleList() {
  1134. return new Promise((resolve, reject) => {
  1135. this.$api
  1136. .post('/order/settle/norm/detail', {
  1137. orderId: this.id
  1138. })
  1139. .then(res => {
  1140. this.settleList = res.data
  1141. if (this.settleList.length > 0 && this.orderStatus_v == 'YJS') {
  1142. this.tabList[3].name = `员工结算(${this.settleList.reduce(
  1143. (total, obj) => total + obj.workerSettleAmount,
  1144. 0
  1145. )})`
  1146. } else {
  1147. this.tabList[3].name = `员工结算`
  1148. }
  1149. resolve(1)
  1150. })
  1151. .catch(res => {
  1152. reject(0)
  1153. })
  1154. })
  1155. },
  1156. // 预览图片
  1157. prevImg(url) {
  1158. uni.previewImage({
  1159. current: this.imageUrl + url,
  1160. urls: [this.imageUrl + url]
  1161. })
  1162. },
  1163. // 加急
  1164. actionUrgent(flag) {
  1165. this.$modal({
  1166. title: '加急操作',
  1167. content: '加急操作,会消息通知所有订单相关人员,请谨慎操作。'
  1168. })
  1169. .then(() => {
  1170. this.$api
  1171. .post('/pg/order/base/flag', {
  1172. orderBaseId: this.id,
  1173. orderFlagEnum: 'JIA_JI',
  1174. flag: flag
  1175. })
  1176. .then(res => {
  1177. this.$successToast()
  1178. this.getDetail()
  1179. this.crossPage.$emit('refreshWorkorderList', '')
  1180. })
  1181. })
  1182. .catch(() => {})
  1183. },
  1184. // 变更小工
  1185. biangengxiaogong() {
  1186. this.title = '更换小工'
  1187. this.selectionWorkersType = 3
  1188. this.item = { ...this.detail }
  1189. this.callback = () => {
  1190. this.$successToast()
  1191. this.getDetail()
  1192. this.crossPage.$emit('refreshWorkorderList', '')
  1193. this.$nextTick(() => {
  1194. this.item = null
  1195. this.selectionWorkersType = null
  1196. this.callback = null
  1197. this.title = null
  1198. })
  1199. }
  1200. },
  1201. // 接单
  1202. actionReceive() {
  1203. this.title = '接收确认'
  1204. this.selectionWorkersType = 1
  1205. this.item = { ...this.detail }
  1206. this.callback = () => {
  1207. this.$successToast()
  1208. this.getDetail()
  1209. this.crossPage.$emit('refreshWorkorderList', '')
  1210. this.$nextTick(() => {
  1211. this.item = null
  1212. this.selectionWorkersType = null
  1213. this.callback = null
  1214. this.title = null
  1215. })
  1216. }
  1217. // this.$modal({
  1218. // title: '接单确认',
  1219. // content: '确认接单?'
  1220. // })
  1221. // .then(() => {
  1222. // this.$api
  1223. // .post('/pg/order/base/rece', {
  1224. // orderBaseId: this.id
  1225. // })
  1226. // .then(res => {
  1227. // this.$successToast()
  1228. // this.getDetail()
  1229. // this.crossPage.$emit('refreshWorkorderList', '')
  1230. // })
  1231. // })
  1232. // .catch(() => {})
  1233. },
  1234. qdOrder(item) {
  1235. // this.title = '接收确认'
  1236. // this.selectionWorkersType = 2
  1237. // this.item = { ...item }
  1238. // this.callback = () => {
  1239. // this.$successToast()
  1240. // this.getDetail()
  1241. // this.crossPage.$emit('refreshWorkorderList', '')
  1242. // this.$nextTick(() => {
  1243. // this.item = null
  1244. // this.selectionWorkersType = null
  1245. // this.callback = null
  1246. // })
  1247. // }
  1248. this.$modal({
  1249. title: '抢单确认',
  1250. content: '确认抢单?'
  1251. })
  1252. .then(() => {
  1253. this.$api
  1254. .post('/pg/order/base/qd', {
  1255. orderBaseId: item.id
  1256. })
  1257. .then(res => {
  1258. this.$successToast()
  1259. this.getDetail()
  1260. this.crossPage.$emit('refreshWorkorderList', '')
  1261. })
  1262. })
  1263. .catch(() => {})
  1264. },
  1265. // 去收费
  1266. toCharge(type) {
  1267. if (type == 'M') {
  1268. this.$navToPage({
  1269. url: `/packageMaterial/pages/sale/orderList?type=${type}&oid=${this.id}&tabCurrent=1`
  1270. })
  1271. } else if (type == 'P') {
  1272. this.$navToPage({
  1273. url: `/packageMaterial/pages/newSale/orderList?type=${type}&oid=${this.id}&tabCurrent=1`
  1274. })
  1275. }
  1276. },
  1277. // 去配件申请
  1278. toPartsApply() {
  1279. this.$navToPage({
  1280. url: `/packageMaterial/pages/partsApply/form?id=${this.id}`
  1281. })
  1282. },
  1283. toNandufysq() {
  1284. this.$navToPage({
  1285. url: `/packageWorkorder/pages/nandufysq?id=${this.id}`
  1286. })
  1287. },
  1288. // 去过程反馈
  1289. toFeedback() {
  1290. this.$navToPage({
  1291. url: `/packageWorkorder/pages/processFeedback?id=${this.id}`
  1292. })
  1293. },
  1294. // 去过程反馈列表
  1295. toFeedbackList() {
  1296. this.$navToPage({
  1297. url: `/packageWorkorder/pages/feedbackList?id=${this.id}`
  1298. })
  1299. },
  1300. // 去完工明细
  1301. toOverDetail() {
  1302. this.$navToPage({
  1303. url: `/packageWorkorder/pages/overDetail?id=${this.id}`
  1304. })
  1305. }
  1306. }
  1307. }
  1308. </script>
  1309. <style lang="scss" scoped>
  1310. .all-container {
  1311. position: relative;
  1312. }
  1313. .bg {
  1314. position: absolute;
  1315. top: 0;
  1316. left: 0;
  1317. width: 100%;
  1318. height: 300rpx;
  1319. background: linear-gradient(179.48deg, rgba(200, 224, 251, 1) 0.45%, rgba(247, 247, 247, 1) 98.96%);
  1320. }
  1321. .status-container {
  1322. padding: 30rpx;
  1323. .status {
  1324. font-size: 36rpx;
  1325. font-weight: 500;
  1326. text {
  1327. margin-left: 12rpx;
  1328. }
  1329. }
  1330. .time {
  1331. font-size: 24rpx;
  1332. color: $sec-font;
  1333. margin-top: 12rpx;
  1334. }
  1335. }
  1336. .tab-container {
  1337. margin-bottom: 30rpx;
  1338. }
  1339. .card {
  1340. @include zj-card;
  1341. }
  1342. .common-title {
  1343. font-size: 36rpx;
  1344. font-weight: 600;
  1345. padding-bottom: 20rpx;
  1346. }
  1347. .common-title2 {
  1348. padding-bottom: 20rpx;
  1349. display: flex;
  1350. align-items: center;
  1351. justify-content: space-between;
  1352. .title {
  1353. font-size: 36rpx;
  1354. font-weight: 600;
  1355. }
  1356. .right {
  1357. font-size: 28rpx;
  1358. color: $theme-color;
  1359. display: flex;
  1360. align-items: center;
  1361. flex-wrap: wrap;
  1362. ::v-deep .u-button {
  1363. width: 175rpx;
  1364. margin: 0;
  1365. margin-left: 10rpx;
  1366. }
  1367. text {
  1368. font-size: 28rpx;
  1369. opacity: 0.5;
  1370. }
  1371. }
  1372. }
  1373. .content-container {
  1374. padding: 0 30rpx 30rpx;
  1375. }
  1376. .user-container {
  1377. .top {
  1378. padding: 30rpx;
  1379. .type {
  1380. display: flex;
  1381. align-items: center;
  1382. justify-content: space-between;
  1383. .left {
  1384. font-size: 36rpx;
  1385. color: $theme-color;
  1386. font-weight: 500;
  1387. }
  1388. .right {
  1389. font-size: 28rpx;
  1390. color: $theme-color;
  1391. }
  1392. }
  1393. .user {
  1394. font-weight: 500;
  1395. margin-top: 20rpx;
  1396. }
  1397. .address {
  1398. display: flex;
  1399. justify-content: space-between;
  1400. margin-top: 20rpx;
  1401. .text {
  1402. font-size: 28rpx;
  1403. flex: 1;
  1404. margin-right: 20rpx;
  1405. }
  1406. .ctrl {
  1407. font-size: 28rpx;
  1408. color: $theme-color;
  1409. .iconfont {
  1410. font-size: 28rpx;
  1411. margin-right: 4rpx;
  1412. }
  1413. }
  1414. }
  1415. }
  1416. .bottom {
  1417. border-top: 1px solid #eaeaea;
  1418. display: flex;
  1419. height: 80rpx;
  1420. .it {
  1421. flex: 1;
  1422. display: flex;
  1423. align-items: center;
  1424. justify-content: center;
  1425. font-size: 28rpx;
  1426. color: $theme-color;
  1427. &:last-child {
  1428. border-left: 1px solid #eaeaea;
  1429. }
  1430. .iconfont {
  1431. font-size: 36rpx;
  1432. margin-right: 8rpx;
  1433. }
  1434. }
  1435. }
  1436. }
  1437. .goods-container {
  1438. padding: 30rpx;
  1439. .item {
  1440. border-bottom: 1px solid #d6e0f2;
  1441. padding: 20rpx 0;
  1442. &:last-child {
  1443. border: none;
  1444. }
  1445. .main {
  1446. display: flex;
  1447. image {
  1448. width: 140rpx;
  1449. height: 140rpx;
  1450. flex-shrink: 0;
  1451. }
  1452. .info {
  1453. flex: 1;
  1454. margin-left: 20rpx;
  1455. .name {
  1456. display: flex;
  1457. justify-content: space-between;
  1458. .left {
  1459. font-weight: 500;
  1460. }
  1461. .right {
  1462. margin-left: 30rpx;
  1463. color: $sec-font;
  1464. }
  1465. }
  1466. .tags {
  1467. display: flex;
  1468. flex-wrap: wrap;
  1469. .it {
  1470. height: 42rpx;
  1471. padding: 0 16rpx;
  1472. background: #f4f5f9;
  1473. border-radius: 8rpx;
  1474. font-size: 24rpx;
  1475. display: flex;
  1476. align-items: center;
  1477. justify-content: center;
  1478. margin-top: 12rpx;
  1479. margin-right: 8rpx;
  1480. &:last-child {
  1481. margin-right: 0;
  1482. }
  1483. }
  1484. }
  1485. }
  1486. }
  1487. .images {
  1488. display: flex;
  1489. flex-wrap: wrap;
  1490. margin-top: 24rpx;
  1491. .it {
  1492. margin-right: 30rpx;
  1493. image {
  1494. width: 116rpx;
  1495. height: 116rpx;
  1496. }
  1497. .text {
  1498. text-align: center;
  1499. color: $sec-font;
  1500. margin-top: 8rpx;
  1501. }
  1502. }
  1503. }
  1504. }
  1505. .ctrl {
  1506. display: flex;
  1507. align-items: center;
  1508. justify-content: center;
  1509. margin-top: 10rpx;
  1510. text {
  1511. color: $sec-font;
  1512. }
  1513. .iconfont {
  1514. font-size: 24rpx;
  1515. transform: rotate(-90deg);
  1516. margin-left: 10rpx;
  1517. &.is {
  1518. transform: rotate(90deg);
  1519. }
  1520. }
  1521. }
  1522. }
  1523. .info-container {
  1524. padding: 30rpx;
  1525. .row {
  1526. display: flex;
  1527. margin-top: 20rpx;
  1528. &:first-child {
  1529. margin-top: 0;
  1530. }
  1531. .label {
  1532. font-size: 28rpx;
  1533. color: $sec-font;
  1534. margin-right: 20rpx;
  1535. flex-shrink: 0;
  1536. }
  1537. .value {
  1538. font-size: 28rpx;
  1539. }
  1540. .ctrl {
  1541. font-size: 28rpx;
  1542. color: $theme-color;
  1543. margin-left: 20rpx;
  1544. }
  1545. }
  1546. }
  1547. .product-container {
  1548. padding: 30rpx;
  1549. margin-bottom: 30rpx;
  1550. .row {
  1551. display: flex;
  1552. .label {
  1553. font-size: 28rpx;
  1554. color: $sec-font;
  1555. margin-right: 20rpx;
  1556. flex-shrink: 0;
  1557. }
  1558. .value {
  1559. font-size: 28rpx;
  1560. flex: 1;
  1561. }
  1562. }
  1563. .product {
  1564. background: #f5f5f5;
  1565. border-radius: 12rpx;
  1566. padding: 20rpx;
  1567. .it {
  1568. display: flex;
  1569. align-items: flex-end;
  1570. margin-bottom: 20rpx;
  1571. .name {
  1572. flex: 1;
  1573. font-size: 28rpx;
  1574. font-weight: 500;
  1575. text {
  1576. color: $sec-font;
  1577. margin-left: 12rpx;
  1578. font-weight: normal;
  1579. }
  1580. }
  1581. .price {
  1582. margin-left: 30rpx;
  1583. font-size: 28rpx;
  1584. font-weight: 500;
  1585. }
  1586. }
  1587. .total {
  1588. display: flex;
  1589. align-items: center;
  1590. justify-content: flex-end;
  1591. margin-top: 30rpx;
  1592. .text {
  1593. font-size: 28rpx;
  1594. color: $sec-font;
  1595. }
  1596. .price {
  1597. font-size: 28rpx;
  1598. color: $minor-color;
  1599. font-weight: 500;
  1600. }
  1601. }
  1602. }
  1603. .bottom {
  1604. margin-top: 20rpx;
  1605. display: flex;
  1606. align-items: center;
  1607. justify-content: space-between;
  1608. .left {
  1609. font-size: 28rpx;
  1610. font-weight: 500;
  1611. }
  1612. .right {
  1613. display: flex;
  1614. align-items: center;
  1615. .text {
  1616. font-size: 28rpx;
  1617. color: $sec-font;
  1618. }
  1619. .price {
  1620. font-size: 28rpx;
  1621. color: $minor-color;
  1622. font-weight: 500;
  1623. }
  1624. }
  1625. }
  1626. }
  1627. .feedback-container {
  1628. padding: 30rpx;
  1629. .list {
  1630. .item {
  1631. display: flex;
  1632. padding: 10rpx 0;
  1633. .main {
  1634. margin-left: 20rpx;
  1635. .name {
  1636. font-weight: 500;
  1637. line-height: 32rpx;
  1638. }
  1639. .time {
  1640. font-size: 28rpx;
  1641. margin-top: 12rpx;
  1642. color: $sec-font;
  1643. line-height: 32rpx;
  1644. }
  1645. .content {
  1646. font-size: 28rpx;
  1647. margin-top: 12rpx;
  1648. line-height: 32rpx;
  1649. }
  1650. }
  1651. }
  1652. }
  1653. }
  1654. .bottom-container {
  1655. box-sizing: border-box;
  1656. display: flex;
  1657. align-items: center;
  1658. justify-content: flex-end;
  1659. flex-wrap: wrap;
  1660. padding: 20rpx 20rpx 20rpx 0;
  1661. ::v-deep .u-button {
  1662. width: 175rpx;
  1663. box-sizing: border-box;
  1664. padding: 10rpx;
  1665. margin: 0;
  1666. margin-left: 10rpx;
  1667. margin-bottom: 10rpx;
  1668. }
  1669. }
  1670. .feedback-dialog {
  1671. padding: 30rpx 30rpx 0;
  1672. .title {
  1673. margin-bottom: 30rpx;
  1674. text-align: center;
  1675. font-weight: 600;
  1676. font-size: 36rpx;
  1677. }
  1678. .content {
  1679. padding-bottom: 30rpx;
  1680. max-height: 800rpx;
  1681. overflow-y: scroll;
  1682. }
  1683. }
  1684. .imgs {
  1685. display: flex;
  1686. flex-wrap: wrap;
  1687. .it {
  1688. display: flex;
  1689. flex-direction: column;
  1690. align-items: center;
  1691. position: relative;
  1692. margin-top: 30rpx;
  1693. margin-right: 30rpx;
  1694. &:nth-child(3n) {
  1695. margin-right: 0;
  1696. }
  1697. image {
  1698. width: 190rpx;
  1699. height: 190rpx;
  1700. background: #f4f4f7;
  1701. border-radius: 20rpx;
  1702. overflow: hidden;
  1703. }
  1704. .name {
  1705. margin-top: 24rpx;
  1706. color: $sec-font;
  1707. text {
  1708. color: $minor-color;
  1709. }
  1710. }
  1711. }
  1712. }
  1713. </style>