|
@@ -45,7 +45,6 @@ public class sharematerialClass extends Controller {
|
|
|
insertSQL.setValue("sequence", content.getLongValue("sequence"));
|
|
|
insertSQL.setValue("level", level);
|
|
|
insertSQL.setValue("parentid", parentid);
|
|
|
- insertSQL.setValue("classtype", content.getLongValue("classtype",1L));
|
|
|
insertSQL.insert();
|
|
|
content.put("sat_sharematerial_classid", sat_sharematerial_classid);
|
|
|
}else{
|
|
@@ -123,17 +122,17 @@ public class sharematerialClass extends Controller {
|
|
|
}
|
|
|
|
|
|
Long parentid = content.getLong("parentid");
|
|
|
- Long classtype=content.getLongValue("classtype",1L);
|
|
|
|
|
|
- Rows rows = getClassRows(parentid,classtype, where);
|
|
|
+
|
|
|
+ Rows rows = getClassRows(parentid, where);
|
|
|
for (Row row : rows) {
|
|
|
Rows attRows = Attachment.get(this, "sat_sharematerial_class", row.getLong("sat_sharematerial_classid"));
|
|
|
row.put("attinfos", attRows);
|
|
|
|
|
|
- Rows secondRows = getClassRows(row.getLong("sat_sharematerial_classid"),classtype, where);
|
|
|
+ Rows secondRows = getClassRows(row.getLong("sat_sharematerial_classid"), where);
|
|
|
row.put("children", secondRows);
|
|
|
for (Row secondRow : secondRows) {
|
|
|
- Rows threeRows = getClassRows(secondRow.getLong("sat_sharematerial_classid"),classtype, where);
|
|
|
+ Rows threeRows = getClassRows(secondRow.getLong("sat_sharematerial_classid"), where);
|
|
|
secondRow.put("children", threeRows);
|
|
|
}
|
|
|
|
|
@@ -141,11 +140,10 @@ public class sharematerialClass extends Controller {
|
|
|
return getSucReturnObject().setData(rows).toString();
|
|
|
}
|
|
|
|
|
|
- public Rows getClassRows(Long parentid,Long classtype, StringBuffer where) throws YosException {
|
|
|
+ public Rows getClassRows(Long parentid, StringBuffer where) throws YosException {
|
|
|
SQLFactory sqlFactory = new SQLFactory(this, "素材分类-查询");
|
|
|
sqlFactory.addParameter("parentid", parentid);
|
|
|
sqlFactory.addParameter("siteid", siteid);
|
|
|
- sqlFactory.addParameter("classtype", classtype);
|
|
|
sqlFactory.addParameter_SQL("where", where);
|
|
|
Rows rows = dbConnect.runSqlQuery(sqlFactory);
|
|
|
return rows;
|