Пример #1
0
        private void btnScan()
        {
            if (!isFilter)
            {
                rowIndex = advancedList.ActiveRowIndex;
            }
            else
            {
                rowIndexFilter = advancedList.ActiveRowIndex;
            }

            frmWaresScan newfrmWaresScan = new frmWaresScan();

            newfrmWaresScan.Show();
        }
Пример #2
0
        private void btnEdit()
        {
            if (!isFilter)
            {
                rowIndex = advancedList.ActiveRowIndex;
            }
            else
            {
                rowIndexFilter = advancedList.ActiveRowIndex;
            }

            if (Global.cBL.IsEditWaresManual(Convert.ToInt32(advancedList.DataRows[advancedList.ActiveRowIndex]["code_wares"])))
            {
                frmWaresScan newfrmWaresScan = new frmWaresScan(Convert.ToInt32(advancedList.DataRows[advancedList.ActiveRowIndex]["code_wares"]));
                newfrmWaresScan.Show();
            }
            else
            {
                clsDialogBox.InformationBoxShow("Ручне редагування к-ті товару заборонено!");
            }
        }
Пример #3
0
        private void btnWaresScan()
        {
            Global.cTerminal.StopScan();
            if (!isFilter)
            {
                rowIndex = advancedList.ActiveRowIndex;
            }
            else
            {
                rowIndexFilter = advancedList.ActiveRowIndex;
            }

            if (advancedList.ActiveRowIndex >= 0)
            {
                if (Convert.ToInt32(advancedList.DataRows[advancedList.ActiveRowIndex]["status"]) == 1)
                {
                    clsDialogBox.InformationBoxShow("Документ відмічений для відправлення на сервер і не може бути змінений!");
                    return;
                }
                try
                {
                    Global.cBL.LoadWaresDocs(Global.cBL.CurTypeDoc, Convert.ToInt32(advancedList.DataRows[advancedList.ActiveRowIndex]["number_doc"]));
                    frmWaresScan newfrmWaresScan = new frmWaresScan();
                    newfrmWaresScan.Show();
                }

                catch (Exception ex)
                {
                    clsException.EnableException(ex);
                }
            }
            else
            {
                clsDialogBox.InformationBoxShow("Відсутній документ для перегляду!");
            }
        }