4 changed files with 67 additions and 11 deletions
@ -0,0 +1,37 @@ |
|||
package com.elink.esua.epdc.util; |
|||
|
|||
import cn.hutool.core.map.MapUtil; |
|||
import cn.hutool.core.util.ArrayUtil; |
|||
import org.apache.commons.lang3.StringUtils; |
|||
|
|||
import java.util.Map; |
|||
|
|||
/** |
|||
* 一些公用方法 |
|||
* |
|||
* @author work@yujt.net.cn |
|||
* @date 2020/2/24 15:23 |
|||
*/ |
|||
public class AppUserUtils { |
|||
|
|||
/** |
|||
* 是否是进入页面时的首次查询 |
|||
* |
|||
* @param params 页面分页参数 |
|||
* @param paramKeys 查询条件的属性名 如:realName,startTime,endTime |
|||
* @return boolean |
|||
* @author work@yujt.net.cn |
|||
* @date 2020/2/24 15:27 |
|||
*/ |
|||
public static boolean isDefaultQuery(Map<String, Object> params, String[] paramKeys) { |
|||
if (ArrayUtil.isEmpty(paramKeys)) { |
|||
return true; |
|||
} |
|||
for (String paramKey : paramKeys) { |
|||
if (StringUtils.isNotBlank(MapUtil.getStr(params, paramKey))) { |
|||
return false; |
|||
} |
|||
} |
|||
return true; |
|||
} |
|||
} |
|||
Loading…
Reference in new issue