mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-18 23:45:52 +08:00
Update file.py
This commit is contained in:
+8
-2
@@ -89,13 +89,19 @@ def mvFile(sfile, dfile):
|
||||
if not checkDir(sfile):
|
||||
return mw.returnData(False, 'FILE_DANGER')
|
||||
|
||||
|
||||
try:
|
||||
pass
|
||||
except Exception as e:
|
||||
raise e
|
||||
|
||||
try:
|
||||
shutil.move(sfile, dfile)
|
||||
msg = mw.getInfo('移动或重名命文件[{1}]到[{2}]成功!', (sfile, dfile,))
|
||||
mw.writeLog('文件管理', msg)
|
||||
return mw.returnData(True, '移动或重名命文件成功!')
|
||||
except:
|
||||
return mw.returnData(False, '移动或重名命文件失败!')
|
||||
except Exception as e:
|
||||
return mw.returnData(False, '移动或重名命文件失败!'. str(e))
|
||||
|
||||
def uncompress(sfile, dfile, path):
|
||||
if not os.path.exists(sfile):
|
||||
|
||||
Reference in New Issue
Block a user