Exemple #1
0
        public async void closeClearSearchViewafterSearch(object sender, EventArgs e)
        {
            try
            {
                JobListHelper.IsSearching = false;
                JobListHelper.IntialzieList();
                clear.IsEnabled  = false;
                search.IsEnabled = false;
                await((JobSearchviewModel)CurrentJobsLayout.BindingContext).BindData(true, true);
                // ChangeToCurrent(null, null);
            }
            catch (Exception ex)
            {
                var logged = new LoggedException.LoggedException("Error in joblistingtapedimage.xaml.cs", ex);
                await logged.LoggAPI();
            }
            finally
            {
                await FilterGrid.FadeTo(0);

                FilterGrid.IsVisible      = false;
                searchtap.BackgroundColor = Color.White;
                isearchtap.Source         = "Magnifier.png";
                searchtapLabel.TextColor  = Color.DimGray;
                MyJobstap.BackgroundColor = Color.FromHex("#87c8ee");
                iMyJobstap.Source         = "MyJobsi.png";
                MyJobstapLabel.TextColor  = Color.White;
                search.IsEnabled          = true;
                clear.IsEnabled           = true;
            }
        }
Exemple #2
0
        private async void TapGestureRecognizer_Tapped_1(object sender, EventArgs e)
        {
            try
            {
                if (_userTapped1)
                {
                    return;
                }
                _userTapped1             = true;
                selectgridtabs.IsEnabled = false;
                if (FilterGrid.IsVisible)
                {
                    constants.SearchView = false;
                    await FilterGrid.FadeTo(0);

                    FilterGrid.IsVisible      = false;
                    searchtap.BackgroundColor = Color.White;
                    isearchtap.Source         = "Magnifier.png";
                    searchtapLabel.TextColor  = Color.DimGray;

                    //
                    MyJobstap.BackgroundColor   = Color.FromHex("#87c8ee");
                    iMyJobstap.Source           = "MyJobsi.png";
                    MyJobstapLabel.TextColor    = Color.White;
                    namegrid.IsVisible          = true;
                    CurrentJobsLayout.IsVisible = true;
                    //gray color
                }
                else
                {
                    FilterGrid.IsVisible = true;
                    await FilterGrid.FadeTo(1);

                    searchtap.BackgroundColor = Color.FromHex("#87c8ee");
                    isearchtap.Source         = "Magnifieri.png";
                    searchtapLabel.TextColor  = Color.White;
                    MyJobstap.BackgroundColor = Color.White;
                    iMyJobstap.Source         = "MyJobs.png";
                    MyJobstapLabel.TextColor  = Color.DimGray;
                    //blue color
                }
            }
            catch (Exception ex)
            {
                var logged = new LoggedException.LoggedException("Error while trying to load jobs", ex);
                await logged.LoggAPI();
            }
            finally
            {
                _userTapped1             = false;
                selectgridtabs.IsEnabled = true;
            }
        }
Exemple #3
0
        public async void closeSearchViewafterSearch(object sender, EventArgs e)
        {
            try
            {
                if (startDate.Date >= endDate.Date)
                {
                    await DisplayAlert(AlertMessages.ErrorTitle, AlertMessages.comparedate, "Ok");

                    return;
                }
                else
                {
                    JobListHelper.IsSearching = true;
                    search.IsEnabled          = false;
                    clear.IsEnabled           = false;

                    await((JobSearchviewModel)CurrentJobsLayout.BindingContext).BindData(true);
                    MyJobstap.BackgroundColor = Color.FromHex("#87c8ee");
                    iMyJobstap.Source         = "MyJobsi.png";
                    MyJobstapLabel.TextColor  = Color.White;
                    searchtap.BackgroundColor = Color.White;
                    isearchtap.Source         = "Magnifier.png";
                    searchtapLabel.TextColor  = Color.DimGray;
                    await FilterGrid.FadeTo(0);

                    search.IsEnabled            = true;
                    clear.IsEnabled             = true;
                    FilterGrid.IsVisible        = false;
                    constants.SearchView        = false;
                    namegrid.IsVisible          = true;
                    CurrentJobsLayout.IsVisible = true;
                    ChangeToCurrent(null, null);
                }
            }
            catch (Exception ex)
            {
                var logged = new LoggedException.LoggedException("Error in joblistingtapedimage.xaml.cs", ex);
                logged.LoggAPI();
            }
            //finally
            //{

            //    await FilterGrid.FadeTo(0);
            //    search.IsEnabled = true;
            //    clear.IsEnabled = true;
            //    FilterGrid.IsVisible = false;
            //    constants.SearchView = false;
            //    namegrid.IsVisible = true;
            //    CurrentJobsLayout.IsVisible = true;
            //    DisplayAlert(AlertMessages.ErrorTitle, "!!!!!!!!!!!1", "Ok");
            //}
        }
Exemple #4
0
        protected override async void OnAppearing()
        {
            try
            {
                // await LoadJobs();

                //JobListHelper.ExpireTimerEnabled = false;
                await Task.Yield();

                LoadingIndicatorHelper.Intialize(this);


                if (JobListHelper.IsApplied)
                {
                    //Refresh Applied List
                    int oldCount = JobsCounterHelper.NoOfAppliedJobs;
                    await((AppliedJobsViewModel)AppliedJobsLayout.BindingContext).BindData(true);
                    int newCount = oldCount + 1;
                    JobsCounterHelper.NoOfAppliedJobs      = newCount;
                    JobsCounterHelper._noOfAppliedJobsText = JobsCounterHelper.NoOfAppliedJobsText();
                    ((JobSearchviewModel)namegrid.BindingContext).Applied = JobsCounterHelper.NoOfAppliedJobsText();

                    ChangeToApplied(null, null);
                    JobListHelper.IsSearching = false;
                    JobListHelper.IsSaved     = false;
                }
                //else if (JobListHelper.IsSearching)
                //{
                //    JobListHelper.IsApplied = false;
                //    JobLissearchtaptHelper.IsSaved = false;
                //    .BackgroundColor = Color.FromHex("#87c8ee");
                //    isearchtap.Source = "Magnifier.png";
                //    searchtapLabel.TextColor = Color.White;
                //    MyJobstap.BackgroundColor = Color.White;
                //    iMyJobstap.Source = "MyJobsi.png";
                //    MyJobstapLabel.TextColor = Color.DimGray;
                //    ChangeToCurrent(null, null);

                //}
                else if (JobListHelper.IsSaved)
                {
                    JobListHelper.IsSearching = false;
                    JobListHelper.IsSaved     = false;
                    ChangeToSaved(null, null);
                }


                if (constants.SearchView)
                {
                    constants.SearchView = false;

                    //if (FilterGrid.IsVisible)
                    //{

                    //    FilterGrid.FadeTo(0);
                    //    FilterGrid.IsVisible = false;

                    //    searchtap.BackgroundColor = Color.White;
                    //    isearchtap.Source = "Magnifier.png";
                    //    searchtapLabel.TextColor = Color.DimGray;
                    //    //gray color
                    //}
                    //else
                    //{
                    FilterGrid.IsVisible        = true;
                    CurrentJobsLayout.IsVisible = false;
                    namegrid.IsVisible          = false;
                    FilterGrid.FadeTo(1);
                    searchtap.BackgroundColor = Color.FromHex("#87c8ee");
                    isearchtap.Source         = "Magnifieri.png";
                    searchtapLabel.TextColor  = Color.White;
                    MyJobstap.BackgroundColor = Color.White;
                    iMyJobstap.Source         = "MyJobs.png";
                    MyJobstapLabel.TextColor  = Color.DimGray;

                    //}
                }
                else
                {
                    MyJobstap.BackgroundColor   = Color.FromHex("#87c8ee");
                    iMyJobstap.Source           = "MyJobsi.png";
                    MyJobstapLabel.TextColor    = Color.White;
                    CurrentJobsLayout.IsVisible = true;
                }
            }
            catch (Exception ex)
            {
                var logged = new LoggedException.LoggedException("error in joblisting.xaml.cs", ex);
                await logged.LoggAPI();
            }
        }