Exemplo n.º 1
0
        /// <summary>
        /// 删除
        /// </summary>
        public override void EntityDelete()
        {
            CheckFormRule rule   = new CheckFormRule();
            CheckForm     entity = EntityGet();

            rule.RDelete(entity);
        }
Exemplo n.º 2
0
        /// <summary>
        /// 修改
        /// </summary>
        public override void EntityUpdate()
        {
            CheckFormRule rule   = new CheckFormRule();
            CheckForm     entity = EntityGet();

            CheckFormDts[] entitydts = EntityDtsGet();
            rule.RUpdate(entity, entitydts);
        }
Exemplo n.º 3
0
        /// <summary>
        /// 新增
        /// </summary>
        public override int EntityAdd()
        {
            CheckFormRule rule   = new CheckFormRule();
            CheckForm     entity = EntityGet();

            CheckFormDts[] entitydts = EntityDtsGet();
            rule.RAdd(entity, entitydts);
            return(entity.ID);
        }
Exemplo n.º 4
0
        /// <summary>
        /// 绑定Grid
        /// </summary>
        public override void BindGrid()
        {
            //Common.BindVendor(drpVendor, new int[] { (int)EnumVendorType.客户 }, true);
            Common.BindVendor(drpVendorID, new int[] { (int)EnumVendorType.客户 }, true);

            CheckFormRule rule = new CheckFormRule();
            DataTable     dt   = rule.RShow(HTDataConditionStr, ProcessGrid.GetQueryField(gridView1));

            gridView1.GridControl.DataSource = dt;
            gridView1.GridControl.Show();
        }
Exemplo n.º 5
0
 private void txtISN_KeyDown(object sender, KeyEventArgs e)
 {
     try
     {
         if (this.HTDataID != 0 && txtISN.Text.Trim() != string.Empty)
         {
             if (e.KeyCode == Keys.Enter)
             {
                 CheckFormRule rule = new CheckFormRule();
                 if (!chkScanCancel.Checked)
                 {
                     rule.RScan(this.HTDataID, txtISN.Text.Trim(), 1, SysConvert.ToString(drpVendorID.EditValue), SysConvert.ToInt32(drpDataDHID.EditValue), System.DateTime.Now);
                     lbCount.Text = SysConvert.ToInt32((SysConvert.ToInt32(lbCount.Text) - 1)).ToString();
                 }
                 else
                 {
                     rule.RScanCancel(this.HTDataID, txtISN.Text.Trim());
                     lbCount.Text = SysConvert.ToInt32((SysConvert.ToInt32(lbCount.Text) + 1)).ToString();
                 }
                 BindGridDts();
                 lblTime.Text = "扫描时间:" + SysConvert.ToString(gridView1.GetRowCellValue(gridView1.RowCount - 1, "AddTime"));
                 //gridView1.SetRowCellValue(gridView1.FocusedRowHandle+gridView1.RowCount-1, "AddTime", System.DateTime.Now.ToString());
                 ProcessGrid.GridViewFocus(gridView1, new string[1] {
                     "GBCode"
                 }, new string[1] {
                     txtISN.Text.Trim()
                 });
                 txtISN.Text = "";
                 txtISN.Focus();
             }
         }
     }
     catch (Exception E)
     {
         this.ShowMessage(E.Message);
         txtISN.Text = "";
         txtISN.Focus();
     }
 }