Пример #1
0
        private void attachmentsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            var view = frkGridView;

            if (view.FocusedRowHandle == DevExpress.XtraGrid.GridControl.NewItemRowHandle || !view.IsDataRow(view.FocusedRowHandle))
            {
                return;
            }

            if (view.DataRowCount == 0)
            {
                return;
            }

            int refId = (int)view.GetFocusedRowCellValue(colFRKID);

            Doc.DocXF frm = new Doc.DocXF();
            frm.RefTbl   = "FRK";
            frm.RefID    = refId;
            frm.RefInfo  = view.GetFocusedRowCellDisplayText(colAD);
            frm.Editable = view.GetFocusedRowCellValue(colEDITABLE).ToString() == "T" ? true : false;

            frm.ShowDialog();
            frm.Dispose();
        }
Пример #2
0
        private void attachmentsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (frtGridView.DataRowCount == 0)
            {
                return;
            }

            int refId;

            /* // Merkezi/HQ varsa onun altinda topla
             * if (frtGridView.GetFocusedRowCellValue(colHDQID) == DBNull.Value)
             *  refId = (int)frtGridView.GetFocusedRowCellValue(colFRTID);
             * else
             *  refId = (int)frtGridView.GetFocusedRowCellValue(colHDQID);
             */
            refId = (int)frtGridView.GetFocusedRowCellValue(colFRTID);

            Doc.DocXF frm = new Doc.DocXF();
            frm.RefTbl  = "FRT";
            frm.RefID   = refId;
            frm.RefInfo = frtGridView.GetFocusedRowCellDisplayText(colADN);
            frm.ShowDialog();
            frm.Dispose();

            /*
             * bool panelYok = true;
             * for (int i = 0; i < dockManager.Panels.Count; i++)
             * {
             *  if (dockManager.Panels[i].Name == "docPanel")
             *  {
             *      dockManager.Panels[i].Show();
             *      panelYok = false;
             *  }
             * }
             * if (panelYok)
             * {
             *  int refId; // Merkezi/HQ varsa onun altinda topla
             *  if (frtGridView.GetFocusedRowCellValue(colHDQID) == DBNull.Value)
             *      refId = (int)frtGridView.GetFocusedRowCellValue(colFRTID);
             *  else
             *      refId = (int)frtGridView.GetFocusedRowCellValue(colHDQID);
             *
             *  var panel = dockManager.AddPanel(DevExpress.XtraBars.Docking.DockingStyle.Bottom);
             *  panel.Name = "docPanel";
             *
             *  docFrm = new Docs.docForm();
             *  docFrm.refTbl = "FRT";
             *  docFrm.refId = refId;
             *  panel.Text = "Attachments " + docFrm.refTbl + "/" + refId.ToString();
             *  docFrm.Dock = DockStyle.Fill;
             *  panel.Controls.Add(docFrm);     // Panel Show edilene kadar FormLoad cagrilmiyor
             * }*/
        }
Пример #3
0
        private void attachmentsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            var view = jrnGridView;

            if (view.DataRowCount > 0 && view.IsDataRow(view.FocusedRowHandle))
            {
                Doc.DocXF frm = new Doc.DocXF();
                frm.RefTbl  = "JRN";
                frm.RefID   = (int)view.GetFocusedRowCellValue(colJRNID);
                frm.RefInfo = view.GetFocusedRowCellDisplayText(colSUBJECT);
                frm.ShowDialog();
                frm.Dispose();
            }
        }
Пример #4
0
        private void documentsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (ustGridView.DataRowCount == 0)
            {
                return;
            }

            Doc.DocXF frm = new Doc.DocXF();
            frm.RefTbl  = "UST";
            frm.RefID   = (int)ustGridView.GetFocusedRowCellValue(colUSTID);
            frm.RefInfo = ustGridView.GetFocusedRowCellDisplayText(colAD);
            frm.ShowDialog();
            frm.Dispose();
        }
Пример #5
0
        private void attachmentsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (ophoGridView.DataRowCount == 0)
            {
                return;
            }

            Doc.DocXF frm = new Doc.DocXF();
            frm.RefTbl  = "OPHO";
            frm.RefID   = (int)ophoGridView.GetFocusedRowCellValue(colOPHOID);
            frm.RefInfo = ophoGridView.GetFocusedRowCellDisplayText(colOPHOID);
            frm.ShowDialog();
            frm.Dispose();
        }
Пример #6
0
        private void attachmentsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (!opcGridView.IsDataRow(opcGridView.FocusedRowHandle))
            {
                return;
            }

            Doc.DocXF frm = new Doc.DocXF();
            frm.RefTbl  = "OPC";
            frm.RefID   = (int)opcGridView.GetFocusedRowCellValue(colOPCID);
            frm.RefInfo = opcGridView.GetFocusedRowCellDisplayText(colCNTNO);
            frm.ShowDialog();
            frm.Dispose();
        }
Пример #7
0
        private void attachmentToolStripMenuItem_Click(object sender, EventArgs e)
        {
            GridView view = tsbGridView;

            if (view.DataRowCount == 0)
            {
                return;
            }

            Doc.DocXF frm = new Doc.DocXF();
            frm.RefTbl  = "TSB";
            frm.RefID   = (int)view.GetFocusedRowCellValue(colTSBID);
            frm.RefInfo = view.GetFocusedRowCellDisplayText(colTSBID);
            frm.ShowDialog();
            frm.Dispose();
        }
Пример #8
0
        private void attachmentsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (!tafGridView.IsDataRow(tafGridView.FocusedRowHandle))
            {
                return;
            }

            if (tafGridView.GetFocusedRowCellValue(colVisible).ToString() == "T")
            {
                Doc.DocXF frm = new Doc.DocXF();
                frm.RefTbl  = "OPC";
                frm.RefID   = (int)tafGridView.GetFocusedRowCellValue(colTAFID);
                frm.RefInfo = tafGridView.GetFocusedRowCellDisplayText(colTAFID);
                frm.ShowDialog();
                frm.Dispose();
            }
        }
Пример #9
0
        private void attachmentsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            var view = afbGridView;

            if (!view.IsDataRow(view.FocusedRowHandle))
            {
                return;
            }

            Doc.DocXF frm = new Doc.DocXF();

            frm.RefTbl  = "AFB";
            frm.RefID   = (int)view.GetFocusedRowCellValue(colAFBID);
            frm.RefInfo = "Fatura: " + view.GetFocusedRowCellDisplayText(colAFBID);
            frm.AltTbl  = "FRT";
            frm.AltID   = (int)view.GetFocusedRowCellValue(colFRTID);;

            frm.ShowDialog();
            frm.Dispose();
        }
Пример #10
0
        private void attachmentsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (tstGridView.DataRowCount == 0)
            {
                return;
            }
            if (!tstGridView.IsDataRow(tstGridView.FocusedRowHandle))
            {
                return;
            }

            int refId = (int)tstGridView.GetFocusedRowCellValue(colTSTIDt);

            Doc.DocXF frm = new Doc.DocXF();
            frm.RefTbl  = "TST";
            frm.RefID   = refId;
            frm.RefInfo = string.Format("Teklif/Talep {0}", refId);
            frm.ShowDialog();
            frm.Dispose();
        }
Пример #11
0
        private void attachmentToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (gridView1.DataRowCount == 0)
            {
                return;
            }
            if (!gridView1.IsDataRow(gridView1.FocusedRowHandle))
            {
                return;
            }

            int refId = (int)gridView1.GetFocusedRowCellValue(colTTTID);

            Doc.DocXF frm = new Doc.DocXF();
            frm.RefTbl  = "TTT";
            frm.RefID   = refId;
            frm.RefInfo = string.Format("Tender {0}", refId);
            frm.ShowDialog();
            frm.Dispose();
        }
Пример #12
0
        private void attachmentsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (vsbl == "F")
            {
                return;
            }

            var view = kkfGridView;

            if (!view.IsDataRow(view.FocusedRowHandle))
            {
                return;
            }

            Doc.DocXF frm = new Doc.DocXF();
            int       pk  = (int)view.GetFocusedRowCellValue("KKFID");

            frm.RefTbl  = "AFB";
            frm.RefID   = pk;
            frm.RefInfo = "Kalite Kontrol Faaliyet: " + pk.ToString();

            frm.ShowDialog();
            frm.Dispose();
        }