Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
NLT-e-cigarette
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
张伯涛
NLT-e-cigarette
Commits
c7104966
Commit
c7104966
authored
Feb 07, 2023
by
杨硕
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加导出按钮
parent
0e5b576a
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
105 additions
and
4 deletions
+105
-4
workOrder.vue
src/views/ProductionProcess/workOrder.vue
+33
-0
homePageTable.vue
src/views/homePageTable.vue
+1
-1
assembling.vue
src/views/productTraceability/assembling.vue
+34
-0
packing.vue
src/views/productTraceability/packing.vue
+37
-3
No files found.
src/views/ProductionProcess/workOrder.vue
View file @
c7104966
...
@@ -710,6 +710,14 @@
...
@@ -710,6 +710,14 @@
<el-button
class=
"resetBtn"
size=
"small"
@
click=
"resetPosition"
>
重置 Reset
</el-button>
<el-button
class=
"resetBtn"
size=
"small"
@
click=
"resetPosition"
>
重置 Reset
</el-button>
</el-form-item>
</el-form-item>
</div>
</div>
<div
style=
"float: right;position: relative;bottom: 10px"
>
<el-button
class=
"redBtn"
type=
"danger"
size=
"small"
@
click=
"handleExport1"
>
导出 Export
</el-button>
</div>
<div
style=
"margin-left: 10px; font-size: 16px;"
>
<div
style=
"margin-left: 10px; font-size: 16px;"
>
SN编码信息列表
SN编码信息列表
</div>
</div>
...
@@ -1259,6 +1267,7 @@ import { formAssembling, getSnsVague, queryBatch, queryTestInfo } from '@/api/as
...
@@ -1259,6 +1267,7 @@ import { formAssembling, getSnsVague, queryBatch, queryTestInfo } from '@/api/as
import
{
listRepairRecordDetails
}
from
'@/api/repairRecord'
import
{
listRepairRecordDetails
}
from
'@/api/repairRecord'
import
{
getDicts
}
from
'@/api/system/dict/data'
import
{
getDicts
}
from
'@/api/system/dict/data'
import
Data
from
"@/views/system/dict/data"
;
import
Data
from
"@/views/system/dict/data"
;
import
{
homePageExport
}
from
'@/api/system/monitoring'
export
default
{
export
default
{
name
:
'WorkOrder'
,
name
:
'WorkOrder'
,
...
@@ -1534,6 +1543,30 @@ export default {
...
@@ -1534,6 +1543,30 @@ export default {
})
})
})
})
},
},
/** SN编码信息表单导出按钮 **/
handleExport1
()
{
const
queryParams
=
this
.
qtyParams
const
newDate
=
moment
(
new
Date
().
getTime
()).
format
(
'YYYYMMDD'
)
// 弹出提示框
this
.
$confirm
(
'是否确认导出所有SN编码信息?'
,
'提示'
,
{
confirmButtonText
:
'确定 Confirm'
,
cancelButtonText
:
'取消 Cancel'
,
cancelButtonClass
:
'btn-custom-cancel'
,
type
:
'warning'
}).
then
(
function
()
{
return
homePageExport
(
queryParams
).
then
(
response
=>
{
const
blob
=
new
Blob
([
response
])
const
downloadElement
=
document
.
createElement
(
'a'
)
// 创建a标签
const
href
=
window
.
URL
.
createObjectURL
(
blob
)
// 创建下载的链接
downloadElement
.
href
=
href
// 点击a标签,进行下载
downloadElement
.
download
=
'SN编码信息导出'
+
newDate
+
'.xls'
// 下载后文件名
document
.
body
.
appendChild
(
downloadElement
)
// 向body添加a标签
downloadElement
.
click
()
// 点击下载
document
.
body
.
removeChild
(
downloadElement
)
// 下载完成移除a标签
window
.
URL
.
revokeObjectURL
(
href
)
// 释放掉blob对象
})
})
},
handleSizeChange1
(
val
)
{
handleSizeChange1
(
val
)
{
this
.
currentPage1
=
1
this
.
currentPage1
=
1
this
.
pageSize1
=
val
this
.
pageSize1
=
val
...
...
src/views/homePageTable.vue
View file @
c7104966
...
@@ -89,7 +89,7 @@
...
@@ -89,7 +89,7 @@
<el-button
class=
"resetBtn"
size=
"small"
@
click=
"resetPosition"
>
重置 Reset
</el-button>
<el-button
class=
"resetBtn"
size=
"small"
@
click=
"resetPosition"
>
重置 Reset
</el-button>
</el-form-item>
</el-form-item>
</div>
</div>
<div
v-if=
"btnShow"
style=
"float: right;position: relative;bottom: 10px"
>
<div
style=
"float: right;position: relative;bottom: 10px"
>
<el-button
<el-button
class=
"redBtn"
class=
"redBtn"
type=
"danger"
type=
"danger"
...
...
src/views/productTraceability/assembling.vue
View file @
c7104966
...
@@ -1030,6 +1030,14 @@
...
@@ -1030,6 +1030,14 @@
<el-button
class=
"resetBtn"
size=
"small"
@
click=
"resetPosition"
>
重置 Reset
</el-button>
<el-button
class=
"resetBtn"
size=
"small"
@
click=
"resetPosition"
>
重置 Reset
</el-button>
</el-form-item>
</el-form-item>
</div>
</div>
<div
style=
"float: right;position: relative;bottom: 10px"
>
<el-button
class=
"redBtn"
type=
"danger"
size=
"small"
@
click=
"handleExport1"
>
导出 Export
</el-button>
</div>
<div
style=
"margin-left: 10px; font-size: 16px;"
>
<div
style=
"margin-left: 10px; font-size: 16px;"
>
SN编码信息列表
SN编码信息列表
</div>
</div>
...
@@ -1167,6 +1175,8 @@ import { formAssembling, queryBatch, queryDeviceAss, queryTestInfo, exportLineNo
...
@@ -1167,6 +1175,8 @@ import { formAssembling, queryBatch, queryDeviceAss, queryTestInfo, exportLineNo
import
{
getOrder
,
listOrderLine
,
listOrderMater
,
listStation
}
from
'@/api/workOrder'
import
{
getOrder
,
listOrderLine
,
listOrderMater
,
listStation
}
from
'@/api/workOrder'
import
{
listRepairRecordDetails
}
from
'@/api/repairRecord'
import
{
listRepairRecordDetails
}
from
'@/api/repairRecord'
import
{
getDicts
}
from
'@/api/system/dict/data'
import
{
getDicts
}
from
'@/api/system/dict/data'
import
moment
from
'moment/moment'
import
{
homePageExport
}
from
'@/api/system/monitoring'
export
default
{
export
default
{
name
:
'Assembling'
,
name
:
'Assembling'
,
...
@@ -1437,6 +1447,30 @@ export default {
...
@@ -1437,6 +1447,30 @@ export default {
})
})
})
})
},
},
/** SN编码信息表单导出按钮 **/
handleExport1
()
{
const
queryParams
=
this
.
qtyParams
const
newDate
=
moment
(
new
Date
().
getTime
()).
format
(
'YYYYMMDD'
)
// 弹出提示框
this
.
$confirm
(
'是否确认导出所有SN编码信息?'
,
'提示'
,
{
confirmButtonText
:
'确定 Confirm'
,
cancelButtonText
:
'取消 Cancel'
,
cancelButtonClass
:
'btn-custom-cancel'
,
type
:
'warning'
}).
then
(
function
()
{
return
homePageExport
(
queryParams
).
then
(
response
=>
{
const
blob
=
new
Blob
([
response
])
const
downloadElement
=
document
.
createElement
(
'a'
)
// 创建a标签
const
href
=
window
.
URL
.
createObjectURL
(
blob
)
// 创建下载的链接
downloadElement
.
href
=
href
// 点击a标签,进行下载
downloadElement
.
download
=
'SN编码信息导出'
+
newDate
+
'.xls'
// 下载后文件名
document
.
body
.
appendChild
(
downloadElement
)
// 向body添加a标签
downloadElement
.
click
()
// 点击下载
document
.
body
.
removeChild
(
downloadElement
)
// 下载完成移除a标签
window
.
URL
.
revokeObjectURL
(
href
)
// 释放掉blob对象
})
})
},
/**
/**
* 查询按钮方法
* 查询按钮方法
*/
*/
...
...
src/views/productTraceability/packing.vue
View file @
c7104966
...
@@ -508,6 +508,14 @@
...
@@ -508,6 +508,14 @@
<el-button
class=
"resetBtn"
size=
"small"
@
click=
"resetPosition"
>
重置 Reset
</el-button>
<el-button
class=
"resetBtn"
size=
"small"
@
click=
"resetPosition"
>
重置 Reset
</el-button>
</el-form-item>
</el-form-item>
</div>
</div>
<div
style=
"float: right;position: relative;bottom: 10px"
>
<el-button
class=
"redBtn"
type=
"danger"
size=
"small"
@
click=
"handleExport1"
>
导出 Export
</el-button>
</div>
<div
style=
"margin-left: 10px; font-size: 16px;"
>
<div
style=
"margin-left: 10px; font-size: 16px;"
>
SN编码信息列表
SN编码信息列表
</div>
</div>
...
@@ -937,9 +945,10 @@
...
@@ -937,9 +945,10 @@
<
script
>
<
script
>
import
moment
from
'moment'
import
moment
from
'moment'
import
{
exportPacking
,
listPacking
,
queryDetailDevice
}
from
'@/api/packing'
import
{
exportPacking
,
listPacking
,
queryDetailDevice
}
from
'@/api/packing'
import
{
exportLineNo
,
formAssembling
,
getSnsVague
,
queryBatch
,
queryDeviceAss
,
queryTestInfo
}
from
'@/api/assembling'
import
{
exportLineNo
,
formAssembling
,
getSnsVague
,
queryBatch
,
queryDeviceAss
,
queryTestInfo
}
from
'@/api/assembling'
import
{
listRepairRecordDetails
}
from
'@/api/repairRecord'
import
{
listRepairRecordDetails
}
from
'@/api/repairRecord'
import
{
getDicts
}
from
'@/api/system/dict/data'
import
{
getDicts
}
from
'@/api/system/dict/data'
import
{
homePageExport
}
from
'@/api/system/monitoring'
export
default
{
export
default
{
name
:
'Packing'
,
name
:
'Packing'
,
/** 路由离开前存储筛选条件*/
/** 路由离开前存储筛选条件*/
...
@@ -1007,7 +1016,8 @@ export default {
...
@@ -1007,7 +1016,8 @@ export default {
materSn
:
''
,
materSn
:
''
,
lineCode
:
''
,
lineCode
:
''
,
orderId
:
''
,
orderId
:
''
,
type
:
'package'
type
:
'package'
,
staId
:
null
},
},
QtyDialog
:
false
,
// sn编码模态框
QtyDialog
:
false
,
// sn编码模态框
SNTableList
:
[],
SNTableList
:
[],
...
@@ -1263,6 +1273,30 @@ export default {
...
@@ -1263,6 +1273,30 @@ export default {
})
})
})
})
},
},
/** SN编码信息表单导出按钮 **/
handleExport1
()
{
const
queryParams
=
this
.
qtyParams
const
newDate
=
moment
(
new
Date
().
getTime
()).
format
(
'YYYYMMDD'
)
// 弹出提示框
this
.
$confirm
(
'是否确认导出所有SN编码信息?'
,
'提示'
,
{
confirmButtonText
:
'确定 Confirm'
,
cancelButtonText
:
'取消 Cancel'
,
cancelButtonClass
:
'btn-custom-cancel'
,
type
:
'warning'
}).
then
(
function
()
{
return
homePageExport
(
queryParams
).
then
(
response
=>
{
const
blob
=
new
Blob
([
response
])
const
downloadElement
=
document
.
createElement
(
'a'
)
// 创建a标签
const
href
=
window
.
URL
.
createObjectURL
(
blob
)
// 创建下载的链接
downloadElement
.
href
=
href
// 点击a标签,进行下载
downloadElement
.
download
=
'SN编码信息导出'
+
newDate
+
'.xls'
// 下载后文件名
document
.
body
.
appendChild
(
downloadElement
)
// 向body添加a标签
downloadElement
.
click
()
// 点击下载
document
.
body
.
removeChild
(
downloadElement
)
// 下载完成移除a标签
window
.
URL
.
revokeObjectURL
(
href
)
// 释放掉blob对象
})
})
},
/**
/**
* 包装追溯号信息导出
* 包装追溯号信息导出
*/
*/
...
...
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