fix: rebuild MES as compilable go-zero+ent backend (renamed bj_power_mes), restore 3 workstation projects from pristine original, align naming; all Go projects go build clean
This commit is contained in:
@@ -0,0 +1,58 @@
|
||||
syntax = "v1"
|
||||
|
||||
type (
|
||||
// === 暂存台监控(对齐 frontend-api.md 7.3 节)===
|
||||
|
||||
BufferSlotsReply {
|
||||
Slots []BufferSlotReply `json:"slots"`
|
||||
Occupied int `json:"occupied"`
|
||||
Free int `json:"free"`
|
||||
Total int `json:"total"`
|
||||
}
|
||||
BufferSlotReply {
|
||||
SlotNo int `json:"slotNo"`
|
||||
Status string `json:"status"`
|
||||
Occupied bool `json:"occupied"`
|
||||
Job *JobBrief `json:"job,omitempty"`
|
||||
}
|
||||
JobBrief {
|
||||
Id int `json:"id"`
|
||||
WorkOrderId int `json:"workOrderId"`
|
||||
WorkpieceNo string `json:"workpieceNo"`
|
||||
ProductTypeId int `json:"productTypeId"`
|
||||
Status string `json:"status"`
|
||||
CurrentStepId string `json:"currentStepId"`
|
||||
CurrentStepName string `json:"currentStepName"`
|
||||
DockNo int `json:"dockNo"` // 来源接驳台编号 (0 表示未记录)
|
||||
DockSlotNo int `json:"dockSlotNo"` // 来源接驳台槽位 (0 表示未记录)
|
||||
}
|
||||
|
||||
// === 暂存台重置 ===
|
||||
|
||||
ResetBufferReply {
|
||||
Reset int `json:"reset"` // 实际重置的工件数
|
||||
Items []ResetBufferItem `json:"items"` // 每个工件的处理详情
|
||||
}
|
||||
ResetBufferItem {
|
||||
JobId int `json:"jobId"`
|
||||
WorkpieceNo string `json:"workpieceNo"`
|
||||
FromSlotNo int `json:"fromSlotNo"` // 原暂存台槽位号
|
||||
DockNo int `json:"dockNo"` // 回填到的接驳台编号
|
||||
DockSlotNo int `json:"dockSlotNo"` // 回填到的接驳台槽位
|
||||
}
|
||||
)
|
||||
|
||||
@server (
|
||||
jwt: Auth
|
||||
group: temp_station
|
||||
prefix: /api/v1
|
||||
)
|
||||
service hougai-api {
|
||||
@doc "暂存台槽位监控"
|
||||
@handler listBufferSlots
|
||||
get /buffer/slots returns (BufferSlotsReply)
|
||||
|
||||
@doc "重置暂存台:将在位工件回写到接驳台位置"
|
||||
@handler resetBuffer
|
||||
post /buffer/reset returns (ResetBufferReply)
|
||||
}
|
||||
Reference in New Issue
Block a user