du
2025-03-25 97b418553da5db33bfface90fbe78246c96a3a13
easegen-front/src/views/Profile/components/BasicInfo.vue
@@ -1,38 +1,38 @@
<template>
  <Form ref="formRef" :labelWidth="200" :rules="rules" :schema="schema">
    <template #mobile="form">
      <el-input
        v-model="form['mobile']"
        type="text"
        placeholder="请绑定手机号"
        readonly
      >
        <template #suffix>
          <span class="input-action" @click="bindMobile" style="margin-right: 10px; color: #409EFF; cursor: pointer;">认证</span>
        </template>
      </el-input>
    </template>
    <template #sex="form">
      <el-radio-group v-model="form['sex']">
        <el-radio :value="1">{{ t('profile.user.man') }}</el-radio>
        <el-radio :value="2">{{ t('profile.user.woman') }}</el-radio>
      </el-radio-group>
    </template>
    <template #apikey="form">
      <el-input
        v-model="form['apikey']"
        type="password"
        placeholder="API Key"
        show-password
        :readonly="true"
        style="width: 300px;"
      >
        <template #suffix>
          <span class="input-action" @click="refreshApiKey" style="margin-right: 10px; color: #409EFF; cursor: pointer;">刷新</span>
          <span class="input-action" @click="copyApiKey" style="color: #409EFF; cursor: pointer;">复制</span>
        </template>
      </el-input>
    </template>
<!--    <template #mobile="form">-->
<!--      <el-input-->
<!--        v-model="form['mobile']"-->
<!--        type="text"-->
<!--        placeholder="请绑定手机号"-->
<!--        readonly-->
<!--      >-->
<!--        <template #suffix>-->
<!--          <span class="input-action" @click="bindMobile" style="margin-right: 10px; color: #409EFF; cursor: pointer;">认证</span>-->
<!--        </template>-->
<!--      </el-input>-->
<!--    </template>-->
<!--    <template #sex="form">-->
<!--      <el-radio-group v-model="form['sex']">-->
<!--        <el-radio :value="1">{{ t('profile.user.man') }}</el-radio>-->
<!--        <el-radio :value="2">{{ t('profile.user.woman') }}</el-radio>-->
<!--      </el-radio-group>-->
<!--    </template>-->
<!--    <template #apikey="form">-->
<!--      <el-input-->
<!--        v-model="form['apikey']"-->
<!--        type="password"-->
<!--        placeholder="API Key"-->
<!--        show-password-->
<!--        :readonly="true"-->
<!--        style="width: 300px;"-->
<!--      >-->
<!--        <template #suffix>-->
<!--          <span class="input-action" @click="refreshApiKey" style="margin-right: 10px; color: #409EFF; cursor: pointer;">刷新</span>-->
<!--          <span class="input-action" @click="copyApiKey" style="color: #409EFF; cursor: pointer;">复制</span>-->
<!--        </template>-->
<!--      </el-input>-->
<!--    </template>-->
  </Form>
  <Dialog :before-close="handleClose" v-model="dialogVisible" title="手机号认证">
    <el-form
@@ -170,27 +170,27 @@
    label: t('profile.user.nickname'),
    component: 'Input'
  },
  {
    field: 'mobile',
    label: t('profile.user.mobile'),
    component: 'Input'
  },
  {
    field: 'email',
    label: t('profile.user.email'),
    component: 'Input'
  },
  {
    field: 'sex',
    label: t('profile.user.sex'),
    component: 'InputNumber',
    value: 0
  },
  {
    field: 'apikey',
    label: 'API Key',
    component: 'Input'
  }
  // {
  //   field: 'mobile',
  //   label: t('profile.user.mobile'),
  //   component: 'Input'
  // },
  // {
  //   field: 'email',
  //   label: t('profile.user.email'),
  //   component: 'Input'
  // },
  // {
  //   field: 'sex',
  //   label: t('profile.user.sex'),
  //   component: 'InputNumber',
  //   value: 0
  // },
  // {
  //   field: 'apikey',
  //   label: 'API Key',
  //   component: 'Input'
  // }
])
const formRef = ref<FormExpose>() // 表单 Ref
const submit = () => {