uint/uint64全部改为uint32
This commit is contained in:
@@ -14,7 +14,7 @@ import (
|
||||
)
|
||||
|
||||
type DeviceThresholdCheckParams struct {
|
||||
DeviceID uint `json:"device_id"` // 设备ID
|
||||
DeviceID uint32 `json:"device_id"` // 设备ID
|
||||
SensorType models.SensorType `json:"sensor_type"` // 传感器类型
|
||||
Thresholds float32 `json:"thresholds"` // 阈值
|
||||
Operator models.Operator `json:"operator"` // 操作符
|
||||
@@ -188,10 +188,10 @@ func (d *DeviceThresholdCheckTask) OnFailure(ctx context.Context, executeErr err
|
||||
logger.Errorf("设备阈值检测任务执行失败, 任务ID: %v: 执行失败: %v", d.taskLog.TaskID, executeErr)
|
||||
}
|
||||
|
||||
func (d *DeviceThresholdCheckTask) ResolveDeviceIDs(ctx context.Context) ([]uint, error) {
|
||||
func (d *DeviceThresholdCheckTask) ResolveDeviceIDs(ctx context.Context) ([]uint32, error) {
|
||||
taskCtx := logs.AddFuncName(ctx, d.ctx, "ResolveDeviceIDs")
|
||||
if err := d.parseParameters(taskCtx); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return []uint{d.params.DeviceID}, nil
|
||||
return []uint32{d.params.DeviceID}, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user