public EventDetailsViewModel(long id) { _eventadorApi = EventadorApi.ResolveApi(); Item = _eventadorApi.GetEventById(id).Result; Item.ImageUrls = new[] { "event2.png", "event3.png" }; var userId = long.Parse(SecureStorage.GetAsync("UserId").Result); isAuthor = Item.AuthorId == userId; }
public MainPage() { _eventadorApi = EventadorApi.ResolveApi(); RequestUserData(); BindingContext = MainViewModel; NavigationPage.SetHasNavigationBar(this, false); MessagingCenter.Unsubscribe <MessageBus, int>(this, Consts.NavigationTabPageMessage); MessagingCenter.Subscribe <MessageBus, int>(this, Consts.NavigationTabPageMessage, NavigationTabPageCallback); InitializeComponent(); }
public ProfileViewModel() { _eventadorApi = EventadorApi.ResolveApi(); _authService = DependencyService.Resolve <AuthService>(); GetUserInfo(); }
public RegisterViewModel() { RegisterModel = new RegisterModel(); _eventadorApi = EventadorApi.ResolveApi(); }
public AuthService() { _eventadorApi = EventadorApi.ResolveApi(); }