.
This commit is contained in:
@@ -1,7 +1,6 @@
|
|||||||
package net.tccn.plat;
|
package net.tccn.plat;
|
||||||
|
|
||||||
import net.tccn.base.JBean;
|
import net.tccn.base.JBean;
|
||||||
import net.tccn.base.Kv;
|
|
||||||
import net.tccn.base.PageBean;
|
import net.tccn.base.PageBean;
|
||||||
import net.tccn.service.BaseService;
|
import net.tccn.service.BaseService;
|
||||||
import org.redkale.net.http.RestMapping;
|
import org.redkale.net.http.RestMapping;
|
||||||
@@ -9,8 +8,6 @@ import org.redkale.net.http.RestService;
|
|||||||
import org.redkale.source.Flipper;
|
import org.redkale.source.Flipper;
|
||||||
import org.redkale.util.Comment;
|
import org.redkale.util.Comment;
|
||||||
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
@RestService(name = "plat", automapping = true, comment = "业务/数据平台")
|
@RestService(name = "plat", automapping = true, comment = "业务/数据平台")
|
||||||
public class PlatService extends BaseService {
|
public class PlatService extends BaseService {
|
||||||
|
|
||||||
@@ -51,18 +48,15 @@ public class PlatService extends BaseService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@RestMapping(name = "db_save", comment = "数据源信息保存")
|
@RestMapping(name = "db_save", comment = "数据源信息保存")
|
||||||
public JBean dbSave(String plat) {
|
public JBean dbSave(DbPlat plat) {
|
||||||
Map map = gson.fromJson(plat, Map.class);
|
|
||||||
DbPlat dbPlat = Kv.toBean(map, DbPlat.class);
|
|
||||||
|
|
||||||
// todo: Kv.toBean 的内部属性深度转换,
|
if (plat.getKey() == null) {
|
||||||
/*if (dbPlat.getKey() == null) {
|
plat.save();
|
||||||
dbPlat.save();
|
|
||||||
} else {
|
} else {
|
||||||
dbPlat.update();
|
plat.update();
|
||||||
}*/
|
}
|
||||||
|
|
||||||
return new JBean().setBody(dbPlat);
|
return new JBean();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user