mirror of
http://git.coreshop.cn/jianweie/coreshoppro.git
synced 2025-12-06 19:03:27 +08:00
修复七牛云上传后返回保存路径错误的问题。
This commit is contained in:
@@ -258,7 +258,6 @@ namespace CoreCms.Net.Services
|
|||||||
var today = DateTime.Now.ToString("yyyyMMdd");
|
var today = DateTime.Now.ToString("yyyyMMdd");
|
||||||
var filePath = options.Path.TrimStart('/') + today + "/" + newFileName; //云保存路径
|
var filePath = options.Path.TrimStart('/') + today + "/" + newFileName; //云保存路径
|
||||||
|
|
||||||
|
|
||||||
Mac mac = new Mac(options.AccessKeyId, options.AccessKeySecret);
|
Mac mac = new Mac(options.AccessKeyId, options.AccessKeySecret);
|
||||||
|
|
||||||
byte[] bytes;
|
byte[] bytes;
|
||||||
@@ -288,7 +287,7 @@ namespace CoreCms.Net.Services
|
|||||||
UploadManager um = new UploadManager(config);
|
UploadManager um = new UploadManager(config);
|
||||||
var outData = um.UploadData(bytes, filePath, token, null);
|
var outData = um.UploadData(bytes, filePath, token, null);
|
||||||
|
|
||||||
return options.BucketBindUrl + newFileName;
|
return options.BucketBindUrl + filePath;
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
@@ -454,7 +453,7 @@ namespace CoreCms.Net.Services
|
|||||||
UploadManager um = new UploadManager(config);
|
UploadManager um = new UploadManager(config);
|
||||||
var outData = um.UploadData(bytes, filePath, token, null);
|
var outData = um.UploadData(bytes, filePath, token, null);
|
||||||
|
|
||||||
return options.BucketBindUrl + newFileName;
|
return options.BucketBindUrl + filePath;
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user