铝交易,微信公众号
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

418 lines
10 KiB

5 months ago
5 months ago
5 months ago
5 months ago
5 months ago
6 months ago
5 months ago
5 months ago
5 months ago
5 months ago
  1. <template>
  2. <view class="registerShop">
  3. <navbar :title="titleList[titleIndex]" leftClick @leftClick="$utils.navigateBack" />
  4. <view class="frame">
  5. <!--基本信息-->
  6. <view class="basicInfo">
  7. <!--用户名-->
  8. <view class="item">
  9. <view>账号/手机号</view>
  10. <!-- <view>{{ $t('components.username')}}</view> -->
  11. <view>
  12. <!-- <input v-model="form.userName" :placeholder="$t('components.enterUserName')" clearable></input> -->
  13. <input v-model="form.userName" placeholder="请输入账号/手机号" clearable></input>
  14. </view>
  15. </view>
  16. <!--密码-->
  17. <view class="item">
  18. <view>{{ $t('components.password')}}</view>
  19. <view>
  20. <input v-model="form.password" password clearable
  21. :placeholder="$t('components.enterYourPassword')" clearable></input>
  22. </view>
  23. </view>
  24. <!--公司名称-->
  25. <view class="item">
  26. <view>{{ $t('other.companyName')}}</view>
  27. <view>
  28. <input v-model="form.companyName" type="number" :placeholder="$t('other.enterCompanyName')"
  29. clearable></input>
  30. </view>
  31. </view>
  32. <!--税收编码-->
  33. <view class="item">
  34. <view>{{ $t('other.taxCode')}}</view>
  35. <view>
  36. <input v-model="form.taxCode" :placeholder="$t('other.enterTaxCode')" clearable></input>
  37. </view>
  38. </view>
  39. <!--公司地址-->
  40. <view class="item">
  41. <view>{{ $t('other.companyAddress')}}</view>
  42. <view>
  43. <input v-model="form.address" :placeholder="$t('other.enterCompanyAddress')" clearable></input>
  44. </view>
  45. </view>
  46. <!--联系电话-->
  47. <view class="item">
  48. <view>{{ $t('components.lxPhone')}}</view>
  49. <view>
  50. <input v-model="form.phone" :placeholder="$t('components.plePhoneNumber')" clearable></input>
  51. </view>
  52. </view>
  53. <!---->
  54. <view class="item">
  55. <view>{{ $t('other.companyAccount')}}</view>
  56. <view>
  57. <input v-model="form.bankAccount" :placeholder="$t('other.enterCompanyAccount')"
  58. clearable></input>
  59. </view>
  60. </view>
  61. <view class="item">
  62. <view>{{ $t('components.bankName')}}</view>
  63. <view>
  64. <input v-model="form.bankNama" :placeholder="$t('components.enterBankName')" clearable></input>
  65. </view>
  66. </view>
  67. </view>
  68. <!--证件信息-->
  69. <view class="certificateInfo">
  70. <!--营业执照-->
  71. <view class="certificateInfoItem">
  72. <view class="title">
  73. <span
  74. style="width: 10rpx;height: 40rpx;background-color: #f78142;border-radius: 10rpx;overflow: hidden;"></span>
  75. <span>{{ $t('components.businessLicense')}}</span>
  76. </view>
  77. <view class="upload">
  78. <uv-upload :fileList="yyzzfileList" :maxCount="4" multiple width="150rpx" height="150rpx"
  79. @delete="(file) => deleteImage(0, file)" @afterRead="(file) => afterRead(0, file)"
  80. :previewFullImage="true"></uv-upload>
  81. </view>
  82. </view>
  83. <!--基本户信息-->
  84. <view class="certificateInfoItem">
  85. <view class="title">
  86. <span
  87. style="width: 10rpx;height: 40rpx;background-color: #f78142;border-radius: 10rpx;overflow: hidden;"></span>
  88. <span>{{ $t('components.basicAccountInfo')}}</span>
  89. </view>
  90. <view class="upload">
  91. <uv-upload :fileList="jbhxxfileList" :maxCount="4" multiple width="150rpx" height="150rpx"
  92. @delete="(file) => deleteImage(1, file)" @afterRead="(file) => afterRead(1, file)"
  93. :previewFullImage="true"></uv-upload>
  94. </view>
  95. </view>
  96. <!--收款银行-->
  97. <view class="certificateInfoItem">
  98. <view class="title">
  99. <span
  100. style="width: 10rpx;height: 40rpx;background-color: #f78142;border-radius: 10rpx;overflow: hidden;"></span>
  101. <span>{{ $t('components.receivingBank')}}</span>
  102. </view>
  103. <view class="upload">
  104. <uv-upload :fileList="skyhfileList" :maxCount="4" multiple width="150rpx" height="150rpx"
  105. @delete="(file) => deleteImage(2, file)" @afterRead="(file) => afterRead(2, file)"
  106. :previewFullImage="true"></uv-upload>
  107. </view>
  108. </view>
  109. </view>
  110. </view>
  111. <view class="bottom">
  112. <view class="btns">
  113. <!--申请审核-->
  114. <span @click="applyReview" class="sqsh">
  115. {{ $t('components.submitReview') }}
  116. </span>
  117. <!--联系我们-->
  118. <span @click="contactUs" class="lxwm">
  119. {{ $t('components.contactUs') }}
  120. </span>
  121. </view>
  122. <view class="others">
  123. <!--注册须知-->
  124. <span @click="applyReview" class="zcxz">
  125. {{ $t('components.registrationNotice') }}
  126. </span>
  127. <!--框架合同预览-->
  128. <span @click="contactUs" class="kjhtyl">
  129. {{ $t('other.frameworkContractPreview') }}
  130. </span>
  131. </view>
  132. </view>
  133. <!-- 联系客服弹框 -->
  134. <customerServicePopup ref="customerServicePopup" />
  135. </view>
  136. </template>
  137. <script>
  138. import customerServicePopup from "@/components/config/customerServicePopup.vue";
  139. export default {
  140. components: {
  141. customerServicePopup
  142. },
  143. onLoad(option) {
  144. this.titleIndex = option.identity
  145. this.form.role = option.identity
  146. },
  147. data() {
  148. return {
  149. titleIndex: 0,
  150. titleList: [
  151. // 采购商注册 供应商注册 国内清关申请
  152. this.$t('other.buyerRegistration'),
  153. this.$t('other.supplierRegistration'),
  154. this.$t('other.domesticCustomsClearanceApplication')
  155. ],
  156. form: {
  157. "address": "",
  158. "auditStatus": 0,
  159. "bankAccount": "",
  160. "bankInfo": "",
  161. "bankNama": "",
  162. "basicAccount": "",
  163. "businessLicense": "",
  164. "companyName": "",
  165. "password": "",
  166. "phone": "",
  167. "role": 0,
  168. "taxCode": "",
  169. "userName": ""
  170. },
  171. yyzzfileList: [],//营业执照
  172. jbhxxfileList: [],//基本户信息
  173. skyhfileList: [],//收款银行
  174. }
  175. },
  176. methods: {
  177. // 申请审核
  178. applyReview() {
  179. let data = JSON.parse(JSON.stringify(this.form))
  180. data.businessLicense = this.yyzzfileList.map((item) => item.url).join(",")
  181. data.basicAccount = this.jbhxxfileList.map((item) => item.url).join(",")
  182. data.bankInfo = this.skyhfileList.map((item) => item.url).join(",")
  183. if(this.$utils.verificationAll(data, {
  184. "userName": this.$t('components.enterUserName'),
  185. "password": this.$t('components.enterYourPassword'),
  186. "companyName": this.$t('other.enterCompanyName'),
  187. "taxCode": this.$t('other.enterTaxCode'),
  188. "address": this.$t('other.enterCompanyAddress'),
  189. "phone": this.$t('components.plePhoneNumber'),
  190. "bankAccount": this.$t('other.enterCompanyAccount'),
  191. "bankNama": this.$t('components.enterBankName'),
  192. "businessLicense": '请上传营业执照',
  193. "basicAccount": '请上传基本户信息照片',
  194. "bankInfo": '请上传收款银行照片',
  195. })){
  196. return
  197. }
  198. this.$api(this.titleIndex == 2 ?
  199. 'addCustoms'
  200. : 'roleOption', this.form, res => {
  201. if (res.code == 200) {
  202. uni.removeStorageSync('token')
  203. this.$store.state.userInfo = {}
  204. // uni.redirectTo({
  205. // url: '/pages/index/index'
  206. // })
  207. uni.showToast({
  208. title: '提交成功!耐心等待审核',
  209. icon: 'none'
  210. })
  211. }
  212. })
  213. },
  214. // 联系我们
  215. contactUs() {
  216. console.log("打开客服弹框")
  217. this.$refs.customerServicePopup.open();
  218. },
  219. // 上传图片
  220. afterRead(type, e) {
  221. let self = this
  222. e.file.forEach(file => {
  223. self.$Oss.ossUpload(file.url).then(url => {
  224. if (type == 0) {
  225. self.yyzzfileList.push({
  226. url
  227. })
  228. } else if (type == 1) {
  229. self.jbhxxfileList.push({
  230. url
  231. })
  232. } else if (type == 2) {
  233. self.skyhfileList.push({
  234. url
  235. })
  236. }
  237. })
  238. })
  239. },
  240. // 删除图片
  241. deleteImage(type, e) {
  242. console.log(e, type, "===========")
  243. if (type == 0) {
  244. this.yyzzfileList.splice(e.index, 1)
  245. } else if (type == 1) {
  246. this.jbhxxfileList.splice(e.index, 1)
  247. } else if (type == 2) {
  248. this.skyhfileList.splice(e.index, 1)
  249. }
  250. },
  251. }
  252. }
  253. </script>
  254. <style scoped lang="scss">
  255. .registerShop {
  256. .frame {
  257. min-height: 100vh;
  258. overflow: auto;
  259. .basicInfo {
  260. display: flex;
  261. flex-direction: column;
  262. gap: 5rpx;
  263. background-color: #FFF;
  264. margin-top: 20rpx;
  265. padding: 20rpx;
  266. .item {
  267. display: flex;
  268. align-items: center;
  269. background-color: #FFF;
  270. height: 80rpx;
  271. // margin: 10rpx 0 0 0;
  272. padding: 10rpx 0 0 20rpx;
  273. >view:nth-of-type(1) {
  274. width: 30%;
  275. // font-weight: 700;
  276. }
  277. >view:nth-of-type(2) {
  278. width: 70%;
  279. border-radius: 10rpx;
  280. overflow: hidden;
  281. input {
  282. background-color: #f5f5f5;
  283. font-size: 28rpx;
  284. padding: 16rpx 8rpx 16rpx 15rpx;
  285. }
  286. }
  287. }
  288. }
  289. .certificateInfo {
  290. display: flex;
  291. flex-direction: column;
  292. gap: 20rpx;
  293. background-color: #FFF;
  294. margin-top: 20rpx;
  295. padding: 20rpx;
  296. .certificateInfoItem {
  297. .title {
  298. display: flex;
  299. // padding-top: 40rpx;
  300. font-size: 30rpx;
  301. font-weight: 700;
  302. padding: 0 0 0 20rpx;
  303. >span:nth-of-type(1) {
  304. margin: 4rpx 0 0 8rpx;
  305. background-color: #FFF;
  306. }
  307. >span:nth-of-type(2) {
  308. margin: 0 0 0 8rpx;
  309. background-color: #FFF;
  310. }
  311. }
  312. .upload {
  313. margin: 5rpx 0 0 40rpx;
  314. }
  315. }
  316. }
  317. }
  318. .bottom {
  319. position: fixed;
  320. bottom: 10rpx;
  321. left: 0;
  322. right: 0;
  323. background-color: #FFF;
  324. .btns {
  325. display: flex;
  326. justify-content: center;
  327. align-items: center;
  328. gap: 40rpx;
  329. .sqsh {
  330. display: flex;
  331. align-items: center;
  332. justify-content: center;
  333. width: 40%;
  334. height: 70rpx;
  335. border-radius: 40rpx;
  336. color: white;
  337. font-size: 28rpx;
  338. margin: 20rpx 10rpx 0 0;
  339. background: #293143;
  340. //margin-top: 20rpx;
  341. border-radius: 40rpx;
  342. }
  343. .lxwm {
  344. display: flex;
  345. align-items: center;
  346. justify-content: center;
  347. width: 40%;
  348. height: 70rpx;
  349. border-radius: 40rpx;
  350. color: #000000;
  351. font-size: 28rpx;
  352. margin: 20rpx 10rpx 0 0;
  353. background: #f2f2f2;
  354. //margin-top: 20rpx;
  355. border-radius: 40rpx;
  356. }
  357. }
  358. .others {
  359. display: flex;
  360. justify-content: center;
  361. align-items: center;
  362. gap: 200rpx;
  363. color: #707070;
  364. font-size: 24rpx;
  365. .zcxz {
  366. text-decoration: underline;
  367. }
  368. .kjhtyl {
  369. text-decoration: underline;
  370. }
  371. }
  372. }
  373. }
  374. </style>