package com.dev.swms.server.service.base;

import java.util.List;

import org.springframework.transaction.annotation.Transactional;

import com.dev.swms.server.model.base.Warehouse;
import com.dev.swms.server.model.base.Worker;
import com.dev.energy.server.service.BaseManager;

@Transactional(readOnly = true)
public interface WorkerManager extends BaseManager {

	@Transactional
	void disabled(List<Long> ids);

	@Transactional
	void active(List<Long> ids);
	
	@Transactional
	void storeWorker(Worker worker);
	
	Warehouse getWarhouseByUser(Long userId);
	
	boolean isExistWorkerByUser(Long userId);
	
	List<Warehouse> getWarehousesByAdmin();
	
	boolean isExistUserByUserId(Long userId);
	
	List getWarehousesByUser(Long userId);
	
	@Transactional
	abstract void invokeStructureToWorker(List<Long> cusIds,Long wId);
	@Transactional
	void revokeStructureToWorker(List<Long> ids,Long wId);
}
