package com.red.circle.console.adapter.app.sys;


import com.red.circle.console.app.service.app.sys.SysBadgePictureConfigService;
import com.red.circle.framework.web.controller.BaseController;
import com.red.circle.other.inner.model.cmd.sys.SysBadgePictureConfigParamCmd;
import lombok.RequiredArgsConstructor;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 徽章图片配置.
 *
 * @author pengshigang
 * @since 2021-06-15
 */
@RestController
@RequestMapping("/sys/badge/picture/config")
@RequiredArgsConstructor
public class SysBadgePictureConfigRestController extends BaseController {

  private final SysBadgePictureConfigService sysBadgePictureConfigService;

  /**
   * 添加或修改.
   */
  @PostMapping("/add-or-update")
  public void addOrUpdateBadgePicture(
      @Validated @RequestBody SysBadgePictureConfigParamCmd param) {
    sysBadgePictureConfigService.addOrUpdateBadgePicture(param);
  }

}
