|
@@ -7,12 +7,14 @@ import (
|
|
|
|
|
|
type Ota struct {
|
|
|
gorm.Model
|
|
|
- RecordId string `gorm:"column:record_id;size:32;index"`
|
|
|
- Name string `gorm:"column:name;size:30"`
|
|
|
- Url string `gorm:"column:url;size:200"`
|
|
|
- Version string `gorm:"column:version;size:20"`
|
|
|
- Size int `gorm:"column:size;"`
|
|
|
- VendorId string `gorm:"column:vendor_id;size:32;"`
|
|
|
+ RecordId string `gorm:"column:record_id;size:32;index"`
|
|
|
+ Name string `gorm:"column:name;size:30"`
|
|
|
+ Url string `gorm:"column:url;size:200"`
|
|
|
+ Version string `gorm:"column:version;size:20"`
|
|
|
+ Size int `gorm:"column:size;"`
|
|
|
+ ProductId string `gorm:"column:product_id;size:32;index;"`
|
|
|
+ ProductName string `gorm:"column:product_name;size:50;"`
|
|
|
+ VendorId string `gorm:"column:vendor_id;size:32;"`
|
|
|
}
|
|
|
|
|
|
// Validate 验证
|
|
@@ -27,7 +29,7 @@ type OtaUpgradeParams struct {
|
|
|
VendorId string `json:"vendor_id"`
|
|
|
FileId string `json:"file_id"`
|
|
|
ProductId string `json:"product_id"`
|
|
|
- DeviceIDs []string `json:"device_id"`
|
|
|
+ DeviceIDs []string `json:"device_ids"`
|
|
|
}
|
|
|
|
|
|
// Validate 验证
|