index.vue 9.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241
  1. <template>
  2. <!-- 撤销客户资料-->
  3. <a-modal class="commonModal custom_info_btn_cancel"
  4. title="撤销客户资料"
  5. v-model:visible="visible"
  6. @cancel="cancel"
  7. centered
  8. width="890px">
  9. <template #footer>
  10. <a-button key="submit"
  11. class="cancelBtn"
  12. @click="cancel">取消</a-button>
  13. <a-button key="submit"
  14. type="primary"
  15. :loading="loading"
  16. @click="submit">确认撤销</a-button>
  17. </template>
  18. <a-form class="inlineForm"
  19. :form="form"
  20. @submit="handleSearch">
  21. <a-row :gutter="24">
  22. <a-col :span="12">
  23. <a-form-item label="客户类型">
  24. <span class="white">{{ selectedRow.userinfotype === '2' ? '企业' : '个人' }}</span>
  25. </a-form-item>
  26. </a-col>
  27. <a-col :span="12">
  28. <a-form-item label="企业名称"
  29. v-if="selectedRow.userinfotype === '2'">
  30. <span class="white">{{ formatValue(selectedRow.customername)}}</span>
  31. </a-form-item>
  32. <a-form-item label="姓名"
  33. v-if="selectedRow.userinfotype !== '2'">
  34. <span class="white">{{ formatValue(selectedRow.customername)}}</span>
  35. </a-form-item>
  36. </a-col>
  37. </a-row>
  38. <template v-if="selectedRow.userinfotype === '2'">
  39. <a-row :gutter="24">
  40. <a-col :span="12">
  41. <a-form-item label="企业简称">
  42. <span class="white">{{ formatValue(selectedRow.nickname) }}</span>
  43. </a-form-item>
  44. </a-col>
  45. <a-col :span="12">
  46. <a-form-item label="证件类型">
  47. <span class="white">{{ getCardTypeEnumItemName(selectedRow.cardtype) }}</span>
  48. </a-form-item>
  49. </a-col>
  50. </a-row>
  51. <a-row :gutter="24">
  52. <a-col :span="12">
  53. <a-form-item label="法定代表人">
  54. <span class="white">{{ formatValue(selectedRow.legalpersonname) }}</span>
  55. </a-form-item>
  56. </a-col>
  57. <a-col :span="12">
  58. <a-form-item label="证件号码">
  59. <span class="white">{{ formatValue(selectedRow.cardnum) }}</span>
  60. </a-form-item>
  61. </a-col>
  62. </a-row>
  63. <a-row :gutter="24">
  64. <a-col :span="12">
  65. <a-form-item label="纳税人识别号">
  66. <span class="white">{{ formatValue(selectedRow.taxpayernum) }}</span>
  67. </a-form-item>
  68. </a-col>
  69. <a-col :span="12">
  70. <a-form-item label="营业执照">
  71. <div class="upload">
  72. <div class="look">查看附件</div>
  73. </div>
  74. </a-form-item>
  75. </a-col>
  76. </a-row>
  77. <a-row :gutter="24">
  78. <a-col :span="12">
  79. <a-form-item label="联系人">
  80. <span class="white">{{ formatValue(selectedRow.contactname) }}</span>
  81. </a-form-item>
  82. </a-col>
  83. <a-col :span="12">
  84. <a-form-item label="联系人手机号">
  85. <span class="white">{{ formatValue(selectedRow.mobile) }}</span>
  86. </a-form-item>
  87. </a-col>
  88. </a-row>
  89. <a-row :gutter="24">
  90. <a-col :span="12">
  91. <a-form-item label="联系电话">
  92. <span class="white">{{ formatValue(selectedRow.telphone) }}</span>
  93. </a-form-item>
  94. </a-col>
  95. <a-col :span="12">
  96. <a-form-item label="状态">
  97. <span class="green">{{ formatValue(getStatusName(selectedRow.status)) }}</span>
  98. </a-form-item>
  99. </a-col>
  100. </a-row>
  101. <a-row :gutter="24">
  102. <a-col :span="24">
  103. <a-form-item label="通讯地址">
  104. <span class="white">{{ formatValue(selectedRow.address) }}</span>
  105. </a-form-item>
  106. </a-col>
  107. </a-row>
  108. <a-row :gutter="24">
  109. <a-col :span="24">
  110. <a-form-item label="备注">
  111. <span class="white">{{ formatValue(selectedRow.remark) }}</span>
  112. </a-form-item>
  113. </a-col>
  114. </a-row>
  115. </template>
  116. <template v-else>
  117. <a-row :gutter="24">
  118. <a-col :span="12">
  119. <a-form-item label="身份证号码">
  120. <span class="white">{{ formatValue(selectedRow.cardnum) }}</span>
  121. </a-form-item>
  122. </a-col>
  123. <a-col :span="12">
  124. <a-form-item label="手机号码">
  125. <span class="white">{{ formatValue(selectedRow.mobile) }}</span>
  126. </a-form-item>
  127. </a-col>
  128. </a-row>
  129. <a-row :gutter="24">
  130. <a-col :span="12">
  131. <a-form-item label="身份证正面照">
  132. <span class="white">{{ formatValue(selectedRow.cardfrontphotourl) }}</span>
  133. </a-form-item>
  134. </a-col>
  135. <a-col :span="12">
  136. <a-form-item label="邮箱">
  137. <span class="white">{{ formatValue(selectedRow.email) }}</span>
  138. </a-form-item>
  139. </a-col>
  140. </a-row>
  141. <a-row :gutter="24">
  142. <a-col :span="12">
  143. <a-form-item label="身份证反面照">
  144. <span class="white">{{ formatValue(selectedRow.cardbackphotourl) }}</span>
  145. </a-form-item>
  146. </a-col>
  147. <a-col :span="12">
  148. <a-form-item label="联系电话">
  149. <span class="white">{{ formatValue(selectedRow.telphone) }}</span>
  150. </a-form-item>
  151. </a-col>
  152. </a-row>
  153. <a-row :gutter="24">
  154. <a-col :span="24">
  155. <a-form-item label="通讯地址">
  156. <span class="white">{{ formatValue(selectedRow.address) }}</span>
  157. </a-form-item>
  158. </a-col>
  159. </a-row>
  160. <a-row :gutter="24">
  161. <a-col :span="24">
  162. <a-form-item label="备注">
  163. <span class="white">{{ formatValue(selectedRow.remark) }}</span>
  164. </a-form-item>
  165. </a-col>
  166. </a-row>
  167. </template>
  168. </a-form>
  169. </a-modal>
  170. </template>
  171. <script lang="ts">
  172. import { defineComponent, PropType, ref } from 'vue';
  173. import { closeModal } from '@/common/setup/modal/index';
  174. import { message, Modal } from 'ant-design-vue';
  175. import { ModifyUserInfoReq, QueryCustomInfoType } from '@/services/go/ermcp/customInfo/interface';
  176. import { formatValue } from '@/common/methods';
  177. import { getStatusName } from '@/common/constants/enumsName';
  178. import { getCardTypeEnumItemName } from '@/common/constants/enumsName';
  179. import { requestResultLoadingAndInfo } from '@/common/methods/request/resultInfo';
  180. import { QueryModifyUserInfo } from '@/services/go/ermcp/customInfo';
  181. export default defineComponent({
  182. name: 'custom_info_btn_cancel',
  183. components: {},
  184. props: {
  185. selectedRow: {
  186. type: Object as PropType<QueryCustomInfoType>,
  187. default: {},
  188. },
  189. },
  190. setup(props, context) {
  191. const { visible, cancel } = closeModal('custom_info_btn_cancel');
  192. const loading = ref<boolean>(false);
  193. function submit() {
  194. loading.value = true;
  195. Modal.confirm({
  196. title: '是否确认撤销客户资料',
  197. content: '是否撤销',
  198. okText: '确认撤销',
  199. cancelText: '取消',
  200. onOk() {
  201. const reqParam: ModifyUserInfoReq = {
  202. userid: props.selectedRow.userid, //用户ID
  203. userstate: 1, //开户状态 - 1:未提交 2: 待初审 3:初审拒绝 4:待复审 5:复审拒绝 6:测评不通过 (必填)
  204. };
  205. requestResultLoadingAndInfo(QueryModifyUserInfo, reqParam, loading, ['撤销成功', '撤销失败:']).then(() => {
  206. cancel();
  207. context.emit('refresh');
  208. });
  209. },
  210. onCancel() {
  211. loading.value = false;
  212. },
  213. class: 'test',
  214. });
  215. }
  216. return {
  217. visible,
  218. cancel,
  219. submit,
  220. loading,
  221. formatValue,
  222. getStatusName,
  223. getCardTypeEnumItemName,
  224. };
  225. },
  226. });
  227. </script>
  228. <style lang="less">
  229. .custom_info_btn_cancel {
  230. .upload {
  231. .look {
  232. margin-left: 0;
  233. }
  234. }
  235. }
  236. </style
  237. >;