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

import com.red.circle.framework.dto.PageResult;
import com.red.circle.framework.dto.ResultResponse;
import com.red.circle.other.inner.model.cmd.approval.ApprovalDynamicCmd;
import com.red.circle.other.inner.model.cmd.approval.ApprovalDynamicContentCmd;
import com.red.circle.other.inner.model.cmd.approval.ApprovalDynamicQryCmd;
import com.red.circle.other.inner.model.dto.approval.ApprovalDynamicDTO;
import java.util.Set;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * 审批动态
 *
 * @author zongpubin on 2024/1/19
 */
public interface ApprovalDynamicClientApi {

  String API_PREFIX = "/approval/dynamic/client";

  @PostMapping("/pageApprovalDynamic")
  ResultResponse<PageResult<ApprovalDynamicDTO>> pageApprovalDynamic(
      @RequestBody ApprovalDynamicQryCmd query);

  @PostMapping("/approvalPass")
  ResultResponse<Void> approvalPass(@RequestBody Set<Long> ids);

  @PostMapping("/approvalNotPass")
  ResultResponse<Void> approvalNotPass(@RequestBody ApprovalDynamicCmd approvalDynamicCmd);

  @PostMapping("/save")
  ResultResponse<Void> save(@RequestBody ApprovalDynamicContentCmd cmd);
}
