| | |
| | | |
| | | type Subscribe struct { |
| | | SubscribeID string `json:"SubscribeID"` |
| | | Title string `json:"Title"` |
| | | SubscribeDetail string `json:"SubscribeDetail"` |
| | | ResourceURI string `json:"ResourceURI"` |
| | | ApplicantName string `json:"ApplicantName"` |
| | | ApplicantOrg string `json:"ApplicantOrg"` |
| | | BeginTime string `json:"BeginTime"` // Kept as string for direct compatibility |
| | | EndTime string `json:"EndTime"` // Kept as string for direct compatibility |
| | | ReceiveAddr string `json:"ReceiveAddr"` |
| | | ReportInterval int `json:"ReportInterval"` |
| | | Reason string `json:"Reason"` |
| | | OperateType int `json:"OperateType"` |
| | | SubscribeStatus int `json:"SubscribeStatus"` |
| | | SubscribeCancelOrg string `json:"SubscribeCancelOrg"` |
| | | SubscribeCancelPerson string `json:"SubscribeCancelPerson"` |
| | | CancelTime string `json:"CancelTime"` // Kept as string for direct compatibility |
| | | CancelReason string `json:"CancelReason"` |
| | | Title string `json:"Title" binding:"required"` |
| | | SubscribeDetail string `json:"SubscribeDetail" binding:"required"` |
| | | ResourceURI string `json:"ResourceURI" binding:"required"` |
| | | ApplicantName string `json:"ApplicantName" binding:"required"` |
| | | ApplicantOrg string `json:"ApplicantOrg" binding:"required"` |
| | | BeginTime string `json:"BeginTime" binding:"required"` |
| | | EndTime string `json:"EndTime" binding:"required"` |
| | | ReceiveAddr string `json:"ReceiveAddr" binding:"required"` |
| | | ReportInterval int `json:"ReportInterval" binding:"required"` |
| | | Reason string `json:"Reason" binding:"required"` |
| | | OperateType int `json:"OperateType" ` // 0:订阅;1:取消订阅 |
| | | SubscribeStatus int `json:"SubscribeStatus" ` // 0:订阅中 1:已取消订阅 2:订阅到期 9:未订阅 |
| | | ResourceClass int `json:"ResourceClass" ` // |
| | | ResultImageDeclare string `json:"ResultImageDeclare" ` // 对应subImage 的 type, -1 不传 |
| | | ResultFeatureDeclare int `json:"ResultFeatureDeclare" ` // |
| | | SubscribeCancelOrg string `json:"SubscribeCancelOrg,omitempty"` // 仅在取消订阅时使用 |
| | | SubscribeCancelPerson string `json:"SubscribeCancelPerson,omitempty"` // 仅在取消订阅时使用 |
| | | CancelTime string `json:"CancelTime,omitempty"` // 仅在取消订阅时使用 |
| | | CancelReason string `json:"CancelReason,omitempty"` // 仅在取消订阅时使用 |
| | | } |
| | | |
| | | func (s *Subscribe) Scan(value interface{}) error { |
| | |
| | | } `json:"SubscribeListObject"` |
| | | } |
| | | |
| | | type RequestCancelSubscribe struct { |
| | | SubscribeObject Subscribe `json:"SubscribeObject"` |
| | | } |
| | | |
| | | type RequestSubscribeNotification struct { |
| | | SubscribeNotificationListObject struct { |
| | | SubscribeNotificationObject []interface{} `json:"SubscribeNotificationObject"` |
| | | } `json:"SubscribeNotificationListObject"` |
| | | } |
| | | |
| | | type RequestSubscribeNotificationBind struct { |
| | | SubscribeNotificationListObject struct { |
| | | SubscribeNotificationObject []Notification `json:"SubscribeNotificationObject"` |
| | | } `json:"SubscribeNotificationListObject"` |
| | | } |
| | | |
| | |
| | | ExecuteOperation int |
| | | FaceObjectList NotificationFaceList |
| | | } |
| | | |
| | | type PersonNotification struct { |
| | | NotificationID string |
| | | SubscribeID string |
| | | Title string |
| | | TriggerTime string |
| | | InfoIDs string |
| | | ExecuteOperation int |
| | | PersonObjectList NotificationPersonList |
| | | } |
| | | |
| | | type Notification struct { |
| | | NotificationID string |
| | | SubscribeID string |
| | | Title string |
| | | TriggerTime string |
| | | InfoIDs string |
| | | ExecuteOperation int |
| | | DeviceList NotificationApeList |
| | | FaceObjectList NotificationFaceList |
| | | PersonObjectList NotificationPersonList |
| | | } |