AssetsCard2.vue 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212
  1. <template>
  2. <view class="listBox">
  3. <view class="listBox-con">
  4. <view class="listBox-top">
  5. <view class="listBox-name" style="display: flex;">
  6. <view class="round">{{index}}</view>
  7. {{ item.info.categoryCode }}
  8. </view>
  9. <view class="listBox-name">
  10. <u-tag @click="open(item.planDetailVOList)" :text="item.info.categoryName"></u-tag>
  11. </view>
  12. </view>
  13. <view class="listBox-bottom">
  14. <view>批次号:{{ item.info.batchNo }}</view>
  15. <view>牌号:{{ item.info.brandNum }}</view>
  16. <view>型号:{{ item.info.categoryModel }}</view>
  17. <view>规格:{{ item.info.specification }}</view>
  18. <view>计量数量:{{ item.info.packingCountBase }}</view>
  19. <view>计量单位:{{ item.info.packingUnit }}</view>
  20. <view>重量:{{ item.info.weight }}</view>
  21. <view>重量单位:{{ item.info.weightUnit }}</view>
  22. </view>
  23. </view>
  24. <u-popup mode="right" :show="show" @close="close">
  25. <u-list>
  26. <u-list-item v-for="(item, index) in list" :key="index">
  27. <view class="listBox-item">
  28. <view class="w100" style="font-weight: bold;">序号:{{ index + 1 }}</view>
  29. <view>包装数量:{{ item.info.packingCountBase }}</view>
  30. <view>包装单位:{{ item.info.packingUnit }}</view>
  31. <view class="w100">包装编码:{{ item.info.packageNo }}</view>
  32. <view class="w100">生产日期:</view>
  33. </view>
  34. </u-list-item>
  35. </u-list>
  36. </u-popup>
  37. </view>
  38. </template>
  39. <script>
  40. import {
  41. number
  42. } from 'echarts'
  43. export default {
  44. props: {
  45. index: {
  46. type: Number,
  47. default: 0
  48. },
  49. item: {
  50. type: Object,
  51. default: () => ({
  52. info: {}
  53. })
  54. }
  55. },
  56. data() {
  57. return {
  58. list: [],
  59. show: false,
  60. statusOption: [{
  61. label: '盘盈',
  62. value: '2',
  63. numKey: 'surplusQuantity'
  64. },
  65. {
  66. label: '丢失',
  67. value: '3',
  68. numKey: 'loseQuantity'
  69. },
  70. {
  71. label: '破损',
  72. value: '4',
  73. numKey: 'wornQuantity'
  74. }
  75. ],
  76. statusInfo: {
  77. 2: '盘盈',
  78. 3: '丢失',
  79. 4: '破损'
  80. },
  81. countInfo: {
  82. 2: 'surplusQuantity',
  83. 3: 'loseQuantity',
  84. 4: 'wornQuantity'
  85. }
  86. }
  87. },
  88. methods: {
  89. close() {
  90. this.show = false
  91. },
  92. open(list) {
  93. console.log(list)
  94. this.list = list
  95. this.show = true
  96. }
  97. }
  98. }
  99. </script>
  100. <style lang="scss" scoped>
  101. .listBox {
  102. display: flex;
  103. // height: 180rpx;
  104. padding: 20rpx;
  105. border-bottom: 2rpx solid #e5e5e5;
  106. .listBox-sel {
  107. height: 90rpx;
  108. width: 80rpx;
  109. // line-height: 90rpx;
  110. text-align: center;
  111. checkbox {
  112. transform: scale(1.2);
  113. }
  114. }
  115. .listBox-con {
  116. width: 100%;
  117. padding: 0 16px 8px 8px;
  118. .listBox-top {
  119. width: 100%;
  120. display: flex;
  121. align-items: center;
  122. justify-content: space-between;
  123. padding-bottom: 10rpx;
  124. .listBox-name,
  125. .listBox-code {
  126. display: inline-block;
  127. font-size: $uni-font-size-sm;
  128. font-weight: bold;
  129. }
  130. }
  131. .round {
  132. width: 40rpx;
  133. height: 40rpx;
  134. line-height: 40rpx;
  135. border-radius: 50%;
  136. background: $theme-color;
  137. color: #fff;
  138. text-align: center;
  139. font-size: 20rpx;
  140. margin-right: 8px;
  141. }
  142. .listBox-bottom {
  143. width: 100%;
  144. display: flex;
  145. justify-content: space-between;
  146. font-size: $uni-font-size-sm;
  147. flex-wrap: wrap;
  148. >view {
  149. width: 50%;
  150. overflow: hidden;
  151. white-space: nowrap;
  152. text-overflow: ellipsis;
  153. line-height: 24px;
  154. }
  155. .input_view {
  156. display: flex;
  157. align-items: center;
  158. justify-content: center;
  159. .u-input {
  160. height: 36rpx;
  161. padding: 0 !important;
  162. margin-right: 10rpx;
  163. border: 1px solid #ddd;
  164. }
  165. }
  166. .w100 {
  167. width: 100%;
  168. }
  169. }
  170. }
  171. .listBox-item {
  172. width: 70vw;
  173. padding: 20rpx;
  174. display: flex;
  175. justify-content: space-between;
  176. font-size: $uni-font-size-sm;
  177. flex-wrap: wrap;
  178. border-bottom: 1px solid #ddd;
  179. >view {
  180. width: 50%;
  181. overflow: hidden;
  182. white-space: nowrap;
  183. text-overflow: ellipsis;
  184. line-height: 24px;
  185. }
  186. .w100 {
  187. width: 100%;
  188. }
  189. }
  190. }
  191. .noDate {
  192. height: 100%;
  193. }
  194. </style>