|
@@ -45,6 +45,7 @@ import io.swagger.v3.oas.annotations.tags.Tag
|
|
|
import org.slf4j.LoggerFactory
|
|
|
import org.springframework.web.bind.annotation.PostMapping
|
|
|
import org.springframework.web.bind.annotation.RequestMapping
|
|
|
+import org.springframework.web.bind.annotation.RequestParam
|
|
|
import org.springframework.web.bind.annotation.RestController
|
|
|
|
|
|
/**
|
|
@@ -123,7 +124,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "设备和楼层关系-同步到中台", description = "设备所在的楼层(图类型 MechInArch 边类型 Eq2Fl ),设备服务的楼层(图类型 MechForArch 边类型 Eq2Fl), ")
|
|
|
@PostMapping("/eq2fl")
|
|
|
- fun eq2Fl(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun eq2Fl(@RequestParam projectId: String, @RequestParam graphCode: String, @RequestParam type: String, @RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
if (graphCode == "MechInArch") {
|
|
@@ -177,7 +178,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "设备和建筑关系-同步到中台", description = "设备所在的建筑(图类型 MechInArch 边类型 Eq2Bd ),设备服务的建筑(图类型 MechForArch 边类型 Eq2Bd), ")
|
|
|
@PostMapping("/eq2bd")
|
|
|
- fun eq2Bd(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun eq2Bd(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
if (graphCode == "MechInArch") {
|
|
@@ -226,7 +227,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "设备和系统关系-同步到中台", description = "系统下设备(图类型 MechSubset 边类型 Sy2Eq )")
|
|
|
@PostMapping("/sy2eq")
|
|
|
- fun sy2Eq(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun sy2Eq(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val rSyEqList = rSyEqService.select(
|
|
@@ -259,7 +260,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "设备和竖井关系-同步到中台", description = "设备所在的竖井(图类型 MechInArch 边类型 Eq2Sh ),设备服务的竖井(图类型 MechForArch 边类型 Eq2Sh), ")
|
|
|
@PostMapping("/eq2sh")
|
|
|
- fun eq2Sh(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun eq2Sh(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
if (graphCode == "MechInArch") {
|
|
@@ -307,7 +308,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "设备和空间关系-同步到中台", description = "设备所在的空间(图类型 MechInArch 边类型 Eq2Sp ),设备服务的空间(图类型 MechForArch 边类型 Eq2Sp), ")
|
|
|
@PostMapping("/eq2sp")
|
|
|
- fun eq2Sp(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun eq2Sp(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val rEq2SpList = rEq2SpService.select(
|
|
@@ -339,7 +340,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "设备和部件关系-同步到中台", description = "设备下部件(图类型 MechSubset 边类型 Eq2Ec )")
|
|
|
@PostMapping("/eq2ec")
|
|
|
- fun eq2Ec(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun eq2Ec(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val equipmentList =
|
|
@@ -373,7 +374,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "系统和竖井关系-同步到中台", description = "系统所在的竖井(图类型 MechInArch 边类型 Sy2Sh ),系统服务于竖井(图类型MechForArch 边类型 Sy2Sh )")
|
|
|
@PostMapping("/sy2sh")
|
|
|
- fun sy2Sh(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse{
|
|
|
+ fun sy2Sh(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse{
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
if (graphCode == "MechInArch") {
|
|
@@ -424,7 +425,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "竖井下的业务空间关系-同步到中台", description = "竖井下的业务空间(图类型 ArchSubset 边类型 Sh2Sp )")
|
|
|
@PostMapping("/sh2sp")
|
|
|
- fun sh2Sp(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun sh2Sp(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val rSh2SpList = rSh2SpService.select(SFilter.eq("projectId", projectId)).exec()
|
|
@@ -454,7 +455,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "建筑体下的竖井关系-同步到中台", description = "建筑体下的竖井(图类型 ArchSubset 边类型 Bd2Sh )")
|
|
|
@PostMapping("/bd2sh")
|
|
|
- fun bd2sh(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun bd2sh(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val rShInBdList = rShInBdService.select(SFilter.eq("projectId", projectId)).exec()
|
|
@@ -486,7 +487,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "竖井贯通关系-同步到中台", description = "竖井贯通关系(图类型 ThroughRelationship 边类型 Sh2Sh )")
|
|
|
@PostMapping("/sh2sh")
|
|
|
- fun sh2sh(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun sh2sh(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val rShaftThroughShaftList = rShaftThroughShaftService.select(SFilter.eq("projectId", projectId)).exec()
|
|
@@ -516,7 +517,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "系统和楼层关系-同步到中台", description = "系统所在的楼层(图类型 MechInArch 边类型 Sy2Fl ),系统服务于楼层(图类型MechForArch 边类型 Sy2Fl )")
|
|
|
@PostMapping("/sy2fl")
|
|
|
- fun sy2fl(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse{
|
|
|
+ fun sy2fl(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse{
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
if (graphCode == "MechInArch") {
|
|
@@ -566,7 +567,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "系统和楼层关系-同步到中台", description = "系统所在的建筑体(图类型 MechInArch 边类型 Sy2Bd ),系统服务于建筑体(图类型MechForArch 边类型 Sy2Bd )")
|
|
|
@PostMapping("/sy2bd")
|
|
|
- fun sy2bd(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse{
|
|
|
+ fun sy2bd(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse{
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
if (graphCode == "MechInArch") {
|
|
@@ -617,7 +618,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "建筑体下的楼层-同步到中台", description = "建筑体下的楼层(图类型 ArchSubset 边类型 Bd2Fl )")
|
|
|
@PostMapping("/bd2fl")
|
|
|
- fun bd2fl(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun bd2fl(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val floorList = floorService.select(SFilter.eq("projectId", projectId)).exec()
|
|
@@ -648,7 +649,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "楼层下的业务空间-同步到中台", description = "楼层下的业务空间(图类型 ArchSubset 边类型 Fl2Sp )")
|
|
|
@PostMapping("/fl2sp")
|
|
|
- fun fl2sp(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun fl2sp(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val rSpinFlList = rSpinFlService.select(SFilter.eq("projectId", projectId)).exec()
|
|
@@ -678,7 +679,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "建筑体下的业务空间-同步到中台", description = "建筑体下的业务空间(图类型 ArchSubset 边类型 Bd2Sp )")
|
|
|
@PostMapping("/bd2sp")
|
|
|
- fun bd2sp(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun bd2sp(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val rSpinBdList = rSpinBdService.select(SFilter.eq("projectId", projectId)).exec()
|
|
@@ -708,7 +709,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "楼层贯通关系-同步到中台", description = "楼层贯通关系(图类型 ThroughRelationship 边类型 Fl2Fl )")
|
|
|
@PostMapping("/fl2fl")
|
|
|
- fun fl2fl(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun fl2fl(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val rFlThroughFlList = rFlThroughFlService.select(SFilter.eq("projectId", projectId)).exec()
|
|
@@ -738,7 +739,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "系统和业务空间关系-同步到中台", description = "系统所在业务空间(图类型 MechInArch 边类型 Sy2Bd ),系统服务于业务空间(图类型MechForArch 边类型 Sy2Bd )")
|
|
|
@PostMapping("/sy2sp")
|
|
|
- fun sy2sp(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse{
|
|
|
+ fun sy2sp(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse{
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
if (graphCode == "MechInArch") {
|
|
@@ -792,7 +793,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "空间和空间的关系-同步到中台", description = "")
|
|
|
@PostMapping("/sp2sp")
|
|
|
- fun sp2sp(projectId: String,graphCode: String,type: String,isDel: Boolean = false): SBaseResponse {
|
|
|
+ fun sp2sp(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false): SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val relContrast = Configure.relContrast(graphCode, type)
|
|
@@ -827,7 +828,7 @@ class RelToFromController {
|
|
|
*/
|
|
|
@Operation(summary= "设备和设备的关系-同步到中台", description = "")
|
|
|
@PostMapping("/eq2eq")
|
|
|
- fun eq2eq(projectId: String,graphCode: String,type: String,isDel: Boolean = false) : SBaseResponse {
|
|
|
+ fun eq2eq(@RequestParam projectId: String,@RequestParam graphCode: String,@RequestParam type: String,@RequestParam isDel: Boolean = false) : SBaseResponse {
|
|
|
try {
|
|
|
val dictProject = dictProjectService.select(SFilter.eq("id", projectId)).entity()
|
|
|
val relContrastEq = Configure.relContrastEq(graphCode, type)
|