package com.mcwl.communityCenter.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.mcwl.communityCenter.domain.CommunityFile;
import com.mcwl.communityCenter.domain.CommunityFileLog;
import com.mcwl.communityCenter.mapper.CommunityFileLogMapper;
import com.mcwl.communityCenter.mapper.CommunityFileMapper;
import com.mcwl.communityCenter.service.CommunityFileLogService;
import com.mcwl.communityCenter.service.CommunityFileService;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;

import java.util.Collections;
import java.util.List;

@Service
@RequiredArgsConstructor
public class CommunityFileLogServiceImpl extends ServiceImpl<CommunityFileLogMapper, CommunityFileLog> implements CommunityFileLogService {


    @Override
    public List<String> getUserAvatarList(Long tenantId, Long communityId, Long communityFileId) {
        return baseMapper.getUserAvatarList(tenantId, communityId, communityFileId);
    }

    @Override
    public Integer getDownloadCount(Long tenantId, Long communityId, Long communityFileId) {
        return baseMapper.getDownloadCount(tenantId, communityId, communityFileId);

    }

    @Override
    public void saveCommunityFileLog(CommunityFileLog communityFileLog) {
        baseMapper.saveCommunityFileLog(communityFileLog);
    }
}
