Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
liuzhen@situdata.com
/
yunxiao-admin-fe
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
5b8758a5
authored
2020-10-23 14:56:47 +0800
by
zhen
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
提取公共字段
1 parent
1a9e9bec
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
2 deletions
src/components/loginForm/LoginForm.vue
src/utils/mappingData.js
src/views/monitor.vue
src/components/loginForm/LoginForm.vue
View file @
5b8758a
...
...
@@ -10,6 +10,7 @@
class="login-input"
placeholder="请输入工号"
v-model.trim="loginForm.username"
:maxlength="inputMaxLength"
)
i(slot="prefix" class="icon username-icon")
el-form-item(prop="password")
...
...
@@ -19,6 +20,7 @@
size="medium"
placeholder="请输入密码"
class="login-input"
:maxlength="inputMaxLength"
v-model.trim="loginForm.password"
)
i(slot="prefix" class="icon password-icon")
...
...
@@ -41,6 +43,7 @@
<
script
>
import
Captcha
from
'captcha-mini'
import
{
maxSizeValidate
}
from
'@/views/validate'
import
{
inputMaxLength
}
from
'@/utils/mappingData'
export
default
{
name
:
'LoginForm'
,
...
...
@@ -70,6 +73,7 @@ export default {
},
data
()
{
return
{
inputMaxLength
,
verCode
:
''
,
captcha1
:
null
,
loginForm
:
{
...
...
src/utils/mappingData.js
View file @
5b8758a
...
...
@@ -19,3 +19,5 @@ export const PERMISSION_USER_MAP = {
name
:
'数据分析员'
}
}
export
const
inputMaxLength
=
21
...
...
src/views/monitor.vue
View file @
5b8758a
...
...
@@ -12,7 +12,7 @@
<el-input
v-model
.
trim=
"ruleForm.username"
placeholder=
"请输入营销员姓名"
maxlength=
"21
"
:maxlength=
"inputMaxLength
"
>
<i
slot=
"prefix"
class=
"el-icon-search"
></i
></el-input>
...
...
@@ -21,7 +21,7 @@
<el-input
v-model
.
trim=
"ruleForm.userId"
placeholder=
"请输入营销员工号"
maxlength=
"21
"
:maxlength=
"inputMaxLength
"
>
<i
slot=
"prefix"
class=
"el-icon-search"
></i
></el-input>
...
...
@@ -107,6 +107,7 @@
import
FooterPaginationfrom
from
'./components/FooterPagination'
import
{
parseTime
,
parseTimeSecond
}
from
'@/utils/util'
import
{
getResourceMonitorList
}
from
'@/api/monitor'
import
{
inputMaxLength
}
from
'@/utils/mappingData'
export
default
{
components
:
{
...
...
@@ -114,6 +115,7 @@ export default {
},
data
()
{
return
{
inputMaxLength
,
parseTime
,
parseTimeSecond
,
ruleForm
:
{
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment