Ejemplo n.º 1
0
        protected override void FillRowViewInfos(XModelBase model, System.Data.DataRow modelRow)
        {
            XVStandEquipmentInfo info = model as XVStandEquipmentInfo;

            info.EquipmentStatus = XHelper.GetString(modelRow["EquipmentStatus"]);
            info.StandName       = XHelper.GetString(modelRow["StandName"]);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 填充实体信息
        /// </summary>
        protected override void FillModelInfo()
        {
            XVStandEquipmentCheckRecordInfo info = this.m_CurrentModel as XVStandEquipmentCheckRecordInfo;

            if (this.m_EditStatus == XEditStatus.AddNew || this.m_EditStatus == XEditStatus.AddContinue)
            {
                info.RID = this.GetNewId();
            }

            info.StandEqupimentId = this.txtStandEqupimentId.ValueMember;
            info.EquipmentName    = this.txtStandEqupimentId.DisplayMember;
            if (this.txtStandEqupimentId.SelectedModel != null)
            {
                XVStandEquipmentInfo equipmentInfo = this.txtStandEqupimentId.SelectedModel as XVStandEquipmentInfo;
                info.StandId   = equipmentInfo.MainId;
                info.StandName = equipmentInfo.StandName;
            }
            info.CheckUserName = this.txtCheckUserName.Text;
            info.CheckDesc     = this.txtCheckDesc.Text;
            info.CheckDate     = XHelper.GetFormatedDate(this.dtCheckDate.Value);
            info.NextCheckDate = XHelper.GetFormatedDate(this.dtNextCheckDate.Value);
            info.Remark        = this.txtRemark.Text;

            base.FillModelInfo();
        }
Ejemplo n.º 3
0
        /// <summary>
        /// 设置修改时的默认值
        /// </summary>
        protected override void SetDefaultValue()
        {
            XVStandEquipmentInfo info = this.m_CurrentModel as XVStandEquipmentInfo;

            if (info.MainId != string.Empty)
            {
                this.txtMainId.Text          = info.StandName;
                this.txtMainId.ValueMember   = info.MainId;
                this.txtMainId.DisplayMember = info.StandName;
            }
            this.cboEquipmentType.Text   = info.EquipmentType;
            this.txtEquipmentCustId.Text = info.EquipmentCustId;
            this.txtEquipmentNo.Text     = info.EquipmentNo;
            this.txtEquipmentName.Text   = info.EquipmentName;
            this.txtFactoryNo.Text       = info.FactoryNo;
            this.txtSpec.Text            = info.Spec;
            this.txtModel.Text           = info.Model;
            this.txtFactoryName.Text     = info.FactoryName;
            this.dtSourceTime.Value      = XHelper.GetDateTime(info.SourceTime);
            this.dtUseTime.Value         = XHelper.GetDateTime(info.UseTime);
            this.txtSourceCustId.Text    = info.SourceCustId;
            this.cboSourceTypeId.Text    = info.SourceTypeId;
            //if (info.EquipmentStatusId != string.Empty)
            //{
            //    this.txtEquipmentStatusId.Text = info.EquipmentStatus;
            //    this.txtEquipmentStatusId.DisplayMember = info.EquipmentStatus;
            //    this.txtEquipmentStatusId.ValueMember = info.EquipmentStatusId;
            //}
            this.cboStatus.Text = info.EquipmentStatusId;

            this.txtSignStatus.Text    = info.SignStatus;
            this.nebQuanlity.Value     = info.Quanlity;
            this.txtLinkMan.Text       = info.LinkMan;
            this.txtTel.Text           = info.Tel;
            this.txtEmail.Text         = info.Email;
            this.txtCheckAccord.Text   = info.CheckAccord;
            this.dtLastCheckDate.Value = XHelper.GetDateTime(info.LastCheckDate);
            this.txtCheckResult.Text   = info.CheckResult;
            this.dtValidDate.Value     = XHelper.GetDateTime(info.ValidDate);
            this.txtCertNo.Text        = info.CertNo;
            this.txtEquipmentDesc.Text = info.EquipmentDesc;
            this.txtRemark.Text        = info.Remark;

            this.chkIsNeedCheck.Checked = info.IsNeedCheck;
            this.dtNextCheckDate.Value  = XHelper.GetDateTime(info.NextCheckDate);
        }
Ejemplo n.º 4
0
        /// <summary>
        /// 填充实体信息
        /// </summary>
        protected override void FillModelInfo()
        {
            XVStandEquipmentInfo info = this.m_CurrentModel as XVStandEquipmentInfo;

            if (this.m_EditStatus == XEditStatus.AddNew || this.m_EditStatus == XEditStatus.AddContinue)
            {
                info.RID = this.GetNewId();
            }

            info.MainId          = this.txtMainId.ValueMember;
            info.StandName       = this.txtMainId.DisplayMember;
            info.EquipmentType   = this.cboEquipmentType.Text;
            info.EquipmentCustId = this.txtEquipmentCustId.Text;
            info.EquipmentNo     = this.txtEquipmentNo.Text;
            info.EquipmentName   = this.txtEquipmentName.Text;
            info.FactoryNo       = this.txtFactoryNo.Text;
            info.Spec            = this.txtSpec.Text;
            info.Model           = this.txtModel.Text;
            info.FactoryName     = this.txtFactoryName.Text;
            info.SourceTime      = XHelper.GetFormatedDate(this.dtSourceTime.Value);
            info.UseTime         = XHelper.GetFormatedDate(this.dtUseTime.Value);
            info.SourceCustId    = this.txtSourceCustId.Text;
            info.SourceTypeId    = this.cboSourceTypeId.Text;
            //info.EquipmentStatusId = this.txtEquipmentStatusId.ValueMember;
            //info.EquipmentStatus = this.txtEquipmentStatusId.DisplayMember;
            info.EquipmentStatusId = this.cboStatus.Text.Trim();
            info.SignStatus        = this.txtSignStatus.Text;
            info.Quanlity          = XHelper.GetInt(this.nebQuanlity.Value);
            info.LinkMan           = this.txtLinkMan.Text;
            info.Tel           = this.txtTel.Text;
            info.Email         = this.txtEmail.Text;
            info.CheckAccord   = this.txtCheckAccord.Text;
            info.LastCheckDate = XHelper.GetFormatedDate(this.dtLastCheckDate.Value);
            info.CheckResult   = this.txtCheckResult.Text;
            info.ValidDate     = XHelper.GetFormatedDate(this.dtValidDate.Value);
            info.CertNo        = this.txtCertNo.Text;
            info.EquipmentDesc = this.txtEquipmentDesc.Text;
            info.Remark        = this.txtRemark.Text;

            info.IsNeedCheck   = this.chkIsNeedCheck.Checked;
            info.NextCheckDate = XHelper.GetFormatedDate(this.dtNextCheckDate.Value);

            base.FillModelInfo();
        }