private void SetUpReceipientUI()
        {
            /** Receipient Row Set Up**/
            var recipientRowTitle = ObjectCreatorHelper.createLabel(12, 22, Color.White, TextAlignment.Center, Color.Orange, "Recipient UserID", new Thickness(8, 4, 8, 0));

            //setUpRecipientPicker();

            recipientEntry = ObjectCreatorHelper.createEntry(14, 36, Color.White, Color.Gray, new Thickness(8, 8, 8, 0), "Input Recipient Username", Keyboard.Create(KeyboardFlags.CapitalizeSentence));
            var recipientDivider = new BoxView {
                WidthRequest = 200, HeightRequest = 0.25, BackgroundColor = Color.LightGray, Margin = new Thickness(0, 0, 0, 0)
            };
            var RecipientRow = ObjectCreatorHelper.createStackLayout(new Thickness(0, 8, 0, 0), Color.White, 80, true);

            RecipientRow.Children.Add(recipientRowTitle);
            RecipientRow.Children.Add(recipientEntry);
            RecipientRow.Children.Add(recipientDivider);

            ObjectCreatorHelper.addChildToParent(deviceInfoRl, RecipientRow, ingestDeviceLv, 0, ingestDeviceLv.Height + 8, 0);
            var receipientDivider = new BoxView {
                WidthRequest = 200, HeightRequest = 1, BackgroundColor = Color.LightGray
            };

            ObjectCreatorHelper.addChildToParent(deviceInfoRl, receipientDivider, RecipientRow, 0, RecipientRow.Height + 0.25, 0);
            recipientEntry.Completed += Entry_Completed;

            void Entry_Completed(object sender, EventArgs e)
            {
                autoPopulateEntry(((Entry)sender));
            }

            ObjectCreatorHelper.addChildToParent(deviceInfoRl, ingestDeviceRecipientLv, receipientDivider, 0, receipientDivider.Height + 0.25, 0);
            ObjectCreatorHelper.addChildToParent(deviceInfoRl, submitBtn, ingestDeviceRecipientLv, 0, ingestDeviceLv.Height + 8, 0);
            /** END - User Recipient Row Set Up**/
        }
 protected override void OnAppearing()
 {
     base.OnAppearing();
     PullListOfDevices(usernameKey);
     noDeviceInListLabel = ObjectCreatorHelper.createLabel(13, 40, Color.White, TextAlignment.Center, Color.Gray, "No Active Devices", new Thickness(0, 0, 0, 0));
     noDeviceInListLabel.VerticalTextAlignment   = TextAlignment.Center;
     noDeviceInListLabel.HorizontalTextAlignment = TextAlignment.Center;
 }
예제 #3
0
        protected override void OnAppearing()
        {
            base.OnAppearing();
            incomingLb = ObjectCreatorHelper.createLabel(10, 12, Color.Transparent, TextAlignment.Start, Color.Black, "INCOMING", new Thickness(0, 0, 0, 0));
            outgoingLb = ObjectCreatorHelper.createLabel(10, 12, Color.Transparent, TextAlignment.Start, Color.Black, "OUTGOING", new Thickness(0, 16, 0, 0));

            noActiveOutgoingLbl = ObjectCreatorHelper.createLabel(13, 40, Color.White, TextAlignment.Center, Color.Black, "No active transfers.", new Thickness(0, 0, 0, 0));
            noActiveOutgoingLbl.VerticalTextAlignment   = TextAlignment.Center;
            noActiveOutgoingLbl.HorizontalTextAlignment = TextAlignment.Center;

            noActiveIncomingLbl = ObjectCreatorHelper.createLabel(13, 40, Color.White, TextAlignment.Center, Color.Black, "No active transfers.", new Thickness(0, 0, 0, 0));
            noActiveIncomingLbl.VerticalTextAlignment   = TextAlignment.Center;
            noActiveIncomingLbl.HorizontalTextAlignment = TextAlignment.Center;            //    new Label

            ObjectCreatorHelper.addToRootParent(historyRl, incomingLb, 8, 8, -16);
        }
        private void SetUpAssetIdUI()
        {
            /** Asset Row Set Up**/
            var AssetRowTitle = ObjectCreatorHelper.createLabel(12, 32, Color.White, TextAlignment.Center, Color.Gray, "AssetID", new Thickness(0, 0, 0, 0));

            AssetRowSubtitle = ObjectCreatorHelper.createLabel(14, 32, Color.White, TextAlignment.Center, Color.LightGray, "Tap to scan assetID barcode", new Thickness(0, 0, 0, 0));
            var AssetIdRow = ObjectCreatorHelper.createStackLayout(new Thickness(8, 0, 8, 0), Color.White, 80, true);

            AssetIdRow.Children.Add(AssetRowTitle);
            AssetIdRow.Children.Add(AssetRowSubtitle);
            AssetIdRow.GestureRecognizers.Add(new TapGestureRecognizer {
                Command = new Command(() => SetUpScanner(AssetRowSubtitle, ZXing.BarcodeFormat.CODE_93, "Scan Asset Id Code")),
            });

            ObjectCreatorHelper.addToRootParent(deviceInfoRl, AssetIdRow, 8, 8, 16);
            assetDivider = new BoxView {
                WidthRequest = 200, HeightRequest = 1, BackgroundColor = Color.LightGray
            };
            ObjectCreatorHelper.addChildToParent(deviceInfoRl, assetDivider, AssetIdRow, 0, assetDivider.Height, 0);
            /** END - Asset Row Set Up**/
        }
        private void SetUpImeiUI()
        {
            /** IMEI Row Set Up**/
            var ImeiCodeRowTitle = ObjectCreatorHelper.createLabel(12, 32, Color.White, TextAlignment.Center, Color.Gray, "IMEI Barcode", new Thickness(0, 0, 0, 0));

            ImeiCodeRowSubtitle = ObjectCreatorHelper.createLabel(14, 32, Color.White, TextAlignment.Center, Color.LightGray, "Tap to scan IMEI barcode", new Thickness(0, 0, 0, 0));
            var ImeiCodeRow = ObjectCreatorHelper.createStackLayout(new Thickness(8, 0, 8, 0), Color.White, 80, true);

            ImeiCodeRow.Children.Add(ImeiCodeRowTitle);
            ImeiCodeRow.Children.Add(ImeiCodeRowSubtitle);
            ImeiCodeRow.GestureRecognizers.Add(new TapGestureRecognizer {
                Command = new Command(() => SetUpScanner(ImeiCodeRowSubtitle, ZXing.BarcodeFormat.CODE_128, "Scan Asset IMEI Code")),
            });

            var imeiDivider = new BoxView {
                WidthRequest = 200, HeightRequest = 1, BackgroundColor = Color.LightGray
            };

            ObjectCreatorHelper.addChildToParent(deviceInfoRl, ImeiCodeRow, assetDivider, 0, assetDivider.Height + 0.25, 0);
            ObjectCreatorHelper.addChildToParent(deviceInfoRl, imeiDivider, ImeiCodeRow, 0, ImeiCodeRow.Height, 0);
            ObjectCreatorHelper.addChildToParent(deviceInfoRl, ingestDeviceLv, imeiDivider, 0, ImeiCodeRow.Height + 0.25, 0);
            /**END -  IMEI Row Set Up**/
        }