detailsList.vue 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273
  1. <template>
  2. <view class="container">
  3. <view style="margin-top: 15rpx;" class="content-header">
  4. <view v-for="item in ledgerList" style="margin-bottom: 30rpx;" class="">
  5. <view style="justify-content: space-between; " class="content">
  6. <view style="color:black;font-size: 36rpx;font-weight: 700;" class="message">
  7. {{item.miInstrument.name}}
  8. </view>
  9. <view style="padding-top: 5rpx;" :style="{
  10. color: recordColor[recordStatus(item.miInstrument.fillingStatus)],
  11. }">{{ recordStatus(item.miInstrument.fillingStatus) }}</view>
  12. </view>
  13. <view style="display: flex;" class="content">
  14. <view class="title">唯一标识:<span class="message">{{item.miInstrument.instrNo}}
  15. </span>
  16. </view>
  17. </view>
  18. <view style="display: flex;" class="content">
  19. <view class="title">器具用途:</view>
  20. <view class="message">{{item.miInstrument.purposeName}}</view>
  21. </view>
  22. <view class="content">
  23. <view class="title">制造单位:</view>
  24. <view class="message">{{item.miInstrument.manufactoryName}}</view>
  25. </view>
  26. <view style="display: flex;justify-content: space-between;" class="">
  27. <view style="display: flex;" class="content">
  28. <view class="title">器具类型:</view>
  29. <view style="padding-top: 5rpx; " class="message">
  30. {{item.miInstrument.typeName}}
  31. </view>
  32. </view>
  33. <view style="display: flex; align-items: center;" class="content">
  34. <view class="title">规格型号:</view>
  35. <view class="message">{{item.miInstrument.modelSpecific}}</view>
  36. </view>
  37. </view>
  38. <view style="display: flex;justify-content: space-between;" class="">
  39. <view style="display: flex;" class="content">
  40. <view class="title">出厂编号:</view>
  41. <view style="padding-top: 5rpx; " class="message">
  42. {{item.miInstrument.serialNumber}}
  43. </view>
  44. </view>
  45. <view style="display: flex; align-items: center;" class="content">
  46. <view class="title">内部编号:</view>
  47. <view class="message">{{item.miInstrument.internalNumber}}</view>
  48. </view>
  49. </view>
  50. </view>
  51. </view>
  52. <view style="display: flex;" class="submitBtn">
  53. <u-button @click="downLoadPDF" type="primary" style="margin: 0 auto; width:47%">备案申请单PDF下载</u-button>
  54. <u-button @click="chehui" type="error" style="margin: 0rpx auto; width: 47%">撤回</u-button>
  55. </view>
  56. <u-modal :show="show" :showCancelButton='true' @cancel="show=false" @confirm="handleGD" title="提示"
  57. content='确认要撤回此备案单吗?'></u-modal>
  58. </view>
  59. </template>
  60. <script>
  61. import {
  62. getMiAuditApplyOneList,
  63. getMiAuditApplyRoobtList,
  64. backAudit
  65. } from "@/api/assay";
  66. import {
  67. useDict,
  68. paraseDict
  69. } from "@/utils/index";
  70. export default {
  71. data() {
  72. return {
  73. show: false,
  74. recordColor: {
  75. 已撤回: "#fa3534",
  76. 已接收: "#2979ff",
  77. 待提交: "#2979ff",
  78. 备案中: "#2979ff",
  79. 已拒绝: "#fa3534",
  80. 勿备案: "#fa3534",
  81. 未备案: "#909399",
  82. 免备案: "#909399",
  83. 已退回: "#fa3534",
  84. },
  85. record: [], //备案字典
  86. ledgerList: [],
  87. total: 0,
  88. record: [],
  89. queryParams: {
  90. pageNum: 1,
  91. pageSize: 10,
  92. auditOrderId: '',
  93. auditOrderApplyId: ''
  94. }
  95. }
  96. },
  97. onLoad(option) {
  98. useDict("ejian_instrFillingStatus").then((res) => {
  99. this.record = res;
  100. });
  101. this.queryParams.auditOrderId = option.auditOrderId,
  102. this.queryParams.auditOrderApplyId = option.auditOrderApplyId
  103. getMiAuditApplyRoobtList({
  104. ...this.queryParams
  105. }).then((res) => {
  106. this.ledgerList = res.rows;
  107. this.total = res.total;
  108. })
  109. },
  110. computed: {
  111. // //检定状态
  112. // verificationStatus() {
  113. // return (row) => {
  114. // return paraseDict(this.verification, row);
  115. // };
  116. // },
  117. // //申请状态
  118. // applicationStatus() {
  119. // return (row) => {
  120. // return paraseDict(this.application, row);
  121. // };
  122. // },
  123. //备案状态
  124. recordStatus() {
  125. return (row) => {
  126. return paraseDict(this.record, row);
  127. };
  128. },
  129. },
  130. methods: {
  131. chehui() {
  132. this.show = true
  133. },
  134. handleGD() {
  135. backAudit().then((res) => {
  136. uni.showToast({
  137. title: "撤回成功",
  138. icon: "none",
  139. duration: 1000,
  140. });
  141. setTimeout(() => {
  142. uni.navigateBack()
  143. })
  144. })
  145. },
  146. downLoadPDF() {},
  147. onReachBottom() {
  148. //触底事件
  149. if (this.queryParams.pageNum * this.queryParams.pageSize >= this.total) {
  150. uni.showToast({
  151. title: "没有更多数据了",
  152. icon: "none",
  153. duration: 1000,
  154. });
  155. setTimeout(() => {
  156. uni.hideLoading();
  157. }, 500);
  158. } else {
  159. if (this.queryParams.pageNum <= this.queryParams.pageNum - 1) {
  160. setTimeout(() => {
  161. uni.hideLoading();
  162. }, 500);
  163. } else {
  164. uni.showLoading({
  165. title: "加载中",
  166. });
  167. this.queryParams.pageNum++;
  168. getMiAuditApplyRoobtList({
  169. ...this.queryParams
  170. }).then(({
  171. rows,
  172. total
  173. }) => {
  174. this.ledgerList = [...this.ledgerList, ...rows];
  175. this.total = total;
  176. });
  177. }
  178. setTimeout(() => {
  179. uni.hideLoading();
  180. }, 500);
  181. }
  182. },
  183. }
  184. }
  185. </script>
  186. <style>
  187. .submitBtn {
  188. width: 100%;
  189. background: #fff;
  190. padding: 15rpx 0;
  191. position: fixed;
  192. bottom: 0;
  193. }
  194. .content-header {
  195. width: 95%;
  196. border-radius: 6px;
  197. background: #fff;
  198. margin: 10rpx auto 10rpx;
  199. padding: 20rpx 30rpx 10rpx;
  200. .content {
  201. /* border-bottom: 1px solid rgb(242, 242, 242); */
  202. padding: 8rpx 0;
  203. display: flex;
  204. /* justify-content: space-between; */
  205. }
  206. .content:last-child {
  207. border-bottom: none;
  208. }
  209. .passIcon {
  210. position: absolute;
  211. top: 20rpx;
  212. right: 40rpx;
  213. }
  214. .title {
  215. font-size: 28rpx;
  216. color: rgb(146, 146, 146);
  217. letter-spacing: 3rpx;
  218. }
  219. .message {
  220. font-size: 28rpx;
  221. color: rgb(146, 146, 146);
  222. }
  223. }
  224. .container {
  225. height: 100vh;
  226. background: rgb(243, 244, 249);
  227. padding: 0rpx 0 110rpx;
  228. .contentItems {
  229. width: 95%;
  230. border-radius: 6px;
  231. background: #fff;
  232. margin: 0rpx auto 10rpx;
  233. padding: 10rpx 30rpx 10rpx;
  234. .content {
  235. /* border-bottom: 1px solid rgb(242, 242, 242); */
  236. padding: 14rpx 0;
  237. display: flex;
  238. /* justify-content: space-between; */
  239. }
  240. .content:last-child {
  241. border-bottom: none;
  242. }
  243. .title {
  244. font-size: 28rpx;
  245. color: black;
  246. letter-spacing: 3rpx;
  247. }
  248. .message {
  249. font-size: 28rpx;
  250. color: rgb(146, 146, 146);
  251. }
  252. }
  253. }
  254. </style>