Просмотр исходного кода

fix(bugs): 修改tapd上面bug

tangning 3 лет назад
Родитель
Сommit
0f186b2757

+ 4 - 1
src/components/Cropper/src/CropperAvatar.vue

@@ -10,6 +10,7 @@
         />
       </div>
       <img :src="sourceValue" v-if="sourceValue" alt="avatar" />
+      <img :src="headerImg" v-else alt="avatar" />
     </div>
     <a-button
       :class="`${prefixCls}-upload-btn`"
@@ -47,6 +48,7 @@
   import { useI18n } from '/@/hooks/web/useI18n';
   import type { ButtonProps } from '/@/components/Button';
   import Icon from '/@/components/Icon';
+  import headerImg from '/@/assets/images/header.jpg';
 
   const props = {
     width: { type: [String, Number], default: '200px' },
@@ -64,7 +66,7 @@
     props,
     emits: ['update:value', 'change'],
     setup(props, { emit, expose }) {
-      const sourceValue = ref(props.value || '');
+      const sourceValue = ref(props.value || false);
       const { prefixCls } = useDesign('cropper-avatar');
       const [register, { openModal, closeModal }] = useModal();
       const { createMessage } = useMessage();
@@ -113,6 +115,7 @@
         getStyle,
         circled: props.circled,
         handleUploadSuccess,
+        headerImg,
       };
     },
   });

+ 3 - 2
src/locales/lang/ja/apiCode.ts

@@ -6,7 +6,7 @@ export default {
   errCode3005: '確認コードの有効期限が切れています',
   errCode3006: '検証コードエラー',
   errCode3007: 'ニックネームはすでに存在します',
-  errCode3008: 'このメールは登録済みです',
+  errCode3008: 'メールが登録されました',
   errCode3009: '入力した2つのパスワードが一致しません',
   errCode3010: 'ニックネームの長さが間違っている',
   errCode3011:
@@ -37,6 +37,7 @@ export default {
   errCode3032: '現在のカメラがバインドされています。バインドする別のカメラを選択してください',
   errCode3033: '確認コードを60秒以内に繰り返し取得することはできません',
   errCode3034: 'サーバーがビジーです。もう一度やり直してください',
+  errCode3035: 'ログインアカウントが承認されていません。しばらくしてからもう一度お試しください',
   errCode9001: 'ディーラーはすでに存在します',
   errCode9002: '最初にリセラーの下のユーザーを削除してください',
   errCode4001: '確認コードがタイムアウトしました',
@@ -61,7 +62,7 @@ export default {
   errCode4019: 'シーン番号が空です',
   errCode4020: 'カメラはユーザーにバインドされていません',
   errCode4021: '請求に失敗しました。注文はすでに請求されています',
-  errCode6001: '繰り返しsnコード',
+  errCode6001: 'SNコードはすでに存在します。再入力してください',
   errCode6002: '返金額がリチャージ総額を超えている',
   errCode6003:
     'カメラがバインドされていません。に移動してください。私のカメラは最初にカメラをバインドして、再試行してください',

+ 1 - 1
src/locales/lang/ja/component.ts

@@ -5,7 +5,7 @@ export default {
     toNavigate: 'トグル',
   },
   countdown: {
-    normalText: '確認コードを取得する',
+    normalText: '電子メール確認コード',
     sendText: '{0}秒後に再フェッチ',
   },
   cropper: {

+ 2 - 1
src/locales/lang/ja/routes/corporation.ts

@@ -23,7 +23,7 @@ export default {
   subNum: 'サブアカウントの数',
   sceneNum: 'アップロードシーン数',
   point: 'バランス',
-  expirationTime: '有効期限',
+  expirationTime: '作成時間',
   detailed: '詳細',
   modifySubId: '改訂',
   addSubId: '追加',
@@ -43,4 +43,5 @@ export default {
   managerName: '会社の代表',
   optSuccess: '追加に成功しました。デフォルトのパスワードはGeosign123',
   approveState: '承認状況',
+  addError: 'アカウントはバインドされています。再入力してください',
 };

+ 1 - 1
src/locales/lang/ja/sys.ts

@@ -89,7 +89,7 @@ export default {
     loginSuccessDesc: 'お帰りなさい',
 
     // placeholder
-    accountPlaceholder: 'ユーザー名を入力してください',
+    accountPlaceholder: '会社名を入力してください',
     passwordPlaceholder: 'パスワードを入力して下さい',
     smsPlaceholder: '確認コードを入力してください',
     mobilePlaceholder: '電話番号を入力してください',

+ 2 - 1
src/locales/lang/zh-CN/apiCode.ts

@@ -33,6 +33,7 @@ export default {
   errCode3032: '当前相机已被授权,请选择另外相机绑定',
   errCode3033: '60秒内不能重复获取验证码',
   errCode3034: '服务器繁忙,请重试!',
+  errCode3035: '当前企业账号未审核通过,请稍后重试',
 
   errCode9001: '经销商已存在',
   errCode9002: '请先删除经销商下的用户',
@@ -59,7 +60,7 @@ export default {
   errCode4020: '相机未绑定用户',
   errCode4021: '开票失败,该订单已经开具发票',
 
-  errCode6001: 'SN码已被绑定,请重新输入。',
+  errCode6001: 'SN码已存在,请重新输入',
   errCode6002: '退充值超过了充值总额',
   errCode6003: '该相机未被绑定,请前往,我的相机 先绑定相机后再进行授权',
   errCode6004: '表示相机的点数超过了10万',

+ 4 - 2
src/locales/lang/zh-CN/routes/corporation.ts

@@ -2,7 +2,7 @@ export default {
   recharge: '充值',
   device: '设备',
   deviceId: '设备ID',
-  sub_account: '员工账',
+  sub_account: '员工账',
   stateName: {
     0: '审核中',
     1: '已通过',
@@ -23,7 +23,8 @@ export default {
   subNum: '已添加员工数',
   sceneNum: '上传场景数',
   point: '余额',
-  expirationTime: '到期时间',
+  expirationTime: '创建时间',
+  auditTime: '到期时间',
   detailed: '详细信息',
   modifySubId: '修改员工',
   addSubId: '新增员工',
@@ -43,4 +44,5 @@ export default {
   managerName: '联系人',
   optSuccess: '添加成功,默认密码为Geosign123',
   approveState: '审核状态',
+  addError: '账号已被绑定,请重新输入',
 };

+ 1 - 1
src/locales/lang/zh-CN/sys.ts

@@ -81,7 +81,7 @@ export default {
     loginSuccessDesc: '欢迎回来',
 
     // placeholder
-    accountPlaceholder: '请输入企业邮箱',
+    accountPlaceholder: '请输入企业名称',
     passwordPlaceholder: '请输入密码',
     smsPlaceholder: '请输入验证码',
     mobilePlaceholder: '请输入手机号码',

+ 2 - 2
src/views/corporation/AddModal.vue

@@ -118,7 +118,7 @@
         });
 
         if (addTips) {
-          return createMessage.error('子账号已被该企业绑定');
+          return createMessage.error(t('routes.corporation.addError'));
         }
         //TODO hack parameter
         let res = await checkUserAddAble({ phoneNum: values.managerPhone });
@@ -132,7 +132,7 @@
           resetFields();
           closeModal();
         } else {
-          createMessage.error('子账号已被该企业绑定');
+          createMessage.error(t('routes.corporation.addError'));
         }
       };
       function handleVisibleChange(v) {

+ 0 - 2
src/views/corporation/SubaccountModal.vue

@@ -98,8 +98,6 @@
         },
         {
           title: t('sys.login.email'),
-          edit: true,
-          editRule: true,
           width: 200,
           dataIndex: 'userName',
         },

+ 1 - 0
src/views/corporation/cameraModal.vue

@@ -164,6 +164,7 @@
 
         searchInfo.id = data.id;
         nextTick(reload);
+        emit('ok');
       }
 
       async function submitModal() {

+ 15 - 9
src/views/corporation/deviceModal.vue

@@ -22,7 +22,7 @@
             style="width: 260px; text-align: center"
             class="justify-center suNum"
             :min="0"
-            :max="20"
+            :max="maxLength"
             @blur="deviceMapping"
             @press-enter="deviceMapping"
           >
@@ -38,7 +38,7 @@
             </template>
             <template #addonAfter>
               <a-button
-                :disabled="modelRef.mappingLength == 20"
+                :disabled="modelRef.mappingLength == maxLength"
                 size="small"
                 type="link"
                 @click="handlePlusDevice"
@@ -80,8 +80,8 @@
     props: {
       userData: { type: Object },
     },
-    emits: ['register'],
-    setup(props) {
+    emits: ['register', 'update'],
+    setup(props, emit) {
       const modelRef = ref({
         mappingLength: 0,
       });
@@ -90,7 +90,7 @@
       const { t } = useI18n();
       const { createMessage } = useMessage();
       const { success, error } = createMessage;
-
+      const maxLength = ref(20);
       const [register, { closeModal }] = useModalInner((data) => {
         data && onDataReceive(data);
       });
@@ -209,13 +209,18 @@
           });
           success(t('common.optSuccess'));
           closeModal();
+          emit('update');
         } catch (error) {}
       }
 
       function onDataReceive(data) {
         // 方式1;
         console.log('userName', data.record);
-
+        let { subNum } = data.record;
+        if (subNum > 979) {
+          //剩余不足二十个
+          maxLength.value = 999 - subNum;
+        }
         resetFields();
         setFieldsValue({
           ...data.record,
@@ -268,7 +273,7 @@
 
       async function deviceMapping() {
         const values = getFieldsValue();
-        const devices: number = clamp(values.deviceNumber, 0, 20);
+        const devices: number = clamp(values.deviceNumber, 0, maxLength.value);
         const currentLength = unref(modelRef).mappingLength;
 
         const rest = devices - currentLength;
@@ -299,7 +304,7 @@
       async function handlePlusDevice() {
         const values = getFieldsValue();
         const currentsubNum = values.deviceNumber;
-        const currentDevice = clamp(currentsubNum + 1, 0, 20);
+        const currentDevice = clamp(currentsubNum + 1, 0, maxLength.value);
         await setFieldsValue({
           deviceNumber: currentDevice,
         });
@@ -308,7 +313,7 @@
       async function handleMinusDevice() {
         const values = getFieldsValue();
         const currentsubNum = values.deviceNumber;
-        const currentDevice = clamp(currentsubNum - 1, 0, 20);
+        const currentDevice = clamp(currentsubNum - 1, 0, maxLength.value);
         await setFieldsValue({
           deviceNumber: currentDevice,
         });
@@ -330,6 +335,7 @@
         t,
         handlePlusDevice,
         handleMinusDevice,
+        maxLength,
       };
     },
   });

+ 3 - 4
src/views/corporation/index.vue

@@ -44,7 +44,7 @@
         />
       </template>
       <template #expirationTime="{ record }">
-        <Time v-if="record.expirationTime" :value="record.expirationTime" mode="datetime" />
+        <Time v-if="record.auditTime" :value="record.auditTime" mode="datetime" />
       </template>
 
       <template #cameraNum="{ record }">
@@ -84,7 +84,7 @@
       </template>
     </BasicTable>
     <chargeModal @register="registerChargeModal" @update="reload" />
-    <deviceModal @register="registerDeviceModal" />
+    <deviceModal @register="registerDeviceModal" @update="reload" />
     <SubaccountModal @register="registerSubaccountModal" @update="reload" />
     <cameraModal @register="registerCameraModal" @ok="reload" />
   </div>
@@ -115,7 +115,6 @@
   import type { Result } from '/#/axios';
   import { useLocaleStore } from '/@/store/modules/locale';
   const localeStore = useLocaleStore();
-
   export default defineComponent({
     components: {
       BasicTable,
@@ -198,7 +197,7 @@
         // },
         {
           title: t('routes.corporation.expirationTime'),
-          dataIndex: 'expirationTime',
+          dataIndex: 'auditTime',
           slots: { customRender: 'expirationTime' },
           width: 180,
         },

+ 19 - 1
src/views/devices/list.vue

@@ -25,6 +25,15 @@
               label: t('common.edit'),
               onClick: handleEditScenes.bind(null, record),
             },
+            {
+              icon: 'clarity:unlink-line',
+              label: t('common.unbind'),
+              ifShow: !!record.userName,
+              popConfirm: {
+                title: t('routes.corporation.isUnBind'),
+                confirm: handleUnbindDevice.bind(null, record),
+              },
+            },
           ]"
         />
       </template>
@@ -40,6 +49,7 @@
   import { Tag } from 'ant-design-vue';
   import { useModal } from '/@/components/Modal';
   import { ListApi } from '/@/api/device/list';
+  import { unDeviceApi } from '/@/api/corporation/list';
   import AddModal from './AddModal.vue';
   import EditModal from './EditModal.vue';
   import { useI18n } from '/@/hooks/web/useI18n';
@@ -108,7 +118,7 @@
           dataIndex: 'action',
           slots: { customRender: 'action' },
           auth: [RoleEnum.SUPER, RoleEnum.PLAT_ADMIN],
-          width: 120,
+          width: 140,
         },
       ];
 
@@ -187,6 +197,13 @@
         console.log('record', record);
         openEditModal(true, record);
       }
+      async function handleUnbindDevice(record: Recordable) {
+        await unDeviceApi({
+          childName: record.childName,
+        });
+        createMessage.success(t('common.optSuccess'));
+        reload();
+      }
       return {
         registerTable,
         createMessage,
@@ -197,6 +214,7 @@
         t,
         reload,
         handleEditScenes,
+        handleUnbindDevice,
         registerEditModal,
         RoleEnum,
       };

+ 100 - 98
src/views/product/addCategoryModal.vue

@@ -21,103 +21,6 @@ wapBannerUrl: "https://4dkk.4dage.com/shop/huafa/20220302/23135195983e96.png?x-o
   import { BasicForm, FormSchema, useForm } from '/@/components/Form/index';
 
   const isLevel2 = (type: string) => type === 'L2';
-  const schemas: FormSchema[] = [
-    {
-      field: 'name',
-      component: 'Input',
-      label: '分类名称',
-      colProps: {
-        span: 24,
-      },
-      required: true,
-    },
-    {
-      field: 'level',
-      component: 'RadioGroup',
-      label: '级别',
-      defaultValue: 'L1',
-      colProps: {
-        span: 24,
-      },
-      componentProps: {
-        options: [
-          {
-            label: '一级分类',
-            value: 'L1',
-          },
-          {
-            label: '二级分类',
-            value: 'L2',
-          },
-        ],
-      },
-    },
-
-    {
-      field: 'parentId',
-      component: 'ApiSelect',
-      label: '上级分类',
-      ifShow: ({ values }) => isLevel2(values.level),
-      colProps: {
-        span: 18,
-      },
-      componentProps: {
-        api: async function (params) {
-          console.log('params', params);
-          const res = (await categoryApi(params)) as any as TreeNode[];
-          // const treeData = makeTree(res);
-          return res.filter((i) => i.level === 'L1');
-        },
-        labelField: 'name',
-        valueField: 'id',
-      },
-    },
-    {
-      field: 'isShow',
-      component: 'RadioGroup',
-      label: '是否显示',
-      defaultValue: '1',
-      colProps: {
-        span: 24,
-      },
-      componentProps: {
-        options: [
-          {
-            label: '显示',
-            value: '1',
-          },
-          {
-            label: '不显示',
-            value: '0',
-          },
-        ],
-      },
-    },
-    {
-      field: 'type',
-      component: 'InputNumber',
-      label: '排序',
-      defaultValue: 1,
-      colProps: {
-        span: 24,
-      },
-    },
-    {
-      field: 'wapBannerUrl',
-      component: 'Upload',
-      label: '手机banner',
-      rules: [{ required: true, message: '请选择上传文件' }],
-      componentProps: {
-        api: uploadBannerApi,
-        maxNumber: 1,
-        afterFetch: function (data) {
-          Reflect.set(data, 'url', data.message.url);
-          return data;
-        },
-      },
-      required: true,
-    },
-  ];
   export default defineComponent({
     components: { BasicModal, BasicForm },
     props: {
@@ -125,7 +28,7 @@ wapBannerUrl: "https://4dkk.4dage.com/shop/huafa/20220302/23135195983e96.png?x-o
     },
     emits: ['update', 'register'],
     setup(_, { emit }) {
-      const [registerForm, { validate, getFieldsValue, resetFields }] = useForm({
+      const [registerForm, { validate, getFieldsValue, resetFields, validateFields }] = useForm({
         labelWidth: 120,
         schemas,
         showActionButtonGroup: false,
@@ -133,7 +36,106 @@ wapBannerUrl: "https://4dkk.4dage.com/shop/huafa/20220302/23135195983e96.png?x-o
           span: 24,
         },
       });
+      const schemas: FormSchema[] = [
+        {
+          field: 'name',
+          component: 'Input',
+          label: '分类名称',
+          colProps: {
+            span: 24,
+          },
+          required: true,
+        },
+        {
+          field: 'level',
+          component: 'RadioGroup',
+          label: '级别',
+          defaultValue: 'L1',
+          colProps: {
+            span: 24,
+          },
+          componentProps: {
+            options: [
+              {
+                label: '一级分类',
+                value: 'L1',
+              },
+              {
+                label: '二级分类',
+                value: 'L2',
+              },
+            ],
+          },
+        },
 
+        {
+          field: 'parentId',
+          component: 'ApiSelect',
+          label: '上级分类',
+          ifShow: ({ values }) => isLevel2(values.level),
+          colProps: {
+            span: 18,
+          },
+          componentProps: {
+            api: async function (params) {
+              console.log('params', params);
+              const res = (await categoryApi(params)) as any as TreeNode[];
+              // const treeData = makeTree(res);
+              return res.filter((i) => i.level === 'L1');
+            },
+            labelField: 'name',
+            valueField: 'id',
+          },
+        },
+        {
+          field: 'isShow',
+          component: 'RadioGroup',
+          label: '是否显示',
+          defaultValue: '1',
+          colProps: {
+            span: 24,
+          },
+          componentProps: {
+            options: [
+              {
+                label: '显示',
+                value: '1',
+              },
+              {
+                label: '不显示',
+                value: '0',
+              },
+            ],
+          },
+        },
+        {
+          field: 'type',
+          component: 'InputNumber',
+          label: '排序',
+          defaultValue: 1,
+          colProps: {
+            span: 24,
+          },
+        },
+        {
+          field: 'wapBannerUrl',
+          component: 'Upload',
+          label: '手机banner',
+          rules: [{ required: true, message: '请选择上传文件' }],
+          componentProps: {
+            onChange: async () => {
+              await validateFields(['wapBannerUrl']);
+            },
+            api: uploadBannerApi,
+            maxNumber: 1,
+            afterFetch: function (data) {
+              Reflect.set(data, 'url', data.message.url);
+              return data;
+            },
+          },
+          required: true,
+        },
+      ];
       const [register, { closeModal }] = useModalInner((data) => {
         data && onDataReceive(data);
       });

+ 109 - 103
src/views/product/editCategoryModal.vue

@@ -24,109 +24,7 @@ wapBannerUrl: "https://4dkk.4dage.com/shop/huafa/20220302/23135195983e96.png?x-o
   import { useI18n } from '/@/hooks/web/useI18n';
   const { t } = useI18n();
   const isLevel2 = (type: string) => type === 'L2';
-  const schemas: FormSchema[] = [
-    {
-      field: 'id',
-      label: 'Id',
-      component: 'Input',
-      ifShow: false,
-    },
-    {
-      field: 'name',
-      component: 'Input',
-      label: '分类名称',
-      colProps: {
-        span: 24,
-      },
-      required: true,
-    },
-    {
-      field: 'level',
-      component: 'RadioGroup',
-      label: '级别',
-      defaultValue: 'L1',
-      colProps: {
-        span: 24,
-      },
-      componentProps: {
-        options: [
-          {
-            label: '一级分类',
-            value: 'L1',
-          },
-          {
-            label: '二级分类',
-            value: 'L2',
-          },
-        ],
-      },
-    },
 
-    {
-      field: 'parentId',
-      component: 'ApiSelect',
-      label: '上级分类',
-      ifShow: ({ values }) => isLevel2(values.level),
-      colProps: {
-        span: 18,
-      },
-      componentProps: {
-        api: async function (params) {
-          console.log('params', params);
-          const res = (await categoryApi(params)) as any as TreeNode[];
-          // const treeData = makeTree(res);
-          return res.filter((i) => i.level === 'L1');
-        },
-        labelField: 'name',
-        valueField: 'id',
-      },
-    },
-    {
-      field: 'isShow',
-      component: 'RadioGroup',
-      label: '是否显示',
-      defaultValue: '1',
-      colProps: {
-        span: 24,
-      },
-      componentProps: {
-        options: [
-          {
-            label: '显示',
-            value: '1',
-          },
-          {
-            label: '不显示',
-            value: '0',
-          },
-        ],
-      },
-    },
-    {
-      field: 'type',
-      component: 'InputNumber',
-      label: '排序',
-      defaultValue: 1,
-      colProps: {
-        span: 24,
-      },
-    },
-    {
-      field: 'wapBannerUrl',
-      component: 'Upload',
-      label: '手机banner',
-      rules: [{ required: true, message: '请选择上传文件' }],
-      componentProps: {
-        api: uploadBannerApi,
-        maxNumber: 1,
-        afterFetch: function (data) {
-          Reflect.set(data, 'url', data.message.url);
-          return data;
-        },
-      },
-      required: true,
-    },
-  ];
   export default defineComponent({
     components: { BasicModal, BasicForm },
     props: {
@@ -135,8 +33,116 @@ wapBannerUrl: "https://4dkk.4dage.com/shop/huafa/20220302/23135195983e96.png?x-o
     emits: ['update', 'register'],
     setup(_, { emit }) {
       const { createMessage } = useMessage();
+      const schemas: FormSchema[] = [
+        {
+          field: 'id',
+          label: 'Id',
+          component: 'Input',
+          ifShow: false,
+        },
+        {
+          field: 'name',
+          component: 'Input',
+          label: '分类名称',
+          colProps: {
+            span: 24,
+          },
+          required: true,
+        },
+        {
+          field: 'level',
+          component: 'RadioGroup',
+          label: '级别',
+          defaultValue: 'L1',
+          colProps: {
+            span: 24,
+          },
+          componentProps: {
+            options: [
+              {
+                label: '一级分类',
+                value: 'L1',
+              },
+              {
+                label: '二级分类',
+                value: 'L2',
+              },
+            ],
+          },
+        },
 
-      const [registerForm, { validate, getFieldsValue, resetFields, setFieldsValue }] = useForm({
+        {
+          field: 'parentId',
+          component: 'ApiSelect',
+          label: '上级分类',
+          ifShow: ({ values }) => isLevel2(values.level),
+          colProps: {
+            span: 18,
+          },
+          componentProps: {
+            api: async function (params) {
+              console.log('params', params);
+              const res = (await categoryApi(params)) as any as TreeNode[];
+              // const treeData = makeTree(res);
+              return res.filter((i) => i.level === 'L1');
+            },
+            labelField: 'name',
+            valueField: 'id',
+          },
+        },
+        {
+          field: 'isShow',
+          component: 'RadioGroup',
+          label: '是否显示',
+          defaultValue: '1',
+          colProps: {
+            span: 24,
+          },
+          componentProps: {
+            options: [
+              {
+                label: '显示',
+                value: '1',
+              },
+              {
+                label: '不显示',
+                value: '0',
+              },
+            ],
+          },
+        },
+        {
+          field: 'type',
+          component: 'InputNumber',
+          label: '排序',
+          defaultValue: 1,
+          colProps: {
+            span: 24,
+          },
+        },
+        {
+          field: 'wapBannerUrl',
+          component: 'Upload',
+          label: '手机banner',
+          rules: [{ required: true, message: '请选择上传文件' }],
+          componentProps: {
+            api: uploadBannerApi,
+            onChange: async () => {
+              await validateFields(['wapBannerUrl']);
+            },
+            maxNumber: 1,
+            afterFetch: function (data) {
+              Reflect.set(data, 'url', data.message.url);
+              return data;
+            },
+          },
+          required: true,
+        },
+      ];
+      const [
+        registerForm,
+        { validate, getFieldsValue, resetFields, setFieldsValue, validateFields },
+      ] = useForm({
         labelWidth: 120,
         schemas,
         showActionButtonGroup: false,

+ 4 - 1
src/views/scenes/liveDrawer.vue

@@ -97,6 +97,9 @@
               Reflect.set(data, 'url', data.message.url);
               return data;
             },
+            onChange: async () => {
+              await validateFields(['wapBannerUrl']);
+            },
           },
         },
         {
@@ -145,7 +148,7 @@
         },
       ];
       // updateSchema, validate
-      const [registerForm, { resetFields, setFieldsValue }] = useForm({
+      const [registerForm, { resetFields, setFieldsValue, validateFields }] = useForm({
         labelWidth: 120,
         schemas: schemas,
         showActionButtonGroup: false,

+ 3 - 1
src/views/sys/login/RegisterForm.vue

@@ -18,7 +18,7 @@
           class="fix-auto-fill"
         />
       </FormItem>
-      <FormItem name="sms" autocomplete="off" class="enter-x">
+      <FormItem name="authCode" autocomplete="off" class="enter-x">
         <CountdownInput
           size="large"
           autoComplete="new-password"
@@ -139,6 +139,8 @@
 
   async function handleRegister() {
     const data = await validForm();
+    // const form = unref(formRef);
+    // await form.validate();
     if (!data) return;
     console.log(data);
     try {