package com.ym.mec.biz.dal.dao;

import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.Param;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.ym.mec.biz.dal.entity.TenantInfo;
import com.ym.mec.biz.dal.entity.TenantProductSumm;

public interface TenantInfoDao extends BaseMapper<TenantInfo> {
	
	TenantInfo getLocked(Integer tenantId);

    <T> IPage<T> queryPage(Page<T> page, @Param("param") Map<String, Object> param);

    <T> List<T> queryPage(@Param("param") Map<String, Object> param);

    TenantProductSumm queryTenantInfoProductSumm(Integer tenantId);

    TenantInfo getOpenTenant(Integer tenantId);

    TenantInfo queryTenantInfoByOrgan(@Param("organId") Integer organId);

    void updatePhone(@Param("newPhone") String newPhone, @Param("oldPhone") String oldPhone);

    Integer queryUserByTenantId(@Param("tenantId") Integer tenantId);

    int openInitNewsInformation(@Param("tenantId") Integer tenantId, @Param("orgId") String orgId);
}