teacher_authentication_detail.vue 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265
  1. <template>
  2. <view class="container">
  3. <!-- 顶部信息 -->
  4. <view class="userInfo">
  5. <view>
  6. <text>用户ID</text>
  7. <text class="userDetail">{{item.uid}}</text>
  8. </view>
  9. <view class="userName">
  10. <text>贵姓</text>
  11. <text class="userDetail">{{item.firstName}}</text>
  12. </view>
  13. </view>
  14. <view class="userInfo">
  15. <view>
  16. <text>手机号</text>
  17. <text class="userDetail">{{item.phone}}</text>
  18. </view>
  19. <view class="userName">
  20. <text>英文名</text>
  21. <text class="userDetail">{{item.englishName || ''}}</text>
  22. </view>
  23. </view>
  24. <view class="userInfo">
  25. <text>微信号</text>
  26. <text class="userDetail">{{item.weixinId}}</text>
  27. </view>
  28. <view class="userInfo">
  29. <text>身份证号</text>
  30. <text class="userDetail">{{item.idCard}}</text>
  31. </view>
  32. <!-- 照片信息 -->
  33. <view class="userImg">
  34. <view class="userImgDetail">
  35. <uni-file-picker class="userImage" :imageStyles="listStyle" fileMediatype="image" v-model="idCardFrontByte" :fileExtname="fileExtname" limit="1" delIcon="false" readonly="true"/>
  36. <!-- <image class="userImage" :src="item.diplomaPhoto"></image> -->
  37. </view>
  38. <view class="userImgDetail">
  39. <uni-file-picker class="userImage" fileMediatype="image" :imageStyles="listStyle" v-model="idCardBackByte" :fileExtname="fileExtname" limit="1" delIcon="false" readonly="true"/>
  40. <!-- <image class="userImage" :src="item.idCardBack"></image> -->
  41. </view>
  42. <view class="userImgDetail">
  43. <uni-file-picker class="userImage" fileMediatype="image" :imageStyles="listStyle" v-model="profilePhotoByte" :fileExtname="fileExtname" limit="1" delIcon="false" readonly="true"/>
  44. <!-- <image class="userImage" :src="item.idCardFront"></image> -->
  45. </view>
  46. <view class="userImgDetail">
  47. <uni-file-picker class="userImage" fileMediatype="image" :imageStyles="listStyle" v-model="diplomaPhotoByte" :fileExtname="fileExtname" limit="1" delIcon="false" readonly="true"/>
  48. <!-- <image class="userImage" :src="item.profilePhoto"></image> -->
  49. </view>
  50. </view>
  51. <!-- 高校信息 -->
  52. <view class="school">
  53. <text>高校全名</text>
  54. <text class="schoolName">{{item.school}}</text>
  55. </view>
  56. <!-- 教员性别和专业 -->
  57. <view class="teacherSexMajor">
  58. <view>
  59. <text>教员性别</text>
  60. <text class="userDetail">{{item.sex}}</text>
  61. </view>
  62. <view class="teacherMajor">
  63. <text>当前学历</text>
  64. <text class="userDetail">{{item.education}}</text>
  65. </view>
  66. </view>
  67. <!-- 籍贯 -->
  68. <view class="userInfo">
  69. <text>籍贯</text>
  70. <text class="userDetail">{{item.nativePlace}}</text>
  71. </view>
  72. <!-- 当前学历 -->
  73. <view class="userInfo">
  74. <text>专业</text>
  75. <text class="userDetail">{{item.major}}</text>
  76. </view>
  77. <!-- 审核状态 -->
  78. <view class="audit">
  79. <text>审核状态</text>
  80. <text class="auditDetail">{{item.verifyStatus}}</text>
  81. </view>
  82. <!-- 审核不通过原因 -->
  83. <view class="auditResult">
  84. <text>审核不通过原因</text>
  85. <text class="auditDetail">{{item.verifyRefuseReason}}</text>
  86. </view>
  87. <!-- 申请日期 -->
  88. <view class="applyDate">
  89. <text>申请日期</text>
  90. <text class="userDetail">{{item.datetime}}</text>
  91. </view>
  92. <!-- 修改认证按钮 -->
  93. <view class="modify" @click="modifyAuthorize">
  94. <text class="modifyBtn">修改认证</text>
  95. </view>
  96. </view>
  97. </template>
  98. <script>
  99. import { mapState } from 'vuex';
  100. export default {
  101. computed: {
  102. ...mapState('m_user', ['authorizePhoto'])
  103. },
  104. data() {
  105. return {
  106. listStyle: {
  107. "height": 111, // 边框高度
  108. "width": 174, // 边框宽度
  109. "border":{ // 如果为 Boolean 值,可以控制边框显示与否
  110. "color":"#ccc", // 边框颜色
  111. "width":"1px", // 边框宽度
  112. "style":"solid", // 边框样式
  113. }
  114. },
  115. item: {},
  116. fileExtname: 'png,jpg',
  117. idCardFrontByte: [{
  118. url: '',
  119. extname: '',
  120. name: ''
  121. }],
  122. idCardBackByte: [{
  123. url: '',
  124. extname: '',
  125. name: ''
  126. }],
  127. profilePhotoByte: [{
  128. url: '',
  129. extname: '',
  130. name: ''
  131. }],
  132. diplomaPhotoByte: [{
  133. url: '',
  134. extname: '',
  135. name: ''
  136. }],
  137. };
  138. },
  139. onLoad(option) {
  140. this.item = JSON.parse(decodeURIComponent(option.item))
  141. let arr = this.item.name.split('')
  142. if (arr.length <= 3) {
  143. this.item.firstName = this.item.name.substring(0,1)
  144. } else {
  145. this.item.firstName = this.item.name.substring(0,2)
  146. }
  147. this.getPhotoes()
  148. },
  149. methods: {
  150. async getPhotoes() {
  151. this.diplomaPhotoByte[0].url = this.item.diplomaPhoto
  152. this.diplomaPhotoByte[0].name = 'diplomaPhoto'
  153. this.idCardBackByte[0].url = this.item.idCardBack
  154. this.idCardBackByte[0].name = 'idCardBack'
  155. this.profilePhotoByte[0].url = this.item.profilePhoto
  156. this.profilePhotoByte[0].name = 'profilePhoto'
  157. this.idCardFrontByte[0].url = this.item.idCardFront
  158. this.idCardFrontByte[0].name = 'idCardFront'
  159. },
  160. modifyAuthorize() {
  161. uni.navigateTo({
  162. url: '/subpkg/teacher/authentication/teacher_authentication_add?item=' + encodeURIComponent(JSON.stringify(this.item))
  163. })
  164. }
  165. }
  166. }
  167. </script>
  168. <!-- 设置页面背景 -->
  169. <style lang="scss">
  170. page{
  171. // height: 100%;
  172. // background-color: #FFF;
  173. }
  174. </style>
  175. <style lang="scss" scoped>
  176. .container {
  177. width: 93%;
  178. padding: 20rpx;
  179. margin-left: 10rpx;
  180. border-radius: 20rpx;
  181. background-color: #FFF;
  182. }
  183. /* 顶部用户信息、性别和专业 */
  184. .userInfo,
  185. .teacherSexMajor{
  186. display: flex;
  187. margin-top: 16rpx;
  188. }
  189. /* 姓、英文名、专业 */
  190. .userName,
  191. .teacherMajor{
  192. position: absolute;
  193. left: 60%;
  194. }
  195. .school{
  196. margin-top: 30rpx;
  197. }
  198. /* 用户详情、高校名称、审核状态即原因 */
  199. .userDetail,
  200. .schoolName,
  201. .auditDetail{
  202. margin-left: 20rpx;
  203. font-weight: bold;
  204. }
  205. /* 照片信息 */
  206. .userImg{
  207. margin-top: 30rpx;
  208. display: flex;
  209. flex-wrap: wrap;
  210. }
  211. /* 设置边框 */
  212. .userImgDetail{
  213. width: 45%;
  214. padding: 10rpx;
  215. height: 200rpx;
  216. display: flex;
  217. // border-left: 1rpx solid gray;
  218. // border-top: 1rpx solid gray;
  219. }
  220. /* 偶数照片添加右边框 */
  221. .userImg :nth-child(even){
  222. // border-right: 1rpx solid gray;
  223. }
  224. /* 第三张照片添加下边框 */
  225. .userImg :nth-child(3){
  226. // border-bottom: 1rpx solid gray;
  227. }
  228. /* 第四张照片添加下边框 */
  229. .userImg :nth-child(4){
  230. // border-bottom: 1rpx solid gray;
  231. }
  232. /* 设置照片 */
  233. .userImage{
  234. width: 100%;
  235. height: 100%;
  236. }
  237. /* 审核状态 */
  238. .audit{
  239. margin-top: 40rpx;
  240. }
  241. /* 审核不通过原因、申请日期 */
  242. .auditResult,
  243. .applyDate{
  244. margin-top: 20rpx;
  245. }
  246. /* 修改认证按钮 */
  247. .modify{
  248. margin-top: 120rpx;
  249. margin-bottom: 60rpx;
  250. display: flex;
  251. justify-content: center;
  252. }
  253. .modifyBtn{
  254. font-size: 38rpx;
  255. padding: 10rpx 30rpx;
  256. border-radius: 40rpx;
  257. background-color: #35b882;
  258. color: white;
  259. }
  260. </style>