Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MES_PAD
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
Administrator
MES_PAD
Commits
23c316c4
Commit
23c316c4
authored
Oct 19, 2018
by
上官
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
针车实报 针车品检
parent
ecd9dc80
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
128 additions
and
88 deletions
+128
-88
Needlecarquality.html
html/Needlecarquality.html
+127
-87
Needlecarreport.html
html/Needlecarreport.html
+1
-1
No files found.
html/Needlecarquality.html
View file @
23c316c4
...
@@ -53,7 +53,7 @@
...
@@ -53,7 +53,7 @@
</tr>
</tr>
</thead>
</thead>
<tbody
class=
"mui-table-view-cell"
>
<tbody
class=
"mui-table-view-cell"
>
<tr
:id=
"'ReportID_'+item.ReportID"
class=
"Report"
v-for=
" item in itemsLeft"
@
tap=
"selectReport(item)"
>
<tr
:id=
"'ReportID_'+item.ReportID"
class=
"Report"
v-for=
" item in itemsLeft"
@
tap=
"selectReport(item
.ReportID
)"
>
<td
align=
"center"
>
{{item.Date}}
</td>
<td
align=
"center"
>
{{item.Date}}
</td>
<td
align=
"center"
>
{{item.IndexNo}}
</td>
<td
align=
"center"
>
{{item.IndexNo}}
</td>
<td
align=
"center"
>
{{item.Qty}}
</td>
<td
align=
"center"
>
{{item.Qty}}
</td>
...
@@ -99,7 +99,7 @@
...
@@ -99,7 +99,7 @@
</div>
</div>
<div
style=
" display: inline-block; width: 17%; position: relative;top: -25px;"
>
<div
style=
" display: inline-block; width: 17%; position: relative;top: -25px;"
>
<button
type=
"button"
class=
"mui-btn mui-btn-blue mui-btn-block"
:disabled=
"disable_reportDelete"
@
tap=
"reportDelete()"
>
撤回品检
</button>
<button
type=
"button"
class=
"mui-btn mui-btn-blue mui-btn-block"
:disabled=
"disable_reportDelete"
@
tap=
"reportDelete()"
>
撤回品检
</button>
<button
type=
"button"
class=
"mui-btn mui-btn-blue mui-btn-block"
:disabled=
"disable_qq"
@
tap=
"back"
>
返回时报
</button>
<button
type=
"button"
class=
"mui-btn mui-btn-blue mui-btn-block"
@
tap=
"back"
>
返回时报
</button>
</div>
</div>
</div>
</div>
...
@@ -153,9 +153,13 @@
...
@@ -153,9 +153,13 @@
</div>
</div>
<div
style=
" display: inline-block; position: absolute;bottom: 10px; width: 12%; right: 15px;"
>
<div
id=
"right-5"
style=
" border: solid,red,3px; position: absolute; bottom: 0px;"
>
<button
type=
"button"
class=
"mui-btn mui-btn-blue mui-btn-block"
:disabled=
"disable_save_button"
@
tap=
"submit"
>
提交
</button>
<button
id=
"ProcessingType_1"
type=
"button"
class=
"mui-btn mui-btn-blue mui-btn-outlined"
style=
"height:50px;width: 100px ;"
@
tap =
"selectProcessingType(1)"
>
返修
</button>
</div>
<button
id=
"ProcessingType_2"
type=
"button"
class=
"mui-btn mui-btn-blue mui-btn-outlined"
style=
"height:50px;width: 100px ;"
@
tap =
"selectProcessingType(2)"
>
报废
</button>
</div>
<button
type=
"button"
class=
"mui-btn mui-btn-blue mui-btn-block"
style=
"position: absolute; right: 0px; bottom: 0px;margin-bottom: 0px; width: 120px; "
:disabled=
"disable_save_button2"
@
tap=
"submit"
>
提交
</button>
</div>
</div>
</div>
</div>
...
@@ -200,10 +204,21 @@
...
@@ -200,10 +204,21 @@
IndexID
:
0
,
IndexID
:
0
,
disable_save_button
:
'disabled'
,
disable_save_button
:
'disabled'
,
disable_reportDelete
:
'disabled'
,
disable_reportDelete
:
'disabled'
,
disable_qq
:
'disabled'
,
ProcessingType
:
0
,
ReportID
:
0
ReportID
:
0
,
Model
:
0
,
//0 可以提交 1 不可以提交
},
computed
:
{
disable_save_button2
:
function
()
{
if
(
this
.
qty
!=
0
&&
this
.
size
!=
0
&&
this
.
qualityID
!=
0
&&
this
.
ProcessingType
!=
0
&&
this
.
Model
==
0
){
return
null
;
}
else
{
return
'disabled'
;
}
}
},
},
methods
:
{
methods
:
{
init
:
function
()
{
init
:
function
()
{
mui
.
init
();
mui
.
init
();
...
@@ -319,6 +334,36 @@
...
@@ -319,6 +334,36 @@
});
});
},
getReportDetail
:
function
(){
var
that
=
this
;
var
para
=
{
ReportID
:
this
.
ReportID
};
// console.log(JSON.stringify(para));
Api
.
post
(
'/api/vMES/InspectionReport/ReportDetail'
,
para
,
function
(
e
)
{
console
.
log
(
"getReportDetail"
+
JSON
.
stringify
(
e
));
if
(
e
.
success
){
that
.
ReportID
=
e
.
data
.
ReportID
;
that
.
itemsDetail
=
e
.
data
;
that
.
itemsSize
=
e
.
data
.
SizeName
;
that
.
qualityID
=
e
.
data
.
QIDetailID
;
that
.
ProcessingType
=
e
.
data
.
ProcessingType
;
that
.
size
=
e
.
data
.
UnQualifiedSizeName
;
that
.
qty
=
e
.
data
.
UnQualifiedQty
;
that
.
Model
=
1
;
that
.
selectQQ
(
that
.
qualityID
);
that
.
selectSize
(
that
.
size
);
that
.
selectProcessingType
(
that
.
ProcessingType
);
}
});
},
},
reportDelete
:
function
()
{
reportDelete
:
function
()
{
var
that
=
this
;
var
that
=
this
;
...
@@ -326,20 +371,25 @@
...
@@ -326,20 +371,25 @@
ReportID
:
this
.
ReportID
,
ReportID
:
this
.
ReportID
,
};
};
// console.log(JSON.stringify(para));
// console.log(JSON.stringify(para));
Api
.
post
(
'/api/vMES/
Produ
ctionReport/Delete'
,
para
,
function
(
e
)
{
Api
.
post
(
'/api/vMES/
Inspe
ctionReport/Delete'
,
para
,
function
(
e
)
{
if
(
e
.
success
){
if
(
e
.
success
){
that
.
disable_reportDelete
=
'disabled'
that
.
disable_reportDelete
=
'disabled'
that
.
size
=
0
;
that
.
size
=
0
;
that
.
qty
=
0
;
that
.
qty
=
0
;
that
.
selectSize
(
0
);
that
.
selectSize
(
0
);
that
.
qualityID
=
0
;
that
.
getDataDetail1
();
//获取列表尺码对应数量
that
.
selectQQ
(
0
);
that
.
selectReport
(
0
);
that
.
selectProcessingType
(
0
);
//that.getDataDetail1(); //获取列表尺码对应数量
that
.
getTatolNum
();
//获取今日完成数量
that
.
getTatolNum
();
//获取今日完成数量
that
.
getDataDetail2
();
//获取左边列表明细
that
.
getDataDetail2
();
//获取左边列表明细
that
.
Model
=
0
;
mui
.
toast
(
"撤回成功"
)
mui
.
toast
(
"撤回成功"
)
}
}
else
{
else
{
mui
.
toast
(
"撤回失败"
+
+
e
.
success
.
message
)
mui
.
toast
(
"撤回失败"
+
e
.
success
.
message
)
}
}
});
});
...
@@ -366,19 +416,24 @@
...
@@ -366,19 +416,24 @@
IndexID
:
this
.
IndexID
,
IndexID
:
this
.
IndexID
,
SizeName
:
this
.
size
,
SizeName
:
this
.
size
,
Qty
:
this
.
qty
,
Qty
:
this
.
qty
,
ProcessingType
:
this
.
ProcessingType
,
QIDetailID
:
this
.
qualityID
,
}
}
console
.
log
(
JSON
.
stringify
(
para
))
console
.
log
(
JSON
.
stringify
(
para
))
var
that
=
this
;
var
that
=
this
;
Api
.
post
(
'/api/vMES/
Produ
ctionReport/Save'
,
para
,
function
(
e
)
{
Api
.
post
(
'/api/vMES/
Inspe
ctionReport/Save'
,
para
,
function
(
e
)
{
if
(
e
.
success
)
{
if
(
e
.
success
)
{
that
.
disable_save_button
=
'disabled'
that
.
disable_save_button
=
'disabled'
that
.
size
=
0
;
that
.
size
=
0
;
that
.
qty
=
0
;
that
.
qty
=
0
;
that
.
ProcessingType
=
0
;
that
.
qualityID
=
0
;
that
.
selectQQ
(
0
);
that
.
selectProcessingType
(
0
);
that
.
selectSize
(
0
);
that
.
selectSize
(
0
);
that
.
selectReport
(
0
);
that
.
getDataDetail1
();
//获取列表尺码对应数量
//
that.getDataDetail1(); //获取列表尺码对应数量
that
.
getTatolNum
();
//获取今日完成数量
that
.
getTatolNum
();
//获取今日完成数量
that
.
getDataDetail2
();
//获取左边列表明细
that
.
getDataDetail2
();
//获取左边列表明细
...
@@ -388,11 +443,32 @@
...
@@ -388,11 +443,32 @@
}
}
});
});
},
},
displayReport
:
function
(){
this
.
getReportDetail
();
},
selectProcessingType
:
function
(
n
){
var
fx
=
document
.
getElementById
(
"ProcessingType_1"
);
var
bf
=
document
.
getElementById
(
"ProcessingType_2"
);
if
(
n
==
1
){
fx
.
style
.
background
=
"#02C1ED"
;
bf
.
style
.
background
=
""
}
if
(
n
==
2
){
fx
.
style
.
background
=
""
;
bf
.
style
.
background
=
"#02C1ED"
;
}
else
if
(
n
==
0
){
fx
.
style
.
background
=
""
;
bf
.
style
.
background
=
""
;
}
this
.
ProcessingType
=
n
;
},
selectQQ
:
function
(
qq
){
selectQQ
:
function
(
qq
){
var
op
=
document
.
getElementById
(
"Quality_"
+
qq
)
var
op
=
document
.
getElementById
(
"Quality_"
+
qq
)
this
.
qualityID
=
qq
;
this
.
qualityID
=
qq
;
if
(
this
.
qty
!=
0
&&
this
.
size
!=
0
&&
this
.
qualityID
!=
0
)
{
if
(
this
.
qty
!=
0
&&
this
.
size
!=
0
&&
this
.
qualityID
!=
0
&&
this
.
ProcessingType
!=
0
)
{
this
.
disable_save_button
=
null
;
this
.
disable_save_button
=
null
;
}
}
var
reportele
=
document
.
getElementsByClassName
(
"Quality"
);
var
reportele
=
document
.
getElementsByClassName
(
"Quality"
);
...
@@ -401,7 +477,8 @@
...
@@ -401,7 +477,8 @@
reportele
[
i
].
style
.
background
=
""
reportele
[
i
].
style
.
background
=
""
}
}
op
.
style
.
background
=
"#02C1ED"
;
if
(
qq
!=
0
){
op
.
style
.
background
=
"#02C1ED"
;}
},
},
selectIndex
:
function
(
idx
){
selectIndex
:
function
(
idx
){
this
.
IndexID
=
idx
this
.
IndexID
=
idx
...
@@ -430,9 +507,12 @@
...
@@ -430,9 +507,12 @@
},
},
selectReport
:
function
(
obj
)
{
selectReport
:
function
(
obj
)
{
var
op
=
document
.
getElementById
(
"ReportID_"
+
obj
.
ReportID
)
var
op
=
document
.
getElementById
(
"ReportID_"
+
obj
)
this
.
ReportID
=
obj
.
ReportID
;
this
.
ReportID
=
obj
;
if
(
this
.
ReportID
!=
0
)
{
if
(
this
.
ReportID
!=
0
)
{
this
.
disable_reportDelete
=
null
;
this
.
disable_reportDelete
=
null
;
}
}
...
@@ -441,7 +521,11 @@
...
@@ -441,7 +521,11 @@
for
(
var
i
=
0
;
i
<
reportele
.
length
;
i
++
)
{
for
(
var
i
=
0
;
i
<
reportele
.
length
;
i
++
)
{
reportele
[
i
].
style
.
background
=
""
reportele
[
i
].
style
.
background
=
""
}
}
op
.
style
.
background
=
"#02C1ED"
;
if
(
obj
!=
0
){
op
.
style
.
background
=
"#02C1ED"
;
}
this
.
displayReport
();
},
},
changeValue
:
function
()
{
changeValue
:
function
()
{
...
@@ -470,8 +554,15 @@
...
@@ -470,8 +554,15 @@
}
else
if
(
this
.
IndexID
==
0
)
{
}
else
if
(
this
.
IndexID
==
0
)
{
mui
.
toast
(
"订单号不正确"
)
mui
.
toast
(
"订单号不正确"
)
return
false
;
return
false
;
}
else
{
}
else
if
(
this
.
qualityID
==
0
){
console
.
log
(
this
.
size
);
mui
.
toast
(
"请选择品检项目"
)
return
false
;
}
else
if
(
this
.
ProcessingType
==
0
){
mui
.
toast
(
"请选择处理类型"
)
return
false
;
}
else
{
return
true
;
return
true
;
}
}
},
},
...
@@ -490,78 +581,27 @@
...
@@ -490,78 +581,27 @@
}
}
}
}
if
(
n
==
0
){
//
if(n==0){
//
bg
[
0
].
style
.
background
=
"#02C1ED"
//
bg[0].style.background = "#02C1ED"
}
//
}
this
.
size
=
n
;
this
.
size
=
n
;
},
},
stylebg
:
function
(
n
)
{
stylebg
:
function
(
n
)
{
if
(
n
==
0
)
{
//
if (n == 0) {
return
{
//
return {
"background"
:
"#02C1ED"
//
"background": "#02C1ED"
//
}
//
}
}
//
}
},
},
SelectDate
:
function
()
{
console
.
log
(
this
.
dateTime
)
},
selecttime
:
function
()
{
var
that
=
this
;
var
_self
=
document
.
getElementById
(
"selectdate"
)
if
(
_self
.
picker
)
{
_self
.
picker
.
show
(
function
(
rs
)
{
_self
.
innerText
=
rs
.
text
_self
.
picker
.
dispose
();
_self
.
picker
=
null
;
});
}
else
{
var
optionsJson
=
_self
.
getAttribute
(
'data-options'
)
||
'{}'
;
var
options
=
JSON
.
parse
(
optionsJson
);
var
id
=
_self
.
getAttribute
(
'id'
);
/*
* 首次显示时实例化组件
* 示例为了简洁,将 options 放在了按钮的 dom 上
* 也可以直接通过代码声明 optinos 用于实例化 DtPicker
*/
_self
.
picker
=
new
mui
.
DtPicker
(
options
);
_self
.
picker
.
show
(
function
(
rs
)
{
/*
* rs.value 拼合后的 value
* rs.text 拼合后的 text
* rs.y 年,可以通过 rs.y.vaue 和 rs.y.text 获取值和文本
* rs.m 月,用法同年
* rs.d 日,用法同年
* rs.h 时,用法同年
* rs.i 分(minutes 的第二个字母),用法同年
*/
_self
.
innerText
=
rs
.
text
that
.
dateTime
=
rs
.
text
;
that
.
getData
();
/*
* 返回 false 可以阻止选择框的关闭
* return false;
*/
/*
* 释放组件资源,释放后将将不能再操作组件
* 通常情况下,不需要示放组件,new DtPicker(options) 后,可以一直使用。
* 当前示例,因为内容较多,如不进行资原释放,在某些设备上会较慢。
* 所以每次用完便立即调用 dispose 进行释放,下次用时再创建新实例。
*/
_self
.
picker
.
dispose
();
_self
.
picker
=
null
;
});
}
},
//selecttime
back
:
function
()
{
back
:
function
()
{
console
.
log
(
"back"
);
mui
.
back
(
);
// plus.screen.lockOrientation("portrait-primary") //横屏
// plus.screen.lockOrientation("portrait-primary") //横屏
}
}
}
}
...
...
html/Needlecarreport.html
View file @
23c316c4
...
@@ -371,7 +371,7 @@
...
@@ -371,7 +371,7 @@
mui
.
toast
(
"撤回成功"
)
mui
.
toast
(
"撤回成功"
)
}
}
else
{
else
{
mui
.
toast
(
"撤回失败"
+
+
e
.
success
.
message
)
mui
.
toast
(
"撤回失败"
+
e
.
success
.
message
)
}
}
});
});
...
...
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