hiddenDangerItemsDetail.vue 8.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360
  1. <!-- 检查详情 -->
  2. <template>
  3. <view class="snapshotDetail">
  4. <scroll-view scroll-y @scrolltolower="scrollGet" class="info-max-box">
  5. <view class="items" v-if="inspectionItems==0">
  6. <view class="items-li">
  7. <view>实验室</view>
  8. <view>{{newData.subName}}({{newData.subRoom}})</view>
  9. </view>
  10. <view class="items-li">
  11. <view>学院单位</view>
  12. <view>{{newData.deptName}}</view>
  13. </view>
  14. <view class="items-t" v-if="newData.hazardCheckName!=''">
  15. <view class="items-t-r">{{newData.hazardCheckCode}} {{newData.hazardCheckName}}</view>
  16. </view>
  17. <view class="items-b" v-if="newData.hazardCheckName!=''">< {{newData.hazardCheckCode2}} {{newData.hazardCheckName2}} < {{newData.hazardCheckCode1}} {{newData.hazardCheckName1}}</view>
  18. </view>
  19. <view class="items-number" v-if="newData.hazardCheckName!=''">此检查项在当前实验室累计出现<text>{{newData.hazardCheckNum}}</text>次隐患</view>
  20. <view class="list">
  21. <view class="list-li" v-if="newData.hazardCheckName!=''">
  22. <view>检查要点</view>
  23. <view>
  24. <img src="@/pages_safetyCheck/images/icon_06.png">
  25. </view>
  26. </view>
  27. <view v-if="newData.hazardCheckName!=''" class="hidden-content">{{newData.hazardCheckPoint}}
  28. </view>
  29. <view class="list-li">
  30. <view>检查隐患</view>
  31. </view>
  32. <view class="hidden-content">{{newData.hazardDescribe}}
  33. </view>
  34. <view class="photo">
  35. <img v-for="(item,index) in newData.yhDtoList" :src="baseUrl+item.fileUrl">
  36. </view>
  37. <view class="list-li">
  38. <view>隐患整改</view>
  39. <view :id="newData.rectifyStatus==0?'fontColor-A':(newData.rectifyStatus==1?'fontColor-B':'fontColor-C')">
  40. {{newData.rectifyStatus==0?'待整改':(newData.rectifyStatus==1?'已整改':'暂无法整改')}}
  41. <img src="@/pages_safetyCheck/images/icon_06.png">
  42. </view>
  43. </view>
  44. <view class="hidden-content" v-if="newData.rectifyStatus==1 || newData.rectifyStatus==2">{{newData.rectifyDescribe}}
  45. </view>
  46. <view class="photo" v-if="newData.rectifyStatus==1 || newData.rectifyStatus==2">
  47. <img v-for="(item,index) in newData.zgDtoList" :src="baseUrl+item.fileUrl">
  48. </view>
  49. <view class="list-li" v-if="newData.rectifyStatus==1 || newData.rectifyStatus==2">
  50. <view>整改方案</view>
  51. <view></view>
  52. </view>
  53. <view class="file-li" v-if="newData.rectifyStatus==1 || newData.rectifyStatus==2">
  54. <img src="@/pages_safetyCheck/images/icon_djc_wj.png">
  55. <view>{{newData.rectifyProjectName}}</view>
  56. </view>
  57. <view class="list-li" v-if="newData.rectifyStatus==1 || newData.rectifyStatus==2">
  58. <view>姓名:</view>
  59. <view>{{newData.rectifyUserName}}</view>
  60. </view>
  61. <view class="list-li" v-if="newData.rectifyStatus==1 || newData.rectifyStatus==2">
  62. <view>时间:</view>
  63. <view>{{newData.rectifyTime}}</view>
  64. </view>
  65. </view>
  66. </scroll-view>
  67. <view class="sub-btn" @click="rectificationBtn">{{newData.rectifyStatus==0?'整改':'继续整改'}}</view>
  68. </view>
  69. </template>
  70. <script>
  71. import {
  72. config
  73. } from '@/api/request/config.js'
  74. import {
  75. securityAppCheckPhotoDetail,
  76. } from '@/pages_safetyCheck/api/index.js'
  77. export default {
  78. name: "snapshotDetail",
  79. components: {
  80. },
  81. data() {
  82. return {
  83. baseUrl: config.base_url,
  84. inspectionItems:0,//0有检查项 1无检查项
  85. newData: {},
  86. photoId:'',
  87. }
  88. },
  89. onLoad(option) {
  90. this.$set(this, 'photoId', JSON.parse(decodeURIComponent(option.infoData)).photoId);
  91. },
  92. onShow() {
  93. },
  94. mounted() {
  95. this.securityAppCheckPhotoDetail();
  96. },
  97. methods: {
  98. //滚动事件
  99. scrollGet() {},
  100. async securityAppCheckPhotoDetail() {
  101. let self = this;
  102. const {
  103. data
  104. } = await securityAppCheckPhotoDetail({photoId:this.photoId});
  105. if (data.code == 200) {
  106. this.$set(this, 'newData', data.data);
  107. }
  108. },
  109. //整改页面
  110. rectificationBtn(){
  111. let self=this;
  112. let infoData=self.newData;
  113. console.log(self.newData)
  114. uni.navigateTo({
  115. url: '/pages_safetyCheck/views/itemsManage/snapshotRectification?infoData=' + encodeURIComponent(JSON.stringify(infoData))
  116. });
  117. },
  118. }
  119. }
  120. </script>
  121. <style lang="stylus" scoped>
  122. .snapshotDetail {
  123. height: 100%;
  124. display flex;
  125. box-sizing: border-box;
  126. padding-bottom: 160rpx;
  127. box-sizing: border-box;
  128. #bgColor-A {
  129. color: #FFD400;
  130. }
  131. #bgColor-B {
  132. color: #FF8C00;
  133. }
  134. #bgColor-C {
  135. color: #E11608;
  136. }
  137. #fontColor-A {
  138. color: #0183FA;
  139. }
  140. #fontColor-B {
  141. color: #16B531;
  142. }
  143. #fontColor-C {
  144. color: #FF8C00;
  145. }
  146. .items {
  147. width: 690rpx;
  148. min-height: 165rpx;
  149. background: #FFFFFF;
  150. border-radius: 20rpx 20rpx 20rpx 20rpx;
  151. margin: 20rpx 0 0 30rpx;
  152. .items-li{
  153. display: flex;
  154. justify-content: space-between;
  155. align-items: center;
  156. padding: 0 30rpx;
  157. box-sizing: border-box;
  158. border-bottom: 1rpx solid #E0E0E0;
  159. >view:nth-of-type(1) {
  160. font-size: 30rpx;
  161. color: #333333;
  162. line-height: 80rpx;
  163. text-align: left;
  164. }
  165. >view:nth-of-type(2) {
  166. font-size: 28rpx;
  167. color: #666666;
  168. line-height: 80rpx;
  169. text-align: left;
  170. display: flex;
  171. justify-content: space-between;
  172. align-items: center;
  173. }
  174. }
  175. .items-t {
  176. border-bottom: 1rpx solid #E0E0E0;
  177. height: 80rpx;
  178. display: flex;
  179. justify-content: flex-start;
  180. align-items: center;
  181. padding: 0 30rpx;
  182. box-sizing: border-box;
  183. .items-t-l {
  184. width: 175rpx;
  185. height: 50rpx;
  186. background: #E11608;
  187. border-radius: 50rpx 50rpx 50rpx 50rpx;
  188. font-size: 30rpx;
  189. color: #FFFFFF;
  190. line-height: 50rpx;
  191. text-align: center;
  192. margin-right: 14rpx;
  193. }
  194. .items-t-r {
  195. font-size: 30rpx;
  196. color: #333333;
  197. line-height: 42rpx;
  198. text-align: left;
  199. }
  200. }
  201. .items-b {
  202. padding: 0 30rpx;
  203. box-sizing: border-box;
  204. height: 80rpx;
  205. font-size: 28rpx;
  206. color: #666666;
  207. line-height: 80rpx;
  208. text-align: left;
  209. }
  210. }
  211. .items-number {
  212. font-size: 24rpx;
  213. color: #3D3D3D;
  214. line-height: 34rpx;
  215. text-align: right;
  216. margin: 20rpx 60rpx 0 0;
  217. >text {
  218. font-size: 24rpx;
  219. color: #FF0000;
  220. line-height: 34rpx;
  221. text-align: right;
  222. }
  223. }
  224. .list {
  225. width: 690rpx;
  226. margin: 20rpx 30rpx 0;
  227. background: #FFFFFF;
  228. border-radius: 20rpx 20rpx 20rpx 20rpx;
  229. .list-li {
  230. display: flex;
  231. justify-content: space-between;
  232. align-items: center;
  233. padding: 0 30rpx;
  234. box-sizing: border-box;
  235. border-bottom: 1rpx solid #E0E0E0;
  236. >view:nth-of-type(1) {
  237. font-size: 30rpx;
  238. color: #333333;
  239. line-height: 80rpx;
  240. text-align: left;
  241. }
  242. >view:nth-of-type(2) {
  243. font-size: 28rpx;
  244. color: #666666;
  245. line-height: 80rpx;
  246. text-align: left;
  247. display: flex;
  248. justify-content: space-between;
  249. align-items: center;
  250. >img {
  251. width: 24rpx;
  252. height: 12rpx;
  253. margin-left: 10rpx;
  254. }
  255. }
  256. }
  257. .file-li{
  258. display: flex;
  259. justify-content: space-between;
  260. align-items: center;
  261. padding: 0 30rpx;
  262. box-sizing: border-box;
  263. >img:nth-of-type(1) {
  264. width: 30rpx;
  265. height: 30rpx;
  266. }
  267. >view{
  268. flex: 1;
  269. font-size: 28rpx;
  270. color: #333333;
  271. line-height: 80rpx;
  272. text-align: left;
  273. margin: 0 92rpx 0 16rpx;
  274. overflow: hidden;
  275. text-overflow: ellipsis;
  276. white-space: nowrap;
  277. }
  278. >img:nth-of-type(2) {
  279. width: 30rpx;
  280. height: 30rpx;
  281. }
  282. }
  283. .hidden-content {
  284. width: 630rpx;
  285. min-height: 120rpx;
  286. background: #F5F5F5;
  287. border-radius: 20rpx 20rpx 20rpx 20rpx;
  288. margin: 20rpx 30rpx 0;
  289. padding: 20rpx;
  290. box-sizing: border-box;
  291. font-size: 28rpx;
  292. color: #666666;
  293. line-height: 39rpx;
  294. text-align: left;
  295. }
  296. .photo {
  297. display: flex;
  298. justify-content: flex-start;
  299. flex-wrap: wrap;
  300. margin-top: 20rpx;
  301. padding: 0 30rpx;
  302. box-sizing: border-box;
  303. >img {
  304. width: 150rpx;
  305. height: 150rpx;
  306. border-radius: 10rpx 10rpx 10rpx 10rpx;
  307. margin: 0 10rpx 10rpx 0;
  308. }
  309. }
  310. .list-li:last-of-type {
  311. border: none;
  312. }
  313. }
  314. }
  315. .sub-btn{
  316. width: 686rpx;
  317. height: 100rpx;
  318. background: #0183FA;
  319. border-radius: 50rpx 50rpx 50rpx 50rpx;
  320. position: fixed;
  321. left: 30rpx;
  322. bottom: 30rpx;
  323. font-weight: 400;
  324. font-size: 30rpx;
  325. color: #FFFFFF;
  326. line-height: 100rpx;
  327. text-align: center;
  328. }
  329. </style>