bottomSheet.vue 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349
  1. <template>
  2. <view class="share">
  3. <view :class="{'share-box': shareState}" @click="handleHiddenShare">
  4. </view>
  5. <view class="share-item" :class="{'share-show': shareState}">
  6. <view class="share-to">
  7. <text style="font-size: 14px;color: #000;">{{title}}</text>
  8. </view>
  9. <scroll-view scroll-y="true" class="scroll-Y">
  10. <view class="uni-list-cell" hover-class="uni-list-cell-hover" v-for="(value, key) in historyList"
  11. :key="key">
  12. <view class="uni-media-list">
  13. <view class="uni-media-list-body" style="margin-left: 15px;">
  14. <view v-if="title=='拆旧管'">
  15. <view class="uni-media-list-text-top"
  16. style="font-size: 13px;color: #000;margin-top: 5px;">
  17. 腐蚀等级:{{value.zEngineeringMaterialBo[0].corrosionLevel}}</view>
  18. <view class="uni-media-list-text-top"
  19. style="font-size: 13px;color: #000;margin-top: 5px;">
  20. 施工时间:{{value.createTime}}</view>
  21. </view>
  22. <view v-if="title=='打孔'">
  23. <view class="uni-media-list-text-top"
  24. style="font-size: 13px;color: #000;margin-top: 5px;">
  25. 孔距:{{value.zEngineeringMaterialBo[0].corrosionLevel}}</view>
  26. <view class="uni-media-list-text-top"
  27. style="font-size: 13px;color: #000;margin-top: 5px;">
  28. 施工时间:{{value.createTime}}</view>
  29. </view>
  30. <view v-else-if="title=='立杠'||title=='表后管'||title=='挂表'||title=='阀管'||title=='报警器切断阀'">
  31. <view class="uni-media-list-text-top"
  32. style="font-size: 13px;color: #000;margin-top: 5px;" v-show="title=='阀管'">
  33. 上门类型:{{value.zEngineeringMaterialBo[0].visitType}}</view>
  34. <view class="uni-media-list-text-top"
  35. style="font-size: 13px;color: #000;margin-top: 5px;" v-show="title=='阀管'">
  36. 自闭阀类型:{{value.zEngineeringMaterialBo[0].selfClosingValveType}}</view>
  37. <view class="uni-media-list-text-top"
  38. style="font-size: 13px;color: #000;margin-top: 5px;"
  39. v-show="title=='立杠'||title=='表后管'||title=='阀管'">
  40. 材质:{{value.zEngineeringMaterialBo[0].materialQualityName}}</view>
  41. <view class="uni-media-list-text-top"
  42. style="font-size: 13px;color: #000;margin-top: 5px;"
  43. v-show="title=='立杠'||title=='表后管'||title=='阀管'">
  44. 规格:{{value.zEngineeringMaterialBo[0].specificationsName}}</view>
  45. <view class="uni-media-list-text-top"
  46. style="font-size: 13px;color: #000;margin-top: 5px;" v-show="title=='挂表'">
  47. 品牌:{{value.zEngineeringMaterialBo[0].brand}}</view>
  48. <view class="uni-media-list-text-top"
  49. style="font-size: 13px;color: #000;margin-top: 5px;" v-show="title=='报警器切断阀'">
  50. 厂家:{{value.zEngineeringMaterialBo[0].brand}}</view>
  51. <view class="uni-media-list-text-top"
  52. style="font-size: 13px;color: #000;margin-top: 5px;" v-show="title=='立杠'||title=='表后管'||title=='挂表'||title=='阀管'">
  53. 数量:{{value.zEngineeringMaterialBo[0].number}}</view>
  54. <view class="uni-media-list-text-top"
  55. style="font-size: 13px;color: #000;margin-top: 5px;">
  56. 施工时间:{{value.createTime}}</view>
  57. </view>
  58. <view
  59. v-else-if="title=='放线'||title=='挖沟'||title=='焊接'||title=='下沟'||title=='除锈'||title=='刷油'||title=='打磨'||title=='焊接'">
  60. <view class="uni-media-list-text-top"
  61. style="font-size: 13px;color: #000;margin-top: 5px;">
  62. 施工时间:{{value.constructTime}}</view>
  63. <view class="uni-media-list-text-top">
  64. <view class="uni-common-mt" style="width: 100%;">
  65. <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
  66. #000;margin-top: 5px;">施工内容:</text>
  67. <view style="width: 100%;padding-right: 20rpx;box-sizing: border-box;">
  68. <textarea class="textarea" maxlength="255" :disabled="true"
  69. placeholder-style="padding: 10rpx;"
  70. style="width: 100%;height: 100%;border: 1rpx solid #cccccc; border-radius: 15rpx;padding: 10rpx;line-height:normal;"
  71. auto-height>{{value.remark}}</textarea>
  72. </view>
  73. </view>
  74. </view>
  75. <view class="uni-media-list-text-top"
  76. style="font-size: 13px;color: #000;margin-top: 5px;">
  77. 材质:{{value.zEngineeringMaterialBo[0].materialQualityName}}</view>
  78. <view class="uni-media-list-text-top"
  79. style="font-size: 13px;color: #000;margin-top: 5px;">
  80. 规格:{{value.zEngineeringMaterialBo[0].specificationsName}}</view>
  81. <view class="uni-media-list-text-top"
  82. style="font-size: 13px;color: #000;margin-top: 5px;">
  83. 数量:{{value.zEngineeringMaterialBo[0].number}}</view>
  84. </view>
  85. <view v-else-if="title=='回填'">
  86. <view class="uni-media-list-text-top"
  87. style="font-size: 13px;color: #000;margin-top: 5px;">
  88. 施工时间:{{value.constructTime}}</view>
  89. <view class="uni-media-list-text-top"
  90. style="font-size: 13px;color: #000;margin-top: 5px;">
  91. 回填时间:{{value.backfillTime}}</view>
  92. <view class="uni-media-list-text-top">
  93. <view class="uni-common-mt" style="width: 100%;">
  94. <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
  95. #000;margin-top: 5px;">施工内容:</text>
  96. <view style="width: 100%;padding-right: 20rpx;box-sizing: border-box;">
  97. <textarea class="textarea" maxlength="255" :disabled="true"
  98. placeholder-style="padding: 10rpx;"
  99. style="width: 100%;height: 100%;border: 1rpx solid #cccccc; border-radius: 15rpx;padding: 10rpx;line-height:normal;"
  100. auto-height>{{value.remark}}</textarea>
  101. </view>
  102. </view>
  103. </view>
  104. <view class="uni-media-list-text-top"
  105. style="font-size: 13px;color: #000;margin-top: 5px;">
  106. 材质:{{value.zEngineeringMaterialBo[0].materialQualityName}}</view>
  107. <view class="uni-media-list-text-top"
  108. style="font-size: 13px;color: #000;margin-top: 5px;">
  109. 规格:{{value.zEngineeringMaterialBo[0].specificationsName}}</view>
  110. <view class="uni-media-list-text-top"
  111. style="font-size: 13px;color: #000;margin-top: 5px;">
  112. 数量:{{value.zEngineeringMaterialBo[0].number}}</view>
  113. </view>
  114. <view v-else-if="title=='打压'">
  115. <view class="uni-media-list-text-top"
  116. style="font-size: 13px;color: #000;margin-top: 5px;">
  117. 施工时间:{{value.constructTime}}</view>
  118. <view class="uni-media-list-text-top"
  119. style="font-size: 13px;color: #000;margin-top: 5px;">
  120. 分段打压是否台格:{{value.segmentedCompressionQualified=='Y'?'是':'否'}}</view>
  121. <view class="uni-media-list-text-top">
  122. <view class="uni-common-mt" style="width: 100%;">
  123. <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
  124. #000;margin-top: 5px;">施工内容:</text>
  125. <view style="width: 100%;padding-right: 20rpx;box-sizing: border-box;">
  126. <textarea class="textarea" maxlength="255" :disabled="true"
  127. placeholder-style="padding: 10rpx;"
  128. style="width: 100%;height: 100%;border: 1rpx solid #cccccc; border-radius: 15rpx;padding: 10rpx;line-height:normal;"
  129. auto-height>{{value.remark}}</textarea>
  130. </view>
  131. </view>
  132. </view>
  133. <view class="uni-media-list-text-top"
  134. style="font-size: 13px;color: #000;margin-top: 5px;">
  135. 材质:{{value.zEngineeringMaterialBo[0].materialQualityName}}</view>
  136. <view class="uni-media-list-text-top"
  137. style="font-size: 13px;color: #000;margin-top: 5px;">
  138. 规格:{{value.zEngineeringMaterialBo[0].specificationsName}}</view>
  139. <view class="uni-media-list-text-top"
  140. style="font-size: 13px;color: #000;margin-top: 5px;">
  141. 数量:{{value.zEngineeringMaterialBo[0].number}}</view>
  142. </view>
  143. <view class="uni-media-list-text-top">
  144. <text style="font-size: 13px;color: #000;margin-top: 5px;">负责人:</text>
  145. <text
  146. style="font-size: 13px;color: #000;margin-top: 5px;">{{value.constructUser}}</text>
  147. </view>
  148. <view class="uni-media-list-text-top">
  149. <text style="font-size: 13px;color: #000;margin-top: 5px;">负责人联系电话:</text>
  150. <text
  151. style="font-size: 13px;color: #000;margin-top: 5px;">{{value.constructPhone}}</text>
  152. </view>
  153. <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
  154. <text style="margin-left: 30rpx;margin-top: 6rpx;">{{ value.published_at }}</text>
  155. <view v-for="(item,index) in value.zEngiineeringPhotoBoList" :key="index"
  156. style="position: relative;">
  157. <view
  158. v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
  159. <image :src="item" mode=""
  160. style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
  161. @click="showPhoto(index,value.zEngiineeringPhotoBoList)">
  162. </image>
  163. </view>
  164. <view v-else>
  165. <video :src="item"
  166. style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
  167. </view>
  168. </view>
  169. </view>
  170. </view>
  171. </view>
  172. </view>
  173. </scroll-view>
  174. </view>
  175. </view>
  176. </template>
  177. <script>
  178. export default {
  179. props: {
  180. data: {
  181. type: Object,
  182. default: {}
  183. },
  184. },
  185. created() {
  186. this.getParamsData();
  187. },
  188. watch: {
  189. data(data) {
  190. this.getParamsData();
  191. }
  192. },
  193. data() {
  194. return {
  195. outPutData: {},
  196. historyList: [], //历史数据
  197. historyPhotoList: [], //历史图片数据
  198. shareState: false,
  199. title: '',
  200. };
  201. },
  202. methods: {
  203. showPhoto(index, list) {
  204. uni.previewImage({
  205. current: index,
  206. urls: list,
  207. })
  208. },
  209. getParamsData() {
  210. var selectData = this.data;
  211. this.outPutData = selectData;
  212. this.title = selectData.zEngineeringNodeBo.type;
  213. this.historyList = selectData.zEngineeringNodeBo.zEngineeringInfoBoList;
  214. //this.historyPhotoList = selectData.zEngineeringNodeBo.zEngineeringInfoBoList.zEngiineeringPhotoBoList;
  215. },
  216. // 显示分享
  217. handleShowShare() {
  218. this.shareState = true;
  219. },
  220. // 隐藏分享
  221. handleHiddenShare() {
  222. this.shareState = false;
  223. }
  224. }
  225. }
  226. </script>
  227. <style lang="less">
  228. .share {
  229. width: 100%;
  230. height: 100%;
  231. }
  232. .share-box {
  233. width: 100%;
  234. height: 100%;
  235. position: fixed;
  236. top: 0rpx;
  237. left: 0rpx;
  238. bottom: 0rpx;
  239. right: 0rpx;
  240. background-color: rgba(0, 0, 0, 0.4);
  241. transition: .3s;
  242. z-index: 999;
  243. }
  244. // 进入分享动画
  245. .share-show {
  246. transition: all 0.3s ease;
  247. transform: translateY(0%) !important;
  248. border-radius: 20px 20px 0px 0px;
  249. }
  250. .scroll-Y {
  251. height: 750rpx;
  252. }
  253. // 离开分享动画
  254. .share-item {
  255. position: fixed;
  256. left: 0;
  257. bottom: 0;
  258. width: 100%;
  259. height: 70%;
  260. background-color: #FFFFFF;
  261. transition: all 0.3s ease;
  262. transform: translateY(100%);
  263. z-index: 1999;
  264. .share-to {
  265. width: 100%;
  266. height: 30px;
  267. display: flex;
  268. justify-content: left;
  269. margin-left: 15px;
  270. align-items: center;
  271. &::after {
  272. content: '';
  273. width: 240rpx;
  274. height: 0rpx;
  275. border-top: 1px solid #E4E7ED;
  276. -webkit-transform: scaleY(0.5);
  277. transform: scaleY(0.5);
  278. margin-left: 30rpx;
  279. }
  280. &::before {
  281. content: '';
  282. width: 240rpx;
  283. height: 0rpx;
  284. border-top: 1px solid #E4E7ED;
  285. -webkit-transform: scaleY(0.5);
  286. transform: scaleY(0.5);
  287. margin-right: 30rpx;
  288. }
  289. }
  290. .content {
  291. width: 100%;
  292. height: auto;
  293. display: flex;
  294. flex-wrap: wrap;
  295. .block {
  296. width: 100%;
  297. display: flex;
  298. flex-direction: column;
  299. justify-content: center;
  300. align-items: left;
  301. height: auto;
  302. image {
  303. width: 80rpx;
  304. height: 80rpx;
  305. }
  306. text {
  307. margin-top: 16rpx;
  308. font-size: 28rpx;
  309. color: #606266;
  310. }
  311. }
  312. }
  313. .cancel {
  314. width: 100%;
  315. height: 3rem;
  316. display: flex;
  317. justify-content: center;
  318. align-items: center;
  319. border-top: 1rpx solid #E4E7ED;
  320. }
  321. }
  322. </style>