protected void btnPrintAnexDeal_Click(object sender, EventArgs e) { if (GXGridView1.SelectedIndex != -1) { Broker.DataAccess.Facture f; if (GXGridView1.SelectedValue != null) { int GXgvSelectedValue = Convert.ToInt32(GXGridView1.SelectedValue); f = Broker.DataAccess.Facture.Get(GXgvSelectedValue); } else { int GXgvSelectedValue = GXGridView1SelectedValue; f = Broker.DataAccess.Facture.Get(GXgvSelectedValue); } if (f.DocumentSubType.Code == Broker.DataAccess.DocumentSubType.FAKTURA_KLIENT) { btnFactureItems.CssClass = "prikaz"; btnPreview.CssClass = "osvezi"; btnReport.CssClass = "izvestaj"; btnSearch.CssClass = "prebaraj"; btnFactureItems.CssClass = "prikaz"; btnPintFacture.CssClass = "pecati"; btnChangeStatus.CssClass = "promeniStatus"; btnPrintAnex.CssClass = "dogovor_Active"; PrintFactures.PrintAnex(f); } } }
protected void btnPrintAnex_Click(object sender, EventArgs e) { if (FactureID > 0) { Broker.DataAccess.Facture f = Broker.DataAccess.Facture.Get(FactureID); PrintFactures.PrintAnex(f); } }
protected void btnPrintAnexDeal_Click(object sender, EventArgs e) { if (GXGridView1.SelectedIndex != -1) { Broker.DataAccess.Facture f; if (GXGridView1.SelectedValue != null) { int GXgvSelectedValue = Convert.ToInt32(GXGridView1.SelectedValue); f = Broker.DataAccess.Facture.Get(GXgvSelectedValue); } else { int GXgvSelectedValue = GXGridView1SelectedValue; f = Broker.DataAccess.Facture.Get(GXgvSelectedValue); } if (f.DocumentSubType.Code == DocumentSubType.FAKTURA_KLIENT || f.DocumentSubType.Code == DocumentSubType.GRUPNA_FAKTURA) { List <PolicyItemFactureItem> pifi = PolicyItemFactureItem.GetByFactureID(f.ID); if (pifi[0].PolicyItem.Rates.Count > 0) { btnNew.CssClass = "novZapis"; btnFactureItems.CssClass = "prikaz"; btnPreview.CssClass = "osvezi"; btnReport.CssClass = "izvestaj"; btnSearch.CssClass = "prebaraj"; btnFactureItems.CssClass = "prikaz"; btnPintFacture.CssClass = "pecati"; btnChangeStatus.CssClass = "promeniStatus"; btnPrintAnex.CssClass = "dogovor_Active"; btnPaymentsPerFacture.CssClass = "plakanja"; PrintFactures.PrintAnex(f); } else { RegisterStartupScript("myAlert", "<script>alert('Фактурата не е договорена за плаќање на рати!')</script>"); } } else { RegisterStartupScript("myAlert", "<script>alert('Фактурата не е договорена за плаќање на рати!')</script>"); } } }