Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
patzn-cloud-web-h5app-drs
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
zhuxiaomei
patzn-cloud-web-h5app-drs
Commits
2c1f235c
Commit
2c1f235c
authored
Nov 07, 2020
by
zhuxiaomei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
历史抽样单的下载打印
parent
25409d87
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
0 deletions
+21
-0
SamplingList.vue
src/page/history-sampling/SamplingList.vue
+21
-0
No files found.
src/page/history-sampling/SamplingList.vue
View file @
2c1f235c
...
@@ -29,6 +29,10 @@
...
@@ -29,6 +29,10 @@
<div>
样品名称:{{item.sampleName}}
</div>
<div>
样品名称:{{item.sampleName}}
</div>
<div>
被抽样单位名称:{{item.testedName}}
</div>
<div>
被抽样单位名称:{{item.testedName}}
</div>
</div>
</div>
<
template
#
right
>
<van-button
square
type=
"primary"
text=
"打印"
class=
"swipe-cell-btn"
@
click=
"_print(item)"
></van-button>
</
template
>
</van-swipe-cell>
</van-swipe-cell>
</van-list>
</van-list>
</div>
</div>
...
@@ -126,6 +130,23 @@
...
@@ -126,6 +130,23 @@
this
.
page
=
this
.
page
+
1
;
this
.
page
=
this
.
page
+
1
;
this
.
_getData
()
this
.
_getData
()
},
},
_print
(
item
)
{
//调用第三放程序打开指定文件(必须是本地路径)
this
.
$toast
.
loading
({
message
:
'加载中...'
,
forbidClick
:
true
,
});
var
dtask
=
plus
.
downloader
.
createDownload
(
this
.
$global
.
baseURL
+
'/drs/v1/sampling_summary/export_multi_sampling?id='
+
item
.
id
,
{},
(
d
,
status
)
=>
{
if
(
status
==
200
)
{
plus
.
runtime
.
openFile
(
d
.
filename
);
//cn.wps.moffice_eng-----wps的包名
}
this
.
$toast
.
clear
();
});
dtask
.
setRequestHeader
(
'Content-Type'
,
'application/x-www-form-urlencoded'
);
dtask
.
setRequestHeader
(
'accessToken'
,
localStorage
.
getItem
(
'accessToken'
));
dtask
.
start
();
},
_goto
(
item
)
{
_goto
(
item
)
{
if
(
item
.
testedType
===
1
)
{
if
(
item
.
testedType
===
1
)
{
this
.
$router
.
push
({
path
:
'/sampling_list/sampling_list_detail_net'
,
query
:
{
id
:
item
.
id
}})
this
.
$router
.
push
({
path
:
'/sampling_list/sampling_list_detail_net'
,
query
:
{
id
:
item
.
id
}})
...
...
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