index.vue 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220
  1. <template>
  2. <!-- 审核客户资料-->
  3. <a-modal class="custom_info_btn_check"
  4. title="审核客户资料"
  5. v-model:visible="visible"
  6. @cancel="cancel"
  7. width="890px">
  8. <template #footer>
  9. <a-button key="submit"
  10. type="primary"
  11. @click="cancel">取消
  12. </a-button>
  13. <a-button key="submit"
  14. type="primary"
  15. :loading="loading"
  16. @click="submit">审核通过
  17. </a-button>
  18. <a-button key="submit"
  19. type="primary"
  20. :loading="loading"
  21. @click="refuseSubmit">审核拒绝
  22. </a-button>
  23. </template>
  24. <a-form class="inlineForm"
  25. :form="form"
  26. @submit="handleSearch">
  27. <a-row :gutter="24">
  28. <a-col :span="12">
  29. <a-form-item label="客户类型">
  30. <span class="white">{{ selectedRow.userinfotype === '2' ? '企业' : '个人' }}</span>
  31. </a-form-item>
  32. </a-col>
  33. <a-col :span="12">
  34. <a-form-item label="企业名称">
  35. <span class="white">{{ formatValue(selectedRow.customername) }}</span>
  36. </a-form-item>
  37. </a-col>
  38. </a-row>
  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. </a-form>
  116. </a-modal>
  117. </template>
  118. <script lang="ts">
  119. import { defineComponent, PropType, ref } from 'vue';
  120. import { closeModal } from '@/common/setup/modal/index';
  121. import { ModifyUserInfoReq, QueryCustomInfoType } from '@/services/go/ermcp/customInfo/interface';
  122. import { formatValue } from '@/common/methods';
  123. import { getStatusName } from '@/views/information/custom/setup';
  124. import { cancelCustomInfo, checkCustomInfo } from '@/views/information/custom/compoments/setup';
  125. import { UserInfoCheckMangeReq } from '@/services/proto/accountinfo/interface';
  126. import { getSelectedAccountId, getUserId } from '@/services/bus/account';
  127. import { message, Modal } from 'ant-design-vue';
  128. import { getCardTypeEnumItemName } from '@/common/constants/enumsName';
  129. export default defineComponent({
  130. name: 'custom_info_btn_check',
  131. components: {},
  132. props: {
  133. selectedRow: {
  134. type: Object as PropType<QueryCustomInfoType>,
  135. default: {},
  136. },
  137. },
  138. setup(props, context) {
  139. const { loading, checkCustomerInfo } = checkCustomInfo();
  140. const { visible, cancel } = closeModal('custom_info_btn_check');
  141. const req: UserInfoCheckMangeReq = {
  142. audituserid: getUserId(),
  143. userid: props.selectedRow.userid,
  144. auditflag: 1,
  145. remark: '',
  146. };
  147. // 审核通过
  148. function submit() {
  149. Modal.confirm({
  150. title: '是否确认审核通过',
  151. okText: '确认通过',
  152. cancelText: '取消',
  153. onOk() {
  154. console.log('OK');
  155. req.auditflag = 1;
  156. req.userid = props.selectedRow.userid;
  157. checkCustomerInfo(req)
  158. .then((res) => {
  159. message.success(res);
  160. context.emit('refresh');
  161. cancel();
  162. })
  163. .catch((err) => {
  164. message.error(err);
  165. });
  166. },
  167. onCancel() {
  168. console.log('Cancel');
  169. },
  170. });
  171. }
  172. // 审核拒绝
  173. function refuseSubmit() {
  174. Modal.confirm({
  175. title: '是否确认审核拒绝',
  176. okText: '审核拒绝',
  177. cancelText: '取消',
  178. onOk() {
  179. console.log('OK');
  180. req.auditflag = 2;
  181. req.userid = props.selectedRow.userid;
  182. checkCustomerInfo(req)
  183. .then((res) => {
  184. message.success(res);
  185. context.emit('refresh');
  186. cancel();
  187. })
  188. .catch((err) => {
  189. message.error(err);
  190. });
  191. },
  192. onCancel() {
  193. console.log('Cancel');
  194. },
  195. });
  196. }
  197. return {
  198. visible,
  199. cancel,
  200. submit,
  201. loading,
  202. refuseSubmit,
  203. formatValue,
  204. getStatusName,
  205. getCardTypeEnumItemName,
  206. };
  207. },
  208. });
  209. </script>
  210. <style lang="less">
  211. .custom_info_btn_check {
  212. }
  213. </style
  214. >;