This commit is contained in:
Caiyanpeng committed 2021-04-19 14:11:53 +08:00
1 parent f4cbad819b
commit 0346b650aa
64 files changed
+12634 -12935

No files matched your search

+16 -1
View File
@@ -103,6 +103,21 @@ namespace Assets.Scripts.Apis
return Encoding.UTF8.GetString(res);
}
/// <summary>
/// 添加收藏
/// </summary>
/// <returns></returns>
public async Task<JsonResult<object>> AddFav(string routeId)
{
return await PostAsync<JsonResult<object>>("/MemberFavoriteMap/Add",new { routeId });
}
/// <summary>
/// 取消收藏
/// </summary>
/// <returns></returns>
public async Task<JsonResult<object>> CancelFav(string routeId)
{
return await PostAsync<JsonResult<object>>("/MemberFavoriteMap/Cancel", new { routeId });
}
}
}
+1
View File
@@ -104,5 +104,6 @@ namespace Assets.Scripts.Apis.Models
public string Hard { get; set; }
public string CountryCode { get; set; }
public bool IsFire { get; set; }
public string AltitudeGraph { get; set; }
}
}
@@ -61,7 +61,7 @@ namespace Assets.Scripts.Apis.Models
//cookie
public string cookie { get; set; }
public string Unionid { get; set; }
public int Height { get; set; }
}
}
+10 -3
View File
@@ -129,7 +129,9 @@ namespace Assets.Scripts.Apis
}
public async Task<JsonResult<UserResultModel>> QuickLogin()
{
return await PostAsync<JsonResult<UserResultModel>>("NoAuth/QuickLogin",null);
var r = await PostAsync<JsonResult<UserResultModel>>("NoAuth/QuickLogin", null);
r.data.cookie = cookies[0].Value;
return r;
}
public async Task<JsonResult<object>> OnWebWxLoginCheckUnionId(string unionId, string openId)
@@ -153,7 +155,7 @@ namespace Assets.Scripts.Apis
}
public async Task<JsonResult<dynamic>> Update(UserResultModel currUser, string filePath = "")
public async Task<JsonResult<JObject>> Update(UserResultModel currUser, string filePath = "")
{
//return await PostAsync<JsonResult<dynamic>>("User/UpdateUserSetting", new {
// UID = currUser.Id,
@@ -186,6 +188,7 @@ namespace Assets.Scripts.Apis
UID = currUser.Id,
Sex = currUser.Sex,
currUser.Unit,
currUser.Height,
currUser.Weight,
currUser.FTP,
currUser.WheelDiameter,
@@ -205,7 +208,11 @@ namespace Assets.Scripts.Apis
//imgData = imgData
}, files);
return Newtonsoft.Json.JsonConvert.DeserializeObject<JsonResult<dynamic>>(res);
return Newtonsoft.Json.JsonConvert.DeserializeObject<JsonResult<JObject>>(res);
}
public async Task<JsonResult<JObject>> GetNotify()
{
return await GetAsync<JsonResult<JObject>>("/Home/GetNotify");
}
}
}