流程阅览打包下载提交
This commit is contained in:
parent
35ff9079dc
commit
4fda6295e0
@ -1171,8 +1171,9 @@ public class CoEPALController {
|
|||||||
@Mapping("com.actionsoft.apps.coe.pal_outputreport_output_downloadZipfile")
|
@Mapping("com.actionsoft.apps.coe.pal_outputreport_output_downloadZipfile")
|
||||||
public String COEPALOUTPUTREPORTOutputProcessDownloadZipFILE(UserContext me, RequestParams params) throws Exception {
|
public String COEPALOUTPUTREPORTOutputProcessDownloadZipFILE(UserContext me, RequestParams params) throws Exception {
|
||||||
UpfileWeb web = new UpfileWeb(me);
|
UpfileWeb web = new UpfileWeb(me);
|
||||||
String uuid = params.get("splitId");
|
String splitId = params.get("splitId");
|
||||||
return web.readZipFileDownLoad(uuid);
|
String toolbarname=params.get("toolbarname");
|
||||||
|
return web.readZipFileDownLoad(splitId,toolbarname);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -415,7 +415,7 @@ public class UpfileWeb extends ActionWeb {
|
|||||||
* @return
|
* @return
|
||||||
* @author zhaolei
|
* @author zhaolei
|
||||||
*/
|
*/
|
||||||
public String readZipFileDownLoad(String downloadZipFile) throws Exception {
|
public String readZipFileDownLoad(String splitId,String toolbarname) throws Exception {
|
||||||
UserContext me = super.getContext();
|
UserContext me = super.getContext();
|
||||||
ResponseObject ro = ResponseObject.newOkResponse();
|
ResponseObject ro = ResponseObject.newOkResponse();
|
||||||
UpFileDao upfileDao = new UpFileDao();
|
UpFileDao upfileDao = new UpFileDao();
|
||||||
@ -423,16 +423,15 @@ public class UpfileWeb extends ActionWeb {
|
|||||||
try {
|
try {
|
||||||
|
|
||||||
long times = System.currentTimeMillis();
|
long times = System.currentTimeMillis();
|
||||||
final String zipName = "批量下载"+ times + ".zip";
|
final String zipName = "批量下载"+ toolbarname + ".zip";
|
||||||
String targetDir = AWSServerConf.getProperty("dc.path") + File.separator + "com.actionsoft.apps.coe.pal" + File.separator + "tmp/grouppackage/zip" + times + "/";
|
String targetDir = AWSServerConf.getProperty("dc.path") + File.separator + "com.actionsoft.apps.coe.pal" + File.separator + "tmp/grouppackage/zip" + times + "/";
|
||||||
File targetFileDir = new File(targetDir);
|
File targetFileDir = new File(targetDir);
|
||||||
if (!targetFileDir.exists()) {
|
if (!targetFileDir.exists()) {
|
||||||
targetFileDir.mkdirs();
|
targetFileDir.mkdirs();
|
||||||
}
|
}
|
||||||
|
|
||||||
String uuids="287f7d3c-7034-4e88-a92c-8564ed041970,c42b7c14-b614-492c-a37d-e045ce86705a,0bef45da-a6d8-43c2-96e3-6476f62bb143";
|
|
||||||
// 查找对应应用下模版
|
// 查找对应应用下模版
|
||||||
String[] uuidSpilt=uuids.split(",");
|
String[] uuidSpilt=splitId.split(",");
|
||||||
if(uuidSpilt.length>0){
|
if(uuidSpilt.length>0){
|
||||||
for(String oneuuid:uuidSpilt){
|
for(String oneuuid:uuidSpilt){
|
||||||
UpfileModel upfileModel = upfileDao.get(oneuuid);
|
UpfileModel upfileModel = upfileDao.get(oneuuid);
|
||||||
|
|||||||
@ -891,7 +891,7 @@
|
|||||||
<canvas id="support_canvas" style="display: none;"></canvas>
|
<canvas id="support_canvas" style="display: none;"></canvas>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<span class="newadd_title"><#toolbarName></span>
|
<span class="newadd_title" id="toolbarname"><#toolbarName></span>
|
||||||
</div>
|
</div>
|
||||||
<div class="newadd_card">
|
<div class="newadd_card">
|
||||||
<div class="title"><span></span></div>
|
<div class="title"><span></span></div>
|
||||||
|
|||||||
@ -1651,13 +1651,14 @@ function downloadProcessFile(taskId) {
|
|||||||
* 相关文件/制度文件下载
|
* 相关文件/制度文件下载
|
||||||
* @param uuid
|
* @param uuid
|
||||||
*/
|
*/
|
||||||
function downloadZipFile(splitId) {
|
function downloadZipFile(splitId,toolbarname) {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type : "POST",
|
type : "POST",
|
||||||
url : "./jd?sid=" + sid
|
url : "./jd?sid=" + sid
|
||||||
+ "&cmd=com.actionsoft.apps.coe.pal_outputreport_output_downloadZipfile",
|
+ "&cmd=com.actionsoft.apps.coe.pal_outputreport_output_downloadZipfile",
|
||||||
data : {
|
data : {
|
||||||
splitId : splitId
|
splitId : splitId,
|
||||||
|
toolbarname:toolbarname
|
||||||
},
|
},
|
||||||
success : function(msg) {
|
success : function(msg) {
|
||||||
if (msg.result == "ok") {
|
if (msg.result == "ok") {
|
||||||
@ -1722,9 +1723,10 @@ function initUpfileData(obj) {
|
|||||||
|
|
||||||
t += '</table>';
|
t += '</table>';
|
||||||
|
|
||||||
|
var toolbarname=$("#toolbarname").text();
|
||||||
if(splitId.length>0){
|
if(splitId.length>0){
|
||||||
splitId=splitId.substring(0,splitId.length-1);
|
splitId=splitId.substring(0,splitId.length-1);
|
||||||
t +='<button id="ProcessManual" type="button" onclick="downloadZipFile(\''+splitId+'\')" class="awsui-btn awsui-btn-blue">';
|
t +='<button id="ProcessManual" type="button" onclick="downloadZipFile(\''+splitId+'\',\''+toolbarname+'\')" class="awsui-btn awsui-btn-blue">';
|
||||||
t +='打包下载';
|
t +='打包下载';
|
||||||
t +='</button>';
|
t +='</button>';
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user