diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/.idea/artifacts/PgInterface.xml b/.idea/artifacts/PgInterface.xml
index b8260a5..2c54522 100644
--- a/.idea/artifacts/PgInterface.xml
+++ b/.idea/artifacts/PgInterface.xml
@@ -91,6 +91,7 @@
+
diff --git a/.idea/artifacts/PgInterface_war.xml b/.idea/artifacts/PgInterface_war.xml
deleted file mode 100644
index 41f5a90..0000000
--- a/.idea/artifacts/PgInterface_war.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- $PROJECT_DIR$/target
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/artifacts/PgInterface_war_exploded.xml b/.idea/artifacts/PgInterface_war_exploded.xml
deleted file mode 100644
index 52a4834..0000000
--- a/.idea/artifacts/PgInterface_war_exploded.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-
-
- $PROJECT_DIR$/target/PgInterface
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/fastjson_1_2_53.xml b/.idea/libraries/fastjson_1_2_53.xml
new file mode 100644
index 0000000..caf0ea2
--- /dev/null
+++ b/.idea/libraries/fastjson_1_2_53.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 6c05feb..82b1019 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -7,47 +7,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -78,8 +63,8 @@
-
-
+
+
@@ -87,40 +72,41 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
+
-
+
@@ -137,20 +123,21 @@
-
+
-
+
+
-
+
@@ -158,72 +145,47 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -232,14 +194,34 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -269,8 +251,14 @@
I
inCriteria
getPgPlanResulList
- getPipeLineBylineName
getPileAcuListByPileAcuStr
+ distinct
+ order
+ canPlanLine
+ isExistLine
+ getPlanResult
+ pgPipeLine
+ getPipeLineBylineName
@@ -279,12 +267,6 @@
-
-
-
-
-
-
@@ -305,29 +287,35 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -367,8 +355,8 @@
-
-
+
+
@@ -376,7 +364,6 @@
-
@@ -384,83 +371,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -473,6 +388,11 @@
+
+
+
+
+
@@ -635,7 +555,12 @@
-
+
+
+
+
+
+
1564361618083
@@ -721,11 +646,18 @@
1568768749481
-
+
+ 1573608273315
+
+
+
+ 1573608273315
+
+
-
+
@@ -738,9 +670,8 @@
-
-
+
@@ -749,9 +680,9 @@
-
+
-
+
@@ -777,7 +708,7 @@
-
+
@@ -841,7 +772,8 @@
-
+
+
@@ -860,48 +792,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -986,13 +876,6 @@
-
-
-
-
-
-
-
@@ -1000,13 +883,6 @@
-
-
-
-
-
-
-
@@ -1021,62 +897,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1084,48 +904,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1149,30 +927,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -1180,64 +934,225 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
@@ -1296,11 +1211,12 @@
- Web|PgInterface
+ PgInterface
+
diff --git a/PgInterface.iml b/PgInterface.iml
index 30b90ae..94ce0b1 100644
--- a/PgInterface.iml
+++ b/PgInterface.iml
@@ -115,5 +115,6 @@
+
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
index 5c2c8c7..45efe50 100644
--- a/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
+++ b/src/main/java/com/casic/PgInterface/core/hibernate/HibernateGenericDao.java
@@ -129,7 +129,7 @@
if (isAsc) {
criteria.addOrder(Order.asc(orderBy));
} else {
- criteria.addOrder(Order.desc(orderBy));
+
}
return criteria;
diff --git a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
index 27f01b3..2f9a15c 100644
--- a/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
+++ b/src/main/java/com/casic/PgInterface/devTable/manager/PgPipeLineManager.java
@@ -104,8 +104,7 @@
return pgPipeLineTypeNumDtoList;
}
- public Map addPipeLine(String lineCode, String lineType, String ownerUnit, String diameter,
- String secRow, String secColumn, String pileAcuList){
+ public Map addPipeLine(String lineType,String secRow, String secColumn, String pileAcuList){
Map resultMap=new HashMap<>();
String msg="";
String result="";
@@ -115,10 +114,7 @@
Long acuLength=pgPileAcuManager.getAcuListLength(pgPileAcuList);
try{
PgPipeLine pgPipeLine=new PgPipeLine();
- pgPipeLine.setLineCode(lineCode);
pgPipeLine.setLineType(lineType);
- pgPipeLine.setOwnerUnit(ownerUnit);
- pgPipeLine.setDiameter(diameter);
pgPipeLine.setLength(acuLength);
pgPipeLine.setActive(1);
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
index a085001..c8810f8 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/domain/PgLineHole.java
@@ -9,7 +9,7 @@
public class PgLineHole implements Serializable {
private Long id;
- private String lineName;//入廊管线ID
+ private String lineName;//入廊管线
private Long pileAcuId;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
index 010b438..8559da7 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineHoleDTO.java
@@ -1,10 +1,18 @@
package com.casic.PgInterface.intelPlan.dto;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
+import com.casic.PgInterface.intelPlan.domain.PgLineHole;
+import com.casic.PgInterface.intelPlan.manager.PgPileAcuManager;
+
+import java.util.ArrayList;
+import java.util.List;
+
public class PgLineHoleDTO {
private Long id;
private String lineName;//管线
- private Long pileAcuId;//桩分区ID
+ private String road;
+ private String pileAcuCode;//桩分区ID
private Long secRow;//行号
private Long secColumn;//列号
private boolean active;//状态位
@@ -25,12 +33,20 @@
this.lineName = lineName;
}
- public Long getPileAcuId() {
- return pileAcuId;
+ public String getRoad() {
+ return road;
}
- public void setPileAcuId(Long pileAcuId) {
- this.pileAcuId = pileAcuId;
+ public void setRoad(String road) {
+ this.road = road;
+ }
+
+ public String getPileAcuCode() {
+ return pileAcuCode;
+ }
+
+ public void setPileAcuCode(String pileAcuCode) {
+ this.pileAcuCode = pileAcuCode;
}
public Long getSecRow() {
@@ -56,4 +72,38 @@
public void setActive(boolean active) {
this.active = active;
}
+
+ public static PgLineHoleDTO ConvertToDTO(PgLineHole pgLineHole, PgPileAcuManager pgPileAcuManager, PgRoadManager pgRoadManager){
+
+ PgLineHoleDTO pgLineHoleDTO=new PgLineHoleDTO();
+ pgLineHoleDTO.setId(pgLineHole.getId());
+ pgLineHoleDTO.setLineName(pgLineHole.getLineName());
+ pgLineHoleDTO.setSecColumn(pgLineHole.getSecColumn());
+ pgLineHoleDTO.setSecRow(pgLineHole.getSecRow());
+ if(pgLineHole.getPileAcuId()==null||pgPileAcuManager.get(pgLineHole.getPileAcuId())==null)
+ pgLineHoleDTO.setPileAcuCode("");
+ else
+ {
+ pgLineHoleDTO.setPileAcuCode(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getAcuCode());
+
+ if(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId())==null)
+ pgLineHoleDTO.setRoad("");
+ else
+ pgLineHoleDTO.setRoad(pgRoadManager.get(pgPileAcuManager.get(pgLineHole.getPileAcuId()).getRoadId()).getRoadName());
+ }
+
+ return pgLineHoleDTO;
+
+ }
+
+ public static List ConvertToDTOList(List pgLineHoleList,
+ PgPileAcuManager pgPileAcuManager,PgRoadManager pgRoadManager){
+ List pgLineHoleDTOList=new ArrayList<>();
+
+ for(PgLineHole pgLineHole:pgLineHoleList){
+ pgLineHoleDTOList.add(ConvertToDTO(pgLineHole,pgPileAcuManager,pgRoadManager));
+ }
+
+ return pgLineHoleDTOList;
+ }
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
new file mode 100644
index 0000000..3344311
--- /dev/null
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgLineType.java
@@ -0,0 +1,14 @@
+package com.casic.PgInterface.intelPlan.dto;
+
+public class PgLineType {
+
+ private String lineType;
+
+ public String getLineType() {
+ return lineType;
+ }
+
+ public void setLineType(String lineType) {
+ this.lineType = lineType;
+ }
+}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
index 45a2ceb..5a76933 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanParams.java
@@ -1,5 +1,10 @@
package com.casic.PgInterface.intelPlan.dto;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.TypeReference;
+
import java.util.List;
public class PgPlanParams {
@@ -14,4 +19,17 @@
this.pgPlanTaskList = pgPlanTaskList;
}
+ public List getPgPlanParamsByString(String paramsStr){
+
+ try {
+ String jsonString=String.valueOf(JSON.parse(paramsStr));
+ PgPlanParams pgPlanParams = JSONObject.parseObject(jsonString, new TypeReference() {});
+ List pgPlanTaskList = pgPlanParams.getPgPlanTaskList();
+ return pgPlanTaskList;
+ }
+ catch(Exception ex){
+ return null;
+ }
+ }
+
}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
index 12abaa8..f216360 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/dto/PgPlanResultRe.java
@@ -22,4 +22,5 @@
public void setPgPlanResultList(List pgPlanResultList) {
this.pgPlanResultList = pgPlanResultList;
}
-}
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
index 1ed5723..71ea765 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgLineHoleManager.java
@@ -1,17 +1,28 @@
package com.casic.PgInterface.intelPlan.manager;
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
+import com.casic.PgInterface.devTable.domain.PgRoad;
+import com.casic.PgInterface.devTable.manager.PgRoadManager;
import com.casic.PgInterface.intelPlan.domain.PgLineHole;
import com.casic.PgInterface.intelPlan.domain.PgPileAcu;
+import com.casic.PgInterface.intelPlan.dto.PgLineHoleDTO;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
+import javax.annotation.Resource;
+import java.util.ArrayList;
import java.util.List;
@Service
public class PgLineHoleManager extends HibernateEntityDao {
+ @Resource
+ private PgPileAcuManager pgPileAcuManager;
+
+ @Resource
+ private PgRoadManager pgRoadManager;
+
public List getPgLineHole(String lineName,Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
@@ -35,18 +46,19 @@
return false;
}
- public List getCurrentHoleByAcu(Long pileAcuId){
+ public List getCurrentHoleByAcu(Long pileAcuId){
Criteria criteria=createCriteria(PgLineHole.class);
criteria.add(Restrictions.eq("pileAcuId",pileAcuId));
criteria.add(Restrictions.eq("active",true));
List pgLineHoleList=criteria.list();
-
+ List pgLineHoleDTOList=new ArrayList<>();
if(pgLineHoleList==null||pgLineHoleList.size()==0)
return null;
else
- return pgLineHoleList;
+ pgLineHoleDTOList=PgLineHoleDTO.ConvertToDTOList(pgLineHoleList,pgPileAcuManager,pgRoadManager);
+ return pgLineHoleDTOList;
}
public void addPgLIneHole(List pgPileAcuList,String lineName,String secRow,String secColumn){
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
index 2947ec4..0fd9e1f 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileAcuManager.java
@@ -83,7 +83,6 @@
//获取pgPlanResultList
PgSection pgSection=pgSectionManager.getPgSectionByRoadAndLine(lineName,raodId);
pgPlanResultList=getPlanResult(lineName,pgPileAcuList,pgSection);
-
}
catch(Exception ex){
ex.printStackTrace();
@@ -109,18 +108,21 @@
pgPlanResult.setSecRow(row);
pgPlanResult.setLength(getAcuListLength(pgPileAcuList));
pgPlanResultList.add(pgPlanResult);
+
+ return pgPlanResultList;
}
}
}
- return pgPlanResultList;
+ return null;
}
private boolean canPlanLine(String lineName,List pgPileAcuList,int row,int column){
try {
for (PgPileAcu pgPileAcu : pgPileAcuList) {
List pgLineHoleList = pgLineHoleManager.getPgLineHole(lineName, pgPileAcu.getId());
- if (pgLineHoleManager.isExistLine(pgLineHoleList, row, column)) return false;
+ if(pgLineHoleList!=null&&pgLineHoleList.size()!=0&&pgLineHoleManager.isExistLine(pgLineHoleList, row, column))
+ return false;
}
return true;
}
@@ -132,7 +134,7 @@
public Long getAcuListLength(List pgPileAcuList){
- Long length=null;
+ long length=0;
for(PgPileAcu pgPileAcu:pgPileAcuList){
length+=pgPileAcu.getLength();
}
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
index 31ce1a4..7038b4d 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgPileManager.java
@@ -4,6 +4,7 @@
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.dto.PgPileDTO;
import org.hibernate.Criteria;
+import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Service;
@@ -16,6 +17,7 @@
public List getPgPileDTOList(){
Criteria criteria=createCriteria(PgPile.class);
criteria.add(Restrictions.eq("active",true));
+ criteria.addOrder(Order.desc("id"));
List pgPileList=criteria.list();
List pgPileDTOList=new ArrayList<>();
diff --git a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
index 2393258..482b7e6 100644
--- a/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
+++ b/src/main/java/com/casic/PgInterface/intelPlan/manager/PgSectionManager.java
@@ -3,10 +3,13 @@
import com.casic.PgInterface.core.hibernate.HibernateEntityDao;
import com.casic.PgInterface.intelPlan.domain.PgPile;
import com.casic.PgInterface.intelPlan.domain.PgSection;
+import com.casic.PgInterface.intelPlan.dto.PgLineType;
import org.hibernate.Criteria;
import org.hibernate.criterion.Restrictions;
+import org.omg.CORBA.OBJ_ADAPTER;
import org.springframework.stereotype.Service;
+import java.util.ArrayList;
import java.util.List;
@Service
@@ -14,7 +17,7 @@
public PgSection getPgSectionByRoadAndLine(String lineName,Long roadId){
- Criteria criteria=createCriteria(PgPile.class);
+ Criteria criteria=createCriteria(PgSection.class);
criteria.add(Restrictions.eq("lineName",lineName));
criteria.add(Restrictions.eq("roadId",roadId));
criteria.add(Restrictions.eq("active",true));
@@ -26,5 +29,20 @@
return pgSectionList.get(0);
}
+ public List getLineType(){
+
+ List pgLineTypeList=new ArrayList<>();
+ String sql="select distinct linename from pg_section where active = 1";
+
+ List