myMsg.vue 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303
  1. <template>
  2. <view class="container">
  3. <!-- 图片区域 -->
  4. <image v-if="info.picture" class="image" :src="info.picture" mode="aspectFill" @click="handleImg(info.picture)"></image>
  5. <image v-else class="image" src="/static/7.png" mode="aspectFill" @click="handleImg('/static/7.png')"></image>
  6. <!-- 基本信息区域 -->
  7. <view class="basic">
  8. <view class="basic_title">
  9. <uni-icons type="staff" size="30" color="#000000"></uni-icons>
  10. <view class="text">基本信息</view>
  11. </view>
  12. <view class="basic_box">录取号:{{ info.admissNum }}</view>
  13. <view class="basic_box">姓名:{{ info.name }}</view>
  14. <view class="basic_box">身份证号:{{ info.cardId }}</view>
  15. <view class="basic_box">出生年月:{{ info.birthday }}</view>
  16. <view class="basic_box">性别:{{ info.sex }}</view>
  17. <view class="basic_box">院系:{{ info.college }}</view>
  18. <view class="basic_box">专业:{{ info.major }}</view>
  19. <view class="basic_box">班级:{{ info.classstr }}</view>
  20. <view class="basic_box">考生号:{{ info.examNum }}</view>
  21. <view class="basic_box">毕业中学:{{ info.graduationSchool }}</view>
  22. <view class="basic_box">政治面貌:{{ info.politicalStatu }}</view>
  23. <view class="basic_box">学制:{{ info.eduSystem }}</view>
  24. <view class="basic_box">批次:{{ info.batchValue }}</view>
  25. <view class="basic_box">民族:{{ info.nationality }}</view>
  26. </view>
  27. <!-- 填报明细区域 -->
  28. <view class="fill">
  29. <view class="fill_title">
  30. <uni-icons type="bars" size="25" color="#000000"></uni-icons>
  31. <view class="text">填报明细</view>
  32. </view>
  33. <view class="fill_box">手机号码:{{ info.phone }}</view>
  34. <view class="fill_box">籍贯:{{ info.oprovince + info.ocity + info.odistrict }}</view>
  35. <view class="fill_box">家庭住址:{{ info.province + info.city + info.district + info.address }}</view>
  36. <view class="fill_box">邮编:{{ info.zipCode }}</view>
  37. <view class="fill_box">按时报到:{{ info.registerOntime == 0 ? '否' : '是' }}</view>
  38. <view class="fill_box">交通方式:{{ info.trafficMethod }}</view>
  39. <view class="fill_box">到站地点:{{ info.arrive }}</view>
  40. <view class="fill_box">到站日期:{{ info.arrvieDate }}</view>
  41. <view class="fill_box">到站时间:{{ info.arriveTime }}</view>
  42. </view>
  43. <!-- 家庭成员区域 -->
  44. <view class="family">
  45. <view class="family_top">
  46. <uni-icons type="staff" size="30"></uni-icons>
  47. <view class="top_title">家庭成员</view>
  48. </view>
  49. <view class="family_table" v-if="info.fvs.length">
  50. <view class="table_box top">
  51. <view class="title">称谓</view>
  52. <view class="name">姓名</view>
  53. <view class="work">工作单位</view>
  54. <view class="phone">联系方式</view>
  55. </view>
  56. <view class="table_box" v-for="(item, index) in info.fvs" :key="index">
  57. <view class="title">{{ item.familyShip }}</view>
  58. <view class="name">{{ item.name }}</view>
  59. <view class="work">{{ item.workUnit }}</view>
  60. <view class="phone">{{ item.phone }}</view>
  61. </view>
  62. </view>
  63. </view>
  64. <!-- 陪同成员区域 -->
  65. <view class="family" v-if="info.avs.length">
  66. <view class="family_top">
  67. <uni-icons type="staff-filled" size="30"></uni-icons>
  68. <view class="top_title">陪同人员信息</view>
  69. </view>
  70. <view class="family_table">
  71. <view class="table_box top">
  72. <view class="title">序号</view>
  73. <view class="name">姓名</view>
  74. <view class="phone">联系电话</view>
  75. </view>
  76. <view class="table_box" v-for="(item, index) in info.avs" :key="index">
  77. <view class="title">{{ index + 1 }}</view>
  78. <view class="name">{{ item.name }}</view>
  79. <view class="phone">{{ item.phone }}</view>
  80. </view>
  81. </view>
  82. </view>
  83. <!-- 修改按钮 -->
  84. <view class="btn" @click="handleEdit">修改</view>
  85. <view class="btn" @click="handlePay">去缴费</view>
  86. <view class="btn margin" @click="logout">退出登录</view>
  87. </view>
  88. </template>
  89. <script setup>
  90. import { ref } from 'vue'
  91. import { onLoad } from '@dcloudio/uni-app'
  92. // 用户信息
  93. const info = ref({})
  94. onLoad(() => {
  95. info.value = uni.getStorageSync('studentInfo')
  96. // console.log(info.value)
  97. })
  98. // 修改按钮回调
  99. const handleEdit = () => {
  100. uni.showModal({
  101. title: '提示',
  102. content: '确定修改吗?',
  103. success: (res) => {
  104. if (res.confirm) {
  105. uni.setStorageSync('editType', 1)
  106. uni.reLaunch({
  107. url: '/pages/family/family'
  108. })
  109. }
  110. }
  111. })
  112. }
  113. // 去缴费按钮回调
  114. const handlePay = () => {
  115. uni.showModal({
  116. title: '提示',
  117. content: '确定去缴费吗?',
  118. success: (res) => {
  119. if (res.confirm) {
  120. window.location.href = `https://pay.ncjti.edu.cn`
  121. }
  122. }
  123. })
  124. }
  125. // 退出登录回调
  126. const logout = () => {
  127. uni.showModal({
  128. title: '提示',
  129. content: '确定退出登录吗?',
  130. success: (res) => {
  131. if (res.confirm) {
  132. let urlstr = uni.getStorageSync('urlstr')
  133. uni.clearStorageSync()
  134. window.location.href = `https://chtech.ncjti.edu.cn/welcome/welcomeH5/#/?urlstr=${urlstr}`
  135. }
  136. }
  137. })
  138. }
  139. // 点击图片回调
  140. const handleImg = (url) => {
  141. uni.previewImage({
  142. urls: [url]
  143. })
  144. }
  145. </script>
  146. <style lang="scss" scoped>
  147. .container {
  148. display: flex;
  149. flex-direction: column;
  150. align-items: center;
  151. padding: 20rpx;
  152. .image {
  153. width: 186rpx;
  154. height: 213rpx;
  155. border-radius: 8rpx;
  156. }
  157. .basic {
  158. margin-top: 20rpx;
  159. width: 100%;
  160. font-size: 28rpx;
  161. .basic_title {
  162. display: flex;
  163. align-items: center;
  164. margin-bottom: 30rpx;
  165. font-size: 30rpx;
  166. font-weight: bold;
  167. .text {
  168. margin-left: 15rpx;
  169. }
  170. }
  171. .basic_box {
  172. margin-bottom: 15rpx;
  173. }
  174. }
  175. .fill {
  176. margin-top: 20rpx;
  177. width: 100%;
  178. .fill_title {
  179. display: flex;
  180. align-items: center;
  181. margin-bottom: 30rpx;
  182. font-size: 30rpx;
  183. font-weight: bold;
  184. .text {
  185. margin-left: 15rpx;
  186. }
  187. }
  188. .fill_box {
  189. margin-bottom: 15rpx;
  190. }
  191. }
  192. .family {
  193. margin-bottom: 15rpx;
  194. width: 100%;
  195. background-color: #fff;
  196. .family_top {
  197. display: flex;
  198. align-items: center;
  199. height: 90rpx;
  200. .top_title {
  201. margin-left: 20rpx;
  202. font-size: 30rpx;
  203. font-weight: bold;
  204. }
  205. }
  206. .family_table {
  207. font-size: 24rpx;
  208. .table_box {
  209. display: flex;
  210. justify-content: space-between;
  211. align-items: center;
  212. height: 70rpx;
  213. border-bottom: 2rpx solid #e6e6e6;
  214. .title {
  215. width: 140rpx;
  216. text-align: center;
  217. white-space: nowrap;
  218. text-overflow: ellipsis;
  219. overflow: hidden;
  220. }
  221. .name {
  222. width: 140rpx;
  223. text-align: center;
  224. white-space: nowrap;
  225. text-overflow: ellipsis;
  226. overflow: hidden;
  227. }
  228. .work {
  229. width: 200rpx;
  230. text-align: center;
  231. white-space: nowrap;
  232. text-overflow: ellipsis;
  233. overflow: hidden;
  234. }
  235. .phone {
  236. width: 200rpx;
  237. text-align: center;
  238. white-space: nowrap;
  239. text-overflow: ellipsis;
  240. overflow: hidden;
  241. }
  242. }
  243. .top {
  244. background-color: #f0f3f7;
  245. }
  246. }
  247. }
  248. .btn {
  249. display: flex;
  250. align-items: center;
  251. justify-content: center;
  252. margin-top: 20rpx;
  253. width: 100%;
  254. height: 100rpx;
  255. font-size: 32rpx;
  256. color: #fff;
  257. border-radius: 8rpx;
  258. background-color: #0061ff;
  259. }
  260. .margin {
  261. margin-bottom: 50rpx;
  262. }
  263. }
  264. </style>