|
|
@@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.core.conditions.Wrapper;
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
|
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
|
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
|
|
import com.fs.common.annotation.Log;
|
|
|
import com.fs.common.core.controller.BaseController;
|
|
|
@@ -134,6 +135,29 @@ public class FsCoursePlaySourceConfigController extends BaseController {
|
|
|
return AjaxResult.success();
|
|
|
}
|
|
|
|
|
|
+ @PreAuthorize("@ss.hasPermi('course:playSourceConfig:bind')")
|
|
|
+ @Log(title = "绑定支付配置", businessType = BusinessType.UPDATE)
|
|
|
+ @PutMapping("/updateBindConfig")
|
|
|
+ public AjaxResult updateBindConfig(@RequestBody FsCoursePlaySourceConfigEditParam param) {
|
|
|
+
|
|
|
+ FsCoursePlaySourceConfig update =new FsCoursePlaySourceConfig();
|
|
|
+ update.setId(param.getId());
|
|
|
+ update.setMerchantConfigId(param.getMerchantConfigId());
|
|
|
+ fsCoursePlaySourceConfigService.updateById(update);
|
|
|
+ return AjaxResult.success();
|
|
|
+ }
|
|
|
+
|
|
|
+ @PreAuthorize("@ss.hasPermi('course:playSourceConfig:unbind')")
|
|
|
+ @Log(title = "解绑支付配置", businessType = BusinessType.UPDATE)
|
|
|
+ @PutMapping("/updateUnbindConfig")
|
|
|
+ public AjaxResult updateUnbindConfig(@RequestBody FsCoursePlaySourceConfigEditParam param) {
|
|
|
+ LambdaUpdateWrapper<FsCoursePlaySourceConfig> updateWrapper = Wrappers.lambdaUpdate();
|
|
|
+ updateWrapper.eq(FsCoursePlaySourceConfig::getId, param.getId())
|
|
|
+ .set(FsCoursePlaySourceConfig::getMerchantConfigId, null);
|
|
|
+ fsCoursePlaySourceConfigService.update(updateWrapper);
|
|
|
+ return AjaxResult.success();
|
|
|
+ }
|
|
|
+
|
|
|
@PreAuthorize("@ss.hasPermi('course:playSourceConfig:remove')")
|
|
|
@Log(title = "点播播放源配置", businessType = BusinessType.DELETE)
|
|
|
@DeleteMapping("/{ids}")
|