package com.malk.service.beisen.impl;

import com.malk.service.beisen.BSClient;
import com.malk.service.beisen.BSClient_Attendance;
import com.malk.service.beisen.BSClient_Employee;
import com.malk.service.beisen.BSService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

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

/**
 * 北森高级业务实现
 * // fixme 根据实际业务需求实现
 */
@Slf4j
@Service
public class BSServiceImpl implements BSService {

    @Autowired
    private BSClient bsClient;

    @Autowired
    private BSClient_Employee bsClientEmployee;

    @Autowired
    private BSClient_Attendance bsClientAttendance;

    @Override
    public List<Map> syncEmployees() {
        String accessToken = bsClient.getAccessToken();
        // fixme 待实现：分页循环获取所有员工
        return null;
    }

    @Override
    public List<Map> syncLeaveRecords(String startDate, String endDate) {
        String accessToken = bsClient.getAccessToken();
        // fixme 待实现：分页循环获取请假记录
        return null;
    }

    @Override
    public List<Map> syncTravelRecords(String startDate, String endDate) {
        String accessToken = bsClient.getAccessToken();
        // fixme 待实现：分页循环获取出差记录
        return null;
    }

    @Override
    public List<Map> syncAttendanceRecords(String startDate, String endDate) {
        String accessToken = bsClient.getAccessToken();
        // fixme 待实现：分页循环获取考勤记录
        return null;
    }
}
