示例#1
0
        public async Task <CustomerContainerResponse> GetCustomerContainers(long customerId)
        {
            CustomerContainerRequest request = new CustomerContainerRequest();

            request.CustomerContainer.CustomerId = customerId;
            CustomerContainerResponse response = await PostRequest <CustomerContainerRequest, CustomerContainerResponse>("GetCustomerContainers", request);

            return(response);
        }
示例#2
0
        private void ShowCustomerContainerData(CustomerContainerResponse response)
        {
            customerContainers = response.CustomerContainers;
            customerContainersOC.Clear();

            foreach (CustomerContainerDTO cc in customerContainers)
            {
                customerContainersOC.Add(cc);
            }

            Device.BeginInvokeOnMainThread(() =>
            {
                CustomerContainerListView.ItemsSource = customerContainersOC;
            });
        }
        private void CustomerContainersLoaded(CustomerContainerResponse result)
        {
            Device.BeginInvokeOnMainThread(() =>
            {
                customerContainers = result.CustomerContainers;

                if (customerContainers.Count > 0)
                {
                    EnableCustomerContainerSecondaryControls(true);

                    containers.Add(new KeyValuePair <long, string>(2, "Customer container at EO"));
                    containers.Add(new KeyValuePair <long, string>(3, "Customer container at customer site")); //means use liner
                }
            });
        }
示例#4
0
        private void CustomerContainersLoaded(CustomerContainerResponse response)
        {
            if (response.CustomerContainers.Count > 0)
            {
                Dispatcher.Invoke(() =>
                {
                    ObservableCollection <CustomerContainerDTO> containers = new ObservableCollection <CustomerContainerDTO>();

                    foreach (CustomerContainerDTO cc in response.CustomerContainers)
                    {
                        containers.Add(cc);
                    }

                    CustomerContainerListView.ItemsSource = containers;
                });
            }
        }
        private void CustomerContainersLoaded(CustomerContainerResponse response)
        {
            Dispatcher.Invoke(() =>
            {
                if (response.CustomerContainers.Count > 0)
                {
                    EnableCustomerContainerSecondaryControls(true);

                    containers.Add(new KeyValuePair <long, string>(2, "Customer container at EO"));
                    containers.Add(new KeyValuePair <long, string>(3, "Customer container at customer location"));

                    if (currentArrangement.Arrangement.CustomerContainerId.HasValue)
                    {
                        customerContainers = response.CustomerContainers;
                        SetComboBoxSelection(Container, currentArrangement.Arrangement.Container);

                        if (customerContainers.Where(a => a.CustomerContainerId == currentArrangement.Arrangement.CustomerContainerId).Any())
                        {
                            CustomerContainer = customerContainers.Where(a => a.CustomerContainerId == currentArrangement.Arrangement.CustomerContainerId).First();
                            CustomerContainerLabelEntry.Text = CustomerContainer.Label;
                        }
                    }
                }
                else
                {
                    EnableCustomerContainerSecondaryControls(false);
                }

                if (currentArrangement.Arrangement.ArrangementId > 0)
                {
                    LoadPageData();

                    ReloadListData();
                }

                //set the handler last - selection change triggers a page load
                Container.SelectionChanged += Container_SelectionChanged;
            });
        }