Commit 839cadad by tongpuxin

增加录音下载解冻

parent c32f2a9e
...@@ -10,7 +10,6 @@ import lombok.extern.slf4j.Slf4j; ...@@ -10,7 +10,6 @@ import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang.StringUtils; import org.apache.commons.lang.StringUtils;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.servlet.ModelAndView; import org.springframework.web.servlet.ModelAndView;
import javax.annotation.Resource; import javax.annotation.Resource;
...@@ -112,11 +111,4 @@ public class CallRecordController extends CrudBaseControllerSupport<CallRecordVi ...@@ -112,11 +111,4 @@ public class CallRecordController extends CrudBaseControllerSupport<CallRecordVi
return new ModelAndView("admin/business/call_record/list.html", result); return new ModelAndView("admin/business/call_record/list.html", result);
} }
@RequestMapping(value = "/thaw")
@ResponseBody
public AjaxResult thaw(String recordUrl) {
log.info("call_record.thaw:{}", recordUrl);
return AjaxResult.wrap(true);
}
} }
...@@ -21,22 +21,12 @@ $(function(){ ...@@ -21,22 +21,12 @@ $(function(){
window.open(recordUrl); window.open(recordUrl);
}, },
thaw: function(row){ thaw: function(row){
App.MsgBox.confirm('确定要解冻吗', function(){
var recordUrl = row['recordUrl']; var recordUrl = row['recordUrl'];
if(!recordUrl) { recordUrl = recordUrl.replace("http://ydl-recording.oss-cn-hangzhou.aliyuncs.com/", "");
App.MsgBox.msg("文件URL为空"); var key = recordUrl.replace("https://ydl-recording.oss-cn-hangzhou.aliyuncs.com/", "");
return;
}
App.Ajax.request({
url : Config.ROOT + '/call/call_record/thaw',
params : {
'recordUrl': recordUrl
},
success: function(resp){
} var oss_url = 'https://oss.console.aliyun.com/bucket/oss-cn-hangzhou/ydl-recording/object?keyword=' + encodeURI(key);
}); window.open(oss_url);
});
}, },
search: function () { search: function () {
$table.search({ $table.search({
...@@ -53,6 +43,7 @@ $(function(){ ...@@ -53,6 +43,7 @@ $(function(){
searchParamName: '', searchParamName: '',
searchPlaceholder: '', searchPlaceholder: '',
columns :[ columns :[
{checkbox: true},
{field:'id', title:'操作', width: 120, toolbar: 'tableRowToolbar', events: AppCallRecord.Events}, {field:'id', title:'操作', width: 120, toolbar: 'tableRowToolbar', events: AppCallRecord.Events},
{field:'', title:'通话记录ID', formatter: function (value, row, index) { {field:'', title:'通话记录ID', formatter: function (value, row, index) {
return row['id']; return row['id'];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment