/// <summary>
        /// 得到新增EquipmentGage
        /// </summary>
        public string GetEquipmentOffice_AddSQL(EquipmentOffice EquipmentOffice)
        {
            StringBuilder strSql = new StringBuilder();

            strSql.Append("insert into [EquipmentOffice](");
            strSql.Append("EquipmentOfficeGuID,EquipmentGuID,Brand,EquipmentOfficeSpec,DiskSize,CPU,Memory,DisplayCar");
            strSql.Append(")");
            strSql.Append(" values (");
            strSql.Append("'" + EquipmentOffice.EquipmentOfficeGuID + "',");
            strSql.Append("'" + EquipmentOffice.EquipmentGuID + "',");
            strSql.Append("'" + EquipmentOffice.Brand + "',");
            strSql.Append("'" + EquipmentOffice.EquipmentOfficeSpec + "',");
            strSql.Append("'" + EquipmentOffice.DiskSize + "',");
            strSql.Append("'" + EquipmentOffice.CPU + "',");
            strSql.Append("'" + EquipmentOffice.Memory + "',");
            strSql.Append("'" + EquipmentOffice.DisplayCar + "'");
            strSql.Append(")");
            return(strSql.ToString());
        }
        ///<summary>
        /// 保存数据
        /// </summary>
        /// <param name="pObj">信息集实体类</param>
        /// <returns>返回保存成功(true)或失败(false)</returns>
        public void SaveBill(Equipment Equipment, EquipmentDie EquipmentDie, EquipmentFrock EquipmentFrock, EquipmentGage EquipmentGage, EquipmentOffice EquipmentOffice, EquipmentInformation EquipmentInformation)
        {
            CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql);

            try
            {
                pComm.BeginTrans();

                //保存单据主表数据
                //先删除主表数据
                string strDeleteSql = "Delete from Equipment where  EquipmentGuid='" + Equipment.EquipmentGuID + "'";
                pComm.Execute(strDeleteSql);

                //插入Equipment数据
                string strInsertSql = GetEquipment_AddSQL(Equipment);
                pComm.Execute(strInsertSql);


                switch (Equipment.EquipmentType)
                {
                case "1":
                    //删除EquipmentDie表
                    strDeleteSql = "Delete from EquipmentDie where  EquipmentGuid='" + Equipment.EquipmentGuID + "'";
                    pComm.Execute(strDeleteSql);

                    //插入EquipmentDie数据
                    strInsertSql = GetEquipmentDie_AddSQL(EquipmentDie);
                    pComm.Execute(strInsertSql);
                    break;



                case "2":
                    //删除EquipmentGage表
                    strDeleteSql = "Delete from EquipmentGage where  EquipmentGuid='" + Equipment.EquipmentGuID + "'";
                    pComm.Execute(strDeleteSql);



                    //插入EquipmentGage数据
                    strInsertSql = GetEquipmentGage_AddSQL(EquipmentGage);
                    pComm.Execute(strInsertSql);

                    break;


                case "3":
                    //删除EquipmentInformation表
                    strDeleteSql = "Delete from EquipmentInformation where  EquipmentGuid='" + Equipment.EquipmentGuID + "'";
                    pComm.Execute(strDeleteSql);



                    //插入EquipmentInformation数据
                    strInsertSql = GetEquipmentInformation_AddSQL(EquipmentInformation);
                    pComm.Execute(strInsertSql);

                    break;

                case "4":
                    //删除EquipmentOffice表
                    strDeleteSql = "Delete from EquipmentOffice where  EquipmentGuid='" + Equipment.EquipmentGuID + "'";
                    pComm.Execute(strDeleteSql);



                    //插入EquipmentOffice数据
                    strInsertSql = GetEquipmentOffice_AddSQL(EquipmentOffice);
                    pComm.Execute(strInsertSql);

                    break;



                case "5":
                    //删除EquipmentFrock表
                    strDeleteSql = "Delete from EquipmentFrock where  EquipmentGuid='" + Equipment.EquipmentGuID + "'";
                    pComm.Execute(strDeleteSql);



                    //插入EquipmentFrock数据
                    strInsertSql = GetEquipmentFrock_AddSQL(EquipmentFrock);
                    pComm.Execute(strInsertSql);

                    break;
                }

                pComm.CommitTrans();
            }
            catch (Exception e)
            {
                pComm.RollbackTrans();
                pComm.Close();
                throw e;
            }
        }