|
@@ -60,7 +60,7 @@ class VoicePromptView(View):
|
|
|
return response.json(201)
|
|
|
|
|
|
auth = oss2.Auth(OSS_STS_ACCESS_KEY, OSS_STS_ACCESS_SECRET)
|
|
|
- bucket = oss2.Bucket(auth, 'oss-cn-hongkong.aliyuncs.com', 'statres')
|
|
|
+ bucket = oss2.Bucket(auth, 'oss-cn-shenzhen.aliyuncs.com', 'ansjer-static-resources')
|
|
|
name = CommonService.createOrderID()
|
|
|
filename = str(name) + '.' + upload_type
|
|
|
obj = 'voice_prompt/{uid}/{channel}/'.format(uid=uid, channel=channel) + filename
|
|
@@ -103,7 +103,7 @@ class VoicePromptView(View):
|
|
|
if device_qs.exists():
|
|
|
voice_qs.delete()
|
|
|
auth = oss2.Auth(OSS_STS_ACCESS_KEY, OSS_STS_ACCESS_SECRET)
|
|
|
- bucket = oss2.Bucket(auth, 'oss-cn-hongkong.aliyuncs.com', 'statres')
|
|
|
+ bucket = oss2.Bucket(auth, 'oss-cn-shenzhen.aliyuncs.com', 'ansjer-static-resources')
|
|
|
obj = 'voice_prompt/{uid}/{channel}/'.format(uid=uid, channel=voice_qs[0].channel) + voice_qs[0].filename
|
|
|
bucket.delete_object(obj)
|
|
|
return response.json(0)
|
|
@@ -152,7 +152,7 @@ class VoicePromptView(View):
|
|
|
res['system'] = {}
|
|
|
res['custom'] = {}
|
|
|
auth = oss2.Auth(OSS_STS_ACCESS_KEY, OSS_STS_ACCESS_SECRET)
|
|
|
- bucket = oss2.Bucket(auth, 'oss-cn-hongkong.aliyuncs.com', 'statres')
|
|
|
+ bucket = oss2.Bucket(auth, 'oss-cn-shenzhen.aliyuncs.com', 'ansjer-static-resources')
|
|
|
if system_qs.exists():
|
|
|
system_qs = system_qs.values('id', 'title', 'filename', 'type')
|
|
|
for system in system_qs:
|