|
@@ -34,9 +34,9 @@ class upload_path(Load):
|
|
|
if crop:
|
|
|
#裁图类型,暂时居中裁图
|
|
|
file_path = cropImage(file_path)
|
|
|
- #self.out('yes', {'src':url + file_path.replace(Demeter.path + 'runtime', '')})
|
|
|
- file = url + file_path.replace(Demeter.path + 'runtime', '')
|
|
|
- self.write({'state':True,'file_path':file, 'src':file})
|
|
|
+ self.out('yes', {'src':url + file_path.replace(Demeter.path + 'runtime', '')})
|
|
|
+ #file = url + file_path.replace(Demeter.path + 'runtime', '')
|
|
|
+ #self.write({'state':True,'file_path':file, 'src':file})
|
|
|
|
|
|
def cropImage(file):
|
|
|
img = Image.open(file)
|