Home.vue 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302
  1. <template>
  2. <div class="mainContent">
  3. <el-row class="order_tab">
  4. <el-col :span="15">
  5. <div class="tab_list">
  6. <div class="tab_item" @click="tab_ac=i" :class="{'tab_item_ac':tab_ac==i?true:false}" v-for="(item,i) in tab_list" :key="i">
  7. <div class="point" v-show="item.num">{{item.num}}</div>
  8. <span>{{item.name}}</span>
  9. <div class="tab_line"></div>
  10. </div>
  11. </div>
  12. </el-col>
  13. <el-col :span="9">
  14. <div class="header_serch">
  15. <div class="search_inp">
  16. <el-input class="inp" v-model="input" placeholder="请输入手机号/姓名/地址/订单编号"></el-input>
  17. <div class="btn"><i class="el-icon-search"></i></div>
  18. </div>
  19. <div class="Manual">手动发单</div>
  20. </div>
  21. </el-col>
  22. </el-row>
  23. <el-row class="order_list">
  24. <el-col :span="18">
  25. <order-list></order-list>
  26. </el-col>
  27. <el-col :span="6">
  28. <div class="order_detail">
  29. <div class="detail_title">
  30. <div class="detail_txt" @click="orderDetailStutus=0" :class="{'detail_txt_ac':orderDetailStutus==0?true:false}">订单跟踪</div>
  31. <div class="detail_txt" @click="orderDetailStutus=1" :class="{'detail_txt_ac':orderDetailStutus==1?true:false}">订单详情</div>
  32. </div>
  33. <order-detail :tabNum='tab_ac' v-if="orderDetailStutus==1"></order-detail>
  34. <order-track :tabNum='tab_ac' v-if="orderDetailStutus==0"></order-track>
  35. </div>
  36. </el-col>
  37. </el-row>
  38. <order-map></order-map>
  39. </div>
  40. </template>
  41. <script>
  42. import sendOrderPopup from './orderComponents/sendOrderPopup.vue';
  43. import OrderDetail from './orderComponents/orderDetail.vue';
  44. import orderMap from './orderComponents/orderAMap.vue';
  45. import OrderList from './orderComponents/orderList.vue';
  46. import orderTrack from './orderComponents/orderTrack'
  47. import orderMap from './orderComponents/orderAMap.vue';
  48. export default {
  49. data() {
  50. return {
  51. tab_list:[
  52. {name:'新订单',num:6},
  53. {name:'预约单',num:0},
  54. {name:'待接单',num:0},
  55. {name:'取货中',num:0},
  56. {name:'配送中',num:0},
  57. {name:'异常单',num:0},
  58. {name:'已取消',num:0}
  59. ],
  60. tab_ac:0,
  61. orderDetailStutus:0,
  62. input:''
  63. }
  64. },
  65. components: {
  66. sendOrderPopup,
  67. OrderDetail,
  68. OrderList,
  69. orderMap,
  70. orderTrack
  71. },
  72. methods: {
  73. sendOrder() {
  74. this.$refs.sendOrderPopup.init();
  75. },
  76. saveRule(t, i) {
  77. let obj = {
  78. id: i + 2,
  79. rule: t,
  80. content: ''
  81. }
  82. this.ruleList.push( obj )
  83. }
  84. }
  85. }
  86. </script>
  87. <style lang="scss" scoped="scoped">
  88. /deep/ .el-input__inner{
  89. padding-right: 50px;
  90. height: 44px;
  91. }
  92. .mainContent{
  93. width: 100%;
  94. .order_tab{
  95. width: 100%;
  96. height: 74px;
  97. background: #FFF;
  98. .tab_list{
  99. width: 100%;
  100. height: 74px;
  101. padding-top: 20px;
  102. padding-left: 36px;
  103. box-sizing: border-box;
  104. display: flex;
  105. .tab_item{
  106. width: 58px;
  107. margin-right: 56px;
  108. font-size: 16px;
  109. font-weight: 500;
  110. color: #B1B1B1;
  111. position: relative;
  112. text-align: center;
  113. cursor: pointer;
  114. .tab_line{
  115. width: 58px;
  116. height: 6px;
  117. background: #FFF;
  118. border-radius: 3px;
  119. margin-top: 15px;
  120. }
  121. .point{
  122. width: 16px;
  123. height: 16px;
  124. border-radius: 50%;
  125. background: #F74141;
  126. font-size: 12px;
  127. font-weight: 400;
  128. color: #FFFFFF;
  129. position: absolute;
  130. top: -5px;
  131. right: -10px;
  132. text-align: center;
  133. line-height: 16px;
  134. }
  135. }
  136. .tab_item_ac{
  137. color: #FC7200;
  138. .tab_line{
  139. background: #FC7200;
  140. }
  141. }
  142. }
  143. .header_serch{
  144. width: 100%;
  145. height: 74px;
  146. padding-right: 25px;
  147. box-sizing: border-box;
  148. display: flex;
  149. align-items: center;
  150. justify-content: flex-end;
  151. .Manual{
  152. width: 118px;
  153. height: 44px;
  154. background: #FC7200;
  155. border-radius: 6px;
  156. font-size: 16px;
  157. font-weight: 500;
  158. color: #FFFFFF;
  159. text-align: center;
  160. line-height: 44px;
  161. margin-left: 18px;
  162. }
  163. .search_inp{
  164. width: 380px;
  165. height: 44px;
  166. display: flex;
  167. align-items: center;
  168. position: relative;
  169. .inp{
  170. width: 380px;
  171. height: 44px;
  172. border: none;
  173. }
  174. .btn{
  175. margin-left: 15px;
  176. font-size: 22px;
  177. position: absolute;
  178. right: 15px;
  179. }
  180. }
  181. }
  182. }
  183. .order_list{
  184. width: 100%;
  185. margin-top: 10px;
  186. .order_detail{
  187. width: 100%;
  188. border-left: 10px solid #F1F2F5;
  189. background: #fff;
  190. box-sizing: border-box;
  191. border-left: 10px solid #F1F2F5;
  192. .detail_title{
  193. width: 100%;
  194. height: 44px;
  195. background: #FAFAFA;
  196. padding-left: 16px;
  197. box-sizing: border-box;
  198. display: flex;
  199. align-items: center;
  200. font-size: 12px;
  201. font-weight: 600;
  202. display: flex;
  203. align-items: flex-end;
  204. .detail_txt{
  205. color: #B1B1B1;
  206. padding-bottom: 13px;
  207. border-bottom: 2px solid #FAFAFA;
  208. margin-right: 28px;
  209. cursor: pointer;
  210. }
  211. .detail_txt_ac{
  212. color: #00152A;
  213. border-color: #00152A;
  214. }
  215. }
  216. .detail_cont{
  217. width: 100%;
  218. padding: 16px;
  219. box-sizing: border-box;
  220. .detail_title2{
  221. width: 100%;
  222. font-size: 12px;
  223. font-weight: 600;
  224. color: #777777;
  225. margin-bottom: 15px;
  226. }
  227. .shop_detail{
  228. width: 100%;
  229. display: flex;
  230. margin-bottom: 10px;
  231. img{
  232. width: 47px;
  233. height: 47px;
  234. border-radius: 4px 4px 4px 4px;
  235. margin-right: 12px;
  236. }
  237. .info{
  238. flex-grow: 1;
  239. display: flex;
  240. justify-content: space-between;
  241. .shop_title{
  242. width: 70%;
  243. font-size: 14px;
  244. font-weight: 500;
  245. color: #333333;
  246. line-height: 18px;
  247. }
  248. .shop_num{
  249. color: #B1B1B1;
  250. }
  251. }
  252. }
  253. .detail_ine{
  254. width: 100%;
  255. height: 1px;
  256. border-top: 2px dotted #F0F0F0;
  257. margin: 16px 0;
  258. }
  259. .info2{
  260. width: 100%;
  261. display: flex;
  262. .title{
  263. font-size: 14px;
  264. font-weight: 400;
  265. width: 80px;
  266. color: #B1B1B1;
  267. }
  268. .cont{
  269. font-size: 14px;
  270. font-weight: 400;
  271. color: #333333;
  272. line-height: 20px;
  273. }
  274. .cont2{
  275. color: #FC7200;
  276. }
  277. }
  278. .info3{
  279. margin-top: 10px;
  280. }
  281. .info4{
  282. display: flex;
  283. justify-content: space-between;
  284. }
  285. .btns{
  286. margin-top: 30px;
  287. .btn{
  288. background: #FC7200;
  289. border-color: #FC7200;
  290. color: #FFF;
  291. }
  292. }
  293. }
  294. }
  295. }
  296. }
  297. </style>