提交 b7e0ae21 authored 作者: renjiancai's avatar renjiancai

--no commit message

上级 657d8b43
......@@ -56,6 +56,12 @@ public interface LabelMapper extends BaseMapper<Label> {
+ " <foreach collection=\"ids\" index=\"index\" item=\"id\" open=\"(\" separator=\",\" close=\")\">"
+ "#{id}"
+ "</foreach>"
+ "<if test='ids !=null and ids.size>0'>"
+ " order by field"
+ " <foreach collection=\"ids\" index=\"index\" item=\"id\" open=\"(id,\" separator=\",\" close=\")\">"
+ "#{id}"
+ "</foreach>"
+ "</if>"
+ "</script>")
List<Label> queryLabelByIds(@Param("ids")List<String> ids);
}
......@@ -7,6 +7,8 @@ import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import tk.mybatis.mapper.entity.Example;
import com.zrqx.core.mapper.BaseMapper;
import com.zrqx.core.model.resource.label.Label;
import com.zrqx.core.model.resource.label.LabelContentDiyType;
......@@ -47,6 +49,8 @@ public class LabelDataTypeServiceImpl extends BaseServiceImpl<LabelDataType,Inte
List<LabelAndContentByDataTypeVO> vos = new ArrayList<LabelAndContentByDataTypeVO>();
LabelDataType dt = new LabelDataType();
dt.setDataType(dataType);
Example ex=createExample();
ex.orderBy("dataTypeSort").asc();
List<LabelDataType> list = LabelDataTypeMapper.select(dt);
if(list.size()>0){
List<String> ids = new ArrayList<String>();
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论