orderList.vue 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <template>
  2. <view>
  3. <view class="margin-sm padding-sm bg-white" v-for="(item, index) in list">
  4. <view class="flex justify-between solid-bottom padding-tb-sm">
  5. <view>佛系小草莓</view>
  6. <view class="text-orange" v-if="item.status==2">待接单</view>
  7. <view class="text-orange" v-if="item.status==3">接单中</view>
  8. <view class="text-orange" v-if="item.status==1">已完成</view>
  9. </view>
  10. <view class="text-lg text-black text-bold margin-top-sm">{{item.content}}</view>
  11. <view class="flex margin-top-sm">
  12. <view class="bg-blue light radius" style="padding: 1px 4px;">限美女</view>
  13. <view class="bg-orange light radius margin-left" style="padding: 1px 4px;">取快递</view>
  14. <view class="bg-orange light radius margin-left" style="padding: 1px 4px;">待接单</view>
  15. </view>
  16. <view class="margin-top-sm">下单时间:{{item.createTime}}</view>
  17. <view class="flex justify-between margin-top-sm">
  18. <view v-if="item.code">收货码:{{item.code}}</view>
  19. <view>实付款:<text class="text-black text-bold">¥{{item.money}}</text></view>
  20. </view>
  21. <view class="flex justify-end bg-white padding-tb-sm" style="">
  22. <button class="cu-btn round margin-right" style="width: 90px;" @click="delDemand(item)" v-if="item.status==2">删除</button>
  23. <button class="cu-btn bg-orange round" style="width: 90px;" @click="edit(item)">完善需求</button>
  24. </view>
  25. </view>
  26. </view>
  27. </template>
  28. <script>
  29. export default {
  30. props: {
  31. list: {
  32. type: Array,
  33. default () {
  34. return []
  35. }
  36. }
  37. },
  38. methods: {
  39. delDemand(e) {
  40. let data = {
  41. helpOrderId: e.id
  42. }
  43. this.$Request.postT('/help/deleteHelpOrder', data).then(res => {
  44. uni.showToast({
  45. title:"删除成功"
  46. })
  47. })
  48. },
  49. edit(item) {
  50. uni.navigateTo({
  51. url: '/pages/order/release?type=hasEdit&id=' + item.id + '&content=' + item.content +
  52. '&site=' + item.site +
  53. '&phone=' + item.phone + '&deliveryTime=' + item.deliveryTime + '&classifyId=' + item
  54. .classifyId +
  55. '&classifyName=' + item.classifyName + '&userType=' + item.userType + '&commission=' + item
  56. .commission
  57. })
  58. }
  59. }
  60. }
  61. </script>
  62. <style>
  63. </style>