package com.zcloud.domain.web;


import com.alibaba.cola.dto.MultiResponse;
import com.alibaba.cola.dto.PageResponse;
import com.alibaba.cola.dto.Response;
import com.alibaba.cola.dto.SingleResponse;
import com.jjb.saas.framework.auth.model.SSOUser;
import com.jjb.saas.framework.auth.utils.AuthContext;
import com.zcloud.domain.api.DomainGroupUserServiceI;
import com.zcloud.domain.dto.DomainGroupUserAddCmd;
import com.zcloud.domain.dto.DomainGroupUserPageQry;
import com.zcloud.domain.dto.DomainGroupUserUpdateCmd;
import com.zcloud.domain.dto.clientobject.DomainGroupUserCO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.AllArgsConstructor;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
import springfox.documentation.annotations.ApiIgnore;

import java.util.ArrayList;

/**
 * web-adapter
 *
 * @Author zhaokai
 * @Date 2026-01-27 11:29:42
 */
@Api(tags = "领域组人员")
@RequestMapping("/${application.gateway}/domainGroupUser")
@RestController
@AllArgsConstructor
public class DomainGroupUserController {
    private final DomainGroupUserServiceI domainGroupUserService;



    @ApiOperation("领域组人员分页")
    @PostMapping("/list")
    public PageResponse<DomainGroupUserCO> page(@Validated @RequestBody DomainGroupUserPageQry qry) {
        return domainGroupUserService.listPage(qry);
    }

    @ApiOperation("领域组人员所有数据")
    @PostMapping("/listAll")
    public MultiResponse<DomainGroupUserCO> listAll(@Validated @RequestBody DomainGroupUserPageQry qry) {
        return MultiResponse.of(domainGroupUserService.listAll(qry));
    }


}

