package com.friday.custody.service.basicService;

import com.baomidou.mybatisplus.extension.service.IService;
import com.friday.custody.dto.TenantEscrowAuthorizationInfoDto;
import com.friday.custody.dto.TenantInfoDto;
import com.friday.custody.entity.TenantEscrowAuthorizationInfoEntity;
import com.friday.custody.req.TenantEscrowAuthorizationInfoReq;
import com.friday.custody.utils.R;

import java.util.List;
import java.util.Set;

/**
 * 
 *
 * @author lyb
 * @email k0051582@gmail.com
 * @date 2022-01-05 14:07:22
 */
public interface TenantEscrowAuthorizationInfoService extends IService<TenantEscrowAuthorizationInfoEntity> {

    R addEscrowAuthorization(String tenantName, TenantEscrowAuthorizationInfoDto dto);

    R<List<TenantEscrowAuthorizationInfoDto>> queryAuthorizations();

    R addEscrowAuthorizations(String TenantName, TenantInfoDto tenantInfoDto, List<TenantEscrowAuthorizationInfoReq> tenantEscrowAuthorizationInfoReqs);

    Set<String> queryAdminList();


    boolean isExistAuthorization(String trustNo, String admin);

    boolean updateByTenant(TenantEscrowAuthorizationInfoEntity authorizationInfo);

    int deleteByTrust(String admin, String trustNo);

    List<TenantEscrowAuthorizationInfoEntity> queryData(String trustNo, String admin, String authorizationApi);

    List<TenantEscrowAuthorizationInfoEntity> queryAuthorizationsByAdmin(String admin);
}

