Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
soss
Overview
Overview
Details
Activity
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
hooloo
web
soss
Commits
765429ee
Commit
765429ee
authored
2 years ago
by
lixiaomin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改原料
parent
14294dff
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
11 deletions
+23
-11
src/views/machine/machineDetails/machineDetailsAttribute.vue
+16
-10
src/views/machine/machineDetails/machineDetailsCom.vue
+7
-1
No files found.
src/views/machine/machineDetails/machineDetailsAttribute.vue
View file @
765429ee
...
...
@@ -130,19 +130,25 @@ export default {
var
regular
=
/
(
^
[
+
]{0,1}([
0-9
]
+
)
$
)
/
;
let
hang
=
0
;
for
(
let
i
=
0
;
i
<
this
.
experienceList
.
length
;
i
++
){
hang
=
i
+
1
;
if
(
!
regular
.
test
(
this
.
experienceList
[
i
].
milli_second
)){
this
.
$message
.
error
(
'第'
+
hang
+
'行,秒,请输入大于0的正数'
);
return
;
}
else
{
// hang=i+1;
// if(!regular.test(this.experienceList[i].milli_second)){
// this.$message.error('第'+hang+'行,秒,请输入大于0的正数');
// return;
// }else{
// this.experienceList[i].milli_second=parseFloat(this.experienceList[i].milli_second);
// }
// if(!regular.test(this.experienceList[i].quantity)){
// this.$message.error('第'+hang+'行,克,请输入大于0的正数');
// return;
// }else{
// this.experienceList[i].quantity=parseFloat(this.experienceList[i].quantity);
// }
if
(
this
.
experienceList
[
i
].
milli_second
){
this
.
experienceList
[
i
].
milli_second
=
parseFloat
(
this
.
experienceList
[
i
].
milli_second
);
}
if
(
!
regular
.
test
(
this
.
experienceList
[
i
].
quantity
)){
this
.
$message
.
error
(
'第'
+
hang
+
'行,克,请输入大于0的正数'
);
return
;
}
else
{
if
(
this
.
experienceList
[
i
].
quantity
){
this
.
experienceList
[
i
].
quantity
=
parseFloat
(
this
.
experienceList
[
i
].
quantity
);
}
}
}
let
obj
=
{
"machine_id"
:
this
.
machine_id
,
...
...
This diff is collapsed.
Click to expand it.
src/views/machine/machineDetails/machineDetailsCom.vue
View file @
765429ee
...
...
@@ -51,7 +51,8 @@ export default {
materialList
:[],
ros_code
:
""
,
component_name
:
""
,
materialId
:
""
materialId
:
""
,
machineState
:
null
};
},
created
()
{
...
...
@@ -65,6 +66,7 @@ export default {
this
.
comDiaLog
=
true
;
this
.
machineId
=
row
.
id
;
this
.
activeName
=
"first"
;
this
.
machineState
=
row
.
state
this
.
getComponentList
();
},
getComponentList
(){
...
...
@@ -100,6 +102,10 @@ export default {
},
//提交原料
submitMaterial
(){
if
(
this
.
machineState
!=
3
&&
this
.
machineState
!=
7
){
this
.
$message
.
error
(
'只有状态为待运营测试或运维中才能修改!'
);
return
;
}
let
materialName
=
""
;
for
(
let
i
=
0
;
i
<
this
.
materialList
.
length
;
i
++
){
if
(
this
.
materialId
==
this
.
materialList
[
i
].
id
){
...
...
This diff is collapsed.
Click to expand it.
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