transportPersonDetail.vue 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264
  1. <!-- 运输人员-详情-->
  2. <template>
  3. <view id="register">
  4. <viwe v-if="isAudit!=1" :class="isAudit==0?'tip':'reject'">{{isAudit==0?'信息正在审核中,请耐心等待...':'您提交的审核被驳回,驳回原因为:'+auditContent}}</viwe>
  5. <view class="register_li">
  6. <view class="register_li_min">
  7. <view></view>
  8. <view>姓名:</view>
  9. <input v-model="form.userName" disabled type="text" placeholder="请输入姓名">
  10. </view>
  11. <view class="register_li_min">
  12. <view></view>
  13. <view>联系方式:</view>
  14. <input v-model="form.phone" disabled type="text" placeholder="请输入联系方式">
  15. </view>
  16. <view v-for="(item,index) in form.userCredentialsVos" :key="index">
  17. <view class="driving_img" @click="lookItem(item)">
  18. <view>{{item.naturalName}}:</view>
  19. <img class="issue_img" :src="baseUrl+item.naturalUrl">
  20. </view>
  21. <view class="register_li_b2">
  22. <view>有效期</view>
  23. <picker mode="date" disabled @change="dateChange">
  24. <input class="picker-text" disabled type="text" v-model="item.startTime" placeholder="开始时间">
  25. </picker>
  26. <view>-</view>
  27. <picker mode="date" disabled @change="dateChange">
  28. <input class="picker-text2" disabled type="text" v-model="item.endTime" placeholder="结束时间">
  29. </picker>
  30. </view>
  31. </view>
  32. </view>
  33. <view class="sub_btn" v-if="isAudit==1" @click="subBnt()">编辑</view>
  34. <view class="sub_btn" v-if="isAudit==2" @click="subBnt()">重新提交</view>
  35. </view>
  36. </template>
  37. <script>
  38. import {transportUserDetail} from '@/api/apiDemo/index.js'
  39. import { config } from '@/api/request/config.js'
  40. export default {
  41. data() {
  42. return {
  43. baseUrl:config.base_url,
  44. form:{
  45. userName:'',
  46. phone:'',
  47. },
  48. id:'',
  49. isAudit:1,//是否已经审核(0=未审核,1=已经审核,2=审核未通过
  50. auditContent:'',//驳回时审核内容
  51. }
  52. },
  53. onLoad(option) {
  54. this.id=option.id;
  55. },
  56. onShow(){
  57. },
  58. methods: {
  59. //获取详情
  60. async getInfo(){
  61. let _this = this;
  62. const {data} = await transportUserDetail(this.id)
  63. if(data.code==200){
  64. let res=data.data
  65. this.isAudit=res.isAudit;
  66. this.form=res;
  67. let arr=[];
  68. _this.form.userCredentialsVos.forEach(function(item,idnex) {
  69. if(item.naturalUrl && item.startTime && item.endTime){
  70. arr.push(item)
  71. }
  72. })
  73. _this.form.userCredentialsVos=arr
  74. //驳回
  75. if(res.syntheticalAudit){
  76. this.auditContent=res.syntheticalAudit.auditContent
  77. }
  78. }
  79. },
  80. subBnt(){
  81. uni.redirectTo({
  82. url:'/pages_supplier/transportPerson/transportPersonAdd?status=1&id='+this.id
  83. });
  84. },
  85. lookItem(item){
  86. //查看图片
  87. wx.previewImage({
  88. urls: [config.base_url+item.naturalUrl], //需要预览的图片http链接列表,多张的时候,url直接写在后面就行了
  89. current: '', // 当前显示图片的http链接,默认是第一个
  90. success: function(res) {},
  91. fail: function(res) {},
  92. complete: function(res) {},
  93. })
  94. },
  95. },
  96. mounted() {
  97. this.getInfo();
  98. }
  99. }
  100. </script>
  101. <style lang="stylus" scoped>
  102. #register{
  103. height:auto;
  104. width:100%;
  105. display flex
  106. flex-direction column;
  107. padding-bottom: 220rpx;
  108. /* 审核中 */
  109. .tip{
  110. width: 750rpx;
  111. background: rgba(255,144,0,0.2);
  112. font-size: 28rpx;
  113. font-family: PingFang SC;
  114. font-weight: 500;
  115. color: #FF9000;
  116. line-height: 28rpx;
  117. padding: 36rpx 20rpx;
  118. box-sizing: border-box;
  119. }
  120. /* 驳回 */
  121. .reject{
  122. width: 750rpx;
  123. background: #F3DCDC;
  124. font-size: 28rpx;
  125. font-family: PingFang SC;
  126. font-weight: 500;
  127. color: #DC0000;
  128. line-height: 36rpx;
  129. padding: 36rpx 20rpx;
  130. box-sizing: border-box;
  131. }
  132. .register_li{
  133. background #fff;
  134. border-radius:20rpx;
  135. margin:20rpx 20rpx 0;
  136. padding:20rpx 0;
  137. box-sizing: border-box;
  138. .register_li_min{
  139. margin:0 26rpx;
  140. display flex;
  141. align-items center;
  142. border-bottom: 1px solid #F5F5F5;
  143. view{
  144. line-height:100rpx;
  145. font-size:28rpx;
  146. }
  147. view:nth-child(1){
  148. color:red;
  149. line-height:28rpx;
  150. margin-right: 12rpx;
  151. }
  152. view:nth-child(2){
  153. width:140rpx;
  154. font-size: 28rpx;
  155. font-family: PingFang SC;
  156. font-weight: 500;
  157. color: #999999;
  158. }
  159. >input{
  160. width 500rpx;
  161. text-align: right;
  162. font-size: 24rpx;
  163. font-family: PingFang SC;
  164. font-weight: 500;
  165. color: #333;
  166. }
  167. }
  168. /* 驾驶证 */
  169. .driving_img{
  170. margin:34rpx 20rpx 0;
  171. display flex;
  172. justify-content: space-between;
  173. border-bottom: 1px solid #F5F5F5;
  174. padding-bottom: 28rpx;
  175. box-sizing: border-box;
  176. view{
  177. //width:140rpx;
  178. font-size: 28rpx;
  179. font-family: PingFang SC;
  180. font-weight: 500;
  181. color: #999999;
  182. }
  183. .issue_img{
  184. width: 210rpx;
  185. height: 210rpx;
  186. border-radius: 10rpx;
  187. margin-left:250rpx;
  188. }
  189. }
  190. /* 有效期 */
  191. .register_li_b2{
  192. border-bottom: 1px solid #f5f5f5;
  193. height: 100rpx;
  194. display: flex;
  195. justify-content: flex-start;
  196. align-items: center;
  197. margin:0 20rpx 0;
  198. >view:nth-child(1){
  199. font-size: 28rpx;
  200. font-family: PingFang SC;
  201. font-weight: 500;
  202. color: #333333;
  203. line-height: 100rpx;
  204. }
  205. .picker-text{
  206. font-size: 24rpx;
  207. font-family: PingFang SC;
  208. font-weight: 500;
  209. color: #CCCCCC;
  210. line-height: 100rpx;
  211. width: 188rpx;
  212. margin-left: 158rpx;
  213. }
  214. >view:nth-child(2){
  215. font-size: 24rpx;
  216. font-family: PingFang SC;
  217. font-weight: 500;
  218. color: #CCCCCC;
  219. line-height: 100rpx;
  220. }
  221. .picker-text2{
  222. font-size: 24rpx;
  223. font-family: PingFang SC;
  224. font-weight: 500;
  225. color: #CCCCCC;
  226. line-height: 100rpx;
  227. width: 188rpx;
  228. text-align: right;
  229. }
  230. }
  231. }
  232. /* 按钮 */
  233. .sub_btn{
  234. width: 650rpx;
  235. height: 100rpx;
  236. background: #0183FA;
  237. border-radius: 20rpx;
  238. font-size: 28rpx;
  239. font-family: PingFang SC;
  240. font-weight: 500;
  241. color: #FFFFFF;
  242. line-height: 100rpx;
  243. text-align: center;
  244. margin-left: 50rpx;
  245. position: fixed;
  246. bottom:30rpx;
  247. z-index: 1000;
  248. }
  249. }
  250. /deep/.input-value-border{
  251. display :none !important;
  252. }
  253. </style>