public InvokeResult NullifySelected(string strHouseIds)
        {
            InvokeResult result = new InvokeResult {
                Success = true
            };

            try
            {
                List <IBatisNetBatchStatement> statements = new List <IBatisNetBatchStatement>();
                string[] arrHouseIds = strHouseIds.Split("|".ToCharArray(), StringSplitOptions.RemoveEmptyEntries);
                if (arrHouseIds.Length == 0)
                {
                    result.Success   = false;
                    result.ErrorCode = 59996;
                    return(result);
                }
                string statementName = new HouseBaseInfo().GetUpdateMethodName();
                foreach (string strHouseId in arrHouseIds)
                {
                    HouseBaseInfo houseBaseInfo = new HouseBaseInfo {
                        HouseId = strHouseId.ToGuid(), Status = 0
                    };
                    /***********************begin 自定义代码*******************/
                    houseBaseInfo.OperatedBy = NormalSession.UserId.ToGuid();
                    houseBaseInfo.OperatedOn = DateTime.Now;
                    houseBaseInfo.DataSource = GlobalManager.DIKey_00012_ManualEdit;
                    /***********************end 自定义代码*********************/
                    statements.Add(new IBatisNetBatchStatement {
                        StatementName = statementName, ParameterObject = houseBaseInfo.ToStringObjectDictionary(false), Type = SqlExecuteType.UPDATE
                    });
                }
                BuilderFactory.DefaultBulder(GetHttpHeader("ConnectId")).ExecuteNativeSqlNoneQuery(statements);
            }
            catch (Exception ex)
            {
                result.Success      = false;
                result.ErrorMessage = ex.Message;
            }
            return(result);
        }
        public ModelInvokeResult <HouseBaseInfoPK> Nullify(string strHouseId)
        {
            ModelInvokeResult <HouseBaseInfoPK> result = new ModelInvokeResult <HouseBaseInfoPK> {
                Success = true
            };

            try
            {
                List <IBatisNetBatchStatement> statements = new List <IBatisNetBatchStatement>();
                Guid?_HouseId = strHouseId.ToGuid();
                if (_HouseId == null)
                {
                    result.Success   = false;
                    result.ErrorCode = 59996;
                    return(result);
                }
                HouseBaseInfo houseBaseInfo = new HouseBaseInfo {
                    HouseId = _HouseId, Status = 0
                };
                /***********************begin 自定义代码*******************/
                houseBaseInfo.OperatedBy = NormalSession.UserId.ToGuid();
                houseBaseInfo.OperatedOn = DateTime.Now;
                houseBaseInfo.DataSource = GlobalManager.DIKey_00012_ManualEdit;
                /***********************end 自定义代码*********************/
                statements.Add(new IBatisNetBatchStatement {
                    StatementName = houseBaseInfo.GetUpdateMethodName(), ParameterObject = houseBaseInfo.ToStringObjectDictionary(false), Type = SqlExecuteType.UPDATE
                });
                /***********************begin 自定义代码*******************/
                /***********************此处添加自定义代码*****************/
                /***********************end 自定义代码*********************/
                BuilderFactory.DefaultBulder(GetHttpHeader("ConnectId")).ExecuteNativeSqlNoneQuery(statements);
                result.instance = new HouseBaseInfoPK {
                    HouseId = _HouseId
                };
            }
            catch (Exception ex)
            {
                result.Success      = false;
                result.ErrorMessage = ex.Message;
            }
            return(result);
        }
        public ModelInvokeResult <HouseBaseInfoPK> Create(HouseBaseInfo houseBaseInfo)
        {
            ModelInvokeResult <HouseBaseInfoPK> result = new ModelInvokeResult <HouseBaseInfoPK> {
                Success = true
            };

            try
            {
                List <IBatisNetBatchStatement> statements = new List <IBatisNetBatchStatement>();
                if (houseBaseInfo.HouseId == GlobalManager.GuidAsAutoGenerate)
                {
                    houseBaseInfo.HouseId = Guid.NewGuid();
                }
                /***********************begin 自定义代码*******************/
                houseBaseInfo.OperatedBy = NormalSession.UserId.ToGuid();
                houseBaseInfo.OperatedOn = DateTime.Now;
                houseBaseInfo.DataSource = GlobalManager.DIKey_00012_ManualEdit;
                /***********************end 自定义代码*********************/
                statements.Add(new IBatisNetBatchStatement {
                    StatementName = houseBaseInfo.GetCreateMethodName(), ParameterObject = houseBaseInfo.ToStringObjectDictionary(false), Type = SqlExecuteType.INSERT
                });
                /***********************begin 自定义代码*******************/
                /***********************此处添加自定义代码*****************/
                /***********************end 自定义代码*********************/
                BuilderFactory.DefaultBulder(GetHttpHeader("ConnectId")).ExecuteNativeSqlNoneQuery(statements);
                result.instance = new HouseBaseInfoPK {
                    HouseId = houseBaseInfo.HouseId
                };
            }
            catch (Exception ex)
            {
                result.Success      = false;
                result.ErrorMessage = ex.Message;
            }
            return(result);
        }