Exemplo n.º 1
0
        /// <summary>
        /// 删除ICD10信息
        /// </summary>
        /// <param name="info"></param>
        /// <returns></returns>
        public int DeleteICD(neusoft.HISFC.Object.RADT.ICD10 info)
        {
            string strSql = "";

            if (this.Sql.GetSql("RADT.Diagnose.myIcdManagerImpl.DeletemyIcd", ref strSql) == -1)
            {
                return(-1);
            }

            try
            {
                strSql = string.Format(strSql, info.ID);
            }
            catch (Exception ex)
            {
                this.ErrCode = ex.Message;
                this.Err     = ex.Message;
                return(-1);
            }

            try
            {
                return(this.ExecNoQuery(strSql));
            }
            catch (Exception ex)
            {
                this.ErrCode = ex.Message;
                this.Err     = ex.Message;
                return(-1);
            }
        }
Exemplo n.º 2
0
        public new ICD10 Clone()
        {
            ICD10 obj = base.Clone() as ICD10;

            //obj.DiagnoseType = this.DiagnoseType.Clone();
            obj.SpellCode = this.SpellCode.Clone();
            return(obj);
        }
Exemplo n.º 3
0
        /// <summary>
        /// 更新ICD10信息,如果发现不能更新则插入一条
        /// </summary>
        /// <param name="info"></param>
        /// <returns></returns>
        public int UpdateICD(neusoft.HISFC.Object.RADT.ICD10 info)
        {
            string strSql = "", strSql2;
            int    i = 0;

            if (this.Sql.GetSql("RADT.Diagnose.myIcdManagerImpl.UpdatemyIcd", ref strSql) == -1)
            {
                return(-1);
            }

            try
            {
                strSql = string.Format(strSql, info.ID, info.SICD10, info.SpellCode.Spell_Code,
                                       info.SpellCode.WB_Code, info.Name, info.User01, info.User02,
                                       info.DeadReason, info.DiseaseCode, info.InDays.ToString(),
                                       info.Memo, info.User03, info.OperDate.ToString());
            }
            catch (Exception ex)
            {
                this.ErrCode = ex.Message;
                this.Err     = ex.Message;
                return(-1);
            }

            try
            {
                i = this.ExecNoQuery(strSql);
            }
            catch (Exception ex)
            {
                this.ErrCode = ex.Message;
                this.Err     = ex.Message;
                return(-1);
            }

            if (i == 0)              //插入
            {
                if (this.Sql.GetSql("RADT.Diagnose.myIcdManagerImpl.InsertmyIcd", ref strSql) == -1)
                {
                    return(-1);
                }
                try
                {
                    strSql2 = string.Format(strSql, strSql, info.ID, info.SICD10, info.SpellCode.Spell_Code,
                                            info.SpellCode.WB_Code, info.Name, info.User01, info.User02,
                                            info.DeadReason, info.DiseaseCode, info.InDays.ToString(),
                                            info.Memo, info.User03, info.OperDate.ToString());
                }
                catch (Exception ex)
                {
                    this.Err     = ex.Message;
                    this.ErrCode = ex.Message;
                    return(-1);
                }

                return(this.ExecNoQuery(strSql2));
            }
            else if (i > 0)
            {
                return(0);
            }
            else
            {
                return(-1);
            }
        }