示例#1
0
        public async Task SearchAndPopulate()
        {
            Busy = true;
            var data = new  PickDataStore();

            var pickModelSearch = new PickModelSearch()
            {
                SearchFromLocationCode = _searchFromLocationCode,
                SearchBarcode          = _searchBarcode,
                SearchDocumentNo       = _searchDocumentNo,
                SearchProduct          = _searchProduct
            };

            try
            {
                var result = await data.GetItemAsync(pickModelSearch, "80");

                if (result == null)
                {
                    Busy = false;
                    await _navigationService.DisplayAlert("Alert", "Store Pick Empty", "Ok");
                }
                else
                {
                    Busy = false;
                    await _navigationService.PushAsync(new StorePickPage(_navigationService, pickModelSearch, (TaskModel)result.Data));
                }
            }
            catch (Exception ex)
            {
                Busy = false;
                await _navigationService.DisplayAlert("Server.", ex.Message, "Ok");
            }
        }
示例#2
0
        private async Task GetTaskMethod()
        {
            var result = await pickDataStore.GetItemAsync(_modelSearch, "80");

            if (result.IsException)
            {
                await _navigationService.DisplayAlert("Alert.", result.Message, "Ok");

                await _navigationService.PopAsync();
            }
            if (result.Status)
            {
                CurrentTask = (TaskModel)result.Data;
            }
        }