Forráskód Böngészése

素材分类调整

eganwu 1 éve
szülő
commit
c057912b3a

+ 1 - 1
src/custom/restcontroller/webmanage/saletool/sharematerial/SQL/素材分类-查询.sql

@@ -1,4 +1,4 @@
 SELECT sat_sharematerial_classid, classname, parentid,createdate, isenable,sequence,level
 FROM sat_sharematerial_class
-WHERE parentid = $parentid$ and siteid = $siteid$ and $where$ and classtype=$classtype$
+WHERE parentid = $parentid$ and siteid = $siteid$ and $where$
 ORDER BY sequence DESC,createdate DESC

+ 5 - 7
src/custom/restcontroller/webmanage/saletool/sharematerial/sharematerialClass.java

@@ -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;