|
@@ -24,8 +24,7 @@ import java.util.Map;
|
|
|
*/
|
|
|
@RestController
|
|
|
@RequestMapping("/live/live")
|
|
|
-public class LiveController extends BaseController
|
|
|
-{
|
|
|
+public class LiveController extends BaseController {
|
|
|
@Autowired
|
|
|
private ILiveService liveService;
|
|
|
|
|
@@ -34,8 +33,7 @@ public class LiveController extends BaseController
|
|
|
*/
|
|
|
@PreAuthorize("@ss.hasPermi('live:live:list')")
|
|
|
@GetMapping("/list")
|
|
|
- public TableDataInfo list(Live live)
|
|
|
- {
|
|
|
+ public TableDataInfo list(Live live) {
|
|
|
startPage();
|
|
|
List<Live> list = liveService.selectLiveList(live);
|
|
|
return getDataTable(list);
|
|
@@ -47,8 +45,7 @@ public class LiveController extends BaseController
|
|
|
@PreAuthorize("@ss.hasPermi('live:live:export')")
|
|
|
@Log(title = "直播", businessType = BusinessType.EXPORT)
|
|
|
@GetMapping("/export")
|
|
|
- public AjaxResult export(Live live)
|
|
|
- {
|
|
|
+ public AjaxResult export(Live live) {
|
|
|
List<Live> list = liveService.selectLiveList(live);
|
|
|
ExcelUtil<Live> util = new ExcelUtil<Live>(Live.class);
|
|
|
return util.exportExcel(list, "直播数据");
|
|
@@ -59,8 +56,7 @@ public class LiveController extends BaseController
|
|
|
*/
|
|
|
@PreAuthorize("@ss.hasPermi('live:live:query')")
|
|
|
@GetMapping(value = "/{liveId}")
|
|
|
- public AjaxResult getInfo(@PathVariable("liveId") Long liveId)
|
|
|
- {
|
|
|
+ public AjaxResult getInfo(@PathVariable("liveId") Long liveId) {
|
|
|
return AjaxResult.success(liveService.selectLiveByLiveId(liveId));
|
|
|
}
|
|
|
|
|
@@ -70,8 +66,7 @@ public class LiveController extends BaseController
|
|
|
@PreAuthorize("@ss.hasPermi('live:live:add')")
|
|
|
@Log(title = "直播", businessType = BusinessType.INSERT)
|
|
|
@PostMapping
|
|
|
- public AjaxResult add(@RequestBody Live live)
|
|
|
- {
|
|
|
+ public AjaxResult add(@RequestBody Live live) {
|
|
|
return toAjax(liveService.insertLive(live));
|
|
|
}
|
|
|
|
|
@@ -81,8 +76,7 @@ public class LiveController extends BaseController
|
|
|
@PreAuthorize("@ss.hasPermi('live:live:edit')")
|
|
|
@Log(title = "直播", businessType = BusinessType.UPDATE)
|
|
|
@PutMapping
|
|
|
- public AjaxResult edit(@RequestBody Live live)
|
|
|
- {
|
|
|
+ public AjaxResult edit(@RequestBody Live live) {
|
|
|
return toAjax(liveService.updateLive(live));
|
|
|
}
|
|
|
|
|
@@ -91,9 +85,8 @@ public class LiveController extends BaseController
|
|
|
*/
|
|
|
@PreAuthorize("@ss.hasPermi('live:live:remove')")
|
|
|
@Log(title = "直播", businessType = BusinessType.DELETE)
|
|
|
- @DeleteMapping("/{liveIds}")
|
|
|
- public AjaxResult remove(@PathVariable Long[] liveIds)
|
|
|
- {
|
|
|
+ @DeleteMapping("/{liveIds}")
|
|
|
+ public AjaxResult remove(@PathVariable Long[] liveIds) {
|
|
|
return toAjax(liveService.deleteLiveByLiveIds(liveIds));
|
|
|
}
|
|
|
|
|
@@ -102,4 +95,8 @@ public class LiveController extends BaseController
|
|
|
return liveService.getLiveRoom(liveId);
|
|
|
}
|
|
|
|
|
|
+ @PostMapping("/updateLiveIsAudit")
|
|
|
+ public Integer updateLiveIsAudit(@RequestBody Live live) {
|
|
|
+ return liveService.updateLive(live);
|
|
|
+ }
|
|
|
}
|