confirmation.vue 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221
  1. <!-- 登记称重详情 -->
  2. <template>
  3. <view class="confirmationPage">
  4. <view class="title-p" style="margin-top:20rpx;">基础信息</view>
  5. <view class="title-weight-p">报备单编号:{{info.reportNo}}</view>
  6. <view class="text-p">实验室:{{info.subName}}({{info.roomNum}})</view>
  7. <view class="text-p">上门回收日期:{{info.expectTime}}({{info.expectWeek}})</view>
  8. <view class="text-p">报备人:{{info.reportName}}({{info.reportAccount}})</view>
  9. <view class="text-p">报备时间:{{info.reportTime}}</view>
  10. <view class="text-p">称重登记人:{{userName}}({{user}})</view>
  11. <view class="text-p">称重登记时间:{{currentTime}}</view>
  12. <view class="title-p">称重登记内容</view>
  13. <view class="text-weight-box">
  14. <view>危险废物种类</view>
  15. <view>共{{info.details.length}}种</view>
  16. </view>
  17. <view class="text-box" v-for="(item,index) in info.details" :key="index">
  18. <view>{{item.typeName}}</view>
  19. <view>{{item.weight}}kg</view>
  20. </view>
  21. <view class="title-p" v-if="info.images[0]">图片</view>
  22. <view class="img-box" v-if="info.images[0]">
  23. <view>
  24. <img :src="baseUrl+img" v-for="(img,imgIndex) in info.images" :key="imgIndex">
  25. </view>
  26. </view>
  27. <view class="flex-null-p"></view>
  28. <view class="bottom-button-p" @click="confirmatinButton()">回收人员确认</view>
  29. </view>
  30. </template>
  31. <script>
  32. import {
  33. config
  34. } from '@/api/request/config.js'
  35. export default {
  36. data() {
  37. return {
  38. baseUrl:config.base_url,
  39. newData:{
  40. images:[],
  41. },
  42. info:{
  43. details:[],
  44. images:[],
  45. },
  46. userName:uni.getStorageSync('user-name'),
  47. user:uni.getStorageSync('userName'),
  48. currentTime:'',
  49. }
  50. },
  51. onLoad(option) {
  52. this.currentTime = this.formatDate(new Date());
  53. this.$set(this,'newData',JSON.parse(decodeURIComponent(option.data)));
  54. this.$set(this,'info',JSON.parse(decodeURIComponent(option.info)));
  55. },
  56. onShow() {
  57. },
  58. mounted() {
  59. },
  60. methods: {
  61. formatDate(date) {
  62. const year = date.getFullYear();
  63. const month = String(date.getMonth() + 1).padStart(2, '0');
  64. const day = String(date.getDate()).padStart(2, '0');
  65. const hours = String(date.getHours()).padStart(2, '0');
  66. const minutes = String(date.getMinutes()).padStart(2, '0');
  67. const seconds = String(date.getSeconds()).padStart(2, '0');
  68. return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;
  69. },
  70. confirmatinButton(){
  71. uni.navigateTo({
  72. url: "/pages_hazardousWasteRecycling/views/weighingRegistration/signatureComponent?data=" + encodeURIComponent(JSON.stringify(this.newData))
  73. });
  74. },
  75. },
  76. }
  77. </script>
  78. <style lang="stylus" scoped>
  79. .confirmationPage{
  80. height: 100%;
  81. display flex;
  82. flex-direction column;
  83. background-color: #fff;
  84. position: relative;
  85. overflow-x: hidden;
  86. overflow-y: scroll;
  87. .title-p{
  88. line-height:80rpx;
  89. font-size:34rpx;
  90. padding:0 30rpx;
  91. color:#0183FA;
  92. }
  93. .title-weight-p{
  94. line-height:60rpx;
  95. font-size:32rpx;
  96. padding:0 50rpx;
  97. color:#333;
  98. font-weight:700;
  99. }
  100. .text-p{
  101. line-height:60rpx;
  102. font-size:32rpx;
  103. padding:0 50rpx;
  104. color:#333;
  105. }
  106. .signature-box{
  107. display: flex;
  108. line-height:60rpx;
  109. font-size:32rpx;
  110. padding:0 50rpx;
  111. view{
  112. flex:1;
  113. }
  114. img{
  115. width:400rpx;
  116. height:160rpx;
  117. margin-top:15rpx;
  118. }
  119. }
  120. .img-box{
  121. line-height:60rpx;
  122. font-size:32rpx;
  123. padding:0 50rpx;
  124. margin-bottom:80rpx;
  125. // view:nth-child(1){
  126. // line-height:60rpx;
  127. // font-size:32rpx;
  128. // color:#333;
  129. // font-weight:700;
  130. // }
  131. view:nth-child(1){
  132. img{
  133. display: inline-block;
  134. width:210rpx;
  135. height:210rpx;
  136. }
  137. img:nth-child(2){
  138. margin:0 10rpx;
  139. }
  140. }
  141. }
  142. .positon-p{
  143. position: absolute;
  144. top:20rpx;
  145. right:30rpx;
  146. }
  147. .text-weight-box{
  148. display: flex;
  149. line-height:60rpx;
  150. font-size:32rpx;
  151. padding:0 50rpx;
  152. color:#333;
  153. font-weight:700;
  154. view:nth-child(1){
  155. flex:1;
  156. }
  157. view:nth-child(2){
  158. }
  159. }
  160. .text-box{
  161. display: flex;
  162. line-height:60rpx;
  163. font-size:32rpx;
  164. padding:0 50rpx;
  165. color:#333;
  166. view:nth-child(1){
  167. flex:1;
  168. }
  169. view:nth-child(2){
  170. }
  171. }
  172. .remark-box{
  173. line-height:60rpx;
  174. font-size:32rpx;
  175. padding:0 30rpx;
  176. color:#333;
  177. view:nth-child(1){
  178. line-height:80rpx;
  179. font-size:32rpx;
  180. color:#333;
  181. font-weight:700;
  182. }
  183. view:nth-child(2){
  184. padding:0 20rpx;
  185. line-height:50rpx;
  186. font-size:32rpx;
  187. color:#333;
  188. }
  189. }
  190. .flex-null-p{
  191. width:2rpx;
  192. height:20rpx;
  193. }
  194. .bottom-button-p{
  195. width:700rpx;
  196. height:80rpx;
  197. line-height:80rpx;
  198. font-size:34rpx;
  199. color:#fff;
  200. background-color: #0183FA;
  201. margin:40rpx 25rpx;
  202. border-radius:10rpx;
  203. text-align: center;
  204. }
  205. .colorA{
  206. color:#0183FA;
  207. }
  208. .colorB{
  209. color:#00CD66;
  210. }
  211. .colorC{
  212. color:#FF6A6A;
  213. }
  214. }
  215. </style>