PersonalEditing.vue 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270
  1. <template>
  2. <view class="page" :style="{'min-height':h+'px'}">
  3. <view class="from-content">
  4. <view class="one-image" @click="upImage">
  5. <view class="user">
  6. 店铺标志
  7. </view>
  8. <view class="image">
  9. <image src="https://i.ringzle.com/file/20240224/2c5f3ed11f1a47519f0a68cb60f0d9a9.png" mode="">
  10. </image>
  11. <!-- <image :src="dto.headUrl" mode="aspectFill"></image> -->
  12. </view>
  13. </view>
  14. <view class="one-realName">
  15. <view class="realName">
  16. 店铺名称
  17. </view>
  18. <!-- <u--input v-model="realName" border="none" pl ></u--input> -->
  19. <view class="right">
  20. <input type="text" v-model="dto.realName" border="none" placeholder="请输入昵称" />
  21. </view>
  22. </view>
  23. <view class="one-mobile">
  24. <view class="mobile">
  25. 联系电话
  26. </view>
  27. <view class="right">
  28. <input type="text" v-model="dto.modifyPhone" border="none" placeholder="请输入手机号"
  29. style="height: 48rpx;" />
  30. </view>
  31. </view>
  32. <view class="one-mobile">
  33. <view class="mobile">
  34. 商家地址
  35. </view>
  36. <view class="right">
  37. 浙江省舟山市嵊泗县菜园镇东海路89号
  38. </view>
  39. </view>
  40. <view class="one" @click="nav">
  41. <view class="">
  42. 营业执照
  43. </view>
  44. <view class="">
  45. <u-icon name="arrow-right"></u-icon>
  46. </view>
  47. </view>
  48. <view class="one">
  49. <view class="">
  50. 统一社会信用代码
  51. </view>
  52. <view class="">
  53. <u-icon name="arrow-right"></u-icon>
  54. </view>
  55. </view>
  56. </view>
  57. <view class="from-content">
  58. <view class="title">
  59. 店铺照片
  60. </view>
  61. <view class="">
  62. 照片
  63. </view>
  64. </view>
  65. </view>
  66. </template>
  67. <script>
  68. export default {
  69. data() {
  70. return {
  71. h: uni.getSystemInfoSync().windowHeight - 87,
  72. mt: uni.getSystemInfoSync().statusBarHeight + 44,
  73. titleHeader: '个人信息',
  74. fileList: [],
  75. dto: {
  76. realName: '黄沙村渔家乐', //昵称
  77. modifyPhone: '18755113256', //手机号
  78. headUrl: '', // 头像
  79. idCode: '', // 证件号
  80. id: ''
  81. },
  82. picList: [],
  83. objList: {}
  84. }
  85. },
  86. onLoad() {
  87. },
  88. methods: {
  89. // 上传头像
  90. upImage() {
  91. uni.chooseImage({
  92. sourceType: ['album'], //从相册选择
  93. success: chooseImageRes => {
  94. const tempFilePaths = chooseImageRes.tempFilePaths;
  95. uni.uploadFile({
  96. url: 'https://i.ringzle.com/island-cloud-server/oss/file/upload', // 仅为示例,非真实的接口地址
  97. filePath: tempFilePaths[0],
  98. name: 'file',
  99. header: {
  100. token: wx.getStorageSync('access_token')
  101. },
  102. success: res => {
  103. // uploadFile上传成功后,根据和后台的约定msgCode判断接口调用状态
  104. let data = JSON.parse(res.data);
  105. this.dto.headUrl = data.data.url
  106. }
  107. });
  108. },
  109. fail: err => {
  110. this.myToast('图片上传失败', 'none');
  111. }
  112. });
  113. },
  114. }
  115. }
  116. </script>
  117. <style lang="scss" scoped>
  118. .page {
  119. box-sizing: border-box;
  120. padding: 30rpx;
  121. // padding-top: 150rpx;
  122. }
  123. .from-content {
  124. .title {
  125. margin: 40rpx 0 36rpx;
  126. font-size: 30rpx;
  127. font-weight: Regular;
  128. color: #111111;
  129. }
  130. .one-image {
  131. width: 100%;
  132. display: flex;
  133. justify-content: space-between;
  134. .image {
  135. width: 124rpx;
  136. height: 124rpx;
  137. border-radius: 100rpx;
  138. image {
  139. width: 100%;
  140. height: 100%;
  141. border-radius: 100rpx;
  142. }
  143. }
  144. .user {
  145. margin-top: 24rpx;
  146. font-size: 30rpx;
  147. color: #111;
  148. font-weight: Regular;
  149. }
  150. }
  151. .one-realName {
  152. width: 100%;
  153. display: flex;
  154. align-items: center;
  155. height: 120rpx;
  156. line-height: 120rpx;
  157. border-bottom: 1rpx solid #EFEFEF;
  158. .realName {
  159. width: 188rpx;
  160. height: 120rpx;
  161. font-size: 30rpx;
  162. color: #333333;
  163. font-weight: Regular;
  164. }
  165. .right {
  166. text-align: right;
  167. width: 100%;
  168. font-size: 30rpx;
  169. color: #666666;
  170. font-weight: Regular;
  171. // display: flex;
  172. // justify-content: space-between;
  173. }
  174. }
  175. .one-mobile {
  176. display: flex;
  177. width: 100%;
  178. align-items: center;
  179. height: 120rpx;
  180. line-height: 120rpx;
  181. border-bottom: 1rpx solid #EFEFEF;
  182. .right {
  183. width: 100%;
  184. text-align: right;
  185. font-size: 30rpx;
  186. color: #666666;
  187. font-weight: Regular;
  188. }
  189. .mobile {
  190. width: 188rpx;
  191. height: 120rpx;
  192. font-size: 30rpx;
  193. color: #333333;
  194. font-weight: Regular;
  195. }
  196. .replacement {
  197. border-radius: 50rpx;
  198. width: 80rpx;
  199. height: 48rpx;
  200. line-height: 48rpx;
  201. border: 1rpx solid #025EA7;
  202. color: #025EA7;
  203. font-weight: Regular;
  204. font-size: 24rpx;
  205. text-align: center;
  206. }
  207. }
  208. .one {
  209. height: 120rpx;
  210. line-height: 120rpx;
  211. display: flex;
  212. border-bottom: 1rpx solid #EFEFEF;
  213. justify-content: space-between;
  214. align-items: center;
  215. font-size: 30rpx;
  216. color: #333333;
  217. font-weight: Regular;
  218. }
  219. }
  220. .btn {
  221. margin: 120rpx auto;
  222. width: 650rpx;
  223. height: 88rpx;
  224. display: flex;
  225. background-color: #01B9F9;
  226. line-height: 88rpx;
  227. border-radius: 50rpx;
  228. .btn-btn {
  229. margin: 0 auto;
  230. font-size: 32rpx;
  231. color: #FFFFFF;
  232. font-weight: Regular;
  233. }
  234. }
  235. </style>