detail.vue 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265
  1. <template>
  2. <view class="detail-page">
  3. <u-navbar height="40px" :title="navTitle" bgColor="#0256FF" :titleStyle="{color:'#fff'}" leftIconColor="#fff" autoBack
  4. placeholder>
  5. </u-navbar>
  6. <view class="container_main">
  7. <view class="info-box">
  8. <view class="info-line">
  9. <view class="info-line-label">
  10. <text>货物名称</text>
  11. </view>
  12. <view class="info-line-value">
  13. 娃哈哈AD钙
  14. </view>
  15. </view>
  16. <view class="info-line">
  17. <view class="info-line-label">
  18. <text>货物条码</text>
  19. </view>
  20. <view class="info-line-value">
  21. 9787540146481
  22. </view>
  23. </view>
  24. <view class="info-line">
  25. <view class="info-line-label">
  26. <text>货物图片</text>
  27. </view>
  28. <view class="info-line-value ss-p-y-24">
  29. <u-image src="" width="120rpx" height="120rpx"></u-image>
  30. </view>
  31. </view>
  32. <view class="info-line">
  33. <view class="info-line-label">
  34. <text>规格</text>
  35. </view>
  36. <view class="info-line-value">
  37. 250ml
  38. </view>
  39. </view>
  40. <view class="info-line">
  41. <view class="info-line-label">
  42. <text>批次号</text>
  43. </view>
  44. <view class="info-line-value">
  45. 12345678966
  46. </view>
  47. </view>
  48. <view class="info-line">
  49. <view class="info-line-label">
  50. <text>生产日期</text>
  51. </view>
  52. <view class="info-line-value">
  53. 2025-04-03
  54. </view>
  55. </view>
  56. <view class="info-line">
  57. <view class="info-line-label">
  58. <text>库存</text>
  59. </view>
  60. <view class="info-line-value">
  61. 20瓶
  62. </view>
  63. </view>
  64. <view class="info-line">
  65. <view class="info-line-label">
  66. <text>库位</text>
  67. </view>
  68. <view class="info-line-value">
  69. A区3-1-1
  70. </view>
  71. </view>
  72. <view class="info-line">
  73. <view class="info-line-label">
  74. <text>创建时间</text>
  75. </view>
  76. <view class="info-line-value">
  77. 2025-04-03 16:44
  78. </view>
  79. </view>
  80. </view>
  81. <view class="crk-box" @click="crkShow = true">
  82. <u-image src="@/static/image/cgrk-icon.png" width="48rpx" height="48rpx"></u-image>
  83. <view class="crk-msg">
  84. <view class="crk-msg-name">出入库明细</view>
  85. <view>查看最近的出入库记录</view>
  86. </view>
  87. <u-icon name="arrow-right" color="rgba(173, 181, 189, 0.50)" size="14"></u-icon>
  88. </view>
  89. </view>
  90. <!-- 出入库明细 -->
  91. <u-popup :show="crkShow" @close="crkShow = false" round="18" closeable :closeOnClickOverlay="false">
  92. <view class="crk-cont">
  93. <view class="crk-cont-title">出入库明细</view>
  94. <view class="crk-cont-tab">
  95. <view class="tab-item" :class="currentCrkId == item.id ? 'tab-item-active' : ''" v-for="(item,i) in crkList" :key="i" @click="tabClick(item)">
  96. {{item.name}}
  97. </view>
  98. </view>
  99. <scroll-view scroll-y class="scroll-y">
  100. <view class="crk-item" v-for="item in 6" :key="item">
  101. <view class="crk-item-title">娃哈哈AD钙</view>
  102. <view class="crk-item-line">出库仓库:我的仓库</view>
  103. <view class="crk-item-line">货物规格:500ml</view>
  104. <view class="crk-item-line">出库时间:2025-04-03 16:44</view>
  105. <view class="crk-item-line">出库数量:25件</view>
  106. <view class="img-box">
  107. <u-image v-if="currentCrkId == 0" src="@/static/image/yck-img.png" width="132rpx" height="132rpx"></u-image>
  108. <u-image v-if="currentCrkId == 1" src="@/static/image/yrk-img.png" width="132rpx" height="132rpx"></u-image>
  109. </view>
  110. </view>
  111. <u-divider text="仅展示最近10条记录" :dashed="true"></u-divider>
  112. <view style="height: 40rpx;"></view>
  113. </scroll-view>
  114. </view>
  115. </u-popup>
  116. </view>
  117. </template>
  118. <script>
  119. export default{
  120. data() {
  121. return {
  122. navTitle:'哇哈哈AD盖',
  123. crkShow: false,
  124. currentCrkId:0,
  125. crkList:[
  126. {
  127. name:'出库',
  128. id:0
  129. },
  130. {
  131. name:'入库',
  132. id:1
  133. }
  134. ]
  135. }
  136. },
  137. methods:{
  138. tabClick(item) {
  139. this.currentCrkId = item.id
  140. }
  141. }
  142. }
  143. </script>
  144. <style lang="scss" scoped>
  145. .detail-page {
  146. min-height: 100vh;
  147. background-color: #F0F6FB;
  148. padding: 24rpx;
  149. .container_main {
  150. .info-box {
  151. background-color: #fff;
  152. border-radius: 16rpx 16rpx 0 0;
  153. padding: 24rpx;
  154. .info-line {
  155. border-bottom: 1px solid #F4F4F4;
  156. min-height: 92rpx;
  157. color: #333;
  158. font-family: "PingFang SC";
  159. font-size: 28rpx;
  160. font-weight: 400;
  161. display: flex;
  162. align-items: center;
  163. &-label {
  164. width: 162rpx;
  165. }
  166. .must-box {
  167. color: #FF3B1D;
  168. }
  169. }
  170. }
  171. .crk-box {
  172. border-radius: 16rpx;
  173. background: #FFF;
  174. padding: 32rpx 24rpx;
  175. margin-top: 24rpx;
  176. display: flex;
  177. align-items: center;
  178. .crk-msg {
  179. flex: 1;
  180. margin-left: 24rpx;
  181. color: #666;
  182. font-size: 28rpx;
  183. font-weight: 400;
  184. .crk-msg-name {
  185. color: #333;
  186. font-size: 32rpx;
  187. font-weight: bold;
  188. }
  189. }
  190. }
  191. }
  192. .crk-cont {
  193. height: 75vh;
  194. &-title {
  195. height: 80rpx;
  196. line-height: 80rpx;
  197. text-align: center;
  198. color: #1F1F39;
  199. font-size: 36rpx;
  200. font-weight: bold;
  201. }
  202. &-tab {
  203. height: 100rpx;
  204. display: flex;
  205. align-items: center;
  206. justify-content: center;
  207. .tab-item {
  208. width: 160rpx;
  209. height: 56rpx;
  210. border-radius: 40rpx;
  211. border: 1px solid rgba(173, 181, 189, 0.50);
  212. color: #666;
  213. text-align: center;
  214. font-size: 28rpx;
  215. font-weight: 500;
  216. line-height: 56rpx;
  217. margin-right: 24rpx;
  218. }
  219. .tab-item-active {
  220. background: #0256FF;
  221. border: 1px solid #0256FF;
  222. color: #FFF;
  223. }
  224. }
  225. .scroll-y {
  226. height: calc(75vh - 80rpx - 100rpx);
  227. padding: 0 24rpx;
  228. .crk-item {
  229. border-radius: 16rpx;
  230. background: #F6F8FA;
  231. padding: 24rpx;
  232. font-family: "PingFang SC";
  233. margin-bottom: 24rpx;
  234. position: relative;
  235. &-title {
  236. color: #000;
  237. font-size: 28rpx;
  238. font-weight: 500;
  239. margin-bottom: 16rpx;
  240. }
  241. &-line {
  242. color: #666;
  243. font-size: 28rpx;
  244. font-weight: 400;
  245. margin-bottom: 8rpx;
  246. }
  247. .img-box {
  248. position: absolute;
  249. top: 24rpx;
  250. right: 24rpx;
  251. }
  252. }
  253. }
  254. }
  255. }
  256. </style>