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"
|
||||
|
||||
import (
|
||||
"base.api"
|
||||
)
|
||||
|
||||
type (
|
||||
EventLog {
|
||||
Id int `json:"id"`
|
||||
EventType string `json:"eventType"`
|
||||
SourceId string `json:"sourceId"`
|
||||
EntityType string `json:"entityType"`
|
||||
EntityId string `json:"entityId"`
|
||||
EntityVersion int64 `json:"entityVersion"`
|
||||
Description string `json:"description"`
|
||||
Payload string `json:"payload"`
|
||||
CreatedAt string `json:"createdAt"`
|
||||
JobId int `json:"jobId,optional"`
|
||||
WorkpieceNo string `json:"workpieceNo,optional"`
|
||||
EquipmentId int `json:"equipmentId,optional"`
|
||||
EquipmentName string `json:"equipmentName,optional"`
|
||||
TempSlotNo int `json:"tempSlotNo,optional"`
|
||||
}
|
||||
|
||||
LatestEventLogReq {
|
||||
Limit int `form:"limit,default=20,range=[1:100]"`
|
||||
}
|
||||
|
||||
QueryEventLogsReq {
|
||||
PageReq
|
||||
SortReq
|
||||
EventType string `form:"eventType,optional"`
|
||||
EntityType string `form:"entityType,optional"`
|
||||
StartTime string `form:"startTime,optional"`
|
||||
EndTime string `form:"endTime,optional"`
|
||||
WorkpieceNo string `form:"workpieceNo,optional"`
|
||||
JobId int `form:"jobId,optional"`
|
||||
}
|
||||
QueryEventLogsReply {
|
||||
PageReply
|
||||
Data []EventLog `json:"data"`
|
||||
}
|
||||
)
|
||||
|
||||
@server (
|
||||
jwt: Auth
|
||||
group: reports
|
||||
prefix: /api/v1
|
||||
)
|
||||
service hougai-api {
|
||||
@doc "获取最新事件日志"
|
||||
@handler getLatestEventLogs
|
||||
get /event-logs/latest (LatestEventLogReq) returns ([]EventLog)
|
||||
|
||||
@doc "分页查询事件日志"
|
||||
@handler queryEventLogs
|
||||
get /event-logs (QueryEventLogsReq) returns (QueryEventLogsReply)
|
||||
}
|
||||
Reference in New Issue
Block a user