selectionWorkers.vue 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
  1. <template>
  2. <view class="z-popup">
  3. <view class="zhuangtaitubiao" style="justify-content: flex-start !important">
  4. <view class="title">接收确认</view>
  5. <view class="row">
  6. <view class="label">客户名称:</view>
  7. <view class="value">¥111111</view>
  8. </view>
  9. <view class="row">
  10. <view class="label">客户电话:</view>
  11. <view class="value">1111111</view>
  12. </view>
  13. <view class="row">
  14. <view class="label">客户地址:</view>
  15. <view class="value">111111</view>
  16. </view>
  17. <view class="row">
  18. <view class="label">选择小工:</view>
  19. <view class="value price">
  20. <checkbox-group @change="changeXz" style="width: 100%">
  21. <label
  22. v-for="(item, index) in workerList"
  23. :key="index"
  24. style="width: 50%; display: inline-block; margin-bottom: 20rpx"
  25. >
  26. <checkbox :value="item.workerId" :checked="item.isSelect" />{{ item.workerName }}
  27. </label>
  28. </checkbox-group>
  29. </view>
  30. </view>
  31. <view class="kakakakak">
  32. <u-button text="取消"></u-button>
  33. <view style="min-width: 30rpx"></view>
  34. <u-button type="primary" text="确认接收" @click="querenss"></u-button>
  35. </view>
  36. </view>
  37. </view>
  38. </template>
  39. <script>
  40. export default {
  41. props: {
  42. detail: {
  43. type: Object,
  44. default: () => ({})
  45. },
  46. type: {
  47. type: [String, Number],
  48. default: 0
  49. }
  50. },
  51. data() {
  52. return {
  53. workerList: [],
  54. checkboxValues: []
  55. }
  56. },
  57. mounted() {
  58. this.getBrandList()
  59. },
  60. methods: {
  61. getBrandList() {
  62. if (this?.detail?.id) {
  63. this.$api
  64. .post('/pg/order/base/slave/worker/team', {
  65. orderBaseId: this?.detail?.id
  66. })
  67. .then(res => {
  68. this.workerList = res.data.records
  69. })
  70. }
  71. },
  72. changeXz(v) {
  73. this.checkboxValues = v.target.value
  74. },
  75. querenss() {
  76. console.log(this.checkboxValues)
  77. }
  78. }
  79. }
  80. </script>
  81. <style scoped lang="scss">
  82. .z-popup {
  83. position: fixed;
  84. background: rgba(0, 0, 0, 0.2);
  85. width: 100%;
  86. height: 100vh;
  87. z-index: 1000000000;
  88. left: 0;
  89. right: 0;
  90. top: 0;
  91. bottom: 0;
  92. transition: top 0.5s;
  93. box-sizing: border-box;
  94. padding: 60rpx;
  95. display: flex;
  96. justify-content: center;
  97. align-items: center;
  98. .zhuangtaitubiao {
  99. width: 100%;
  100. height: auto;
  101. box-sizing: border-box;
  102. padding: 30rpx;
  103. background: #fff;
  104. border-radius: 20rpx;
  105. margin-bottom: 50rpx;
  106. display: flex;
  107. justify-content: center;
  108. align-items: center;
  109. flex-direction: column;
  110. }
  111. .title {
  112. font-size: 28rpx;
  113. font-weight: bold;
  114. align-items: left;
  115. }
  116. .row {
  117. display: flex;
  118. align-items: left;
  119. margin-top: 30rpx;
  120. width: 100%;
  121. .label {
  122. color: $sec-font;
  123. min-width: 160rpx;
  124. }
  125. .price {
  126. width: 100%;
  127. }
  128. }
  129. .kakakakak {
  130. width: 100%;
  131. height: auto;
  132. display: flex;
  133. justify-content: space-between;
  134. align-items: center;
  135. margin-top: 40rpx;
  136. }
  137. }
  138. </style>