⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 topicquery.java

📁 blog,介绍:ui层是用ext做的
💻 JAVA
字号:
package com.easyjf.simpleblog.query;

import com.easyjf.container.annonation.POLoad;
import com.easyjf.core.support.query.QueryObject;
import com.easyjf.simpleblog.domain.TopicCategory;

public class TopicQuery extends QueryObject {
@POLoad(name="categoryId")
private TopicCategory category;
private String title="";

public TopicCategory getCategory() {
	return category;
}

public void setCategory(TopicCategory category) {
	this.category = category;
}

public String getTitle() {
	return title;
}

public void setTitle(String title) {
	this.title = title;
}

@Override
public void customizeQuery() {
	if(category!=null)
	{
		this.addQuery("obj.category",category,"=");
	}
	if(!"".equals(title))
	{
		this.addQuery("obj.title","%"+title+"%","like");
	}
	if(this.getOrderBy()==null|| "".equals(this.getOrderBy()))
	{
		this.setOrderBy("inputTime");
		this.setOrderType("desc");
	}
	super.customizeQuery();
}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -