package com.ld.igds.three;
|
|
import com.bstek.dorado.annotation.DataProvider;
|
import com.bstek.dorado.annotation.DataResolver;
|
import com.bstek.dorado.annotation.Expose;
|
import com.ld.igds.models.ThreeConf;
|
import com.ld.igds.three.impl.ThreeConfServiceImpl;
|
import com.ld.igds.util.ContextUtil;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.stereotype.Component;
|
import java.util.List;
|
|
/**
|
* @author chen
|
*/
|
@Component
|
public class ThreeConfPR {
|
|
@Autowired
|
private ThreeConfServiceImpl threeConfService;
|
|
/**
|
* threeConfPR#getAllThreeConf
|
*
|
* @return
|
* @throws Exception
|
*/
|
@DataProvider
|
public List<ThreeConf> getAllThreeConf() throws Exception {
|
return threeConfService.getAllThreeConf(ContextUtil.getCompanyId());
|
}
|
|
|
/**
|
* threeConfPR#updateThreeConf
|
*
|
* @param threeConf
|
* @throws Exception
|
*/
|
@DataResolver
|
public void updateThreeConf(ThreeConf threeConf) throws Exception {
|
threeConfService.updateThreeConf(threeConf);
|
}
|
|
|
/**
|
* threeConfPR#delThreeConf
|
* 根据分机id和名称删除分机
|
*/
|
@Expose
|
public void delThreeConf(ThreeConf threeConf) {
|
threeConfService.delThreeConf(threeConf);
|
}
|
|
|
/**
|
* threeConfPR#refreshCache
|
*/
|
@Expose
|
public void refreshCache() {
|
threeConfService.refreshCache(ContextUtil.getCompanyId());
|
}
|
|
}
|