Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
I
integrate-server
Project
Project
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
Graph
比较
统计图
议题
0
议题
0
列表
看板
标记
Milestones
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
inroi
integrate-server
Commits
ddb024fb
提交
ddb024fb
authored
12月 14, 2022
作者:
inroi
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
微调
上级
3534142d
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
32 行增加
和
5 行删除
+32
-5
LicFileController.java
...rc/main/java/com/system/controller/LicFileController.java
+8
-5
ILicFileService.java
...tem/src/main/java/com/system/serivce/ILicFileService.java
+11
-0
LicFileServiceImpl.java
...main/java/com/system/serivce/impl/LicFileServiceImpl.java
+13
-0
没有找到文件。
integrate-system/src/main/java/com/system/controller/LicFileController.java
浏览文件 @
ddb024fb
...
@@ -6,10 +6,7 @@ import com.system.transfer.response.RestResponse;
...
@@ -6,10 +6,7 @@ import com.system.transfer.response.RestResponse;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.ModelAttribute
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
/**
/**
* @author Inori
* @author Inori
...
@@ -29,7 +26,13 @@ public class LicFileController {
...
@@ -29,7 +26,13 @@ public class LicFileController {
return
licFileService
.
licInfoFileImport
(
inVo
);
return
licFileService
.
licInfoFileImport
(
inVo
);
}
}
@ApiOperation
(
"Lic文件下载"
)
@ApiOperation
(
"获取MAC地址"
)
@GetMapping
(
"/lic/info/file/download"
)
public
RestResponse
macAddressDetail
()
{
return
licFileService
.
macAddressDetail
();
}
@ApiOperation
(
"流下载文件(测试)"
)
@PostMapping
(
"/lic/info/file/download"
)
@PostMapping
(
"/lic/info/file/download"
)
public
RestResponse
licInfoFileDownload
()
{
public
RestResponse
licInfoFileDownload
()
{
return
licFileService
.
licInfoFileDownload
();
return
licFileService
.
licInfoFileDownload
();
...
...
integrate-system/src/main/java/com/system/serivce/ILicFileService.java
浏览文件 @
ddb024fb
...
@@ -16,7 +16,18 @@ public interface ILicFileService {
...
@@ -16,7 +16,18 @@ public interface ILicFileService {
*/
*/
RestResponse
licInfoFileImport
(
LicInfoFileImportInVo
inVo
);
RestResponse
licInfoFileImport
(
LicInfoFileImportInVo
inVo
);
/**
* 获取MAC地址
*
* @return 结果
*/
RestResponse
macAddressDetail
();
/**
* 流下载文件(测试)
*
* @return 结果
*/
RestResponse
licInfoFileDownload
();
RestResponse
licInfoFileDownload
();
...
...
integrate-system/src/main/java/com/system/serivce/impl/LicFileServiceImpl.java
浏览文件 @
ddb024fb
...
@@ -13,6 +13,9 @@ import org.springframework.stereotype.Service;
...
@@ -13,6 +13,9 @@ import org.springframework.stereotype.Service;
import
org.springframework.util.CollectionUtils
;
import
org.springframework.util.CollectionUtils
;
import
java.io.*
;
import
java.io.*
;
import
java.net.InetAddress
;
import
java.net.SocketException
;
import
java.net.UnknownHostException
;
import
java.text.SimpleDateFormat
;
import
java.text.SimpleDateFormat
;
import
java.util.Date
;
import
java.util.Date
;
import
java.util.Map
;
import
java.util.Map
;
...
@@ -64,6 +67,16 @@ public class LicFileServiceImpl implements ILicFileService {
...
@@ -64,6 +67,16 @@ public class LicFileServiceImpl implements ILicFileService {
}
}
@Override
@Override
public
RestResponse
macAddressDetail
()
{
try
{
return
RestResponse
.
success
(
LocalMacUtil
.
getLocalMac
(
InetAddress
.
getLocalHost
()));
}
catch
(
SocketException
|
UnknownHostException
e
)
{
e
.
printStackTrace
();
return
RestResponse
.
fail
(
"获取MAC地址失败"
);
}
}
@Override
public
RestResponse
licInfoFileDownload
()
{
public
RestResponse
licInfoFileDownload
()
{
BufferedInputStream
bis
=
null
;
BufferedInputStream
bis
=
null
;
FileOutputStream
fos
=
null
;
FileOutputStream
fos
=
null
;
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论