suspendIndex.uvue 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800
  1. <template>
  2. <view class="detail-page">
  3. <scroll-view class="detail-content" :scroll-y="true">
  4. <!-- 工单信息 -->
  5. <view class="info-section">
  6. <view class="section-title">
  7. <text class="section-title-text">工单信息</text>
  8. </view>
  9. <view class="info-card">
  10. <view class="info-item">
  11. <text class="info-label">工单编码</text>
  12. <text class="info-value">{{ detailData.workOrderProjectNo ?? '' }}</text>
  13. </view>
  14. <view class="info-item">
  15. <text class="info-label">工单类型</text>
  16. <text class="info-value">{{ detailData.orderType == 1 ? '维修工单' : '维保工单' }}</text>
  17. </view>
  18. <view class="info-item">
  19. <text class="info-label">风机编号</text>
  20. <text class="info-value">{{ detailData.pcsDeviceName ?? '' }}</text>
  21. </view>
  22. <view class="info-item">
  23. <text class="info-label">维保中心</text>
  24. <text class="info-value">{{ detailData.gxtCenter ?? '' }}</text>
  25. </view>
  26. <view class="info-item">
  27. <text class="info-label">场站</text>
  28. <text class="info-value">{{ detailData.pcsStationName ?? '' }}</text>
  29. </view>
  30. <!-- <view class="info-item">
  31. <text class="info-label">品牌</text>
  32. <text class="info-value">{{ detailData.model ?? '' }}</text>
  33. </view> -->
  34. <view class="info-item">
  35. <text class="info-label">机型</text>
  36. <text class="info-value">{{ detailData.brand ?? '' }} {{ detailData.model ?? '' }}</text>
  37. </view>
  38. <view class="info-item">
  39. <text class="info-label">接单时间</text>
  40. <text class="info-value">{{ detailData.acceptTime ?? '' }}</text>
  41. </view>
  42. <!-- <view class="info-item">
  43. <text class="info-label">挂起原因</text>
  44. <view class="form-picker" @click="showReasonPicker = true">
  45. <view class="picker-display">
  46. <text v-if="suspendReason" class="selected-value">{{ suspendReason }}</text>
  47. <text v-else class="placeholder">请选择挂起原因</text>
  48. <text class="arrow">▼</text>
  49. </view>
  50. </view>
  51. </view> -->
  52. </view>
  53. </view>
  54. <!-- <view class="info-section">
  55. <view class="section-title">
  56. <text class="section-title-text">工作负责人</text>
  57. </view>
  58. <view class="info-card">
  59. <view class="info-item">
  60. <input class="input" type="text" placeholder="请输入工作负责人" v-model="teamLeaderName" />
  61. </view>
  62. </view>
  63. </view> -->
  64. <!-- 工作负责人选择 -->
  65. <view class="info-section">
  66. <!-- <view class="section-title">
  67. <text class="section-title-text">挂起原因<text style="color: red;">*</text></text>
  68. </view> -->
  69. <view class="info-card">
  70. <view class="info-item">
  71. <view class="info-label">
  72. <text class="form-label required">挂起原因<text style="color: red;">*</text></text>
  73. </view>
  74. <!-- <text class="form-label required">挂起原因</text> -->
  75. <view class="info-value">
  76. <view class="form-picker" @click="showReasonPicker = true">
  77. <view class="picker-display">
  78. <text v-if="suspendReason" class="selected-value">{{ suspendReason }}</text>
  79. <text v-else class="placeholder">请选择挂起原因</text>
  80. <text class="arrow">▼</text>
  81. </view>
  82. </view>
  83. </view>
  84. </view>
  85. <view class="info-item" v-if="detailData.suspendReason == '4'">
  86. <view class="info-label">
  87. <text class="form-label required">说明<text style="color: red;">*</text></text>
  88. </view>
  89. <view class="info-value">
  90. <textarea
  91. class="reject-reason-textarea"
  92. placeholder="请输入说明(必填)"
  93. v-model="suspendExplain"
  94. maxlength="500"
  95. :show-confirm-bar="false"
  96. auto-height
  97. ></textarea>
  98. </view>
  99. </view>
  100. </view>
  101. </view>
  102. <!-- 自定义选择器弹窗 -->
  103. <view v-if="showReasonPicker" class="picker-modal">
  104. <view class="modal-mask" @click="showReasonPicker = false"></view>
  105. <view class="modal-content">
  106. <view class="modal-header">
  107. <text class="modal-title">挂起原因</text>
  108. <text class="modal-close" @click="showReasonPicker = false">取消</text>
  109. </view>
  110. <scroll-view class="modal-body" scroll-y="true">
  111. <view
  112. v-for="(option, index) in suspendReasonOptions"
  113. :key="index"
  114. class="picker-option"
  115. :class="{ 'selected': index === selectedReasonIndex }"
  116. @click="selectLeaderManually(index)"
  117. >
  118. <text class="option-text">{{ option.label }}</text>
  119. <text v-if="index === selectedReasonIndex" class="option-check">✓</text>
  120. </view>
  121. </scroll-view>
  122. </view>
  123. </view>
  124. <!-- 工单流转 -->
  125. <!-- <view class="info-section">
  126. <view class="section-title">
  127. <text class="section-title-text">工单流转</text>
  128. </view>
  129. <view class="info-card" v-if="detailData.workOrderFlowList != null && detailData.workOrderFlowList.length > 0">
  130. <view class="flow-item" v-for="(flow, index) in detailData.workOrderFlowList" :key="index">
  131. <view class="flow-header">
  132. <text class="flow-operator">{{ flow.operatorName ?? '未知操作人' }}</text>
  133. <text class="flow-time">{{ flow.actionTime ?? '' }}</text>
  134. </view>
  135. <view class="flow-content">
  136. <text class="flow-action">{{ getActionTypeName(flow.actionType) }}</text>
  137. <text class="flow-remark" v-if="flow.actionRemark">{{ flow.actionRemark }}</text>
  138. </view>
  139. </view>
  140. </view>
  141. <view class="info-card" v-else>
  142. <view class="no-data">暂无流转记录</view>
  143. </view>
  144. </view> -->
  145. </scroll-view>
  146. <!-- 接单按钮 -->
  147. <view class="accept-button-container" v-if="checkPermi(detailData.orderType == 2 ? ['gxt:maintenance:order:suspend'] : ['gxt:repairOrder:suspend'])">
  148. <button class="accept-button" @click="handleSuspendOrder">{{ isDealing ? '挂起中...' : '挂 起' }}</button>
  149. </view>
  150. <!-- 加载中状态 -->
  151. <view v-if="loading" class="loading-mask">
  152. <text class="loading-text">加载中...</text>
  153. </view>
  154. </view>
  155. </template>
  156. <script setup lang="uts">
  157. import { ref } from 'vue'
  158. import type { acceptOrderInfo } from '../../../types/order'
  159. import type { WorkOrderFlow } from '../../../types/flow'
  160. import { getOrderInfoById, getRepairOrderInfoById, suspendOrder } from '../../../api/order/detail'
  161. import type { SysDictData } from '../../../types/dict'
  162. import { getDictDataByType } from '../../../api/dict/index'
  163. import type { UserInfo } from '../../../types/user'
  164. import {checkPermi} from '../../../utils/storage'
  165. const teamLeaderName = ref<string>("")
  166. const statusDictList = ref<SysDictData[]>([]) // 工单状态字典列表
  167. // 添加字典加载状态
  168. const dictLoaded = ref<boolean>(false)
  169. // 详情数据
  170. const detailData = ref<acceptOrderInfo>({
  171. orderType: 0,
  172. id: 0,
  173. teamLeaderId: 0,
  174. acceptUserId: 0,
  175. teamLeaderName: null,
  176. acceptUserName: null,
  177. acceptTime: null,
  178. assignTime: null,
  179. assignUserName: null,
  180. status: 0,
  181. workOrderProjectNo: null,
  182. workOrderStatus: null,
  183. gxtCenterId: 0,
  184. gxtCenter: null,
  185. pcsStationId: 0,
  186. pcsStationName: null,
  187. pcsDeviceId: 0,
  188. pcsDeviceName: null,
  189. brand: null,
  190. model: null,
  191. createTime: null,
  192. workOrderFlowList: null,
  193. suspendReason: null,
  194. rejectionReason: null,
  195. updateTime: null, // 新增字段
  196. workEndTime: null // 新增字段
  197. })
  198. // 选择器选项类型
  199. type PickerOption = {
  200. label: string
  201. value: string
  202. }
  203. // 选中的挂起原因
  204. const suspendReason = ref<string>('')
  205. const selectedReasonIndex = ref<number>(-1)
  206. const suspendReasonOptions = ref<PickerOption[]>([])
  207. const showReasonPicker = ref<boolean>(false)
  208. const suspendExplain = ref<string>("")
  209. // 获取负责人列表(使用用户列表接口)
  210. const dictList = async (): Promise<void> => {
  211. try {
  212. const result = await getDictDataByType('gxt_order_suspend_reason')
  213. const resultObj = result as UTSJSONObject
  214. if (resultObj['code'] == 200) {
  215. const data = resultObj['data'] as any[]
  216. const options: PickerOption[] = []
  217. if (data.length > 0) {
  218. for (let i = 0; i < data.length; i++) {
  219. const item = data[i] as UTSJSONObject
  220. let dictItem: SysDictData = {
  221. dictValue: item['dictValue'] as string | null,
  222. dictLabel: item['dictLabel'] as string | null,
  223. dictCode: null,
  224. dictSort: null,
  225. dictType: null,
  226. cssClass: null,
  227. listClass: null,
  228. isDefault: null,
  229. status: null,
  230. default: null,
  231. createTime: null,
  232. remark: null
  233. }
  234. // 构建选择器选项
  235. options.push({
  236. label: dictItem.dictLabel ?? '',
  237. value: dictItem.dictValue ?? ''
  238. })
  239. }
  240. }
  241. suspendReasonOptions.value = options
  242. }
  243. } catch (e: any) {
  244. console.error('获取挂起原因失败:', e.message)
  245. }
  246. }
  247. // 手动选择负责人
  248. const selectLeaderManually = (index: number): void => {
  249. selectedReasonIndex.value = index
  250. if (index >= 0 && index < suspendReasonOptions.value.length) {
  251. const selectedOption = suspendReasonOptions.value[index]
  252. suspendReason.value = selectedOption.label
  253. detailData.value.suspendReason = selectedOption.value
  254. console.log("=======",detailData.value.suspendReason)
  255. }
  256. showReasonPicker.value = false
  257. }
  258. // 获取工单状态字典列表
  259. const loadStatusDictList = async (): Promise<void> => {
  260. try {
  261. const result = await getDictDataByType('gxt_repair_order_flow_action_type')
  262. const resultObj = result as UTSJSONObject
  263. if (resultObj['code'] == 200) {
  264. const data = resultObj['data'] as any[]
  265. const dictData: SysDictData[] = []
  266. if (data.length > 0) {
  267. for (let i = 0; i < data.length; i++) {
  268. const item = data[i] as UTSJSONObject
  269. // 只提取需要的字段
  270. const dictItem: SysDictData = {
  271. dictValue: item['dictValue'] as string | null,
  272. dictLabel: item['dictLabel'] as string | null,
  273. dictCode: null,
  274. dictSort: null,
  275. dictType: null,
  276. cssClass: null,
  277. listClass: null,
  278. isDefault: null,
  279. status: null,
  280. default: null,
  281. createTime: null,
  282. remark: null
  283. }
  284. dictData.push(dictItem)
  285. }
  286. }
  287. statusDictList.value = dictData
  288. dictLoaded.value = true
  289. }
  290. } catch (e: any) {
  291. console.error('获取工单状态字典失败:', e.message)
  292. dictLoaded.value = true
  293. }
  294. }
  295. const isDealing = ref(false)
  296. const hasDealed = ref(false)
  297. // 处理接单操作
  298. const handleSuspendOrder = async (): Promise<void> => {
  299. if (suspendReason.value == null || suspendReason.value.trim() === '') {
  300. uni.showToast({
  301. title: '请选择挂起原因',
  302. icon: 'none'
  303. })
  304. return
  305. }
  306. if ((suspendExplain.value == '' || suspendExplain.value.trim() === '') && detailData.value.suspendReason == '4') {
  307. uni.showToast({
  308. title: '请输入说明',
  309. icon: 'none'
  310. })
  311. return
  312. }
  313. if (isDealing.value || hasDealed.value) return // 双重保险
  314. isDealing.value = true
  315. detailData.value.workOrderStatus = 'to_approve'
  316. detailData.value.rejectionReason = suspendExplain.value
  317. try {
  318. const result = await suspendOrder(detailData.value)
  319. const resultObj = result as UTSJSONObject
  320. const code = resultObj['code'] as number
  321. if (code == 200) {
  322. uni.showToast({
  323. title: '挂起成功',
  324. icon: 'success'
  325. })
  326. hasDealed.value = true
  327. // 使用事件总线通知列表页面刷新
  328. uni.$emit('refreshOrderList', {})
  329. uni.$emit('refreshAssignedCount')
  330. uni.$emit('refreshOverdueCount')
  331. // 接单成功后返回上一页
  332. setTimeout(() => {
  333. uni.navigateBack()
  334. }, 800)
  335. } else {
  336. // 处理业务错误
  337. uni.showToast({
  338. title: resultObj['msg'] as string,
  339. icon: 'none'
  340. })
  341. }
  342. } catch (error: any) {
  343. console.error('请求失败:', error);
  344. uni.showToast({
  345. title: error.message ?? '挂起失败',
  346. icon: 'none'
  347. })
  348. } finally {
  349. isDealing.value = false // 无论成功失败都解锁
  350. }
  351. }
  352. const loading = ref<boolean>(false)
  353. // 获取操作类型名称
  354. const getActionTypeName = (item: string | null): string | null => {
  355. if (item == null) return ''
  356. // const orderInfoItem = item as orderInfo
  357. const rawStatus = item
  358. if (rawStatus==null) return ''
  359. // 如果字典尚未加载,返回原始值
  360. if (!dictLoaded.value) {
  361. return rawStatus
  362. }
  363. // 查找字典中对应的标签
  364. const dictItem = statusDictList.value.find(dict => dict.dictValue == rawStatus)
  365. return dictItem!=null ? dictItem.dictLabel : rawStatus
  366. }
  367. // 加载详情数据
  368. const loadDetail = async (id: string, orderType?: number): Promise<void> => {
  369. try {
  370. loading.value = true
  371. let result: any;
  372. // 根据orderType决定调用哪个API
  373. if (orderType == 1) {
  374. // 维修工单
  375. result = await getRepairOrderInfoById(id)
  376. } else {
  377. // 维保工单
  378. result = await getOrderInfoById(id)
  379. }
  380. // 提取响应数据
  381. const resultObj = result as UTSJSONObject
  382. const code = resultObj['code'] as number
  383. const data = resultObj['data'] as UTSJSONObject | null
  384. if (code == 200 && data != null) {
  385. // 处理工单流转列表
  386. let workOrderFlowList: WorkOrderFlow[] | null = null
  387. let flowList: UTSJSONObject[] = []
  388. if (orderType == 1) {
  389. // 维修工单
  390. flowList = data['repairOrderFlowList'] as UTSJSONObject[]
  391. } else {
  392. // 维保工单
  393. flowList = data['workOrderFlowList'] as UTSJSONObject[]
  394. }
  395. if (flowList != null) {
  396. workOrderFlowList = []
  397. for (let i = 0; i < flowList.length; i++) {
  398. const flowItem = flowList[i]
  399. const flow: WorkOrderFlow = {
  400. id: flowItem['id'] as Number,
  401. orderId: flowItem['orderId'] as Number,
  402. orderCode: flowItem['orderCode'] as string,
  403. actionType: flowItem['actionType'] as string,
  404. fromStatus: flowItem['fromStatus'] as string | null,
  405. toStatus: flowItem['toStatus'] as string,
  406. operatorId: flowItem['operatorId'] as Number | null,
  407. operatorName: flowItem['operatorName'] as string | null,
  408. actionTime: flowItem['actionTime'] as string,
  409. actionRemark: flowItem['actionRemark'] as string | null,
  410. createBy: flowItem['createBy'] as string | null,
  411. createTime: flowItem['createTime'] as string | null
  412. }
  413. workOrderFlowList.push(flow)
  414. }
  415. }
  416. // 转换数据
  417. const orderDtail: acceptOrderInfo = {
  418. orderType: data['orderType'] as Number,
  419. id: data['id'] as Number,
  420. teamLeaderId: data['teamLeaderId'] != null ? (data['teamLeaderId'] as Number) : 0,
  421. acceptUserId: data['acceptUserId'] != null ? (data['acceptUserId'] as Number) : 0,
  422. teamLeaderName: data['teamLeaderName'] as string | null,
  423. acceptUserName: data['acceptUserName'] as string | null,
  424. acceptTime: data['acceptTime'] as string | null,
  425. assignTime: data['assignTime'] as string | null,
  426. assignUserName: data['assignUserName'] as string | null,
  427. status: (data['status']==null)?0:data['status'] as Number,
  428. workOrderProjectNo: data['workOrderProjectNo'] as string | null,
  429. workOrderStatus: data['workOrderStatus'] as string | null,
  430. gxtCenterId: data['gxtCenterId'] as Number | 0,
  431. gxtCenter: data['gxtCenter'] as string | null,
  432. pcsStationId: data['pcsStationId'] as Number | 0,
  433. pcsStationName: data['pcsStationName'] as string | null,
  434. pcsDeviceId: data['pcsDeviceId'] as Number | 0,
  435. pcsDeviceName: data['pcsDeviceName'] as string | null,
  436. brand: data['brand'] as string | null,
  437. model: data['model'] as string | null,
  438. createTime: data['createTime'] as string | null,
  439. workOrderFlowList: workOrderFlowList,
  440. suspendReason: data['suspendReason'] as string | null,
  441. rejectionReason: data['rejectionReason'] as string | null,
  442. updateTime: data['updateTime'] as string | null, // 新增字段
  443. workEndTime: data['workEndTime'] as string | null // 新增字段
  444. }
  445. detailData.value = orderDtail
  446. // 如果工单数据中已有负责人信息,设置到输入框中
  447. if (orderDtail.teamLeaderName != null && orderDtail.teamLeaderName.length > 0) {
  448. teamLeaderName.value = orderDtail.teamLeaderName as string
  449. }
  450. dictList()
  451. } else {
  452. const msg = resultObj['msg'] as string | null
  453. uni.showToast({
  454. title: msg ?? '加载失败',
  455. icon: 'none'
  456. })
  457. }
  458. } catch (e: any) {
  459. uni.showToast({
  460. title: e.message ?? '加载失败',
  461. icon: 'none'
  462. })
  463. } finally {
  464. loading.value = false
  465. }
  466. }
  467. // 页面加载
  468. onLoad((options: any) => {
  469. const params = options as UTSJSONObject
  470. const id = params['id'] as string | null
  471. const orderTypeParam = params['orderType'] as string | null
  472. if (id != null && orderTypeParam != null) {
  473. // 先尝试从参数中获取orderType
  474. const orderTypeNumber = parseInt(orderTypeParam)
  475. loadDetail(id, orderTypeNumber)
  476. }
  477. })
  478. // 初始化
  479. onMounted(() => {
  480. loadStatusDictList()
  481. })
  482. </script>
  483. <style lang="scss">
  484. .detail-page {
  485. flex: 1;
  486. background-color: #e8f0f9;
  487. }
  488. .detail-content {
  489. flex: 1;
  490. padding: 20rpx 0;
  491. }
  492. .info-section {
  493. margin: 0 30rpx 24rpx;
  494. .section-title {
  495. position: relative;
  496. padding-left: 20rpx;
  497. margin-bottom: 20rpx;
  498. &::before {
  499. // content: '';
  500. position: absolute;
  501. left: 0;
  502. top: 50%;
  503. transform: translateY(-50%);
  504. width: 8rpx;
  505. height: 32rpx;
  506. background-color: #007aff;
  507. border-radius: 4rpx;
  508. }
  509. &-text {
  510. font-size: 32rpx;
  511. font-weight: bold;
  512. color: #333333;
  513. }
  514. }
  515. .info-card {
  516. background-color: #ffffff;
  517. border-radius: 16rpx;
  518. padding: 30rpx;
  519. .info-item {
  520. flex-direction: row;
  521. padding: 20rpx 0;
  522. border-bottom: 1rpx solid #f0f0f0;
  523. &:last-child {
  524. border-bottom: none;
  525. }
  526. &.full-width {
  527. flex-direction: column;
  528. .info-label {
  529. margin-bottom: 12rpx;
  530. }
  531. .info-value {
  532. line-height: 44rpx;
  533. }
  534. }
  535. .info-label {
  536. width: 240rpx;
  537. font-size: 28rpx;
  538. color: #666666;
  539. white-space: nowrap;
  540. }
  541. .info-value {
  542. flex: 1;
  543. font-size: 28rpx;
  544. color: #333333;
  545. text-align: right;
  546. &.highlight {
  547. color: #007aff;
  548. font-weight: bold;
  549. }
  550. &.input {
  551. text-align: left;
  552. border: 1rpx solid #e0e0e0;
  553. border-radius: 8rpx;
  554. padding: 10rpx;
  555. }
  556. }
  557. }
  558. .flow-item {
  559. padding: 20rpx 0;
  560. border-bottom: 1rpx solid #f0f0f0;
  561. &:last-child {
  562. border-bottom: none;
  563. }
  564. .flow-header {
  565. flex-direction: row;
  566. justify-content: space-between;
  567. margin-bottom: 10rpx;
  568. .flow-operator {
  569. font-size: 28rpx;
  570. color: #333333;
  571. font-weight: bold;
  572. }
  573. .flow-time {
  574. font-size: 24rpx;
  575. color: #999999;
  576. }
  577. }
  578. .flow-content {
  579. flex-direction: column;
  580. .flow-action {
  581. font-size: 26rpx;
  582. color: #666666;
  583. margin-bottom: 8rpx;
  584. }
  585. .flow-remark {
  586. font-size: 24rpx;
  587. color: #999999;
  588. background-color: #f5f5f5;
  589. padding: 10rpx;
  590. border-radius: 8rpx;
  591. }
  592. }
  593. }
  594. .no-data {
  595. text-align: center;
  596. padding: 40rpx 0;
  597. font-size: 28rpx;
  598. color: #999999;
  599. }
  600. }
  601. }
  602. .accept-button-container {
  603. padding: 30rpx 30rpx 50rpx;
  604. background-color: #ffffff;
  605. .accept-button {
  606. width: 100%;
  607. height: 80rpx;
  608. background-color: #007aff;
  609. color: #ffffff;
  610. font-size: 32rpx;
  611. border-radius: 16rpx;
  612. border: none;
  613. &:active {
  614. background-color: #0062cc;
  615. }
  616. }
  617. }
  618. .loading-mask {
  619. position: absolute;
  620. top: 0;
  621. left: 0;
  622. right: 0;
  623. bottom: 0;
  624. justify-content: center;
  625. align-items: center;
  626. background-color: rgba(0, 0, 0, 0.3);
  627. .loading-text {
  628. padding: 30rpx 60rpx;
  629. background-color: rgba(0, 0, 0, 0.7);
  630. color: #ffffff;
  631. font-size: 28rpx;
  632. border-radius: 12rpx;
  633. }
  634. }
  635. .picker-modal {
  636. position: fixed;
  637. top: 0;
  638. left: 0;
  639. right: 0;
  640. bottom: 0;
  641. z-index: 1000;
  642. }
  643. .modal-mask {
  644. position: absolute;
  645. top: 0;
  646. left: 0;
  647. right: 0;
  648. bottom: 0;
  649. background-color: rgba(0, 0, 0, 0.5);
  650. }
  651. .modal-content {
  652. position: absolute;
  653. bottom: 0;
  654. left: 0;
  655. right: 0;
  656. background-color: #ffffff;
  657. border-top-left-radius: 16rpx;
  658. border-top-right-radius: 16rpx;
  659. max-height: 700rpx;
  660. }
  661. .modal-header {
  662. flex-direction: row;
  663. justify-content: space-between;
  664. align-items: center;
  665. padding: 30rpx;
  666. border-bottom: 1rpx solid #f0f0f0;
  667. }
  668. .modal-title {
  669. font-size: 32rpx;
  670. font-weight: bold;
  671. color: #333333;
  672. }
  673. .modal-close {
  674. font-size: 28rpx;
  675. color: #007aff;
  676. }
  677. .modal-body {
  678. max-height: 600rpx;
  679. }
  680. .picker-option {
  681. flex-direction: row;
  682. justify-content: space-between;
  683. align-items: center;
  684. padding: 24rpx 30rpx;
  685. border-bottom: 1rpx solid #f0f0f0;
  686. }
  687. .picker-option.selected {
  688. background-color: #f8f9fa;
  689. }
  690. .option-text {
  691. font-size: 28rpx;
  692. color: #333333;
  693. }
  694. .option-check {
  695. font-size: 28rpx;
  696. color: #007aff;
  697. }
  698. .form-picker {
  699. flex: 1;
  700. }
  701. .picker-display {
  702. flex-direction: row;
  703. justify-content: space-between;
  704. align-items: center;
  705. min-height: 40rpx;
  706. }
  707. .selected-value {
  708. font-size: 28rpx;
  709. color: #333333;
  710. }
  711. .placeholder {
  712. font-size: 28rpx;
  713. color: #999999;
  714. }
  715. .arrow {
  716. font-size: 24rpx;
  717. color: #999999;
  718. margin-left: 12rpx;
  719. }
  720. </style>