您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

order.vue 6.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415
  1. <!-- 订单列表2 -->
  2. <template>
  3. <filter>
  4. <empty-view v-if="!data.login" mode="permission" content="请先登录再查看订单" btnTxt="立即登录"
  5. @btnClick="$util.navTo('/login/login')">
  6. </empty-view>
  7. <view class="list-wrapper" v-else>
  8. <view class="top-content">
  9. <order-tabbar ref="tabbarRef" :tabs="data.tabsList" v-model:curIndex="data.tabIndex"
  10. v-if="data.tabsList.length > 0"></order-tabbar>
  11. </view>
  12. <order-list-item ref="mescrollItem" :index="data.tabIndex"
  13. :refresh="data.refresh">
  14. </order-list-item>
  15. </view>
  16. </filter>
  17. </template>
  18. <script setup lang="ts">
  19. import orderTabbar from "./components/order-tabbar.vue";
  20. import orderListItem from "./components/order-list-item";
  21. import useOrderList from "@/composables/order/useOrderList";
  22. import filter from '@/components/filter/filter.vue';
  23. import {onUnload,onLoad} from '@dcloudio/uni-app'
  24. import { reactive } from "vue";
  25. const {
  26. data,
  27. tabbarRef
  28. } = useOrderList();
  29. onLoad((option : any) => {
  30. if(option.indexPage){
  31. state.indexPage = option.indexPage
  32. }
  33. })
  34. onUnload(()=>{
  35. if(state.indexPage == 1){
  36. uni.reLaunch({
  37. url: `/pages/index/index`
  38. });
  39. }
  40. })
  41. const state = reactive({
  42. indexPage:0
  43. });
  44. </script>
  45. <style lang="scss">
  46. page {
  47. background: #E9EDF0;
  48. }
  49. :deep(.u-mode-center-box) {
  50. border-radius: 20rpx;
  51. }
  52. </style>
  53. <style lang="scss" scoped>
  54. .top-content {
  55. position: fixed;
  56. left: 0;
  57. z-index: 99999;
  58. background-color: white;
  59. }
  60. .top-menu {
  61. display: flex;
  62. justify-content: space-around;
  63. }
  64. .top-menu .tab {
  65. font-size: 28rpx;
  66. padding: 30rpx 30rpx;
  67. color: #666666;
  68. position: relative;
  69. }
  70. .top-menu .active .border {
  71. position: absolute;
  72. width: 70%;
  73. height: 16rpx;
  74. background: #00b38b;
  75. opacity: 0.3;
  76. bottom: 28rpx;
  77. z-index: -99;
  78. left: 15%;
  79. border-radius: 6rpx;
  80. }
  81. .top-menu .active {
  82. font-weight: bold;
  83. font-size: 32rpx;
  84. color: #0d0f26;
  85. }
  86. .top-menu .active::before {
  87. width: 100%;
  88. height: 16rpx;
  89. background: #00b38b;
  90. opacity: 0.3;
  91. }
  92. .search-layout {
  93. .search-box {
  94. margin: 30rpx 30rpx 0rpx 30rpx;
  95. height: 80rpx;
  96. background: #FFFFFF;
  97. border: 1px solid #DCDCDC;
  98. border-radius: 40rpx;
  99. display: flex;
  100. justify-content: center;
  101. align-items: center;
  102. box-sizing: border-box;
  103. flex: 1;
  104. }
  105. .search-box .icon {
  106. width: 48rpx;
  107. height: 48rpx;
  108. margin: 0 20rpx;
  109. }
  110. .search-box .search {
  111. flex: 1;
  112. margin-right: 20rpx;
  113. height: 100%;
  114. padding: 0 10rpx;
  115. font-size: 28rpx;
  116. color: #00b38b;
  117. }
  118. .search-btn {
  119. color: white;
  120. background-color: #00B38B;
  121. width: 140rpx;
  122. height: 75rpx;
  123. line-height: 75rpx;
  124. font-size: 32rpx;
  125. border-radius: 40rpx;
  126. text-align: center;
  127. margin-right: 30rpx;
  128. margin-top: 30rpx;
  129. }
  130. }
  131. .item .head {
  132. display: flex;
  133. justify-content: space-between;
  134. align-items: center;
  135. padding: 20rpx 28rpx;
  136. border-bottom: 1px solid #dcdcdc;
  137. }
  138. .item .head {
  139. .head-row {
  140. display: flex;
  141. width: 100%;
  142. justify-content: space-between;
  143. align-items: center;
  144. }
  145. .name {}
  146. .name>text {
  147. font-size: 26rpx;
  148. font-family: Noto Sans S Chinese;
  149. font-weight: 400;
  150. color: #999999;
  151. line-height: 36rpx;
  152. }
  153. }
  154. .item .head .icon {
  155. width: 48rpx;
  156. height: 48rpx;
  157. }
  158. .item .head .name {
  159. display: flex;
  160. align-items: center;
  161. }
  162. .text-green {
  163. font-size: 26rpx;
  164. color: #00b38b;
  165. }
  166. .text-orange {
  167. font-size: 26rpx;
  168. color: #ff8000;
  169. }
  170. .text-black {
  171. font-size: 28rpx;
  172. color: #333;
  173. font-weight: 500;
  174. }
  175. .title {
  176. font-size: 30rpx;
  177. color: #333;
  178. }
  179. .tag-green {
  180. font-size: 22rpx;
  181. height: 40rpx;
  182. line-height: 40rpx;
  183. padding: 0 12rpx;
  184. border-radius: 6rpx;
  185. background: #d9f4ee;
  186. color: #00b38b;
  187. }
  188. .tag-grey {
  189. font-size: 22rpx;
  190. height: 40rpx;
  191. line-height: 40rpx;
  192. padding: 0 12rpx;
  193. border-radius: 6rpx;
  194. background: #e8e8e8;
  195. color: #666;
  196. }
  197. .detail {
  198. display: flex;
  199. justify-content: space-between;
  200. align-items: center;
  201. padding: 30rpx 32rpx;
  202. }
  203. .detail .type {
  204. font-size: 26rpx;
  205. color: #999;
  206. }
  207. .detail .value {
  208. font-size: 26rpx;
  209. color: #333;
  210. }
  211. .finished .detail .value {
  212. color: #999;
  213. }
  214. .detail .odd {
  215. margin: 20rpx 0;
  216. }
  217. .cny {
  218. font-size: 26rpx;
  219. color: #333;
  220. }
  221. .finished .cny {
  222. color: #999;
  223. }
  224. .amount {
  225. font-size: 40rpx;
  226. font-weight: bold;
  227. }
  228. .bottom .amount {
  229. color: #ff8000;
  230. }
  231. .finished .amount {
  232. color: #999;
  233. }
  234. .btns {
  235. position: relative;
  236. display: flex;
  237. align-items: center;
  238. justify-content: flex-end;
  239. border-top: 1px solid #dcdcdc;
  240. margin: 0 30rpx;
  241. padding: 20rpx 0;
  242. }
  243. .bottom {
  244. display: flex;
  245. justify-content: space-between;
  246. align-items: center;
  247. border-top: 1px solid #dcdcdc;
  248. margin: 0 30rpx;
  249. padding: 20rpx 0;
  250. }
  251. .btn {
  252. height: 60rpx;
  253. line-height: 58rpx;
  254. border-radius: 30rpx;
  255. padding: 0 24rpx;
  256. font-size: 23rpx;
  257. box-sizing: border-box;
  258. margin-right: 12rpx;
  259. }
  260. .btns .btn:last-child {
  261. margin: 0;
  262. }
  263. .btns .state {
  264. position: absolute;
  265. left: 0;
  266. font-size: 26rpx;
  267. font-family: Noto Sans S Chinese;
  268. font-weight: 400;
  269. color: #999999;
  270. line-height: 58rpx;
  271. text {
  272. font-size: 26rpx;
  273. font-family: Noto Sans S Chinese;
  274. font-weight: 400;
  275. color: #00B38B;
  276. line-height: 58rpx;
  277. }
  278. }
  279. .btn-primary {
  280. border: 1px solid #00b38b;
  281. color: #00b38b;
  282. }
  283. .btn-disable {
  284. border: 1px solid #999;
  285. color: #999;
  286. }
  287. .btn-normal {
  288. border: 1px solid #dcdcdc;
  289. color: #333;
  290. }
  291. .evaluation {
  292. display: flex;
  293. }
  294. .finished .detail .value {
  295. color: #999;
  296. }
  297. .detail .odd {
  298. margin: 20rpx 0;
  299. }
  300. .cny {
  301. font-size: 26rpx;
  302. color: #333;
  303. }
  304. .finished .cny {
  305. color: #999;
  306. }
  307. .item {
  308. background: #ffffff;
  309. box-shadow: 0rpx 2rpx 6rpx 0rpx rgba(223, 223, 223, 0.8);
  310. border-radius: 20rpx;
  311. box-sizing: border-box;
  312. display: flex;
  313. flex-direction: column;
  314. margin: 30rpx 30rpx 0rpx;
  315. }
  316. .bg-white .item {
  317. box-shadow: 0rpx 4rpx 13rpx 3rpx rgba(223, 223, 223, 0.8);
  318. }
  319. .item .head {
  320. display: flex;
  321. justify-content: space-between;
  322. align-items: center;
  323. padding: 20rpx 28rpx;
  324. border-bottom: 1px solid #dcdcdc;
  325. }
  326. .item .head {
  327. .head-row {
  328. display: flex;
  329. width: 100%;
  330. justify-content: space-between;
  331. align-items: center;
  332. }
  333. .name {}
  334. .name>text {
  335. font-size: 26rpx;
  336. font-family: Noto Sans S Chinese;
  337. font-weight: 400;
  338. color: #999999;
  339. line-height: 36rpx;
  340. }
  341. }
  342. .item .head .icon {
  343. width: 48rpx;
  344. height: 48rpx;
  345. }
  346. .item .head .name {
  347. display: flex;
  348. align-items: center;
  349. }
  350. </style>