package com.engine.kq.service.impl;

import com.engine.core.impl.Service;
import com.engine.kq.cmd.shiftschedule.GetTabsCmd;
import com.engine.kq.cmd.shiftschedule.*;
import com.engine.kq.service.KQShiftScheduleService;
import weaver.hrm.User;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.Map;

public class KQShiftScheduleServiceImpl extends Service implements KQShiftScheduleService {

	@Override
	public Map<String, Object> getSearchCondition(Map<String, Object> params, User user) {
		return commandExecutor.execute(new GetSearchConditionCmd(params, user));
	}

	@Override
	public Map<String, Object> getTabs(Map<String, Object> params, User user) {
		return commandExecutor.execute(new GetTabsCmd(params, user));
	}

	@Override
	public Map<String, Object> getShiftSchedule(Map<String, Object> params, User user) {
		return commandExecutor.execute(new GetShiftScheduleCmd(params, user));
	}

	@Override
	public Map<String, Object> save(Map<String, Object> params, User user) {
		return commandExecutor.execute(new SaveShiftScheduleCmd(params, user));
	}

	@Override
	public Map<String, Object> del(Map<String, Object> params, User user) {
		return commandExecutor.execute(new DelShiftScheduleCmd(params, user));
	}

	@Override
	public Map<String, Object> getBatchShiftScheduleFrom(Map<String, Object> params, User user) {
		return commandExecutor.execute(new GetBatchShiftScheduleFromCmd(params, user));
	}

	@Override
	public Map<String, Object> batchSave(Map<String, Object> params, User user) {
		return commandExecutor.execute(new SaveBatchShiftScheduleCmd(params, user));
	}

	@Override
	public Map<String, Object> importExcel(Map<String, Object> params, User user) {
		return commandExecutor.execute(new ImportExcelCmd(params, user));
	}

	@Override
	public Map<String, Object> exportExcel(Map<String, Object> params, HttpServletRequest request, HttpServletResponse response, User user) {
		return commandExecutor.execute(new ExportExcelCmd(params, request, response, user));
	}

	@Override
	public Map<String, Object> getShiftScheduleTotal(Map<String, Object> params, User user) {
		return commandExecutor.execute(new GetShiftScheduleTotalCmd(params, user));
	}

	@Override
	public Map<String, Object> getHrmScheduleReportInfo(Map<String, Object> params, User user) {
		return commandExecutor.execute(new GetHrmScheduleReportInfoCmd(params, user));
	}
}
