|
@@ -4,7 +4,6 @@ import (
|
|
|
"context"
|
|
|
"encoding/json"
|
|
|
"errors"
|
|
|
- "fmt"
|
|
|
"github.com/gogf/gf/encoding/gjson"
|
|
|
"sparrow/pkg/productconfig"
|
|
|
"sparrow/pkg/rpcs"
|
|
@@ -166,8 +165,6 @@ func DeviceUpgrade(device *models.Device, urlparams martini.Params, req *http.Re
|
|
|
args.FileSize = param.FileSize
|
|
|
var reply rpcs.ReplyEmptyResult
|
|
|
err = server.RPCCallByName(context.Background(), rpcs.MQTTAccessName, "Access.Upgrade", args, &reply)
|
|
|
- fmt.Println("11111111111111111111111")
|
|
|
- fmt.Println(err)
|
|
|
if err != nil {
|
|
|
server.Log.Errorf("设备OTA升级失败:", err)
|
|
|
r.JSON(http.StatusOK, renderError(ErrSystemFault, err))
|