package com.palmnest.service.washcar.service.impl;

import com.palmnest.application.dto.output.ElementDto;
import com.palmnest.model.Element;
import com.palmnest.service.ElementGroupManager;
import com.palmnest.service.washcar.service.ElementGroupService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("elementGroupService")
public class ElementGroupServiceImpl implements ElementGroupService {

	@Autowired
	private ElementGroupManager elementGroupManager;

	@Override
	public List<ElementDto> convert(List<Element> elements) {
		return elementGroupManager.convert(elements);
	}

	@Override
	public List<Element> getElementsByGroupName(String code) {
		return elementGroupManager.getElementsByGroupName(code);
	}

	@Override
	public List<ElementDto> getOrgElementGroupInfo(int orgId, String groupCode) {
		return elementGroupManager.getOrgElementGroupInfo(orgId, groupCode);
	}

}
