From 1afa5b031e2f13a2b93adc99d292cdeb2ba2a6dd Mon Sep 17 00:00:00 2001
From: sunty <1172534965@qq.com>
Date: 星期二, 11 二月 2020 18:30:55 +0800
Subject: [PATCH] add clearData

---
 service/SysService.go |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/service/SysService.go b/service/SysService.go
index 6108ca1..1a1f14c 100644
--- a/service/SysService.go
+++ b/service/SysService.go
@@ -234,10 +234,10 @@
 		return false
 	}
 
-	zipFilePath := configPatchPath+"/"+identifier+ext
-	err := util.DeCompress(zipFilePath, unPackPath)
+	unPackFilePath := configPatchPath+"/"+identifier+ext
+	err := util.UnTarGz(unPackFilePath, unPackPath)
 	if err !=nil {
-		logger.Debug("UnZip err:",err,"zipFile:",zipFilePath)
+		logger.Debug("UnPack err:",err,"unPackFile:",unPackFilePath)
 		return false
 	}
 
@@ -252,9 +252,9 @@
 	}
 
 	//鍒ゆ柇鏇存柊鍖呴噷鏄惁鏈夎ˉ涓佽剼鏈紝濡傛灉鏈夊垯鎵ц锛屽惁鍒欐墽琛寀pdatePatch.sh
-	updateCmd := fmt.Sprintf("./updatePatch.sh %s %s %s &",unPackPath,zipFilePath,configPatchPath+"/"+identifier)
+	updateCmd := fmt.Sprintf("./updatePatch.sh %s %s %s &",unPackPath,unPackFilePath,configPatchPath+"/"+identifier)
 	if util.Exists(unPackPath+"upgrade.sh") {
-		updateCmd = fmt.Sprintf("%supgrade.sh %s %s %s &",unPackPath,unPackPath,zipFilePath,configPatchPath+"/"+identifier)
+		updateCmd = fmt.Sprintf("%supgrade.sh %s %s %s &",unPackPath,unPackPath,unPackFilePath,configPatchPath+"/"+identifier)
 	}
 	//2.鏇存柊绯荤粺
 	b,err := ExecCmd(updateCmd)

--
Gitblit v1.8.0