package com.red.circle.other.inner.endpoint.sys.api;

import com.red.circle.framework.dto.PageResult;
import com.red.circle.framework.dto.ResultResponse;
import com.red.circle.other.inner.model.cmd.sys.SysNoticeMessageCmd;
import com.red.circle.other.inner.model.cmd.sys.SysNoticeMessageQryCmd;
import com.red.circle.other.inner.model.dto.sys.SysNoticeMessageDTO;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 系统通知消息
 *
 * @author lisizhe 2023/11/13  17:27
 */
public interface SysNoticeMessageClientApi {

  String API_PREFIX = "/sys/notice-message";

  @PostMapping("/getNoticeMessage")
  ResultResponse<PageResult<SysNoticeMessageDTO>> getNoticeMessage(
      @RequestBody SysNoticeMessageQryCmd query);

  @PostMapping("/addNoticeMessage")
  ResultResponse<Void> addNoticeMessage(@RequestBody SysNoticeMessageCmd sysNoticeMessage);

  @GetMapping("/deleteNoticeMessage")
  ResultResponse<Void> deleteNoticeMessage(@RequestParam("id") Long id);

  @PostMapping("/updateNoticeMessage")
  ResultResponse<Void> updateNoticeMessage(@RequestBody SysNoticeMessageCmd sysNoticeMessage);

  @GetMapping("/offShelf")
  ResultResponse<Void> offShelf(@RequestParam("id") Long id,
      @RequestParam("offShelf") Boolean offShelf);

  @GetMapping("/announcement")
  ResultResponse<Void> announcement(@RequestParam("id") Long id);
}
