diff --git a/internal/model/device.go b/internal/model/device.go index 1da6f85..fe9167d 100644 --- a/internal/model/device.go +++ b/internal/model/device.go @@ -43,7 +43,7 @@ type Device struct { SoftwareVersion string `gorm:"column:software_version;type:varchar(100);not null;default:'';comment:固件版本号" json:"software_version"` SwitchMode string `gorm:"column:switch_mode;type:varchar(10);not null;default:'0';comment:切卡模式:0=自动 1=手动" json:"switch_mode"` LastGatewaySyncAt *time.Time `gorm:"column:last_gateway_sync_at;comment:最后一次 sync-info 同步时间" json:"last_gateway_sync_at,omitempty"` - RealnamePolicy string `gorm:"column:realname_policy;type:varchar(20);default:'none';not null;comment:实名认证策略(none=无需实名,before_order=先实名后充值/购买,after_order=先充值/购买后实名)" json:"realname_policy"` + RealnamePolicy string `gorm:"column:realname_policy;type:varchar(20);default:'after_order';not null;comment:实名认证策略(none=无需实名,before_order=先实名后充值/购买,after_order=先充值/购买后实名)" json:"realname_policy"` } // TableName 指定表名 diff --git a/internal/model/device_import_task.go b/internal/model/device_import_task.go index e6d1f63..01b7132 100644 --- a/internal/model/device_import_task.go +++ b/internal/model/device_import_task.go @@ -28,7 +28,7 @@ type DeviceImportTask struct { ErrorMessage string `gorm:"column:error_message;type:text;comment:错误信息" json:"error_message"` StartedAt *time.Time `gorm:"column:started_at;comment:开始处理时间" json:"started_at"` CompletedAt *time.Time `gorm:"column:completed_at;comment:完成时间" json:"completed_at"` - RealnamePolicy string `gorm:"column:realname_policy;type:varchar(20);default:'none';not null;comment:导入批次实名策略(none=无需实名,before_order=先实名后充值/购买,after_order=先充值/购买后实名)" json:"realname_policy"` + RealnamePolicy string `gorm:"column:realname_policy;type:varchar(20);default:'after_order';not null;comment:导入批次实名策略(none=无需实名,before_order=先实名后充值/购买,after_order=先充值/购买后实名)" json:"realname_policy"` } // TableName 指定表名 diff --git a/internal/model/iot_card.go b/internal/model/iot_card.go index 70038b6..cd675a3 100644 --- a/internal/model/iot_card.go +++ b/internal/model/iot_card.go @@ -54,7 +54,7 @@ type IotCard struct { VirtualNo string `gorm:"column:virtual_no;type:varchar(50);uniqueIndex:idx_iot_card_virtual_no,where:deleted_at IS NULL AND virtual_no IS NOT NULL AND virtual_no <> '';comment:虚拟号(可选,非空时全局唯一)" json:"virtual_no,omitempty"` DeviceVirtualNo string `gorm:"column:device_virtual_no;type:varchar(100);not null;default:'';comment:绑定设备的虚拟号快照(未绑定时为空字符串)" json:"device_virtual_no"` LastGatewayReadingMB float64 `gorm:"column:last_gateway_reading_mb;type:float;not null;default:0;comment:上次轮询时网关返回的流量读数(MB)" json:"last_gateway_reading_mb"` - RealnamePolicy string `gorm:"column:realname_policy;type:varchar(20);default:'none';not null;comment:实名认证策略(none=无需实名,before_order=先实名后充值/购买,after_order=先充值/购买后实名)" json:"realname_policy"` + RealnamePolicy string `gorm:"column:realname_policy;type:varchar(20);default:'after_order';not null;comment:实名认证策略(none=无需实名,before_order=先实名后充值/购买,after_order=先充值/购买后实名)" json:"realname_policy"` } // TableName 指定表名 diff --git a/internal/model/iot_card_import_task.go b/internal/model/iot_card_import_task.go index 3dc85ba..c2e42f8 100644 --- a/internal/model/iot_card_import_task.go +++ b/internal/model/iot_card_import_task.go @@ -32,7 +32,7 @@ type IotCardImportTask struct { StorageBucket string `gorm:"column:storage_bucket;type:varchar(100);comment:对象存储桶名" json:"storage_bucket,omitempty"` StorageKey string `gorm:"column:storage_key;type:varchar(500);comment:对象存储文件路径" json:"storage_key,omitempty"` CardCategory string `gorm:"column:card_category;type:varchar(20);default:normal;not null;comment:卡业务类型(normal/industry)" json:"card_category"` - RealnamePolicy string `gorm:"column:realname_policy;type:varchar(20);default:'none';not null;comment:导入批次实名策略(none=无需实名,before_order=先实名后充值/购买,after_order=先充值/购买后实名)" json:"realname_policy"` + RealnamePolicy string `gorm:"column:realname_policy;type:varchar(20);default:'after_order';not null;comment:导入批次实名策略(none=无需实名,before_order=先实名后充值/购买,after_order=先充值/购买后实名)" json:"realname_policy"` } // CardItem 卡信息(ICCID + MSISDN + VirtualNo)