public FisOzet(List <ImageForApiModel> images) { totalAmount = 0; totalTax = 0; this.images = images; InitializeComponent(); getFisler(); getImages(); for (int i = 0; i < urunList.Count; i++) { RecipeItemStr item = urunList[i]; Label lblLineDescription = new Label(); lblLineDescription.Text = item.LineDescription; grdRecipeItems.Children.Add(lblLineDescription, 0, i); Label lblLineTax = new Label(); lblLineTax.Text = item.LineTax; grdRecipeItems.Children.Add(lblLineTax, 1, i); Label lblLineTotal = new Label(); lblLineTotal.Text = item.LineTotal; lblLineTotal.HorizontalOptions = LayoutOptions.End; grdRecipeItems.Children.Add(lblLineTotal, 2, i); } lblToplamTutar.Text = totalAmount.ToString(); lblToplamKdv.Text = totalTax.ToString(); }
public FisDetay(ReceiptStr fis) { receipt = fis; InitializeComponent(); if (receipt == null) { DisplayAlert("File Location", "Fiş Yüklenemedi", "OK"); return; } lblCompany.Text = receipt.Company; lblAdress.Text = receipt.Adress; lblTarih.Text = receipt.Date; lblSaat.Text = receipt.Time; lblFisNo.Text = receipt.DocumentNumber; for (int i = 0; i < receipt.RecipeItems.Count; i++) { RecipeItemStr item = receipt.RecipeItems[i]; Label lblLineDescription = new Label(); lblLineDescription.Text = item.LineDescription; grdRecipeItems.Children.Add(lblLineDescription, 0, i); Label lblLineTax = new Label(); lblLineTax.Text = item.LineTax; grdRecipeItems.Children.Add(lblLineTax, 1, i); Label lblLineTotal = new Label(); lblLineTotal.Text = item.LineTotal; lblLineTotal.HorizontalOptions = LayoutOptions.End; grdRecipeItems.Children.Add(lblLineTotal, 2, i); } lblToplamKdv.Text = receipt.TaxTotal; lblToplamTutar.Text = receipt.GrandTotal; lblTaxNumber.Text = receipt.TaxNumber; }