package com.ycwl.basic.mapper;

import com.ycwl.basic.model.pc.scenic.entity.ScenicAccountEntity;
import com.ycwl.basic.model.pc.scenic.req.ScenicAccountReqQuery;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface ScenicAccountMapper {
    ScenicAccountEntity getByAccount(String account);
    int add(ScenicAccountEntity scenicAccount);
    ScenicAccountEntity getSuperAccountOfScenic(Long scenicId);
    int update(ScenicAccountEntity scenicAccount);
    int deleteById(Long id);
    int updateStatus(Long id);
    int updateActiveStatus(Long id);
    int deleteByScenicId(Long scenicId);

    ScenicAccountEntity findAccountById(String id);
    List<ScenicAccountEntity> pageQuery(ScenicAccountReqQuery req);

    int addAccountScenicRelation(Long accountId, Long scenicId, int isAdmin);

    int deleteRelationByScenicId(Long scenicId);

    List<Long> getAccountRelations(Long accountId);

    int deleteRelationById(Long accountId);
}
