package com.qxueyou.scc.base.service.impl;
|
|
|
import org.springframework.stereotype.Service;
|
|
import com.qxueyou.scc.base.model.Result;
|
import com.qxueyou.scc.base.service.IDictionaryService;
|
import com.qxueyou.scc.base.util.CollectionUtils;
|
|
/**
|
* ÅäÖ÷þÎñ£¬¶ÁÈ¡ÅäÖÃÏî
|
*
|
* @author lyl
|
*
|
*/
|
@Service
|
public class DictionaryService extends CommonAppService implements IDictionaryService {
|
|
@Override
|
public String getConfig(String key) {
|
String hql="select value from SysDictionary where dicKey=?";
|
|
return findUnique(hql, CollectionUtils.newList(key), String.class) ;
|
}
|
|
@Override
|
public Result updateConfig(String key, String value) {
|
|
return bulkUpdate("update SysDictionary set value=? where dicKey=?", new Object[] {value,key});
|
}
|
|
|
}
|