コード例 #1
0
        private void updateDataGridView(SortedDictionary <int, BillConfigTable> billConfigList)
        {
            m_dataGridRecordCount = billConfigList.Count;

            SortedDictionary <int, ArrayList> billConfigLArrary = new SortedDictionary <int, ArrayList>();

            for (int i = 0; i < billConfigList.Count; i++)
            {
                BillConfigTable record = new BillConfigTable();
                record = (BillConfigTable)billConfigList[i];

                ArrayList temp = new ArrayList();

                temp.Add(record.pkey);
                temp.Add(record.billpType);
                temp.Add(record.name);
                temp.Add(record.code);

                temp.Add(toChiness(record.isInput));
                temp.Add(toChiness(record.isAutoSave));
                temp.Add(toChiness(record.isUseRules));

                billConfigLArrary.Add(i, temp);
            }

            m_dateGridViewExtend.initDataGridViewData(billConfigLArrary, 3);
        }
コード例 #2
0
        private void buttonSave_Click(object sender, EventArgs e)
        {
            BillConfigTable billConfig = new BillConfigTable();

            int inputChecked       = 0;
            int autoSaveChecked    = 0;
            int useChecked         = 0;
            int useSysdateeChecked = 0;

            if (checkBoxIsInput.Checked)
            {
                inputChecked = 1;
            }
            if (checkBoxIsUse.Checked)
            {
                useChecked = 1;
            }
            if (checkBoxIsAutoSave.Checked)
            {
                autoSaveChecked = 1;
            }
            if (checkBoxUseSysdate.Checked)
            {
                useSysdateeChecked = 1;
            }

            billConfig.pkey = m_billConfig.pkey;

            billConfig.isAutoSave   = autoSaveChecked;
            billConfig.isUseSysdate = useSysdateeChecked;
            billConfig.isUseRules   = useChecked;
            billConfig.isInput      = inputChecked;

            billConfig.code  = this.textBoxCode.Text;
            billConfig.front = this.textBoxFront.Text;
            billConfig.num   = Convert.ToInt32(this.numericUpDownNum.Text.ToString());

            BillConfig.getInctance().update(billConfig.pkey, billConfig);

            this.Close();
        }
コード例 #3
0
 public FormBillConfigEdit(string winText, int pkey)
 {
     InitializeComponent();
     this.Text    = winText;
     m_billConfig = BillConfig.getInctance().getBillConfigInfoFromPeky(pkey);
 }