Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
d9eb09cf
Commit
d9eb09cf
authored
Aug 20, 2024
by
taabe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
96333大屏统计接口移至statistics服务
parent
cf4d521e
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
121 additions
and
0 deletions
+121
-0
pom.xml
...module-statistics/amos-boot-module-statistics-api/pom.xml
+5
-0
EmergencyBizController.java
...dule/statistcs/biz/controller/EmergencyBizController.java
+39
-0
EmergencyBizServiceImpl.java
...e/statistcs/biz/service/impl/EmergencyBizServiceImpl.java
+0
-0
JsonUtils.java
...ejoin/amos/boot/module/statistcs/biz/utils/JsonUtils.java
+14
-0
emergencyInformation.json
...ics-biz/src/main/resources/json/emergencyInformation.json
+63
-0
No files found.
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-api/pom.xml
View file @
d9eb09cf
...
@@ -22,6 +22,11 @@
...
@@ -22,6 +22,11 @@
<artifactId>
amos-boot-module-jg-api
</artifactId>
<artifactId>
amos-boot-module-jg-api
</artifactId>
<version>
${amos-boot-biz.version}
</version>
<version>
${amos-boot-biz.version}
</version>
</dependency>
</dependency>
<dependency>
<groupId>
com.amosframework.boot
</groupId>
<artifactId>
amos-boot-module-96333-api
</artifactId>
<version>
${amos-boot-biz.version}
</version>
</dependency>
</dependencies>
</dependencies>
...
...
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-biz/src/main/java/com/yeejoin/amos/boot/module/statistcs/biz/controller/EmergencyBizController.java
0 → 100644
View file @
d9eb09cf
package
com
.
yeejoin
.
amos
.
boot
.
module
.
statistcs
.
biz
.
controller
;
import
com.yeejoin.amos.boot.module.statistcs.biz.service.impl.EmergencyBizServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.PathVariable
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
@RestController
@RequestMapping
(
value
=
"/dp/biz/emergency"
)
@Api
(
tags
=
"大屏-应急-业务API"
)
public
class
EmergencyBizController
{
private
EmergencyBizServiceImpl
emergencyBizService
;
public
EmergencyBizController
(
EmergencyBizServiceImpl
emergencyBizService
)
{
this
.
emergencyBizService
=
emergencyBizService
;
}
/**
* 应急大屏使用
*
* @param id 主键
* @return Object
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@GetMapping
(
value
=
"/detail/{id}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据id获取应急事件详细信息"
,
notes
=
"根据id获取应急事件详细信息"
)
public
ResponseModel
<
Object
>
getDetail
(
@PathVariable
Long
id
)
{
return
ResponseHelper
.
buildResponse
(
emergencyBizService
.
getDetail
(
id
));
}
}
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-biz/src/main/java/com/yeejoin/amos/boot/module/statistcs/biz/service/impl/EmergencyBizServiceImpl.java
0 → 100644
View file @
d9eb09cf
This diff is collapsed.
Click to expand it.
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-biz/src/main/java/com/yeejoin/amos/boot/module/statistcs/biz/utils/JsonUtils.java
View file @
d9eb09cf
package
com
.
yeejoin
.
amos
.
boot
.
module
.
statistcs
.
biz
.
utils
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
statistcs
.
biz
.
utils
;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.JSONObject
;
import
com.yeejoin.amos.boot.module.elevator.api.dto.FormValue
;
import
org.apache.commons.io.IOUtils
;
import
org.apache.commons.io.IOUtils
;
import
org.springframework.core.io.Resource
;
import
org.springframework.core.io.Resource
;
import
java.io.IOException
;
import
java.io.IOException
;
import
java.nio.charset.StandardCharsets
;
import
java.nio.charset.StandardCharsets
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Map
;
import
static
com
.
alibaba
.
fastjson
.
JSON
.
parseArray
;
public
class
JsonUtils
{
public
class
JsonUtils
{
//将json文件转化为Map<list<Map<>>>
//将json文件转化为Map<list<Map<>>>
...
@@ -19,4 +23,14 @@ public class JsonUtils {
...
@@ -19,4 +23,14 @@ public class JsonUtils {
}
}
return
JSONObject
.
parseObject
(
json
,
Map
.
class
);
return
JSONObject
.
parseObject
(
json
,
Map
.
class
);
}
}
public
static
List
<
FormValue
>
getJsonData
(
Resource
resource
)
{
String
json
;
try
{
json
=
IOUtils
.
toString
(
resource
.
getInputStream
(),
String
.
valueOf
(
StandardCharsets
.
UTF_8
));
}
catch
(
IOException
e
)
{
throw
new
RuntimeException
(
e
);
}
return
parseArray
(
json
,
FormValue
.
class
);
}
}
}
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-biz/src/main/resources/json/emergencyInformation.json
0 → 100644
View file @
d9eb09cf
[
{
"key"
:
"emergencyPerson"
,
"label"
:
"救援人姓名"
,
"type"
:
"text"
},
{
"key"
:
"callTime"
,
"label"
:
"接警时间"
,
"type"
:
"text"
},
{
"key"
:
"contactPhone"
,
"label"
:
"联系人电话"
,
"type"
:
"text"
},
{
"key"
:
"useSiteCategory"
,
"label"
:
"使用场所分类"
,
"type"
:
"text"
},
{
"key"
:
"deviceId"
,
"label"
:
"电梯识别码"
,
"type"
:
"text"
},
{
"key"
:
"useStatus"
,
"label"
:
"使用情况"
,
"type"
:
"text"
},
{
"key"
:
"address"
,
"label"
:
"地址"
,
"type"
:
"text"
},
{
"key"
:
"useUnitName"
,
"label"
:
"使用单位"
,
"type"
:
"text"
},
{
"key"
:
"principalPhone"
,
"label"
:
"单位电话"
,
"type"
:
"text"
},
{
"key"
:
"unitAddress"
,
"label"
:
"单位地址"
,
"type"
:
"text"
},
{
"key"
:
"securityAdministrator"
,
"label"
:
"电梯安全管理员"
,
"type"
:
"text"
},
{
"key"
:
"securityAdministratorPhone"
,
"label"
:
"电梯安全管理员电话"
,
"type"
:
"text"
}
]
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment