package com.yonge.cooleshow.biz.dal.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.microsvc.toolkit.common.response.ParamResponse;
import com.yonge.cooleshow.biz.dal.wrapper.TenantGroupWrapper;
import com.yonge.cooleshow.biz.dal.entity.TenantGroup;

import java.util.List;

/**
 * 机构小组表
 * 2023-10-11 09:24:50
 */
public interface TenantGroupService extends IService<TenantGroup>  {

    /**
     * 查询详情
     * @param id 详情ID
     * @return TenantGroup
     */
    TenantGroup detail(Long id);

    /**
     * 分页查询
     * @param page IPage<TenantGroup>
     * @param query TenantGroupWrapper.TenantGroupQuery
     * @return IPage<TenantGroup>
     */
    IPage<TenantGroupWrapper.TenantGroup> selectPage(IPage<TenantGroupWrapper.TenantGroup> page,
                                                     TenantGroupWrapper.TenantGroupQuery query);

    /**
     * 添加
     * @param tenantGroup TenantGroupWrapper.TenantGroup
     * @param imGroupCreate 是否创建群聊
     * @return Boolean
     */
    Boolean add(TenantGroupWrapper.TenantGroup tenantGroup, Boolean imGroupCreate);

    /**
     * 更新
     * @param tenantGroup TenantGroupWrapper.TenantGroup
     * @param imGroupCreate 是否创建IM群
     * @return Boolean
     */
    Boolean update(TenantGroupWrapper.TenantGroup tenantGroup, Boolean imGroupCreate);

    Boolean delete(Long id);

    List<TenantGroupWrapper.TenantGroupMember> queryGroupMember(Long tenantId, Long tenantGroupId);

    Boolean adjustTenantGroup(TenantGroupWrapper.AdjustTenantGroup adjustTenantGroup);
}