|
|
@@ -44,16 +44,13 @@ public class tagents extends Controller {
|
|
|
where.append(")");
|
|
|
}
|
|
|
}
|
|
|
- SQLFactory singleagentSql = new SQLFactory(this, "个人商户列表查询", pageSize, pageNumber, "t1.tagentsid");
|
|
|
+ /**
|
|
|
+ * 认证中状态排第一
|
|
|
+ */
|
|
|
+ SQLFactory singleagentSql = new SQLFactory(this, "个人商户列表查询", pageSize, pageNumber, "case when exists(select *from tagents_msgchangeapp where ftype='商户认证' and fstatus='申请' and tagentsid=t1.tagentsid) then '认证中' else '未认证' end),t1.tagentsid desc");
|
|
|
singleagentSql.addParameter("siteid", siteid);
|
|
|
singleagentSql.addParameter_SQL("where", where);
|
|
|
Rows rows = dbConnect.runSqlQuery(singleagentSql.getSQL());
|
|
|
-
|
|
|
- ArrayList<String> tagentsidlist = dbConnect.runSqlQuery("select tagentsid from tagents_msgchangeapp where ftype='商户认证' and fstatus='申请'").toArrayList("tagentsid");
|
|
|
- for (Row row : rows) {
|
|
|
- String tagentsid = row.getString("tagentsid");
|
|
|
- row.put("fstatus", tagentsidlist.contains(tagentsid) ? "认证中" : "未认证");
|
|
|
- }
|
|
|
return getSucReturnObject().setDataByPaging(rows).setFinalDo(DataPool.defaultdatalife, 1);
|
|
|
}
|
|
|
|
|
|
@@ -87,7 +84,7 @@ public class tagents extends Controller {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- SQLFactory agentsql = new SQLFactory(this, "认证商户列表查询", pageSize, pageNumber, "t1.tagentsid");
|
|
|
+ SQLFactory agentsql = new SQLFactory(this, "认证商户列表查询", pageSize, pageNumber, "t1.tagentsid desc");
|
|
|
agentsql.addParameter("siteid", siteid);
|
|
|
agentsql.addParameter_SQL("where", where);
|
|
|
Rows rows = dbConnect.runSqlQuery(agentsql.getSQL());
|