Browse Source

登录页 修改密码页lang

Karsa 1 year ago
parent
commit
54fb79108f

+ 12 - 0
src/lang/commonLang.js

@@ -48,6 +48,14 @@ export default {
     submit_btn: {
       en: 'Submit',
       zh: '提交'
+    },
+    next_step: {
+      en: 'Next step',
+      zh: '下一步'
+    },
+    prev_step: {
+      en: 'Previous step',
+      zh: '上一步'
     }
   },
   Table: {
@@ -250,6 +258,10 @@ export default {
     clean_classify_msg: {
       en: 'Category Cleared Successfully',
       zh: '清除分类成功'
+    },
+    confirm_logout_msg: {
+      en: 'Are you sure you want to log out?',
+      zh: '确认退出吗?'
     }
   },
   Common: {

+ 67 - 0
src/lang/modules/MainApp/En.js

@@ -0,0 +1,67 @@
+/* 主框架 登录 
+  $t('EtaChartPage.xxx')
+*/
+
+export default {
+  MainPage: {
+    help_center: 'Help Center',
+    tab_help_update: 'Update Log',
+    tab_help_docs: 'Help Documentation',
+    tab_reset_pwd: 'Change Password',
+    tab_log_out: 'Log out'
+  },
+
+  /* 修改密码页面 */
+  ResetPwdPage: {
+    label_old_pwd: 'Old Password',
+    label_new_pwd: 'New Password',
+    label_ensure_pwd: 'Confirm New Password',
+    ph_pwd:'Please enter no more than 20 characters',
+    vaild_old:'Please enter the old password',
+    vaild_rule:'Password must be at least 8 characters with numbers, upper/lowercase letters, and symbols',
+    vaild_new:'Please enter confirmation password',
+    vaild_same:'The new password entries do not match; please check them!',
+    edit_pwd_msg:'Password change successful, please log in again!'
+  },
+
+  /* 登录页 */
+  LoginPage: {
+    login_sub_tit: 'Stay half a step ahead of the market in investment research',
+    login_btn: 'Log in',
+    other_login_type: 'Other login methods',
+    login_by_account:'Account login',
+    login_by_mobile:'Mobile phone login',
+    login_by_email:'Email login',
+    ph_account:'Please enter your account',
+    ph_pwd:'Please enter your password',
+    label_remember: 'Remember account and password',
+    vaild_day_msg: 'Valid for 60 days',
+    label_forget: 'Forgot password',
+    error_wrong_msg: 'Incorrect account or password',
+    error_abnormal_msg: 'Account is abnormal, please log in through verification',
+
+    ph_mobile: 'Please enter your mobile number',
+    ph_email:'Please enter your email address',
+    ph_img_code: 'Please enter the graphic verification code',
+    ph_msg_code: 'Please enter the verification code',
+    ver_code_msg:'Get verification code',
+    recode_ing_msg:'Retrieve Again({count})seconds',
+    recode_msg:'Retrieve Again',
+    vaild_curr_mobile: 'Please enter the correct mobile phone format',
+    vaild_curr_email:'Please enter the correct email format',
+    recode_warn_msg:'To retrieve again, you need to enter the graphic verification code once more',
+    send_code_msg: 'Verification code has been sent',
+
+    ph_new_pwd:"Please enter a new password",
+    label_find_pwd: 'You are retrieving the password for account {name}',
+    label_not_bind:'Not yet bound',
+    send_vaild_btn:'Start verification',
+    step_vaild_one: 'Choose a verification method',
+    step_vaild_two: 'Perform security verification',
+    step_vaild_three: 'Setup a password',
+    reset_pwd_success_msg:'Password reset successful, please log in',
+
+    tab_vaild_phone:'Mobile Phone Verification',
+    tab_vaild_email:'Email Verification',
+  }
+}

+ 67 - 0
src/lang/modules/MainApp/Zh.js

@@ -0,0 +1,67 @@
+/* 主框架 登录 
+  $t('EtaChartPage.xxx')
+*/
+
+export default {
+  MainPage: {
+    help_center: '帮助中心',
+    tab_help_update: '更新日志',
+    tab_help_docs: '帮助文档',
+    tab_reset_pwd: '修改密码',
+    tab_log_out: '退出登录'
+  },
+
+  /* 修改密码页面 */
+  ResetPwdPage: {
+    label_old_pwd: '原密码',
+    label_new_pwd: '新密码',
+    label_ensure_pwd: '确认新密码',
+    ph_pwd:'请输入不超过20个字符',
+    vaild_old:'请输入原密码',
+    vaild_rule:'密码要求8位及以上,包含数字、大写字母、小写字母、特殊字符中的三个类型',
+    vaild_new:'请输入确认密码',
+    vaild_same:'新密码两次输入不一致,请核对!',
+    edit_pwd_msg:'修改密码成功,请重新登录!'
+  },
+
+  /* 登录页 */
+  LoginPage: {
+    login_sub_tit: '让投研领先市场半步',
+    login_btn: '登录',
+    other_login_type: '其他登录方式',
+    login_by_account:'账号登录',
+    login_by_mobile:'手机号登录',
+    login_by_email:'邮箱登录',
+    ph_account:'请输入账号',
+    ph_pwd:'请输入密码',
+    label_remember: '记住账号密码',
+    vaild_day_msg: '有效期60天',
+    label_forget: '忘记密码',
+    error_wrong_msg: '账号或密码错误',
+    error_abnormal_msg: '账号异常,请通过验证登录',
+
+    ph_mobile: '请输入手机号',
+    ph_email:'请输入邮箱',
+    ph_img_code: '请输入图形验证码',
+    ph_msg_code: '请输入短信验证码',
+    ver_code_msg:'获取验证码',
+    recode_ing_msg:'重新获取({count})秒',
+    recode_msg:'重新获取',
+    vaild_curr_mobile: '请输入正确的手机号格式',
+    vaild_curr_email:'请输入正确的邮箱格式',
+    recode_warn_msg:'重新获取需再次输入图形验证码',
+    send_code_msg: '验证码已发送',
+    
+    ph_new_pwd:"请输入新密码",
+    label_find_pwd: '您正在找回账号{name}的密码',
+    label_not_bind:'暂未绑定',
+    send_vaild_btn:'开始验证',
+    step_vaild_one: '选择验证方式',
+    step_vaild_two: '进行安全验证',
+    step_vaild_three: '设置密码',
+    reset_pwd_success_msg:'重置密码成功,请登陆',
+
+    tab_vaild_phone:'手机号验证',
+    tab_vaild_email:'邮箱验证',
+  }
+}

+ 8 - 20
src/views/Home.vue

@@ -149,7 +149,7 @@
                         margin: 0 9px;
                         font-weight: 700;
                         color: #c0c4cc;
-                        fontsize: 16px;
+                        font-size: 16px;
                       "
                     >/</span>
                     <span
@@ -203,31 +203,22 @@
                   {{item.name}}
                 </el-button>
 
-                <!-- <el-tooltip effect="dark" content="帮助文档" placement="bottom">
-                  <div class="icon-box-item" v-if="isShowRole" @click="toOperation('fingerpost')">
-                    <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg" style="color:#333">
-                      <path d="M9.24255 14.5C9.24255 14.0858 9.57834 13.75 9.99255 13.75C10.4068 13.75 10.7426 14.0858 10.7426 14.5C10.7426 14.9142 10.4068 15.25 9.99255 15.25C9.57834 15.25 9.24255 14.9142 9.24255 14.5Z" fill="currentColor"/>
-                      <path d="M9.99261 5.00763C8.32056 5.00763 6.96136 6.36682 6.96136 8.03888H8.21136C8.21136 7.05718 9.01092 6.25763 9.99261 6.25763C10.9743 6.25763 11.7739 7.05718 11.7739 8.03888C11.7739 8.71106 11.2183 9.3851 10.4931 9.67971L10.4899 9.68101C9.82793 9.95419 9.36767 10.6052 9.36767 11.3656V12.5H10.6177V11.3656C10.6177 11.1228 10.7618 10.9216 10.9655 10.837C11.9996 10.4161 13.0239 9.37337 13.0239 8.03888C13.0239 6.36682 11.6647 5.00763 9.99261 5.00763Z" fill="currentColor"/>
-                      <path d="M18.7427 10C18.7427 5.16751 14.8252 1.25 9.99268 1.25C5.16019 1.25 1.24268 5.16751 1.24268 10C1.24267 14.8325 5.16018 18.75 9.99267 18.75C14.8252 18.75 18.7427 14.8325 18.7427 10ZM17.4927 10C17.4927 14.1421 14.1348 17.5 9.99267 17.5C5.85054 17.5 2.49267 14.1421 2.49268 10C2.49268 5.85786 5.85054 2.5 9.99268 2.5C14.1348 2.5 17.4927 5.85787 17.4927 10Z" fill="currentColor"/>
-                    </svg>
-                  </div>
-                </el-tooltip> -->
-                <el-dropdown trigger="click" style="width:130px;" v-if="isUpdateLogShow||isHelpDocShow">
+                <el-dropdown trigger="click" style="width:140px;" v-if="isUpdateLogShow||isHelpDocShow">
                   <span class="el-dropdown-link userinfo-inner help-center-inner">
                     <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg" style="color:#333">
                       <path d="M9.24255 14.5C9.24255 14.0858 9.57834 13.75 9.99255 13.75C10.4068 13.75 10.7426 14.0858 10.7426 14.5C10.7426 14.9142 10.4068 15.25 9.99255 15.25C9.57834 15.25 9.24255 14.9142 9.24255 14.5Z" fill="currentColor"/>
                       <path d="M9.99261 5.00763C8.32056 5.00763 6.96136 6.36682 6.96136 8.03888H8.21136C8.21136 7.05718 9.01092 6.25763 9.99261 6.25763C10.9743 6.25763 11.7739 7.05718 11.7739 8.03888C11.7739 8.71106 11.2183 9.3851 10.4931 9.67971L10.4899 9.68101C9.82793 9.95419 9.36767 10.6052 9.36767 11.3656V12.5H10.6177V11.3656C10.6177 11.1228 10.7618 10.9216 10.9655 10.837C11.9996 10.4161 13.0239 9.37337 13.0239 8.03888C13.0239 6.36682 11.6647 5.00763 9.99261 5.00763Z" fill="currentColor"/>
                       <path d="M18.7427 10C18.7427 5.16751 14.8252 1.25 9.99268 1.25C5.16019 1.25 1.24268 5.16751 1.24268 10C1.24267 14.8325 5.16018 18.75 9.99267 18.75C14.8252 18.75 18.7427 14.8325 18.7427 10ZM17.4927 10C17.4927 14.1421 14.1348 17.5 9.99267 17.5C5.85054 17.5 2.49267 14.1421 2.49268 10C2.49268 5.85786 5.85054 2.5 9.99268 2.5C14.1348 2.5 17.4927 5.85787 17.4927 10Z" fill="currentColor"/>
                     </svg>
-                    <span style="line-height: 20px;margin-left: 4px;">帮助中心</span>
+                    <span style="line-height: 20px;margin-left: 4px;"><!-- 帮助中心 -->{{ $t('MainPage.help_center') }}</span>
                     <i class="el-icon-arrow-down el-icon--right" />
                   </span>
                   <el-dropdown-menu slot="dropdown">
                     <el-dropdown-item divided @click.native="toDoc" v-if="isUpdateLogShow"
-                      >更新日志</el-dropdown-item
+                      ><!-- 更新日志 -->{{ $t('MainPage.tab_help_update') }}</el-dropdown-item
                     >
                     <el-dropdown-item divided @click.native="toOperation" v-if="isHelpDocShow"
-                      >帮助文档</el-dropdown-item
+                      ><!-- 帮助文档 -->{{ $t('MainPage.tab_help_docs') }}</el-dropdown-item
                     >
                   </el-dropdown-menu>
                 </el-dropdown>
@@ -247,10 +238,10 @@
                 </span>
                 <el-dropdown-menu slot="dropdown">
                   <el-dropdown-item divided @click.native="resetpwd"
-                    >修改密码</el-dropdown-item
+                    ><!-- 修改密码 -->{{ $t('MainPage.tab_reset_pwd') }}</el-dropdown-item
                   >
                   <el-dropdown-item divided @click.native="logout"
-                    >退出登录</el-dropdown-item
+                    ><!-- 退出登录 -->{{ $t('MainPage.tab_log_out') }}</el-dropdown-item
                   >
                   <!-- <el-dropdown-item divided @click.native="toDoc"
                     >更新日志</el-dropdown-item
@@ -307,9 +298,6 @@ import EventBus from "@/api/bus.js";
 
 import {recordActiveLoginFun,loginEndCalc} from "@/utils/TimeOnPage.js"
 import NotificationMsg from "../components/notificationMsg.vue";
-import langEN from 'element-ui/lib/locale/lang/en'
-import langZH from 'element-ui/lib/locale/lang/zh-CN'
-import locale from 'element-ui/lib/locale'
 export default {
   components: {
     PwdDlg,
@@ -810,7 +798,7 @@ export default {
     logout() {
       //退出登录
       var that = this;
-      this.$confirm("确认退出吗?", "提示", {
+      this.$confirm(/* "确认退出吗?" */this.$t('MsgPrompt.confirm_logout_msg'), this.$t('Dialog.warn_tit'), {
         type: "warning",
       })
         .then(() => {

+ 108 - 98
src/views/Login.vue

@@ -64,39 +64,32 @@
 					>
 				</el-form-item>
 			</el-form>  -->
+
+            <el-radio-group v-model="lang" @input="changeLang" class="lang-wrapper">
+                <el-radio-button label="zh">中文版</el-radio-button>
+                <el-radio-button label="en">英文版</el-radio-button>
+            </el-radio-group>
+
 			<div class="login-box" id="login-container" v-if="activeModel!=='forgetPassModel'">
                 <div class="fixed-login-cont">
                     <span class="login-title">{{ loginTitle }}</span>
-                    <span class="login-sub-title">ETA — 让投研领先市场半步</span>
+                    <span class="login-sub-title">ETA — {{ $t('LoginPage.login_sub_tit') }}<!-- 让投研领先市场半步 --></span>
                     <el-tabs v-model="activeModel" >
-                        <!-- <el-tab-pane label="账号登录" name="ordinaryModel">
-                            <OrdinaryModel ref="ordinaryModel"
-                                :loginCheck="loginCheck"
-                                :accountCheck="accountCheck"
-                                @clearnHint="clearnHint"
-                                @changeModel="changeModel('forgetPassModel')"
-                            />
-                        </el-tab-pane>
-                        <el-tab-pane label="手机号登录" name="mobileModel">
-                            <MobileModel ref="mobileModel"
-                                :areaCode="areaCode"
-                            />
-                        </el-tab-pane> -->
 
                         <OrdinaryModel ref="ordinaryModel"
                             :loginCheck="loginCheck"
                             :accountCheck="accountCheck"
                             @clearnHint="clearnHint"
                             @changeModel="changeModel('forgetPassModel')"
-                            v-show="activeModel=='ordinaryModel'"
+                            v-if="activeModel=='ordinaryModel'"
                         />
 
                         <MobileModel ref="mobileModel"
                             :areaCode="areaCode"
-                            v-show="activeModel=='mobileModel'"
+                            v-if="activeModel=='mobileModel'"
                         />
 
-                        <EmailModel ref="emailModel" v-show="activeModel=='emailModel'"/>
+                        <EmailModel ref="emailModel" v-if="activeModel=='emailModel'"/>
                     </el-tabs>
                     <el-button
                         type="primary"
@@ -104,11 +97,11 @@
                         @click.native="handleLogin"
                         :loading="logining"
                         class="submit_btn"
-                        >登录</el-button>
+                        ><!-- 登录 -->{{ $t('LoginPage.login_btn') }}</el-button>
                     <div class="another-login-type">
                         <div class="another-type-hint">
                             <div class="type-hint-line"></div>
-                            <div class="type-hint-text">其他登录方式</div>
+                            <div class="type-hint-text"><!-- 其他登录方式 -->{{ $t('LoginPage.other_login_type') }}</div>
                             <div class="type-hint-line"></div>
                         </div>
                         <div class="another-type">
@@ -121,7 +114,6 @@
                             <div v-html="item.svg"></div>
                             {{item.label}}
                             </div>
-                                <!-- <img src="~@/assets/img/icons/email-login-type.png" @click="activeModel='emailModel';handleClick({name:'emailModel'})" /> -->
                         </div>
                     </div>
                 </div>
@@ -149,12 +141,12 @@
 			@close="isCheckDialogShow = false"
 			>
 			<el-tabs v-model="checkActiveModel" @tab-click="handleClick">
-				<el-tab-pane label="手机号验证" name="checkMobileModel">
+				<el-tab-pane :label="$t('LoginPage.tab_vaild_phone')" name="checkMobileModel">
 						<MobileModel ref="checkMobileModel"
 							:areaCode="areaCode"
 						/>
 					</el-tab-pane>
-					<el-tab-pane label="邮箱验证" name="checkEmailModel">
+					<el-tab-pane :label="$t('LoginPage.tab_vaild_email')" name="checkEmailModel">
 						<EmailModel ref="checkEmailModel"/>
 					</el-tab-pane>
 			</el-tabs>
@@ -162,7 +154,7 @@
 				<el-button 
 					type="primary" 
 					:loading="checkLogining"
-					@click="submitCheck">提 交</el-button>
+					@click="submitCheck"><!-- 提 交 -->{{ $t('Dialog.submit_btn') }}</el-button>
 			</span>
 		</el-dialog>
 	</div>
@@ -180,6 +172,88 @@ import OrdinaryModel from "./login_manage/OrdinaryModel.vue";
 
 export default {
     components: { OrdinaryModel, MobileModel, EmailModel, ForgetPassModel },
+    computed: {
+        lang() {
+            return this.$i18n.locale
+        },
+         /* 登录方式icon */
+        loginTypeIcons(){
+          return  [
+                    {
+                        name: 'ordinaryModel',
+                        label: /* '账号登录'  */this.$t('LoginPage.login_by_account'),
+                        svg: `<svg data-v-5b948168="" width="64" height="64" viewBox="0 0 60 64" fill="none" xmlns="http://www.w3.org/2000/svg"><g filter="url(#filter0_d_6575_1450)">
+                            <circle cx="26" cy="25" r="20" fill="white"></circle>
+                            <circle cx="26" cy="25" r="19.75" stroke="#DCDFE6" stroke-width="0.5"></circle>
+                            </g>
+                            <g clip-path="url(#clip0_6575_1450)">
+                            <path d="M30.9555 24.9201C29.6869 26.0392 28.0029 26.7261 26.1469 26.7261C24.2634 26.7261 22.5516 26.0169 21.2775 24.8647C18.3137 25.6402 16.48 28.2883 16.48 31.4516V33.0637C16.48 36.8364 35.5204 36.8364 35.5204 33.0637V31.4516C35.5203 28.3716 33.7809 25.7678 30.9555 24.9201ZM26.1469 25.5794C29.4321 25.5794 32.1023 23.0144 32.1023 19.8457C32.1023 16.677 29.4376 14.1064 26.1469 14.1064C22.8673 14.1064 20.1972 16.677 20.1972 19.8457C20.1972 23.0145 22.8673 25.5794 26.1469 25.5794Z" fill="#0052D9"></path>
+                            </g>
+                            <defs>
+                            <filter id="filter0_d_6575_1450" x="0" y="0" width="52" height="52" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
+                            <feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood>
+                            <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"></feColorMatrix>
+                            <feOffset dy="1"></feOffset>
+                            <feGaussianBlur stdDeviation="3"></feGaussianBlur>
+                            <feComposite in2="hardAlpha" operator="out"></feComposite>
+                            <feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.1 0"></feColorMatrix>
+                            <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_6575_1450"></feBlend>
+                            <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_6575_1450" result="shape"></feBlend>
+                            </filter>
+                            <clipPath id="clip0_6575_1450">
+                            <rect width="24" height="24" fill="white" transform="translate(14 13)"></rect>
+                            </clipPath>
+                            </defs></svg>`
+                    },
+                    {
+                        name:'mobileModel',
+                        label: /* '手机号登录' */this.$t('LoginPage.login_by_mobile'),
+                        svg: `<svg data-v-5b948168="" width="64" height="64" viewBox="0 0 56 64" fill="none" xmlns="http://www.w3.org/2000/svg">
+                            <g filter="url(#filter0_d_6575_1430)">
+                            <circle cx="26" cy="25" r="20" fill="white"></circle>
+                            <circle cx="26" cy="25" r="19.75" stroke="#DCDFE6" stroke-width="0.5"></circle>
+                            </g>
+                            <path d="M31.7982 13.6985H19.7718C18.6414 13.6985 17.7246 14.6153 17.7246 15.7457V34.2977C17.7246 35.4281 18.6414 36.3449 19.7718 36.3449H24.8262H27.6366H31.7982C32.9286 36.3449 33.8454 35.4281 33.8454 34.2977V15.7457C33.8454 14.6153 32.9286 13.6985 31.7982 13.6985ZM23.8038 15.1577H27.7662C27.963 15.1577 28.1238 15.3185 28.1238 15.5153C28.1238 15.7121 27.963 15.8729 27.7662 15.8729H23.8038C23.607 15.8729 23.4462 15.7121 23.4462 15.5153C23.4462 15.3185 23.607 15.1577 23.8038 15.1577ZM25.7862 33.9689C24.9894 33.9689 24.3438 33.3233 24.3438 32.5265C24.3438 31.7297 24.9894 31.0841 25.7862 31.0841C26.583 31.0841 27.2286 31.7297 27.2286 32.5265C27.2262 33.3233 26.5806 33.9689 25.7862 33.9689ZM32.3478 28.6337C32.3478 28.9169 32.1198 29.1449 31.8366 29.1449H19.7334C19.4502 29.1449 19.2222 28.9169 19.2222 28.6337V17.7377C19.2222 17.4545 19.4502 17.2265 19.7334 17.2265H31.8342C32.1174 17.2265 32.3454 17.4545 32.3454 17.7377V28.6337H32.3478Z" fill="#0052D9"></path>
+                            <defs>
+                            <filter id="filter0_d_6575_1430" x="0" y="0" width="52" height="52" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
+                            <feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood>
+                            <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"></feColorMatrix>
+                            <feOffset dy="1"></feOffset>
+                            <feGaussianBlur stdDeviation="3"></feGaussianBlur>
+                            <feComposite in2="hardAlpha" operator="out"></feComposite>
+                            <feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.1 0"></feColorMatrix>
+                            <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_6575_1430"></feBlend>
+                            <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_6575_1430" result="shape"></feBlend>
+                            </filter>
+                            </defs></svg>`
+                    },
+                    {
+                        name: 'emailModel',
+                        label: /* '邮箱登录' */this.$t('LoginPage.login_by_email'),
+                        svg: `
+                            <svg data-v-5b948168="" width="64" height="64" viewBox="0 4 64 64" fill="none" xmlns="http://www.w3.org/2000/svg">
+                            <g filter="url(#filter0_d_6575_1422)">
+                            <circle cx="32" cy="30" r="20" fill="white"></circle>
+                            <circle cx="32" cy="30" r="19.5" stroke="#DCDFE6"></circle>
+                            </g>
+                            <path d="M41.1382 34.9875C41.1382 37.1966 39.3473 38.9875 37.1382 38.9875H26.8774C24.6683 38.9875 22.8774 37.1966 22.8774 34.9875V28.1164C22.8774 26.864 23.464 25.6839 24.4623 24.9278L31.3139 19.7381C31.517 19.5832 31.7594 19.5 32.0078 19.5C32.2562 19.5 32.4986 19.5832 32.7017 19.7381L39.5533 24.9278C40.5516 25.6839 41.1382 26.864 41.1382 28.1164V34.9875Z" fill="#0052D9"></path>
+                            <path d="M38.682 26.5957C38.682 27.0061 38.4316 27.3751 38.0501 27.5266L33.4963 29.3353C32.5408 29.7148 31.4758 29.7119 30.5224 29.327L25.956 27.4837C25.5853 27.334 25.3425 26.9743 25.3425 26.5745C25.3425 26.033 25.7815 25.594 26.323 25.594H37.6803C38.2335 25.594 38.682 26.0425 38.682 26.5957Z" fill="white"></path>
+                            <defs>
+                            <filter id="filter0_d_6575_1422" x="0" y="0" width="64" height="64" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
+                            <feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood>
+                            <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"></feColorMatrix>
+                            <feOffset dy="2"></feOffset>
+                            <feGaussianBlur stdDeviation="6"></feGaussianBlur>
+                            <feComposite in2="hardAlpha" operator="out"></feComposite>
+                            <feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.1 0"></feColorMatrix>
+                            <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_6575_1422"></feBlend>
+                            <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_6575_1422" result="shape"></feBlend>
+                            </filter>
+                            </defs></svg>`
+                    },
+                  ]
+        } 
+    },
     data() {
         return {
             b: new http.Base64(),
@@ -219,81 +293,6 @@ export default {
             isCheckDialogShow:false,
             checkActiveModel:'checkMobileModel',
             
-            /* 登录方式icon */
-            loginTypeIcons: [
-                {
-                    name: 'ordinaryModel',
-                    label: '账号登录',
-                    svg: `<svg data-v-5b948168="" width="64" height="64" viewBox="0 0 60 64" fill="none" xmlns="http://www.w3.org/2000/svg"><g filter="url(#filter0_d_6575_1450)">
-                        <circle cx="26" cy="25" r="20" fill="white"></circle>
-                        <circle cx="26" cy="25" r="19.75" stroke="#DCDFE6" stroke-width="0.5"></circle>
-                        </g>
-                        <g clip-path="url(#clip0_6575_1450)">
-                        <path d="M30.9555 24.9201C29.6869 26.0392 28.0029 26.7261 26.1469 26.7261C24.2634 26.7261 22.5516 26.0169 21.2775 24.8647C18.3137 25.6402 16.48 28.2883 16.48 31.4516V33.0637C16.48 36.8364 35.5204 36.8364 35.5204 33.0637V31.4516C35.5203 28.3716 33.7809 25.7678 30.9555 24.9201ZM26.1469 25.5794C29.4321 25.5794 32.1023 23.0144 32.1023 19.8457C32.1023 16.677 29.4376 14.1064 26.1469 14.1064C22.8673 14.1064 20.1972 16.677 20.1972 19.8457C20.1972 23.0145 22.8673 25.5794 26.1469 25.5794Z" fill="#0052D9"></path>
-                        </g>
-                        <defs>
-                        <filter id="filter0_d_6575_1450" x="0" y="0" width="52" height="52" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
-                        <feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood>
-                        <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"></feColorMatrix>
-                        <feOffset dy="1"></feOffset>
-                        <feGaussianBlur stdDeviation="3"></feGaussianBlur>
-                        <feComposite in2="hardAlpha" operator="out"></feComposite>
-                        <feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.1 0"></feColorMatrix>
-                        <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_6575_1450"></feBlend>
-                        <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_6575_1450" result="shape"></feBlend>
-                        </filter>
-                        <clipPath id="clip0_6575_1450">
-                        <rect width="24" height="24" fill="white" transform="translate(14 13)"></rect>
-                        </clipPath>
-                        </defs></svg>`
-                },
-                {
-                    name:'mobileModel',
-                    label: '手机号登录',
-                    svg: `<svg data-v-5b948168="" width="64" height="64" viewBox="0 0 56 64" fill="none" xmlns="http://www.w3.org/2000/svg">
-                        <g filter="url(#filter0_d_6575_1430)">
-                        <circle cx="26" cy="25" r="20" fill="white"></circle>
-                        <circle cx="26" cy="25" r="19.75" stroke="#DCDFE6" stroke-width="0.5"></circle>
-                        </g>
-                        <path d="M31.7982 13.6985H19.7718C18.6414 13.6985 17.7246 14.6153 17.7246 15.7457V34.2977C17.7246 35.4281 18.6414 36.3449 19.7718 36.3449H24.8262H27.6366H31.7982C32.9286 36.3449 33.8454 35.4281 33.8454 34.2977V15.7457C33.8454 14.6153 32.9286 13.6985 31.7982 13.6985ZM23.8038 15.1577H27.7662C27.963 15.1577 28.1238 15.3185 28.1238 15.5153C28.1238 15.7121 27.963 15.8729 27.7662 15.8729H23.8038C23.607 15.8729 23.4462 15.7121 23.4462 15.5153C23.4462 15.3185 23.607 15.1577 23.8038 15.1577ZM25.7862 33.9689C24.9894 33.9689 24.3438 33.3233 24.3438 32.5265C24.3438 31.7297 24.9894 31.0841 25.7862 31.0841C26.583 31.0841 27.2286 31.7297 27.2286 32.5265C27.2262 33.3233 26.5806 33.9689 25.7862 33.9689ZM32.3478 28.6337C32.3478 28.9169 32.1198 29.1449 31.8366 29.1449H19.7334C19.4502 29.1449 19.2222 28.9169 19.2222 28.6337V17.7377C19.2222 17.4545 19.4502 17.2265 19.7334 17.2265H31.8342C32.1174 17.2265 32.3454 17.4545 32.3454 17.7377V28.6337H32.3478Z" fill="#0052D9"></path>
-                        <defs>
-                        <filter id="filter0_d_6575_1430" x="0" y="0" width="52" height="52" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
-                        <feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood>
-                        <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"></feColorMatrix>
-                        <feOffset dy="1"></feOffset>
-                        <feGaussianBlur stdDeviation="3"></feGaussianBlur>
-                        <feComposite in2="hardAlpha" operator="out"></feComposite>
-                        <feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.1 0"></feColorMatrix>
-                        <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_6575_1430"></feBlend>
-                        <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_6575_1430" result="shape"></feBlend>
-                        </filter>
-                        </defs></svg>`
-                },
-                {
-                    name: 'emailModel',
-                    label: '邮箱登录',
-                    svg: `
-                        <svg data-v-5b948168="" width="64" height="64" viewBox="0 4 64 64" fill="none" xmlns="http://www.w3.org/2000/svg">
-                        <g filter="url(#filter0_d_6575_1422)">
-                        <circle cx="32" cy="30" r="20" fill="white"></circle>
-                        <circle cx="32" cy="30" r="19.5" stroke="#DCDFE6"></circle>
-                        </g>
-                        <path d="M41.1382 34.9875C41.1382 37.1966 39.3473 38.9875 37.1382 38.9875H26.8774C24.6683 38.9875 22.8774 37.1966 22.8774 34.9875V28.1164C22.8774 26.864 23.464 25.6839 24.4623 24.9278L31.3139 19.7381C31.517 19.5832 31.7594 19.5 32.0078 19.5C32.2562 19.5 32.4986 19.5832 32.7017 19.7381L39.5533 24.9278C40.5516 25.6839 41.1382 26.864 41.1382 28.1164V34.9875Z" fill="#0052D9"></path>
-                        <path d="M38.682 26.5957C38.682 27.0061 38.4316 27.3751 38.0501 27.5266L33.4963 29.3353C32.5408 29.7148 31.4758 29.7119 30.5224 29.327L25.956 27.4837C25.5853 27.334 25.3425 26.9743 25.3425 26.5745C25.3425 26.033 25.7815 25.594 26.323 25.594H37.6803C38.2335 25.594 38.682 26.0425 38.682 26.5957Z" fill="white"></path>
-                        <defs>
-                        <filter id="filter0_d_6575_1422" x="0" y="0" width="64" height="64" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
-                        <feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood>
-                        <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"></feColorMatrix>
-                        <feOffset dy="2"></feOffset>
-                        <feGaussianBlur stdDeviation="6"></feGaussianBlur>
-                        <feComposite in2="hardAlpha" operator="out"></feComposite>
-                        <feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.1 0"></feColorMatrix>
-                        <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_6575_1422"></feBlend>
-                        <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_6575_1422" result="shape"></feBlend>
-                        </filter>
-                        </defs></svg>`
-                },
-            ],
             recordInformation:[],
             loginTitle:''
         };
@@ -618,6 +617,11 @@ export default {
                     }
                 }
             }
+        },
+
+        changeLang(val) {
+            this.$i18n.locale = val
+            localStorage.setItem('i18n',this.$i18n.locale)
         }
     },
     destroyed() {
@@ -857,5 +861,11 @@ export default {
 			font-size: 14px;
 		}
 	}
+
+    .lang-wrapper {
+        position: absolute;
+        top: 3%;
+        right: 3%;
+    }
 }
 </style>

+ 1 - 1
src/views/dataEntry_manage/databaseList.vue

@@ -426,7 +426,7 @@
 			<ul class="computed-ul">
 				<li
 					:class="['cpmputed-li',item.type === computed_type?'act':'']" 
-					v-for="item in computedTypes" 
+					v-for="item in computedShowTypes" 
 					:key="item.type" 
 					@click="changeComputedType(item.type)">
 					{{item.name}}

+ 16 - 13
src/views/login_manage/EmailModel.vue

@@ -11,7 +11,7 @@
                     type="text"
                     v-model="form.email"
                     auto-complete="off"
-                    placeholder="请输入邮箱"
+                    :placeholder="$t('LoginPage.ph_email')"
                 >
                 </el-input>
                 <span class="inline-message el-form-item__error" 
@@ -25,7 +25,7 @@
                     type="text"
                     v-model="form.picCode"
                     auto-complete="off"
-                    placeholder="请输入图形验证码"
+                    :placeholder="$t('LoginPage.ph_img_code')"
                 >
                     <div class="pic-box" slot="append" @click="getCodePic">
                         <img :src="picSrc" alt="图形验证码"/>
@@ -37,7 +37,7 @@
                     type="text"
                     v-model="form.checkCode"
                     auto-complete="off"
-                    placeholder="请输入验证码"
+                    :placeholder="$t('LoginPage.ph_msg_code')"
                 ></el-input>
                 <el-button type="text" class="code-btn" @click="checkForm" :disabled="codeCountDown<60&&codeCountDown>0">{{codeStr}}</el-button>
             </el-form-item>
@@ -71,7 +71,7 @@ export default {
             picSrc:'',
             picId:'',
             timer:0,
-            codeStr:'获取验证码',
+            codeStr:/* '获取验证码'  */this.$t('LoginPage.ver_code_msg'),
             codeCountDown:60,
             isGetNewCode:false,
             form:{
@@ -81,17 +81,17 @@ export default {
             },
             rules:{
                 email:[
-                    {required:true,message:'请输入邮箱',trigger:'blur'},
+                    {required:true,message:/* '请输入邮箱' */this.$t('LoginPage.ph_email'),trigger:'blur'},
                     {validator:(rule,value,callback)=>{
                         if(!patternEmail.test(value)){
-                            callback(new Error("请输入正确的邮箱格式"))
+                            callback(new Error(/* "请输入正确的邮箱格式" */this.$t('LoginPage.vaild_curr_email')))
                         }else{
                             callback()
                         }
                     },trigger:'blur'}
                 ],
-                picCode:[{required:true,message:'请输入图形验证码',trigger:'blur'}],
-                checkCode:[{required:true,message:'请输入短信验证码',trigger:'blur'}]
+                picCode:[{required:true,message:/* '请输入图形验证码' */this.$t('LoginPage.ph_img_code'),trigger:'blur'}],
+                checkCode:[{required:true,message:/* '请输入短信验证码' */this.$t('LoginPage.ph_msg_code'),trigger:'blur'}]
             },
             hintMessage:''
         };
@@ -99,9 +99,9 @@ export default {
     methods: {
         checkForm(){
             //首先检查是否是重新获取验证码
-            if(this.codeStr==='重新获取'&&!this.isGetNewCode){
+            if(this.codeStr===this.$t('LoginPage.recode_msg')&&!this.isGetNewCode){
                 //引导用户重新输入图形验证码
-                this.$message.warning('重新获取需再次输入图形验证码')
+                this.$message.warning(/* '重新获取需再次输入图形验证码' */this.$t('LoginPage.recode_warn_msg'))
                 this.getCodePic()
                 this.form.picCode = ''
                 this.isGetNewCode = true
@@ -110,11 +110,11 @@ export default {
             //检查邮箱和图形验证码是否正确
             const {email,picCode} = this.form
             if(!picCode.length){
-                this.$message.warning('请输入图形验证码')
+                this.$message.warning(/* '请输入图形验证码' */this.$t('LoginPage.ph_img_code'))
                 return
             }
             if(!patternEmail.test(email)){
-                this.$message.warning('请输入正确的邮箱')
+                this.$message.warning(/* '请输入正确的邮箱' */this.$t('LoginPage.vaild_curr_email'))
                 return
             }
             //通过请求发送验证码
@@ -126,7 +126,7 @@ export default {
                 Source:this.Source
             }).then(res=>{
                 if(res.Ret!==200) return 
-                this.$message.success('验证码已发送')
+                this.$message.success(/* '验证码已发送' */this.$t('LoginPage.send_code_msg'))
                 this.isGetNewCode = false
                 //60秒倒计时
                 this.codeCountDown = 60
@@ -137,6 +137,9 @@ export default {
             })
         }
     },
+    mounted() {
+        this.getCodePic()
+    }
 };
 </script>
 

+ 18 - 18
src/views/login_manage/ForgetPassModel.vue

@@ -2,7 +2,7 @@
     <div class="forget-pass-model">
         <div class="header-nav" @click="changeModel">
             <span><i class="el-icon-back"></i></span>
-            <span>忘记密码</span>
+            <span><!-- 忘记密码 -->{{ $t('LoginPage.label_forget') }}</span>
         </div>
         <div class="step-container model-wrap" v-show="currentStep===0">
             <el-form 
@@ -16,7 +16,7 @@
                         type="text"
                         v-model="form.account"
                         auto-complete="off"
-                        placeholder="请输入账号">
+                        :placeholder="$t('LoginPage.ph_account')">
                     </el-input>
                 </el-form-item>
                 <el-form-item prop="picCode">
@@ -25,7 +25,7 @@
                         type="text"
                         v-model="form.picCode"
                         auto-complete="off"
-                        placeholder="请输入图形验证码"
+                        :placeholder="$t('LoginPage.ph_img_code')"
                     >
                         <div class="pic-box" slot="append" @click="getCodePic">
                             <img :src="picSrc" alt="图形验证码"/>
@@ -33,23 +33,23 @@
                     </el-input>
                 </el-form-item>
             </el-form>
-            <el-button class="submit_btn" @click="getUserInfo">下一步</el-button>
+            <el-button class="submit_btn" @click="getUserInfo"><!-- 下一步 -->{{ $t('Dialog.next_step') }}</el-button>
         </div>
         <div class="step-container" v-show="currentStep>0">
             <div class="container-header">
-                <p>您正在找回账号{{form.account}}的密码</p>
+                <p> {{ $t('LoginPage.label_find_pwd',{name: form.account}) }}</p>
                 <ModelSteps :active-step="currentStep"/>
             </div>
             <div class="container-inner model-wrap" v-show="currentStep===1">
                 <VerificationBox
                     verifies-type="mobile"
-                    :info-text="userMobile||'暂未绑定'"
+                    :info-text="userMobile||$t('LoginPage.label_not_bind')"
                     :hideBtn="!userMobile"
                     @goNext="getCode"
                 />
                 <VerificationBox
                     verifies-type="email"
-                    :info-text="userEmail||'暂未绑定'"
+                    :info-text="userEmail||$t('LoginPage.label_not_bind')"
                     :hideBtn="!userEmail"
                     @goNext="getCode"
                 />
@@ -59,8 +59,8 @@
                     ref="captInput"
                 />
                 <div class="btn-wrap">
-                    <el-button type="primary" plain @click="changeModel">上一步</el-button>
-                    <el-button type="primary" @click="checkInput">下一步</el-button>
+                    <el-button type="primary" plain @click="changeModel"><!-- 上一步 -->{{ $t('Dialog.prev_step') }}</el-button>
+                    <el-button type="primary" @click="checkInput"><!-- 下一步 -->{{ $t('Dialog.next_step') }}</el-button>
                 </div>
                 
             </div>
@@ -79,7 +79,7 @@
                             @copy.native.capture.prevent="()=>{return false}"
                             @cut.native.capture.prevent="()=>{return false}"
                             @paste.native.capture.prevent="()=>{return false}"
-                            placeholder="请输入新密码">
+                            :placeholder="$t('LoginPage.ph_new_pwd')">
                         </el-input>
                     </el-form-item>
                     <el-form-item prop="pass2">
@@ -90,7 +90,7 @@
                             @copy.native.capture.prevent="()=>{return false}"
                             @cut.native.capture.prevent="()=>{return false}"
                             @paste.native.capture.prevent="()=>{return false}"
-                            placeholder="请确认新密码">
+                            :placeholder="$t('ResetPwdPage.vaild_new')">
                         </el-input>
                     </el-form-item>
                 </el-form>
@@ -120,22 +120,22 @@ export default {
     data() {
         const validatePass = (rule,value,callback)=>{
             if(value===''){
-                callback(new Error('请输入新密码'))
+                callback(new Error(/* '请输入新密码' */this.$t('LoginPage.ph_new_pwd')))
             }
             if(this.passForm.pass2!==''){
                 this.$refs.passForm.validateField('pass2')
             }
             if(!checkPassWord(value)){
-                callback(new Error('密码要求8位及以上,包含数字、大写字母、小写字母、特殊字符中的三个类型'))
+                callback(new Error(/* '密码要求8位及以上,包含数字、大写字母、小写字母、特殊字符中的三个类型' */this.$t('ResetPwdPage.vaild_rule')))
             }else{
                 callback()
             }
         }
         const validateCheck = (rule,value,callback)=>{
             if(value===''){
-                callback(new Error('请输入确认密码'))
+                callback(new Error(/* '请输入确认密码' */this.$t('ResetPwdPage.vaild_new')))
             }else if(value!==this.passForm.pass1){
-                callback(new Error('两次输入的密码不一致,请检查'))
+                callback(new Error(/* '两次输入的密码不一致,请检查' */this.$t('ResetPwdPage.vaild_same')))
             }else{
                 callback()
             }
@@ -182,11 +182,11 @@ export default {
             //检查form是否填写完整
             const {account,picCode} = this.form
             if(!account){
-                this.$message.warning('请输入账号')
+                this.$message.warning(/* '请输入账号' */this.$t('LoginPage.ph_account'))
                 return
             }
             if(!picCode){
-                this.$message.warning('请输入图形验证码')
+                this.$message.warning(/* '请输入图形验证码' */this.$t('LoginPage.ph_img_code'))
                 return
             }
             //请求接口获取账号数据,赋值userMobile,userEmail
@@ -280,7 +280,7 @@ export default {
                         RePassword:new http.Base64().encode(this.passForm.pass2)
                     }).then(res=>{
                         if(res.Ret!==200) return
-                        this.$message.success('重置密码成功,请登陆')
+                        this.$message.success(/* '重置密码成功,请登陆' */this.$t('LoginPage.reset_pwd_success_msg'))
                         localStorage.setItem('timeKey',Date.now())
                         localStorage.setItem("account", new http.Base64().encode(this.form.account));
                         localStorage.setItem("checkPass", new http.Base64().encode(this.passForm.pass1));

+ 17 - 14
src/views/login_manage/MobileModel.vue

@@ -12,7 +12,7 @@
                     type="text"
                     v-model="form.mobile"
                     auto-complete="off"
-                    placeholder="请输入手机号"
+                    :placeholder="$t('LoginPage.ph_mobile')"
                 >
                     <el-select v-model="areaCodeSelect" slot="prepend" placeholder="请选择">
                         <el-option v-for="item in areaCode" :key="item.Value"
@@ -30,7 +30,7 @@
                     type="text"
                     v-model="form.picCode"
                     auto-complete="off"
-                    placeholder="请输入图形验证码"
+                    :placeholder="$t('LoginPage.ph_img_code')"
                 >
                     <div class="pic-box" slot="append" @click="getCodePic">
                         <img :src="picSrc" alt="图形验证码"/>
@@ -42,7 +42,7 @@
                     type="text"
                     v-model="form.checkCode"
                     auto-complete="off"
-                    placeholder="请输入验证码">
+                    :placeholder="$t('LoginPage.ph_msg_code')">
                 </el-input>
                 <el-button type="text" class="code-btn" @click="checkForm" :disabled="codeCountDown<60&&codeCountDown>0">{{codeStr}}</el-button>
             </el-form-item>
@@ -81,7 +81,7 @@ export default {
             picSrc:'',//图形验证码地址
             picId:'',//图形验证码id
             timer:0,
-            codeStr:'获取验证码',
+            codeStr:/* '获取验证码'  */this.$t('LoginPage.ver_code_msg'),
             codeCountDown:60,
             isGetNewCode:false,
             form:{
@@ -91,28 +91,28 @@ export default {
             },
             rules:{
                 mobile:[
-                    {required: true,message: "请输入手机号",trigger: "blur"},
+                    {required: true,message: /* "请输入手机号" */this.$t('LoginPage.ph_mobile'),trigger: "blur"},
                     {validator:(rule,value,callback)=>{
                         if(this.areaCodeSelect==='86'&&!isMobileNo(value)){
-                            callback(new Error('请输入正确的手机号格式'));
+                            callback(new Error(/* '请输入正确的手机号格式' */this.$t('LoginPage.vaild_curr_mobile')));
                         }else if(this.areaCodeSelect!=='86'&&isNaN(value.trim())){
-                            callback(new Error('请输入正确的手机号格式'));
+                            callback(new Error(/* '请输入正确的手机号格式' */this.$t('LoginPage.vaild_curr_mobile')));
                         }else{
                             callback()
                         }
                     },trigger:'blur'}
                 ],
-                picCode:[{required:true,message:'请输入图形验证码',trigger:'blur'}],
-                checkCode:[{required:true,message:'请输入短信验证码',trigger:'blur'}]
+                picCode:[{required:true,message:/* '请输入图形验证码' */this.$t('LoginPage.ph_img_code'),trigger:'blur'}],
+                checkCode:[{required:true,message:/* '请输入短信验证码' */this.$t('LoginPage.ph_msg_code'),trigger:'blur'}]
             }
         };
     },
     methods: {
         checkForm(){
             //首先检查是否是重新获取验证码
-            if(this.codeStr==='重新获取'&&!this.isGetNewCode){
+            if(this.codeStr===this.$t('LoginPage.recode_msg')&&!this.isGetNewCode){
                 //引导用户重新输入图形验证码
-                this.$message.warning('重新获取需再次输入图形验证码')
+                this.$message.warning(/* '重新获取需再次输入图形验证码' */this.$t('LoginPage.recode_warn_msg'))
                 this.getCodePic()
                 this.form.picCode = ''
                 this.isGetNewCode = true
@@ -121,11 +121,11 @@ export default {
             //检查手机号和图形验证码是否正确
             const {picCode,mobile} = this.form
             if(!picCode.length){
-                this.$message.warning('请输入图形验证码')
+                this.$message.warning(/* '请输入图形验证码' */this.$t('LoginPage.ph_img_code'))
                 return
             }
             if(this.areaCodeSelect==='86'&&!isMobileNo(mobile)){
-                this.$message.warning('请输入正确的手机号')
+                this.$message.warning(/* '请输入正确的手机号' */this.$t('LoginPage.vaild_curr_mobile'))
                 return
             }
 
@@ -139,7 +139,7 @@ export default {
                 Source:this.Source
             }).then(res=>{
                 if(res.Ret!==200) return 
-                this.$message.success('验证码已发送')
+                this.$message.success(/* '验证码已发送' */this.$t('LoginPage.send_code_msg'))
                 this.isGetNewCode = false
                 //60秒倒计时
                 this.codeCountDown = 60
@@ -151,6 +151,9 @@ export default {
 
         }
     },
+    mounted() {
+        this.getCodePic()
+    }
 };
 </script>
 

+ 9 - 9
src/views/login_manage/OrdinaryModel.vue

@@ -11,7 +11,7 @@
                     type="text"
                     v-model="form.account"
                     auto-complete="off"
-                    placeholder="请输入用户名"
+                    :placeholder="$t('LoginPage.ph_account')"
                 />
                 <span class="inline-message el-form-item__error" 
                     v-show="(loginCheck||accountCheck)&&form.account.length">
@@ -23,7 +23,7 @@
                     type="password" show-password
                     v-model="form.checkPass"
                     auto-complete="off"
-                    placeholder="请输入密码"
+                    :placeholder="$t('LoginPage.ph_pwd')"
                     @copy.native.capture.prevent="()=>{return false}"
                     @cut.native.capture.prevent="()=>{return false}"
                     @paste.native.capture.prevent="()=>{return false}"
@@ -34,14 +34,14 @@
             </el-form-item>
             <el-form-item class="remember-cont" prop="checked">
                 <el-checkbox v-model="form.checked" class="remember">
-                    记住账号密码
-                    <el-tooltip effect="dark" content="有效期60天" placement="top">
+                    <!-- 记住账号密码 -->{{ $t('LoginPage.label_remember') }}
+                    <el-tooltip effect="dark" :content="$t('LoginPage.vaild_day_msg')" placement="top">
                         <span class="hint-text">
                             <i class="el-icon-question"></i>
                         </span>
                     </el-tooltip>
                 </el-checkbox>
-                <el-button type="text" style="font-size: 16px;" @click="changeModel">忘记密码</el-button>
+                <el-button type="text" style="font-size: 16px;" @click="changeModel"><!-- 忘记密码 -->{{ $t('LoginPage.label_forget') }}</el-button>
             </el-form-item>
         </el-form>
     </div>
@@ -76,11 +76,11 @@ export default {
             },
             rules:{
                 account:[
-                    {required: true,message: "请输入账号",trigger: "blur"},
+                    {required: true,message: /* "请输入账号" */this.$t('LoginPage.ph_account'),trigger: "blur"},
                     {validator:validateClearn,trigger:['change']}
                 ],
                 checkPass:[
-                    {required: true,message: "请输入密码",trigger: "blur"},
+                    {required: true,message: /* "请输入密码" */this.$t('LoginPage.ph_pwd'),trigger: "blur"},
                     {validator:validateClearn,trigger:['change']}
                 ]
             },
@@ -91,14 +91,14 @@ export default {
         loginCheck(newVal){
             //显示/隐藏inline-message
             if(newVal){
-                this.hintMessage="账号或密码错误"
+                this.hintMessage=/* "账号或密码错误" */ this.$t('LoginPage.error_wrong_msg')
             }else{
                 this.hintMessage=''
             }
         },
         accountCheck(newVal){
             if(newVal){
-                this.hintMessage="账号异常,请通过验证登录"
+                this.hintMessage=/* "账号异常,请通过验证登录" */this.$t('LoginPage.error_abnormal_msg')
             }else{
                 this.hintMessage=''
             }

+ 6 - 2
src/views/login_manage/components/ModelSteps.vue

@@ -7,7 +7,7 @@
             <div class="step-line"></div>
             <div class="step-num" v-if="index+1>=activeStep">{{index+1}}</div>
             <div class="step-num" v-else><i class="el-icon-check"></i></div>
-            <div class="step-text">{{step.text}}</div>
+            <div class="step-text">{{textMap[step.text]}}</div>
             
         </li>
     </ul>
@@ -33,7 +33,11 @@ export default {
     },
     data() {
         return {
-
+            textMap: {
+                '选择验证方式':  this.$t('LoginPage.step_vaild_one'),
+                '进行安全验证':  this.$t('LoginPage.step_vaild_two'),
+                '设置密码':  this.$t('LoginPage.step_vaild_three'),
+            }
         };
     },
     methods: {

+ 1 - 1
src/views/login_manage/components/VerificationBox.vue

@@ -4,7 +4,7 @@
             <img :src="verifiesType==='mobile'?mobile_src:email_src" />
         </div>
         <div class="text">{{infoText}}</div>
-        <el-button  type="primary" @click="goNext" v-if="!hideBtn" :disabled="countDown">{{countDown?`重发(${countDown}秒)`:btnText}}</el-button>
+        <el-button  type="primary" @click="goNext" v-if="!hideBtn" :disabled="countDown">{{countDown?`重发(${countDown}秒)`:(btnText==='开始验证'?$t('LoginPage.send_vaild_btn'):btnText)}}</el-button>
     </div>
 </template>
 

+ 2 - 2
src/views/login_manage/modelMixins.js

@@ -23,10 +23,10 @@ export default {
             /* if(!this.timer) return */
             //console.log('click down')
             this.codeCountDown--
-            this.codeStr=`重新获取(${this.codeCountDown})秒`
+            this.codeStr=/* `重新获取(${this.codeCountDown})秒` */ this.$t('LoginPage.recode_ing_msg',{count: this.codeCountDown})
             if(this.codeCountDown<=0){
                 clearInterval(this.timer)
-                this.codeStr = '重新获取'
+                this.codeStr = /* '重新获取' */ this.$t('LoginPage.recode_msg')
                 return
             }
         }

+ 19 - 23
src/views/resetpassword.vue

@@ -2,7 +2,7 @@
   <div>
     <el-card class="box-card">
       <div slot="header" class="clearfix">
-        <b>修改密码</b>
+        <b><!-- 修改密码 -->{{ $t('MainPage.tab_reset_pwd') }}</b>
       </div>
       <el-form
         :model="addForm"
@@ -11,76 +11,72 @@
         ref="addForm"
         style="width: 500px"
       >
-        <el-form-item label="原密码" prop="OldPwd">
+        <el-form-item :label="$t('ResetPwdPage.label_old_pwd')" prop="OldPwd">
           <el-input
             type="text"
             v-model="addForm.OldPwd"
-            placeholder="请输入不超过20个字符"
+            :placeholder="$t('ResetPwdPage.ph_pwd')"
             clearable
             autocomplete="new-password"
           ></el-input>
         </el-form-item>
-        <el-form-item label="新密码" prop="NewPwd" v-if="visible">
+        <el-form-item :label="$t('ResetPwdPage.label_new_pwd')" prop="NewPwd" v-if="visible">
           <el-input
             type="password"
             v-model="addForm.NewPwd"
-            placeholder="请输入长度不超过20个字符"
+            :placeholder="$t('ResetPwdPage.ph_pwd')"
             maxlength="20"
             autocomplete="new-password"
           >
             <i
               slot="suffix"
               class="el-icon-view el-input__icon"
-              title="显示密码"
               @click="changePass('show')"
               style="cursor: pointer"
             ></i>
           </el-input>
         </el-form-item>
-        <el-form-item label="新密码" prop="NewPwd" v-else>
+        <el-form-item :label="$t('ResetPwdPage.label_new_pwd')" prop="NewPwd" v-else>
           <el-input
             type="text"
             v-model="addForm.NewPwd"
-            placeholder="请输入长度不超过20个字符"
+            :placeholder="$t('ResetPwdPage.ph_pwd')"
             maxlength="20"
             autocomplete="new-password"
           >
             <i
               slot="suffix"
               class="el-icon-more el-input__icon"
-              title="隐藏密码"
               @click="changePass('hide')"
               style="cursor: pointer"
             ></i>
           </el-input>
         </el-form-item>
-        <el-form-item label="确认新密码" prop="twoNewPwd" v-if="twovisible">
+        <el-form-item :label="$t('ResetPwdPage.label_ensure_pwd')" prop="twoNewPwd" v-if="twovisible">
           <el-input
             type="password"
             v-model="addForm.twoNewPwd"
-            placeholder="请输入长度不超过20个字符"
+            :placeholder="$t('ResetPwdPage.ph_pwd')"
             maxlength="20"
           >
             <i
               slot="suffix"
               class="el-icon-view el-input__icon"
-              title="显示密码"
               @click="changetwoPass('show')"
               style="cursor: pointer"
             ></i>
           </el-input>
         </el-form-item>
-        <el-form-item label="确认新密码" prop="twoNewPwd" v-else>
+        <el-form-item :label="$t('ResetPwdPage.label_ensure_pwd')" prop="twoNewPwd" v-else>
           <el-input
             type="text"
             v-model="addForm.twoNewPwd"
-            placeholder="请输入长度不超过20个字符"
+            :placeholder="$t('ResetPwdPage.ph_pwd')"
             maxlength="20"
           >
             <i
               slot="suffix"
               class="el-icon-more el-input__icon"
-              title="隐藏密码"
               @click="changetwoPass('hide')"
               style="cursor: pointer"
             ></i>
@@ -88,14 +84,14 @@
         </el-form-item>
         <el-form-item style="text-align: center;">
           <el-button type="primary" size="medium" @click.native="addSubmit"
-            >确定</el-button
+            ><!-- 确定 -->{{ $t('Dialog.confirm_btn') }}</el-button
           >
           <el-button
             type="primary"
             size="medium"
             plain
             @click.native="historyBack"
-            >返回</el-button
+            ><!-- 返回 -->{{ $t('Dialog.back_btn') }}</el-button
           >
         </el-form-item>
       </el-form>
@@ -122,7 +118,7 @@ export default {
         OldPwd: [
           {
             required: true,
-            message: "请输入原密码",
+            message: /* "请输入原密码" */ this.$t('ResetPwdPage.vaild_old'),
             trigger: "blur",
           },
         ],
@@ -130,7 +126,7 @@ export default {
             {
                 validator:(rule,value,callback)=>{
                     if(!checkPassWord(value)){
-                        callback(new Error('密码要求8位及以上,包含数字、大写字母、小写字母、特殊字符中的三个类型'))
+                        callback(new Error(/* '密码要求8位及以上,包含数字、大写字母、小写字母、特殊字符中的三个类型' */this.$t('ResetPwdPage.vaild_rule')))
                     }else{
                         callback()
                     }
@@ -138,14 +134,14 @@ export default {
             },
           {
             required: true,
-            message: "请输入确认密码",
+            message: /* "请输入确认密码" */this.$t('ResetPwdPage.vaild_new'),
             trigger: "blur",
           },
         ],
         twoNewPwd: [
           {
             required: true,
-            message: "请输入确认密码",
+            message: /* "请输入确认密码" */this.$t('ResetPwdPage.vaild_new'),
             trigger: "blur",
           },
         ],
@@ -165,7 +161,7 @@ export default {
         if (valid) {
           let that = this;
           if (that.addForm.NewPwd != that.addForm.twoNewPwd) {
-            that.$message.warning("新密码两次输入不一致,请核对!");
+            that.$message.warning(/* "新密码两次输入不一致,请核对!"  */this.$t('ResetPwdPage.vaild_same'));
             return false;
           }
           modifyPwd({
@@ -173,7 +169,7 @@ export default {
             NewPwd: md5.hex_md5(that.addForm.NewPwd),
           }).then((res) => {
             if (res.Ret == 200) {
-              that.$message.success("修改密码成功,请重新登录!");
+              that.$message.success(/* "修改密码成功,请重新登录!" */ this.$t('ResetPwdPage.edit_pwd_msg'));
               setTimeout(function () {
                 localStorage.setItem("auth", "");
                 localStorage.setItem("userName", "");