zhouhao 8 yıl önce
ebeveyn
işleme
5a917b7a92

+ 16 - 0
hsweb-web-controller/src/main/java/org/hsweb/web/controller/classified/ClassifiedController.java

@@ -48,12 +48,28 @@ public class ClassifiedController extends GenericController<Classified, String>
 
     /**
      * 根据类型查询分类 {@link GenericController#list(QueryParam)}
+     * 已过时,在正式版中删除 todo
      *
      * @param type  分类类型
      * @param param 查询参数
      * @return 查询结果
      */
     @RequestMapping(value = "/byType/{type}")
+    @Deprecated
+    public ResponseMessage listByTypeOld(@PathVariable("type") String type, QueryParam param) {
+        param.where("type", type);
+        return list(param);
+    }
+
+
+    /**
+     * 根据类型查询分类 {@link GenericController#list(QueryParam)}
+     *
+     * @param type  分类类型
+     * @param param 查询参数
+     * @return 查询结果
+     */
+    @RequestMapping(value = "/type/{type}")
     public ResponseMessage listByType(@PathVariable("type") String type, QueryParam param) {
         param.where("type", type);
         return list(param);