Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
Z
zhmes-agecal
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
耿迪迪
zhmes-agecal
Commits
6452389e
Commit
6452389e
authored
Sep 16, 2025
by
wanghao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1 老化柜层 加上 上料 和 下料操作
2 设置 回零 和 停止操作 机械臂
parent
bffaa226
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
162 additions
and
8 deletions
+162
-8
TStoreyInfoController.java
...ehong/web/controller/equipment/TStoreyInfoController.java
+16
-0
IRobotArmCommandService.java
...va/com/zehong/system/service/IRobotArmCommandService.java
+2
-0
ITStoreyInfoService.java
...n/java/com/zehong/system/service/ITStoreyInfoService.java
+4
-0
RobotArmCommandServiceImpl.java
...ehong/system/service/impl/RobotArmCommandServiceImpl.java
+13
-0
TStoreyInfoServiceImpl.java
...om/zehong/system/service/impl/TStoreyInfoServiceImpl.java
+29
-0
storey.js
zhmes-agecal-web/src/api/storey/storey.js
+13
-0
index.vue
zhmes-agecal-web/src/views/storey/index.vue
+85
-8
No files found.
zhmes-agecal-admin/src/main/java/com/zehong/web/controller/equipment/TStoreyInfoController.java
View file @
6452389e
...
...
@@ -80,6 +80,22 @@ public class TStoreyInfoController extends BaseController
return
tStoreyInfoService
.
powerOutage
(
tStoreyInfo
);
}
/**
* 处理喂食
*/
@GetMapping
(
value
=
"/handleFeeding"
)
public
AjaxResult
handleFeeding
(
String
command
)
{
return
tStoreyInfoService
.
handleFeeding
(
command
);
}
/**
* 处理消 blanking
*/
@GetMapping
(
value
=
"/handleBlanking"
)
public
AjaxResult
handleBlanking
(
String
command
)
{
return
tStoreyInfoService
.
handleBlanking
(
command
);
}
/**
* 批量读取老化柜状态
*/
...
...
zhmes-agecal-system/src/main/java/com/zehong/system/service/IRobotArmCommandService.java
View file @
6452389e
...
...
@@ -70,6 +70,8 @@ public interface IRobotArmCommandService
void
sendStopCommand
();
void
sendCommand
(
String
command
);
void
markCommandTimeout
(
Long
commandId
);
public
void
processPendingCommands
();
}
zhmes-agecal-system/src/main/java/com/zehong/system/service/ITStoreyInfoService.java
View file @
6452389e
...
...
@@ -49,6 +49,10 @@ public interface ITStoreyInfoService
public
AjaxResult
powerOnAllStore
();
public
AjaxResult
handleFeeding
(
String
command
);
public
AjaxResult
handleBlanking
(
String
command
);
/**
* 新增老化层信息
*
...
...
zhmes-agecal-system/src/main/java/com/zehong/system/service/impl/RobotArmCommandServiceImpl.java
View file @
6452389e
...
...
@@ -157,6 +157,19 @@ public class RobotArmCommandServiceImpl implements IRobotArmCommandService
);
}
/**
* 发送指令
* @param command c
*/
@Override
public
void
sendCommand
(
String
command
)
{
SocketAddress
robotAddress
=
getRobotAddress
();
udpCommandSender
.
sendCommandWithId
(
robotAddress
,
command
);
}
@Override
@Transactional
public
void
completeCommand
(
Long
commandId
)
{
...
...
zhmes-agecal-system/src/main/java/com/zehong/system/service/impl/TStoreyInfoServiceImpl.java
View file @
6452389e
package
com
.
zehong
.
system
.
service
.
impl
;
import
java.net.SocketAddress
;
import
java.util.*
;
import
java.util.concurrent.CompletableFuture
;
import
java.util.concurrent.ExecutorService
;
...
...
@@ -16,6 +17,7 @@ import com.zehong.common.utils.StringUtils;
import
com.zehong.system.domain.TEquipmentInfo
;
import
com.zehong.system.mapper.TEquipmentInfoMapper
;
import
com.zehong.system.modbus.util.Modbus4jUtils
;
import
com.zehong.system.service.IRobotArmCommandService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
com.zehong.system.mapper.TStoreyInfoMapper
;
...
...
@@ -39,6 +41,9 @@ public class TStoreyInfoServiceImpl implements ITStoreyInfoService
@Resource
private
TEquipmentInfoMapper
equipmentInfoMapper
;
@Resource
private
IRobotArmCommandService
robotArmCommandService
;
private
final
ExecutorService
executorService
=
Executors
.
newFixedThreadPool
(
10
);
/**
...
...
@@ -227,6 +232,30 @@ public class TStoreyInfoServiceImpl implements ITStoreyInfoService
return
AjaxResult
.
success
();
}
/**
* 批量处理
* @param command c
* @return r
*/
@Override
public
AjaxResult
handleFeeding
(
String
command
)
{
// 发送UDP指令
robotArmCommandService
.
sendCommand
(
command
);
return
AjaxResult
.
success
();
}
/**
* 批量关灯
* @return r
*/
@Override
public
AjaxResult
handleBlanking
(
String
command
)
{
// 发送UDP指令
robotArmCommandService
.
sendCommand
(
command
);
return
AjaxResult
.
success
();
}
/**
* 批量开灯
* @return r
...
...
zhmes-agecal-web/src/api/storey/storey.js
View file @
6452389e
...
...
@@ -77,6 +77,19 @@ export function PowerOutage( query) {
})
}
export
function
feeding
(
command
)
{
return
request
({
url
:
'/storey/handleFeeding/'
+
command
,
method
:
'get'
})
}
export
function
blanking
(
command
)
{
return
request
({
url
:
'/storey/handleBlanking/'
+
command
,
method
:
'get'
})
}
export
function
batchReadingCabinetStatus
(
fEquipmentCode
)
{
return
request
({
url
:
'/storey/batchReadingCabinetStatus/'
+
fEquipmentCode
,
...
...
zhmes-agecal-web/src/views/storey/index.vue
View file @
6452389e
...
...
@@ -56,7 +56,7 @@
</el-col>
<el-col
:span=
"1.5"
>
<el-button
type=
"
warning
"
type=
"
info
"
plain
icon=
"el-icon-reading"
size=
"mini"
...
...
@@ -65,22 +65,42 @@
</el-col>
<el-col
:span=
"1.5"
>
<el-button
type=
"
warning
"
type=
"
danger
"
plain
icon=
"el-icon-
reading
"
icon=
"el-icon-
circle-plus
"
size=
"mini"
@
click=
"handleAllPowerOn"
>
所有设备上电
</el-button>
</el-col>
<el-col
:span=
"1.5"
>
<el-button
type=
"
warning
"
type=
"
danger
"
plain
icon=
"el-icon-re
ading
"
icon=
"el-icon-re
move
"
size=
"mini"
@
click=
"handleAllPowerOff"
>
所有设备断电
</el-button>
</el-col>
<el-col
:span=
"1.5"
>
<el-button
type=
"danger"
plain
icon=
"el-icon-refresh"
size=
"mini"
@
click=
"handleHome"
>
机械臂回零
</el-button>
</el-col>
<el-col
:span=
"1.5"
>
<el-button
type=
"danger"
plain
icon=
"el-icon-circle-close"
size=
"mini"
@
click=
"handleStop"
>
机械臂停止
</el-button>
</el-col>
<right-toolbar
:showSearch
.
sync=
"showSearch"
@
queryTable=
"getList"
></right-toolbar>
</el-row>
...
...
@@ -127,20 +147,31 @@
icon
=
"el-icon-delete"
@
click
=
"handleDelete(scope.row)"
>
删除
<
/el-button
>
<
el
-
button
size
=
"mini"
type
=
"text"
icon
=
"el-icon-delete"
@
click
=
"handlePowerOn(scope.row)"
>
上电
<
/el-button
>
<
el
-
button
size
=
"mini"
type
=
"text"
icon
=
"el-icon-delete"
@
click
=
"handlePowerOutage(scope.row)"
>
断电
<
/el-button
>
<
el
-
button
size
=
"mini"
type
=
"text"
icon
=
"el-icon-delete"
@
click
=
"handleFeeding(scope.row)"
>
上料
<
/el-button
>
<
el
-
button
size
=
"mini"
type
=
"text"
icon
=
"el-icon-delete"
@
click
=
"handleBlanking(scope.row)"
>
下料
<
/el-button
>
<
/template
>
<
/el-table-column
>
<
/el-table
>
...
...
@@ -202,7 +233,11 @@
<
/template
>
<
script
>
import
{
listStorey
,
getStorey
,
delStorey
,
addStorey
,
updateStorey
,
exportStorey
,
PowerOn
,
PowerOutage
,
batchReadingCabinetStatus
,
powerOnAllStore
,
powerOffAllStore
}
from
"@/api/storey/storey"
;
import
{
listStorey
,
getStorey
,
delStorey
,
addStorey
,
updateStorey
,
exportStorey
,
PowerOn
,
PowerOutage
,
batchReadingCabinetStatus
,
powerOnAllStore
,
powerOffAllStore
,
feeding
,
blanking
}
from
"@/api/storey/storey"
;
import
{
sendHomeCommand
,
sendStopCommand
}
from
"@/api/robotArm/robotArmCommand"
;
export
default
{
name
:
"Info"
,
...
...
@@ -365,6 +400,34 @@ export default {
this
.
msgSuccess
(
"上电成功"
);
}
).
catch
(()
=>
{
}
);
}
,
// 上料
handleFeeding
(
row
)
{
const
fIp
=
row
.
fIp
;
this
.
$confirm
(
'是否确认给设备IP为"'
+
fIp
+
'"的设备上料?'
,
"警告"
,
{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
"warning"
}
).
then
(
function
()
{
return
feeding
(
row
.
feedingCommand
);
}
).
then
(()
=>
{
this
.
getList
();
this
.
msgSuccess
(
"上电成功"
);
}
).
catch
(()
=>
{
}
);
}
,
// 下料
handleBlanking
(
row
)
{
const
fIp
=
row
.
fIp
;
this
.
$confirm
(
'是否确认给设备IP为"'
+
fIp
+
'"的设备下料?'
,
"警告"
,
{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
"warning"
}
).
then
(
function
()
{
return
blanking
(
row
.
blankingCommand
);
}
).
then
(()
=>
{
this
.
getList
();
this
.
msgSuccess
(
"上电成功"
);
}
).
catch
(()
=>
{
}
);
}
,
// 断电
handlePowerOutage
(
row
)
{
const
fIp
=
row
.
fIp
;
...
...
@@ -430,6 +493,20 @@ export default {
this
.
msgSuccess
(
"上电成功"
);
}
).
catch
(()
=>
{
}
);
}
,
// 回零
handleHome
()
{
sendHomeCommand
().
then
(
response
=>
{
this
.
$message
.
success
(
"已发送"
);
}
)
}
,
// 停止
handleStop
()
{
sendStopCommand
().
then
(
response
=>
{
this
.
$message
.
success
(
"已发送"
);
}
)
}
,
/** 导出按钮操作 */
handleExport
()
{
const
queryParams
=
this
.
queryParams
;
...
...
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