Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
template_vue
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
胡宝山
template_vue
Commits
5b6f4b04
Commit
5b6f4b04
authored
Aug 02, 2023
by
吴志坤
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/project1' into project1
parents
09a900cb
e1634e19
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
19 deletions
+14
-19
income.vue
src/views/equipment/income.vue
+14
-19
No files found.
src/views/equipment/income.vue
View file @
5b6f4b04
...
...
@@ -17,7 +17,7 @@
<el-row
:gutter=
"40"
style=
"padding-left: 8.6%;"
>
<el-col
:span=
"12"
>
<el-form-item
label=
"厚度:"
style=
"flex-basis: 50%;"
prop=
"phd"
>
<el-input
ref=
"input3"
v-model=
"form.phd"
placeholder=
"请输入厚度"
:style=
"
{ width: '400px', height: '30px' }" :maxlength="10
0
" @keyup.enter.native="handelTab(3,$event)" />
<el-input
ref=
"input3"
v-model=
"form.phd"
placeholder=
"请输入厚度"
:style=
"
{ width: '400px', height: '30px' }" :maxlength="10" @keyup.enter.native="handelTab(3,$event)" />
</el-form-item>
</el-col>
<el-col
:span=
"12"
>
...
...
@@ -27,7 +27,7 @@
</el-col>
</el-row>
</el-form>
<el-table
border
:data=
"tableData"
style=
"width:
1250px; padding-left: 8
.6%;"
>
<el-table
border
:data=
"tableData"
style=
"width:
86.4%; padding-left: 13
.6%;"
>
<el-table-column
type=
"index"
label=
"序号"
width=
"50px"
/>
<el-table-column
label=
"pn"
prop=
"businessId"
>
<template
slot-scope=
"scope"
>
...
...
@@ -106,17 +106,17 @@ export default {
rule
:
{
pn
:
[
{
required
:
true
,
message
:
'请输入pn'
,
trigger
:
'blur'
},
{
max
:
100
,
message
:
'输入长度不能超过100个字符'
,
trigger
:
'
blur
'
}
{
max
:
100
,
message
:
'输入长度不能超过100个字符'
,
trigger
:
'
change
'
}
],
lot
:
[
{
required
:
true
,
message
:
'请输入lot'
,
trigger
:
'blur'
},
{
max
:
100
,
message
:
'输入长度不能超过100个字符'
,
trigger
:
'
blur
'
}
{
max
:
100
,
message
:
'输入长度不能超过100个字符'
,
trigger
:
'
change
'
}
],
plocation
:
[
{
required
:
true
,
message
:
'请输入位置'
,
trigger
:
'blur'
},
{
max
:
100
,
message
:
'输入长度不能超过100个字符'
,
trigger
:
'
blur
'
}
{
max
:
100
,
message
:
'输入长度不能超过100个字符'
,
trigger
:
'
change
'
}
],
phd
:
[{
pattern
:
/^
\d
+$/
,
message
:
'仅能输入
数字
'
,
trigger
:
'change'
}]
phd
:
[{
pattern
:
/^
\d
+$/
,
message
:
'仅能输入
整数
'
,
trigger
:
'change'
}]
}
}
},
...
...
@@ -217,7 +217,6 @@ export default {
this
.
form
.
pn
=
''
this
.
form
.
lot
=
''
this
.
form
.
phd
=
''
this
.
form
.
plocation
=
''
this
.
form
.
index
=
undefined
}
}
...
...
@@ -259,9 +258,6 @@ export default {
// 提交时要调的接口
submitForm
()
{
const
{
pn
,
lot
,
phd
,
plocation
}
=
this
.
form
if
(
this
.
tableData
.
length
===
0
)
{
...
...
@@ -274,9 +270,6 @@ export default {
type
:
'warning'
}).
then
(()
=>
{
const
newRow
=
{
pn
,
lot
,
phd
,
plocation
}
this
.
$refs
.
form
.
validate
((
valid
)
=>
{
...
...
@@ -289,17 +282,19 @@ export default {
if
(
res
.
code
===
200
)
{
this
.
open
=
false
this
.
$message
.
success
(
'操作成功'
)
this
.
tableData
.
push
(
newRow
)
// 清空输入框
this
.
form
.
pn
=
''
this
.
form
.
lot
=
''
this
.
form
.
phd
=
''
this
.
from
.
plocation
=
''
this
.
tableData
=
[]
this
.
form
.
plocation
=
''
}
else
if
(
res
.
code
===
null
)
{
this
.
$message
.
error
(
res
.
message
)
this
.
tableData
=
[]
this
.
form
.
plocation
=
''
}
})
}
else
{
this
.
tableData
=
[]
this
.
tableData
.
push
(
newRow
)
// 清空输入框
this
.
from
.
plocation
=
''
// 校验失败,显示错误信息或进行其他操作
}
})
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment