Integrated with user API
Refactoring Mocks and App
This commit is contained in:
parent
ea2aa57426
commit
e9c9ccd2d3
@ -9,12 +9,19 @@ namespace eShopOnContainers.Core.Extensions
|
|||||||
{
|
{
|
||||||
ObservableCollection<T> collection = new ObservableCollection<T>();
|
ObservableCollection<T> collection = new ObservableCollection<T>();
|
||||||
|
|
||||||
foreach (T item in source)
|
try
|
||||||
{
|
{
|
||||||
collection.Add(item);
|
foreach (T item in source)
|
||||||
}
|
{
|
||||||
|
collection.Add(item);
|
||||||
|
}
|
||||||
|
|
||||||
return collection;
|
return collection;
|
||||||
|
}
|
||||||
|
catch
|
||||||
|
{
|
||||||
|
return collection;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -35,6 +35,8 @@
|
|||||||
|
|
||||||
public string IdentityEndpoint { get; set; }
|
public string IdentityEndpoint { get; set; }
|
||||||
|
|
||||||
|
public string UserInfoEndpoint { get; set; }
|
||||||
|
|
||||||
public string LogoutEndpoint { get; set; }
|
public string LogoutEndpoint { get; set; }
|
||||||
|
|
||||||
public string IdentityCallback { get; set; }
|
public string IdentityCallback { get; set; }
|
||||||
@ -46,6 +48,7 @@
|
|||||||
OrdersEndpoint = string.Format("{0}:5102", baseEndpoint);
|
OrdersEndpoint = string.Format("{0}:5102", baseEndpoint);
|
||||||
BasketEndpoint = string.Format("{0}:5103", baseEndpoint);
|
BasketEndpoint = string.Format("{0}:5103", baseEndpoint);
|
||||||
IdentityEndpoint = string.Format("{0}:5105/connect/authorize", baseEndpoint);
|
IdentityEndpoint = string.Format("{0}:5105/connect/authorize", baseEndpoint);
|
||||||
|
UserInfoEndpoint = string.Format("{0}:5105/connect/userinfo", baseEndpoint);
|
||||||
LogoutEndpoint = string.Format("{0}:5105/connect/endsession", baseEndpoint);
|
LogoutEndpoint = string.Format("{0}:5105/connect/endsession", baseEndpoint);
|
||||||
IdentityCallback = "http://eshopxamarin/callback.html";
|
IdentityCallback = "http://eshopxamarin/callback.html";
|
||||||
}
|
}
|
||||||
|
@ -1,18 +0,0 @@
|
|||||||
using System.Collections.ObjectModel;
|
|
||||||
|
|
||||||
namespace eShopOnContainers.Core.Helpers
|
|
||||||
{
|
|
||||||
public class NumericHelper
|
|
||||||
{
|
|
||||||
public static ObservableCollection<int> GetNumericList(int count = 100)
|
|
||||||
{
|
|
||||||
var result = new ObservableCollection<int>();
|
|
||||||
for (int i = 1; i < count; i++)
|
|
||||||
{
|
|
||||||
result.Add(i);
|
|
||||||
}
|
|
||||||
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,105 +1,23 @@
|
|||||||
using eShopOnContainers.Core.Helpers;
|
using System;
|
||||||
using eShopOnContainers.Core.ViewModels.Base;
|
|
||||||
using eShopOnContainers.ViewModels.Base;
|
|
||||||
using System;
|
|
||||||
using System.Collections.ObjectModel;
|
|
||||||
using Xamarin.Forms;
|
|
||||||
|
|
||||||
namespace eShopOnContainers.Core.Models.Basket
|
namespace eShopOnContainers.Core.Models.Basket
|
||||||
{
|
{
|
||||||
public class BasketItem : ExtendedBindableObject
|
public class BasketItem
|
||||||
{
|
{
|
||||||
private string _id;
|
public string Id { get; set; }
|
||||||
private string _productId;
|
|
||||||
private string _productName;
|
|
||||||
private decimal _unitPrice;
|
|
||||||
private int _quantity;
|
|
||||||
private string _pictureUrl;
|
|
||||||
private ObservableCollection<int> _numbers;
|
|
||||||
|
|
||||||
public BasketItem()
|
public string ProductId { get; set; }
|
||||||
{
|
|
||||||
Numbers = NumericHelper.GetNumericList();
|
|
||||||
}
|
|
||||||
|
|
||||||
public string Id
|
public string ProductName { get; set; }
|
||||||
{
|
|
||||||
get { return _id; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_id = value;
|
|
||||||
RaisePropertyChanged(() => Id);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public string ProductId
|
public decimal UnitPrice { get; set; }
|
||||||
{
|
|
||||||
get { return _productId; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_productId = value;
|
|
||||||
RaisePropertyChanged(() => ProductId);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public string ProductName
|
public int Quantity { get; set; }
|
||||||
{
|
|
||||||
get { return _productName; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_productName = value;
|
|
||||||
RaisePropertyChanged(() => ProductName);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public decimal UnitPrice
|
public string PictureUrl { get; set; }
|
||||||
{
|
|
||||||
get { return _unitPrice; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_unitPrice = value;
|
|
||||||
RaisePropertyChanged(() => UnitPrice);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public int Quantity
|
|
||||||
{
|
|
||||||
get { return _quantity; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
if (_quantity != value)
|
|
||||||
{
|
|
||||||
_quantity = value;
|
|
||||||
RaisePropertyChanged(() => Quantity);
|
|
||||||
RaisePropertyChanged(() => Total);
|
|
||||||
|
|
||||||
MessagingCenter.Send(this, MessengerKeys.UpdateProduct);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public string PictureUrl
|
|
||||||
{
|
|
||||||
get { return _pictureUrl; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_pictureUrl = value;
|
|
||||||
RaisePropertyChanged(() => PictureUrl);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public decimal Total { get { return Quantity * UnitPrice; } }
|
public decimal Total { get { return Quantity * UnitPrice; } }
|
||||||
|
|
||||||
public ObservableCollection<int> Numbers
|
|
||||||
{
|
|
||||||
get { return _numbers; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_numbers = value;
|
|
||||||
RaisePropertyChanged(() => Numbers);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
return String.Format("Product Id: {0}, Quantity: {1}", ProductId, Quantity);
|
return String.Format("Product Id: {0}, Quantity: {1}", ProductId, Quantity);
|
||||||
|
@ -1,109 +1,18 @@
|
|||||||
using eShopOnContainers.Core.Helpers;
|
using System;
|
||||||
using eShopOnContainers.ViewModels.Base;
|
|
||||||
using System;
|
|
||||||
using System.Collections.ObjectModel;
|
|
||||||
|
|
||||||
namespace eShopOnContainers.Core.Models.Orders
|
namespace eShopOnContainers.Core.Models.Orders
|
||||||
{
|
{
|
||||||
public class OrderItem : ExtendedBindableObject
|
public class OrderItem
|
||||||
{
|
{
|
||||||
private string _pictureUrl;
|
public Guid ProductId { get; set; }
|
||||||
private string _productId;
|
public Guid OrderId { get; set; }
|
||||||
private Guid _orderId;
|
public decimal UnitPrice { get; set; }
|
||||||
private string _productName;
|
public string ProductName { get; set; }
|
||||||
private decimal _unitPrice;
|
public string PictureUrl { get; set; }
|
||||||
private int _quantity;
|
public int Quantity { get; set; }
|
||||||
private decimal _discount;
|
public decimal Discount { get; set; }
|
||||||
private ObservableCollection<int> _numbers;
|
|
||||||
|
|
||||||
public OrderItem()
|
|
||||||
{
|
|
||||||
Numbers = NumericHelper.GetNumericList();
|
|
||||||
}
|
|
||||||
|
|
||||||
public string ProductId
|
|
||||||
{
|
|
||||||
get { return _productId; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_productId = value;
|
|
||||||
RaisePropertyChanged(() => ProductId);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Guid OrderId
|
|
||||||
{
|
|
||||||
get { return _orderId; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_orderId = value;
|
|
||||||
RaisePropertyChanged(() => OrderId);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public string ProductName
|
|
||||||
{
|
|
||||||
get { return _productName; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_productName = value;
|
|
||||||
RaisePropertyChanged(() => ProductName);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public decimal UnitPrice
|
|
||||||
{
|
|
||||||
get { return _unitPrice; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_unitPrice = value;
|
|
||||||
RaisePropertyChanged(() => UnitPrice);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public int Quantity
|
|
||||||
{
|
|
||||||
get { return _quantity; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_quantity = value;
|
|
||||||
RaisePropertyChanged(() => Quantity);
|
|
||||||
RaisePropertyChanged(() => Total);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public decimal Discount
|
|
||||||
{
|
|
||||||
get { return _discount; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_discount = value;
|
|
||||||
RaisePropertyChanged(() => Discount);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public decimal Total { get { return Quantity * UnitPrice; } }
|
public decimal Total { get { return Quantity * UnitPrice; } }
|
||||||
|
|
||||||
public string PictureUrl
|
|
||||||
{
|
|
||||||
get { return _pictureUrl; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_pictureUrl = value;
|
|
||||||
RaisePropertyChanged(() => PictureUrl);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public ObservableCollection<int> Numbers
|
|
||||||
{
|
|
||||||
get { return _numbers; }
|
|
||||||
set
|
|
||||||
{
|
|
||||||
_numbers = value;
|
|
||||||
RaisePropertyChanged(() => Numbers);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
return String.Format("Product Id: {0}, Quantity: {1}", ProductId, Quantity);
|
return String.Format("Product Id: {0}, Quantity: {1}", ProductId, Quantity);
|
||||||
|
@ -3,7 +3,6 @@ using System;
|
|||||||
|
|
||||||
namespace eShopOnContainers.Core.Models.User
|
namespace eShopOnContainers.Core.Models.User
|
||||||
{
|
{
|
||||||
|
|
||||||
public class PaymentInfo
|
public class PaymentInfo
|
||||||
{
|
{
|
||||||
public Guid Id { get; set; }
|
public Guid Id { get; set; }
|
||||||
|
@ -0,0 +1,55 @@
|
|||||||
|
using Newtonsoft.Json;
|
||||||
|
|
||||||
|
namespace eShopOnContainers.Core.Models.User
|
||||||
|
{
|
||||||
|
public class UserInfo
|
||||||
|
{
|
||||||
|
[JsonProperty("sub")]
|
||||||
|
public string UserId { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("preferred_username")]
|
||||||
|
public string PreferredUsername { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("name")]
|
||||||
|
public string Name { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("last_name")]
|
||||||
|
public string LastName { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("card_number")]
|
||||||
|
public string CardNumber { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("card_holder")]
|
||||||
|
public string CardHolder { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("card_security_number")]
|
||||||
|
public string CardSecurityNumber { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("address_city")]
|
||||||
|
public string Address { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("address_country")]
|
||||||
|
public string Country { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("address_state")]
|
||||||
|
public string State { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("address_street")]
|
||||||
|
public string Street { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("address_zip_code")]
|
||||||
|
public string ZipCode { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("email")]
|
||||||
|
public string Email { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("email_verified")]
|
||||||
|
public bool EmailVerified { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("phone_number")]
|
||||||
|
public string PhoneNumber { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("phone_number_verified")]
|
||||||
|
public bool PhoneNumberVerified { get; set; }
|
||||||
|
}
|
||||||
|
}
|
@ -12,8 +12,8 @@ namespace eShopOnContainers.Core.Services.Basket
|
|||||||
BuyerId = "9245fe4a-d402-451c-b9ed-9c1a04247482",
|
BuyerId = "9245fe4a-d402-451c-b9ed-9c1a04247482",
|
||||||
Items = new List<BasketItem>
|
Items = new List<BasketItem>
|
||||||
{
|
{
|
||||||
new BasketItem { Id = "1", PictureUrl = Device.OS != TargetPlatform.Windows ? "fake_product_01.png" : "Assets/fake_product_01.png", ProductId = "1", ProductName = ".NET Bot Blue Sweatshirt (M)", Quantity = 1, UnitPrice = 19.50M },
|
new BasketItem { Id = "1", PictureUrl = Device.OS != TargetPlatform.Windows ? "fake_product_01.png" : "Assets/fake_product_01.png", ProductId = Common.Common.MockCatalogItemId01.ToString(), ProductName = ".NET Bot Blue Sweatshirt (M)", Quantity = 1, UnitPrice = 19.50M },
|
||||||
new BasketItem { Id = "2", PictureUrl = Device.OS != TargetPlatform.Windows ? "fake_product_04.png" : "Assets/fake_product_04.png", ProductId = "4", ProductName = ".NET Black Cupt", Quantity = 1, UnitPrice = 17.00M }
|
new BasketItem { Id = "2", PictureUrl = Device.OS != TargetPlatform.Windows ? "fake_product_04.png" : "Assets/fake_product_04.png", ProductId = Common.Common.MockCatalogItemId04.ToString(), ProductName = ".NET Black Cupt", Quantity = 1, UnitPrice = 17.00M }
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
using eShopOnContainers.Core.Extensions;
|
using eShopOnContainers.Core.Extensions;
|
||||||
using eShopOnContainers.Core.Models.Catalog;
|
using eShopOnContainers.Core.Models.Catalog;
|
||||||
|
using System;
|
||||||
using System.Collections.ObjectModel;
|
using System.Collections.ObjectModel;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
@ -23,11 +24,11 @@ namespace eShopOnContainers.Core.Services.Catalog
|
|||||||
|
|
||||||
private ObservableCollection<CatalogItem> MockCatalog = new ObservableCollection<CatalogItem>
|
private ObservableCollection<CatalogItem> MockCatalog = new ObservableCollection<CatalogItem>
|
||||||
{
|
{
|
||||||
new CatalogItem { Id = "1", PictureUri = Device.OS != TargetPlatform.Windows ? "fake_product_01.png" : "Assets/fake_product_01.png", Name = ".NET Bot Blue Sweatshirt (M)", Price = 19.50M, CatalogBrand = "Visual Studio", CatalogType = "T-Shirt" },
|
new CatalogItem { Id = Common.Common.MockCatalogItemId01.ToString(), PictureUri = Device.OS != TargetPlatform.Windows ? "fake_product_01.png" : "Assets/fake_product_01.png", Name = ".NET Bot Blue Sweatshirt (M)", Price = 19.50M, CatalogBrandId = 2, CatalogBrand = "Visual Studio", CatalogTypeId = 2, CatalogType = "T-Shirt" },
|
||||||
new CatalogItem { Id = "2", PictureUri = Device.OS != TargetPlatform.Windows ? "fake_product_02.png" : "Assets/fake_product_02.png", Name = ".NET Bot Purple Sweatshirt (M)", Price = 19.50M, CatalogBrand = "Visual Studio", CatalogType = "T-Shirt" },
|
new CatalogItem { Id = Common.Common.MockCatalogItemId02.ToString(), PictureUri = Device.OS != TargetPlatform.Windows ? "fake_product_02.png" : "Assets/fake_product_02.png", Name = ".NET Bot Purple Sweatshirt (M)", Price = 19.50M, CatalogBrandId = 2, CatalogBrand = "Visual Studio", CatalogTypeId = 2, CatalogType = "T-Shirt" },
|
||||||
new CatalogItem { Id = "3", PictureUri = Device.OS != TargetPlatform.Windows ? "fake_product_03.png" : "Assets/fake_product_03.png", Name = ".NET Bot Black Sweatshirt (M)", Price = 19.95M, CatalogBrand = "Visual Studio", CatalogType = "T-Shirt" },
|
new CatalogItem { Id = Common.Common.MockCatalogItemId03.ToString(), PictureUri = Device.OS != TargetPlatform.Windows ? "fake_product_03.png" : "Assets/fake_product_03.png", Name = ".NET Bot Black Sweatshirt (M)", Price = 19.95M, CatalogBrandId = 2, CatalogBrand = "Visual Studio", CatalogTypeId = 2, CatalogType = "T-Shirt" },
|
||||||
new CatalogItem { Id = "4", PictureUri = Device.OS != TargetPlatform.Windows ? "fake_product_04.png" : "Assets/fake_product_04.png", Name = ".NET Black Cupt", Price = 17.00M, CatalogBrand = "Visual Studio", CatalogType = "Mug" },
|
new CatalogItem { Id = Common.Common.MockCatalogItemId04.ToString(), PictureUri = Device.OS != TargetPlatform.Windows ? "fake_product_04.png" : "Assets/fake_product_04.png", Name = ".NET Black Cupt", Price = 17.00M, CatalogBrandId = 2, CatalogBrand = "Visual Studio", CatalogTypeId = 1, CatalogType = "Mug" },
|
||||||
new CatalogItem { Id = "5", PictureUri = Device.OS != TargetPlatform.Windows ? "fake_product_05.png" : "Assets/fake_product_05.png", Name = "Azure Black Sweatshirt (M)", Price = 19.50M, CatalogBrand = "Azure", CatalogType = "T-Shirt" }
|
new CatalogItem { Id = Common.Common.MockCatalogItemId05.ToString(), PictureUri = Device.OS != TargetPlatform.Windows ? "fake_product_05.png" : "Assets/fake_product_05.png", Name = "Azure Black Sweatshirt (M)", Price = 19.50M, CatalogBrandId = 1, CatalogBrand = "Azure", CatalogTypeId = 2, CatalogType = "T-Shirt" }
|
||||||
};
|
};
|
||||||
|
|
||||||
public async Task<ObservableCollection<CatalogItem>> GetCatalogAsync()
|
public async Task<ObservableCollection<CatalogItem>> GetCatalogAsync()
|
||||||
|
@ -30,7 +30,10 @@ namespace eShopOnContainers.Core.Services.Catalog
|
|||||||
CatalogRoot catalog =
|
CatalogRoot catalog =
|
||||||
await _requestProvider.GetAsync<CatalogRoot>(uri);
|
await _requestProvider.GetAsync<CatalogRoot>(uri);
|
||||||
|
|
||||||
return catalog?.Data?.ToObservableCollection();
|
if (catalog?.Data != null)
|
||||||
|
return catalog?.Data.ToObservableCollection();
|
||||||
|
else
|
||||||
|
return new ObservableCollection<CatalogItem>();
|
||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
@ -51,7 +54,10 @@ namespace eShopOnContainers.Core.Services.Catalog
|
|||||||
CatalogRoot catalog =
|
CatalogRoot catalog =
|
||||||
await _requestProvider.GetAsync<CatalogRoot>(uri);
|
await _requestProvider.GetAsync<CatalogRoot>(uri);
|
||||||
|
|
||||||
return catalog?.Data?.ToObservableCollection();
|
if (catalog?.Data != null)
|
||||||
|
return catalog?.Data.ToObservableCollection();
|
||||||
|
else
|
||||||
|
return new ObservableCollection<CatalogItem>();
|
||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
@ -77,7 +83,10 @@ namespace eShopOnContainers.Core.Services.Catalog
|
|||||||
IEnumerable<CatalogBrand> brands =
|
IEnumerable<CatalogBrand> brands =
|
||||||
await _requestProvider.GetAsync<IEnumerable<CatalogBrand>>(uri);
|
await _requestProvider.GetAsync<IEnumerable<CatalogBrand>>(uri);
|
||||||
|
|
||||||
return brands?.ToObservableCollection();
|
if (brands != null)
|
||||||
|
return brands?.ToObservableCollection();
|
||||||
|
else
|
||||||
|
return new ObservableCollection<CatalogBrand>();
|
||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
@ -98,7 +107,10 @@ namespace eShopOnContainers.Core.Services.Catalog
|
|||||||
IEnumerable<CatalogType> types =
|
IEnumerable<CatalogType> types =
|
||||||
await _requestProvider.GetAsync<IEnumerable<CatalogType>>(uri);
|
await _requestProvider.GetAsync<IEnumerable<CatalogType>>(uri);
|
||||||
|
|
||||||
return types?.ToObservableCollection();
|
if (types != null)
|
||||||
|
return types.ToObservableCollection();
|
||||||
|
else
|
||||||
|
return new ObservableCollection<CatalogType>();
|
||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
|
@ -0,0 +1,13 @@
|
|||||||
|
using System;
|
||||||
|
|
||||||
|
namespace eShopOnContainers.Core.Services.Common
|
||||||
|
{
|
||||||
|
public static class Common
|
||||||
|
{
|
||||||
|
public static Guid MockCatalogItemId01 = new Guid("0f8fad5b-d9cb-469f-a165-708677289501");
|
||||||
|
public static Guid MockCatalogItemId02 = new Guid("0f8fad5b-d9cb-469f-a165-708677289502");
|
||||||
|
public static Guid MockCatalogItemId03 = new Guid("0f8fad5b-d9cb-469f-a165-708677289503");
|
||||||
|
public static Guid MockCatalogItemId04 = new Guid("0f8fad5b-d9cb-469f-a165-708677289504");
|
||||||
|
public static Guid MockCatalogItemId05 = new Guid("0f8fad5b-d9cb-469f-a165-708677289505");
|
||||||
|
}
|
||||||
|
}
|
@ -52,8 +52,8 @@ namespace eShopOnContainers.Core.Services.Order
|
|||||||
|
|
||||||
private static List<OrderItem> MockOrderItems = new List<OrderItem>()
|
private static List<OrderItem> MockOrderItems = new List<OrderItem>()
|
||||||
{
|
{
|
||||||
new OrderItem { OrderId = Guid.NewGuid(), ProductId = "1", Discount = 15, ProductName = ".NET Bot Blue Sweatshirt (M)", Quantity = 1, UnitPrice = 16.50M },
|
new OrderItem { OrderId = Guid.NewGuid(), ProductId = Common.Common.MockCatalogItemId01, Discount = 15, ProductName = ".NET Bot Blue Sweatshirt (M)", Quantity = 1, UnitPrice = 16.50M },
|
||||||
new OrderItem { OrderId = Guid.NewGuid(), ProductId = "3", Discount = 0, ProductName = ".NET Bot Black Sweatshirt (M)", Quantity = 2, UnitPrice = 19.95M }
|
new OrderItem { OrderId = Guid.NewGuid(), ProductId = Common.Common.MockCatalogItemId03, Discount = 0, ProductName = ".NET Bot Black Sweatshirt (M)", Quantity = 2, UnitPrice = 19.95M }
|
||||||
};
|
};
|
||||||
|
|
||||||
private static List<CardType> MockCardTypes = new List<CardType>()
|
private static List<CardType> MockCardTypes = new List<CardType>()
|
||||||
|
@ -5,7 +5,6 @@ namespace eShopOnContainers.Core.Services.User
|
|||||||
{
|
{
|
||||||
public interface IUserService
|
public interface IUserService
|
||||||
{
|
{
|
||||||
Task<Address> GetAddressAsync();
|
Task<UserInfo> GetUserInfoAsync(string authToken);
|
||||||
Task<PaymentInfo> GetPaymentInfoAsync();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,56 +1,36 @@
|
|||||||
using System;
|
using System;
|
||||||
using eShopOnContainers.Core.Models.User;
|
using eShopOnContainers.Core.Models.User;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using eShopOnContainers.Core.Models.Orders;
|
|
||||||
|
|
||||||
namespace eShopOnContainers.Core.Services.User
|
namespace eShopOnContainers.Core.Services.User
|
||||||
{
|
{
|
||||||
public class UserMockService : IUserService
|
public class UserMockService : IUserService
|
||||||
{
|
{
|
||||||
private static DateTime MockExpirationDate = DateTime.Now.AddYears(5);
|
private UserInfo MockUserInfo = new UserInfo
|
||||||
|
|
||||||
private Address MockAdress = new Address
|
|
||||||
{
|
{
|
||||||
Id = Guid.NewGuid(),
|
UserId = Guid.NewGuid().ToString(),
|
||||||
City = "Seattle, WA",
|
Name = "Jhon",
|
||||||
|
LastName = "Doe",
|
||||||
|
PreferredUsername = "Jdoe",
|
||||||
|
Email = "jdoe@eshop.com",
|
||||||
|
EmailVerified = true,
|
||||||
|
PhoneNumber = "202-555-0165",
|
||||||
|
PhoneNumberVerified = true,
|
||||||
|
Address = "Seattle, WA",
|
||||||
Street = "120 E 87th Street",
|
Street = "120 E 87th Street",
|
||||||
CountryCode = "98122",
|
ZipCode = "98101",
|
||||||
Country = "United States",
|
Country = "United States",
|
||||||
Latitude = 40.785091,
|
|
||||||
Longitude = -73.968285,
|
|
||||||
State = "Seattle",
|
State = "Seattle",
|
||||||
StateCode = "WA",
|
|
||||||
ZipCode = "98101"
|
|
||||||
};
|
|
||||||
|
|
||||||
private PaymentInfo MockPaymentInfo = new PaymentInfo
|
|
||||||
{
|
|
||||||
Id = Guid.NewGuid(),
|
|
||||||
CardHolderName = "American Express",
|
|
||||||
CardNumber = "378282246310005",
|
CardNumber = "378282246310005",
|
||||||
CardType = new CardType
|
CardHolder = "American Express",
|
||||||
{
|
CardSecurityNumber = "1234"
|
||||||
Id = 3,
|
|
||||||
Name = "MasterCard"
|
|
||||||
},
|
|
||||||
Expiration = MockExpirationDate.ToString(),
|
|
||||||
ExpirationMonth = MockExpirationDate.Month,
|
|
||||||
ExpirationYear = MockExpirationDate.Year,
|
|
||||||
SecurityNumber = "123"
|
|
||||||
};
|
};
|
||||||
|
|
||||||
public async Task<Address> GetAddressAsync()
|
public async Task<UserInfo> GetUserInfoAsync(string authToken)
|
||||||
{
|
{
|
||||||
await Task.Delay(500);
|
await Task.Delay(500);
|
||||||
|
|
||||||
return MockAdress;
|
return MockUserInfo;
|
||||||
}
|
|
||||||
|
|
||||||
public async Task<PaymentInfo> GetPaymentInfoAsync()
|
|
||||||
{
|
|
||||||
await Task.Delay(500);
|
|
||||||
|
|
||||||
return MockPaymentInfo;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -0,0 +1,36 @@
|
|||||||
|
using eShopOnContainers.Core.Services.RequestProvider;
|
||||||
|
using System;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using eShopOnContainers.Core.Models.User;
|
||||||
|
|
||||||
|
namespace eShopOnContainers.Core.Services.User
|
||||||
|
{
|
||||||
|
public class UserService : IUserService
|
||||||
|
{
|
||||||
|
private readonly IRequestProvider _requestProvider;
|
||||||
|
|
||||||
|
public UserService(IRequestProvider requestProvider)
|
||||||
|
{
|
||||||
|
_requestProvider = requestProvider;
|
||||||
|
}
|
||||||
|
|
||||||
|
public async Task<UserInfo> GetUserInfoAsync(string authToken)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
UriBuilder builder = new UriBuilder(GlobalSetting.Instance.UserInfoEndpoint);
|
||||||
|
|
||||||
|
string uri = builder.ToString();
|
||||||
|
|
||||||
|
var userInfo =
|
||||||
|
await _requestProvider.GetAsync<UserInfo>(uri, authToken);
|
||||||
|
|
||||||
|
return userInfo;
|
||||||
|
}
|
||||||
|
catch
|
||||||
|
{
|
||||||
|
return new UserInfo();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -8,9 +8,6 @@
|
|||||||
// Update Basket
|
// Update Basket
|
||||||
public const string UpdateBasket = "UpdateBasket";
|
public const string UpdateBasket = "UpdateBasket";
|
||||||
|
|
||||||
// Update product basket
|
|
||||||
public const string UpdateProduct = "UpdateProduct";
|
|
||||||
|
|
||||||
// Filter
|
// Filter
|
||||||
public const string Filter = "Filter";
|
public const string Filter = "Filter";
|
||||||
|
|
||||||
|
@ -73,7 +73,7 @@ namespace eShopOnContainers.ViewModels.Base
|
|||||||
_unityContainer.RegisterInstance<ICatalogService>(new CatalogService(requestProvider));
|
_unityContainer.RegisterInstance<ICatalogService>(new CatalogService(requestProvider));
|
||||||
_unityContainer.RegisterInstance<IBasketService>(new BasketService(requestProvider));
|
_unityContainer.RegisterInstance<IBasketService>(new BasketService(requestProvider));
|
||||||
_unityContainer.RegisterInstance<IOrderService>(new OrderService(requestProvider));
|
_unityContainer.RegisterInstance<IOrderService>(new OrderService(requestProvider));
|
||||||
_unityContainer.RegisterInstance<IUserService>(new UserMockService());
|
_unityContainer.RegisterInstance<IUserService>(new UserService(requestProvider));
|
||||||
|
|
||||||
UseMockService = false;
|
UseMockService = false;
|
||||||
}
|
}
|
||||||
|
@ -68,6 +68,8 @@ namespace eShopOnContainers.Core.ViewModels
|
|||||||
{
|
{
|
||||||
MessagingCenter.Subscribe<CatalogViewModel, List<BasketItem>>(this, MessengerKeys.UpdateBasket, (sender, arg) =>
|
MessagingCenter.Subscribe<CatalogViewModel, List<BasketItem>>(this, MessengerKeys.UpdateBasket, (sender, arg) =>
|
||||||
{
|
{
|
||||||
|
MessagingCenter.Unsubscribe<CatalogViewModel, List<BasketItem>>(this, MessengerKeys.UpdateBasket);
|
||||||
|
|
||||||
foreach (var basketItem in arg)
|
foreach (var basketItem in arg)
|
||||||
{
|
{
|
||||||
BadgeCount += basketItem.Quantity;
|
BadgeCount += basketItem.Quantity;
|
||||||
@ -77,16 +79,13 @@ namespace eShopOnContainers.Core.ViewModels
|
|||||||
|
|
||||||
MessagingCenter.Subscribe<CatalogViewModel, CatalogItem>(this, MessengerKeys.AddProduct, (sender, arg) =>
|
MessagingCenter.Subscribe<CatalogViewModel, CatalogItem>(this, MessengerKeys.AddProduct, (sender, arg) =>
|
||||||
{
|
{
|
||||||
|
MessagingCenter.Unsubscribe<CatalogViewModel, CatalogItem>(this, MessengerKeys.AddProduct);
|
||||||
|
|
||||||
BadgeCount++;
|
BadgeCount++;
|
||||||
|
|
||||||
AddCatalogItem(arg);
|
AddCatalogItem(arg);
|
||||||
});
|
});
|
||||||
|
|
||||||
MessagingCenter.Subscribe<BasketItem>(this, MessengerKeys.UpdateProduct, (sender) =>
|
|
||||||
{
|
|
||||||
ReCalculateTotal();
|
|
||||||
});
|
|
||||||
|
|
||||||
BasketItems = new ObservableCollection<BasketItem>();
|
BasketItems = new ObservableCollection<BasketItem>();
|
||||||
|
|
||||||
return base.InitializeAsync(navigationData);
|
return base.InitializeAsync(navigationData);
|
||||||
@ -135,13 +134,12 @@ namespace eShopOnContainers.Core.ViewModels
|
|||||||
Total += (orderItem.Quantity * orderItem.UnitPrice);
|
Total += (orderItem.Quantity * orderItem.UnitPrice);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
var shippingAddress = await _userService.GetAddressAsync();
|
|
||||||
var authToken = Settings.AuthAccessToken;
|
var authToken = Settings.AuthAccessToken;
|
||||||
|
var userInfo = await _userService.GetUserInfoAsync(authToken);
|
||||||
|
|
||||||
await _basketService.UpdateBasketAsync(new CustomerBasket
|
await _basketService.UpdateBasketAsync(new CustomerBasket
|
||||||
{
|
{
|
||||||
BuyerId = shippingAddress.Id.ToString(),
|
BuyerId = userInfo.UserId,
|
||||||
Items = BasketItems.ToList()
|
Items = BasketItems.ToList()
|
||||||
}, authToken);
|
}, authToken);
|
||||||
}
|
}
|
||||||
|
@ -104,10 +104,10 @@ namespace eShopOnContainers.Core.ViewModels
|
|||||||
Brands = await _productsService.GetCatalogBrandAsync();
|
Brands = await _productsService.GetCatalogBrandAsync();
|
||||||
Types = await _productsService.GetCatalogTypeAsync();
|
Types = await _productsService.GetCatalogTypeAsync();
|
||||||
|
|
||||||
var shippingAddress = await _userService.GetAddressAsync();
|
|
||||||
var authToken = Settings.AuthAccessToken;
|
var authToken = Settings.AuthAccessToken;
|
||||||
|
var userInfo = await _userService.GetUserInfoAsync(authToken);
|
||||||
|
|
||||||
var basket = await _basketService.GetBasketAsync(shippingAddress.Id.ToString(), authToken);
|
var basket = await _basketService.GetBasketAsync(userInfo.UserId, authToken);
|
||||||
|
|
||||||
if (basket != null && basket.Items.Any())
|
if (basket != null && basket.Items.Any())
|
||||||
{
|
{
|
||||||
|
@ -78,8 +78,23 @@ namespace eShopOnContainers.Core.ViewModels
|
|||||||
|
|
||||||
OrderItems = orderItems;
|
OrderItems = orderItems;
|
||||||
|
|
||||||
ShippingAddress = await _userService.GetAddressAsync();
|
var authToken = Settings.AuthAccessToken;
|
||||||
var paymentInfo = await _userService.GetPaymentInfoAsync();
|
var userInfo = await _userService.GetUserInfoAsync(authToken);
|
||||||
|
|
||||||
|
ShippingAddress = new Address
|
||||||
|
{
|
||||||
|
Street = userInfo.Street,
|
||||||
|
ZipCode = userInfo.ZipCode,
|
||||||
|
State = userInfo.State,
|
||||||
|
Country = userInfo.Country,
|
||||||
|
};
|
||||||
|
|
||||||
|
var paymentInfo = new PaymentInfo
|
||||||
|
{
|
||||||
|
CardNumber = userInfo.CardNumber,
|
||||||
|
CardHolderName = userInfo.CardHolder,
|
||||||
|
SecurityNumber = userInfo.CardSecurityNumber
|
||||||
|
};
|
||||||
|
|
||||||
Order = new Order
|
Order = new Order
|
||||||
{
|
{
|
||||||
@ -117,7 +132,8 @@ namespace eShopOnContainers.Core.ViewModels
|
|||||||
{
|
{
|
||||||
orderItems.Add(new OrderItem
|
orderItems.Add(new OrderItem
|
||||||
{
|
{
|
||||||
ProductId = basketItem.ProductId,
|
// TODO:
|
||||||
|
//ProductId = basketItem.ProductId,
|
||||||
ProductName = basketItem.ProductName,
|
ProductName = basketItem.ProductName,
|
||||||
PictureUrl = basketItem.PictureUrl,
|
PictureUrl = basketItem.PictureUrl,
|
||||||
Quantity = basketItem.Quantity,
|
Quantity = basketItem.Quantity,
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
using eShopOnContainers.Core.Models.User;
|
using eShopOnContainers.Core.Models.User;
|
||||||
using eShopOnContainers.Core.Services.Identity;
|
using eShopOnContainers.Core.Services.Identity;
|
||||||
using eShopOnContainers.Core.Services.OpenUrl;
|
using eShopOnContainers.Core.Services.OpenUrl;
|
||||||
|
using eShopOnContainers.Core.Services.User;
|
||||||
using eShopOnContainers.Core.Validations;
|
using eShopOnContainers.Core.Validations;
|
||||||
using eShopOnContainers.Core.ViewModels.Base;
|
using eShopOnContainers.Core.ViewModels.Base;
|
||||||
using eShopOnContainers.ViewModels.Base;
|
using eShopOnContainers.ViewModels.Base;
|
||||||
@ -20,16 +21,21 @@ namespace eShopOnContainers.Core.ViewModels
|
|||||||
private ValidatableObject<string> _password;
|
private ValidatableObject<string> _password;
|
||||||
private bool _isMock;
|
private bool _isMock;
|
||||||
private bool _isValid;
|
private bool _isValid;
|
||||||
|
private bool _isLogin;
|
||||||
private string _authUrl;
|
private string _authUrl;
|
||||||
|
|
||||||
private IOpenUrlService _openUrlService;
|
private IOpenUrlService _openUrlService;
|
||||||
private IIdentityService _identityService;
|
private IIdentityService _identityService;
|
||||||
|
private IUserService _userService;
|
||||||
|
|
||||||
public LoginViewModel(IOpenUrlService openUrlService,
|
public LoginViewModel(
|
||||||
IIdentityService identityService)
|
IOpenUrlService openUrlService,
|
||||||
|
IIdentityService identityService,
|
||||||
|
IUserService userService)
|
||||||
{
|
{
|
||||||
_openUrlService = openUrlService;
|
_openUrlService = openUrlService;
|
||||||
_identityService = identityService;
|
_identityService = identityService;
|
||||||
|
_userService = userService;
|
||||||
|
|
||||||
_userName = new ValidatableObject<string>();
|
_userName = new ValidatableObject<string>();
|
||||||
_password = new ValidatableObject<string>();
|
_password = new ValidatableObject<string>();
|
||||||
@ -91,6 +97,19 @@ namespace eShopOnContainers.Core.ViewModels
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public bool IsLogin
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return _isLogin;
|
||||||
|
}
|
||||||
|
set
|
||||||
|
{
|
||||||
|
_isLogin = value;
|
||||||
|
RaisePropertyChanged(() => IsLogin);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public string LoginUrl
|
public string LoginUrl
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
@ -170,6 +189,7 @@ namespace eShopOnContainers.Core.ViewModels
|
|||||||
LoginUrl = _identityService.CreateAuthorizeRequest();
|
LoginUrl = _identityService.CreateAuthorizeRequest();
|
||||||
|
|
||||||
IsValid = true;
|
IsValid = true;
|
||||||
|
IsLogin = true;
|
||||||
|
|
||||||
IsBusy = false;
|
IsBusy = false;
|
||||||
}
|
}
|
||||||
@ -188,7 +208,7 @@ namespace eShopOnContainers.Core.ViewModels
|
|||||||
{
|
{
|
||||||
LoginUrl = logoutRequest;
|
LoginUrl = logoutRequest;
|
||||||
Settings.AuthAccessToken = string.Empty;
|
Settings.AuthAccessToken = string.Empty;
|
||||||
IsValid = true;
|
IsLogin = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -156,10 +156,10 @@
|
|||||||
Text="{Binding ShippingAddress.Street}"
|
Text="{Binding ShippingAddress.Street}"
|
||||||
Style="{StaticResource AddressStyle}"/>
|
Style="{StaticResource AddressStyle}"/>
|
||||||
<Label
|
<Label
|
||||||
Text="{Binding ShippingAddress.City}"
|
Text="{Binding ShippingAddress.ZipCode}"
|
||||||
Style="{StaticResource AddressStyle}"/>
|
Style="{StaticResource AddressStyle}"/>
|
||||||
<Label
|
<Label
|
||||||
Text="{Binding ShippingAddress.CountryCode}"
|
Text="{Binding ShippingAddress.State}"
|
||||||
Style="{StaticResource AddressStyle}"/>
|
Style="{StaticResource AddressStyle}"/>
|
||||||
<Label
|
<Label
|
||||||
Text="{Binding ShippingAddress.Country}"
|
Text="{Binding ShippingAddress.Country}"
|
||||||
|
@ -259,7 +259,7 @@
|
|||||||
Grid.ColumnSpan="2"
|
Grid.ColumnSpan="2"
|
||||||
Grid.Row="0"
|
Grid.Row="0"
|
||||||
Grid.RowSpan="2"
|
Grid.RowSpan="2"
|
||||||
IsVisible="{Binding IsValid}">
|
IsVisible="{Binding IsLogin}">
|
||||||
<WebView
|
<WebView
|
||||||
Source="{Binding LoginUrl}"
|
Source="{Binding LoginUrl}"
|
||||||
AbsoluteLayout.LayoutBounds="0, 0, 1, 1"
|
AbsoluteLayout.LayoutBounds="0, 0, 1, 1"
|
||||||
|
@ -3,7 +3,6 @@
|
|||||||
xmlns="http://xamarin.com/schemas/2014/forms"
|
xmlns="http://xamarin.com/schemas/2014/forms"
|
||||||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
||||||
x:Class="eShopOnContainers.Core.Views.Templates.BasketItemTemplate"
|
x:Class="eShopOnContainers.Core.Views.Templates.BasketItemTemplate"
|
||||||
xmlns:controls="clr-namespace:eShopOnContainers.Core.Controls;assembly=eShopOnContainers.Core"
|
|
||||||
xmlns:ffimageloading="clr-namespace:FFImageLoading.Forms;assembly=FFImageLoading.Forms">
|
xmlns:ffimageloading="clr-namespace:FFImageLoading.Forms;assembly=FFImageLoading.Forms">
|
||||||
<ContentView.Resources>
|
<ContentView.Resources>
|
||||||
<ResourceDictionary>
|
<ResourceDictionary>
|
||||||
@ -54,12 +53,12 @@
|
|||||||
Value="End" />
|
Value="End" />
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
<Style x:Key="QuantityPickerStyle"
|
<Style x:Key="QuantityStyle"
|
||||||
TargetType="{x:Type controls:BindablePicker}">
|
TargetType="{x:Type Label}">
|
||||||
|
<Setter Property="FontFamily"
|
||||||
|
Value="{StaticResource MontserratRegular}" />
|
||||||
<Setter Property="TextColor"
|
<Setter Property="TextColor"
|
||||||
Value="{StaticResource BlackColor}" />
|
Value="{StaticResource BlackColor}" />
|
||||||
<Setter Property="BackgroundColor"
|
|
||||||
Value="Transparent" />
|
|
||||||
<Setter Property="HorizontalOptions"
|
<Setter Property="HorizontalOptions"
|
||||||
Value="End" />
|
Value="End" />
|
||||||
<Setter Property="VerticalOptions"
|
<Setter Property="VerticalOptions"
|
||||||
@ -138,19 +137,11 @@
|
|||||||
Grid.Column="0"
|
Grid.Column="0"
|
||||||
Text="{Binding UnitPrice, StringFormat='${0:N}'}"
|
Text="{Binding UnitPrice, StringFormat='${0:N}'}"
|
||||||
Style="{StaticResource OrderItemUnitPriceStyle}"/>
|
Style="{StaticResource OrderItemUnitPriceStyle}"/>
|
||||||
<controls:BindablePicker
|
<!-- QUANTITY -->
|
||||||
|
<Label
|
||||||
Grid.Column="1"
|
Grid.Column="1"
|
||||||
ItemsSource="{Binding Numbers}"
|
Text="{Binding Quantity}"
|
||||||
SelectedItem="{Binding Quantity, Mode=TwoWay}"
|
Style="{StaticResource QuantityStyle}"/>
|
||||||
Style="{StaticResource QuantityPickerStyle}">
|
|
||||||
<controls:BindablePicker.WidthRequest>
|
|
||||||
<OnPlatform
|
|
||||||
x:TypeArguments="x:Double"
|
|
||||||
Android="36"
|
|
||||||
iOS="36"
|
|
||||||
WinPhone="72"/>
|
|
||||||
</controls:BindablePicker.WidthRequest>
|
|
||||||
</controls:BindablePicker>
|
|
||||||
</Grid>
|
</Grid>
|
||||||
<!-- TOTAL -->
|
<!-- TOTAL -->
|
||||||
<Label
|
<Label
|
||||||
|
@ -65,7 +65,6 @@
|
|||||||
<Compile Include="Extensions\ObservableExtension.cs" />
|
<Compile Include="Extensions\ObservableExtension.cs" />
|
||||||
<Compile Include="GlobalSettings.cs" />
|
<Compile Include="GlobalSettings.cs" />
|
||||||
<Compile Include="Helpers\EasingHelper.cs" />
|
<Compile Include="Helpers\EasingHelper.cs" />
|
||||||
<Compile Include="Helpers\NumericHelper.cs" />
|
|
||||||
<Compile Include="Helpers\Settings.cs" />
|
<Compile Include="Helpers\Settings.cs" />
|
||||||
<Compile Include="Models\Basket\BasketItem.cs" />
|
<Compile Include="Models\Basket\BasketItem.cs" />
|
||||||
<Compile Include="Models\Catalog\CatalogBrand.cs" />
|
<Compile Include="Models\Catalog\CatalogBrand.cs" />
|
||||||
@ -81,8 +80,10 @@
|
|||||||
<Compile Include="Models\User\Address.cs" />
|
<Compile Include="Models\User\Address.cs" />
|
||||||
<Compile Include="Models\User\LogoutParameter.cs" />
|
<Compile Include="Models\User\LogoutParameter.cs" />
|
||||||
<Compile Include="Models\User\PaymentInfo.cs" />
|
<Compile Include="Models\User\PaymentInfo.cs" />
|
||||||
|
<Compile Include="Models\User\UserInfo.cs" />
|
||||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||||
<Compile Include="Services\Catalog\CatalogService.cs" />
|
<Compile Include="Services\Catalog\CatalogService.cs" />
|
||||||
|
<Compile Include="Services\Common\Common.cs" />
|
||||||
<Compile Include="Services\Dialog\DialogService.cs" />
|
<Compile Include="Services\Dialog\DialogService.cs" />
|
||||||
<Compile Include="Services\Dialog\IDialogService.cs" />
|
<Compile Include="Services\Dialog\IDialogService.cs" />
|
||||||
<Compile Include="Services\Identity\IdentityService.cs" />
|
<Compile Include="Services\Identity\IdentityService.cs" />
|
||||||
@ -103,6 +104,7 @@
|
|||||||
<Compile Include="Services\RequestProvider\RequestProvider.cs" />
|
<Compile Include="Services\RequestProvider\RequestProvider.cs" />
|
||||||
<Compile Include="Services\User\IUserService.cs" />
|
<Compile Include="Services\User\IUserService.cs" />
|
||||||
<Compile Include="Services\User\UserMockService.cs" />
|
<Compile Include="Services\User\UserMockService.cs" />
|
||||||
|
<Compile Include="Services\User\UserService.cs" />
|
||||||
<Compile Include="Triggers\BeginAnimation.cs" />
|
<Compile Include="Triggers\BeginAnimation.cs" />
|
||||||
<Compile Include="Validations\IsNotNullOrEmptyRule.cs" />
|
<Compile Include="Validations\IsNotNullOrEmptyRule.cs" />
|
||||||
<Compile Include="Validations\IValidationRule.cs" />
|
<Compile Include="Validations\IValidationRule.cs" />
|
||||||
|
@ -10,7 +10,6 @@ namespace eShopOnContainers.Droid.Activities
|
|||||||
Label = "eShopOnContainers",
|
Label = "eShopOnContainers",
|
||||||
Icon = "@drawable/icon",
|
Icon = "@drawable/icon",
|
||||||
Theme = "@style/Theme.Splash",
|
Theme = "@style/Theme.Splash",
|
||||||
MainLauncher = true,
|
|
||||||
NoHistory = true,
|
NoHistory = true,
|
||||||
ScreenOrientation = ScreenOrientation.Portrait)]
|
ScreenOrientation = ScreenOrientation.Portrait)]
|
||||||
public class SplashActivity : AppCompatActivity
|
public class SplashActivity : AppCompatActivity
|
||||||
|
Loading…
x
Reference in New Issue
Block a user