mirror of
https://github.com/silenceper/wechat.git
synced 2026-02-12 00:32:26 +08:00
删除多余代码
This commit is contained in:
@@ -8,14 +8,6 @@ const (
|
|||||||
//更新设备标识
|
//更新设备标识
|
||||||
DEVCIE_UPGRADE
|
DEVCIE_UPGRADE
|
||||||
)
|
)
|
||||||
const (
|
|
||||||
//android classic bluetooth
|
|
||||||
PROTOCOL_ANDROID_BLE = iota
|
|
||||||
//ios classic bluetooth
|
|
||||||
PROTOCOL_IOS_BLE
|
|
||||||
PROTOCOL_BLE
|
|
||||||
PROTOCOL_WIFI
|
|
||||||
)
|
|
||||||
|
|
||||||
type reqDeviceAuthorize struct {
|
type reqDeviceAuthorize struct {
|
||||||
// 设备id的个数
|
// 设备id的个数
|
||||||
@@ -79,12 +71,12 @@ type resBaseInfo struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 授权回调根信息
|
// 授权回调根信息
|
||||||
type ResDeviceAuthorize struct {
|
type resDeviceAuthorize struct {
|
||||||
util.CommonError
|
util.CommonError
|
||||||
Resp []resBaseInfo `json:"resp"`
|
Resp []resBaseInfo `json:"resp"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type ResCreateQRCode struct {
|
type resCreateQRCode struct {
|
||||||
util.CommonError
|
util.CommonError
|
||||||
DeviceNum int `json:"device_num"`
|
DeviceNum int `json:"device_num"`
|
||||||
CodeList []resQRCode `json:"code_list"`
|
CodeList []resQRCode `json:"code_list"`
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ func (d *Device) DeviceAuthorize(devices []ReqDevice, opType int, productId stri
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
var result ResDeviceAuthorize
|
var result resDeviceAuthorize
|
||||||
err = json.Unmarshal(response, &result)
|
err = json.Unmarshal(response, &result)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return
|
return
|
||||||
@@ -73,7 +73,7 @@ func (d *Device) CreateQRCode(devices []string) (res []resQRCode, err error) {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
var result ResCreateQRCode
|
var result resCreateQRCode
|
||||||
err = json.Unmarshal(response, &result)
|
err = json.Unmarshal(response, &result)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user