Ver Fonte

列表查询方案选择重写

wu há 2 meses atrás
pai
commit
ebccb493eb

+ 25 - 0
src/custom/restcontroller/sysmanage/develop/querytemplet/querytemplet.java

@@ -0,0 +1,25 @@
+package restcontroller.sysmanage.develop.querytemplet;
+
+import com.alibaba.fastjson.JSONObject;
+import common.Controller;
+import common.YosException;
+import common.annotation.API;
+import common.data.Rows;
+import common.data.SQLFactory;
+import restcontroller.R;
+
+public class querytemplet extends Controller {
+    public querytemplet(JSONObject content) throws YosException {
+        super(content);
+    }
+
+    @API(title = "列表查询方案选择")
+    public String query() throws YosException {
+        String sql = "select templetid,templetname from sys_querytemplet t1 WHERE templetid!=99";
+        if (usertype == 0) {
+            sql = "select templetid,templetname from sys_querytemplet t1 ";
+        }
+        Rows rows = dbConnect.runSqlQuery(sql);
+        return getSucReturnObject().setData(rows).toString();
+    }
+}