作者 yangfu

版本分享修改

@@ -63,25 +63,25 @@ func (srv *CommonService) LatestVersionInfo(q *query.GetLatestVersionQuery) (int @@ -63,25 +63,25 @@ func (srv *CommonService) LatestVersionInfo(q *query.GetLatestVersionQuery) (int
63 63
64 //AppSharing 获取分享链接地址 64 //AppSharing 获取分享链接地址
65 func (srv *CommonService) AppSharing(q *query.GetLatestVersionQuery) (interface{}, error) { 65 func (srv *CommonService) AppSharing(q *query.GetLatestVersionQuery) (interface{}, error) {
66 - page := IOSPage  
67 - if q.DeviceType == "1" { // 安卓  
68 - page = ANDPage  
69 - }  
70 - return map[string]interface{}{  
71 - "version": map[string]interface{}{  
72 - "downloadPage": page,  
73 - "downloadFile": "",  
74 - },  
75 - }, nil  
76 - //vs:= version_server.NewHttpLibVersionServer()  
77 - //data,err:= vs.GetLatestVersion(q.Request,version_server.ReqLatestVersion{  
78 - // VersionNo: q.VersionNo,  
79 - // Channel: q.Channel,  
80 - //})  
81 - //if err != nil {  
82 - // return nil, application.ThrowError(application.BUSINESS_ERROR, err.Error()) 66 + //page := IOSPage
  67 + //if q.DeviceType == "1" { // 安卓
  68 + // page = ANDPage
83 //} 69 //}
84 - //return data, nil 70 + //return map[string]interface{}{
  71 + // "version": map[string]interface{}{
  72 + // "downloadPage": page,
  73 + // "downloadFile": "",
  74 + // },
  75 + //}, nil
  76 + vs := version_server.NewHttpLibVersionServer()
  77 + data, err := vs.GetLatestVersion(q.Request, version_server.ReqLatestVersion{
  78 + VersionNo: q.VersionNo,
  79 + Channel: q.Channel,
  80 + })
  81 + if err != nil {
  82 + return nil, application.ThrowError(application.BUSINESS_ERROR, err.Error())
  83 + }
  84 + return data, nil
85 } 85 }
86 86
87 // AdvancedSetting 高级查询 配置 87 // AdvancedSetting 高级查询 配置