From 29ec8b29f26b7d4b92cc75820ca7988d464c0185 Mon Sep 17 00:00:00 2001 From: 黄千龙 <huangqianlong@prec-tech.com> Date: 星期二, 29 三月 2022 13:39:07 +0800 Subject: [PATCH] Merge branch 'master' of http://47.92.229.245:8089/r/OlyMEBG --- force-app/main/default/pages/UploadPdf.page | 14 ++++++++------ 1 files changed, 8 insertions(+), 6 deletions(-) diff --git a/force-app/main/default/pages/UploadPdf.page b/force-app/main/default/pages/UploadPdf.page index 0d2702d..6759466 100644 --- a/force-app/main/default/pages/UploadPdf.page +++ b/force-app/main/default/pages/UploadPdf.page @@ -23,7 +23,6 @@ var fileObject = document.getElementById("page:theForm:block:uploadSection:file"); var reader = new FileReader(); var data = reader.readAsDataURL(fileObject.files[0]); - debugger console.log(event); } function getBase64(file) { @@ -79,7 +78,10 @@ "sfRecordId":"", "isSuccess":isSuccess }), function(result){ - window.location.reload(); + console.log("confirmTrans-" + JSON.stringify(data)); + document.getElementById("file").files[0].name = ''; + enableButtonStatus(); + refreshFiles(); }, staticResources.token); } @@ -89,7 +91,7 @@ } } function uploadFileToAWS(data, size, fileName) { - debugger + console.log("body=" + JSON.stringify({ 'file': data, "size": size, 'fileName': fileName })); AWSService.post(uploadUrl, JSON.stringify({ 'file': data, @@ -118,11 +120,11 @@ confirmTrans(result.txId, 1); } - // window.location.reload(); + window.location.reload(); }, { escape: true } ); - debugger + console.log('key' + key); } else { alertErrorMessage('涓婁紶澶辫触璇风◢鍚庡啀璇曪紒'); @@ -196,7 +198,7 @@ } </style> <apex:form id="theForm"> - <apex:actionFunction name="refreshFiles" action="{!refreshFiles}" reRender="pdf,uploadSection"/> + <apex:actionFunction name="refreshFiles" action="{!refreshFiles}" reRender="pdf,theForm"/> <br/> <br/> <apex:pageBlock id="block"> -- Gitblit v1.9.1