コード例 #1
0
ファイル: PathBll.cs プロジェクト: wwkkww1983/128_5.6_2010
        /// <summary>
        /// 增加HisPathAlert
        /// </summary>
        /// <param name="hisPathAlert">历史线路报警类对象</param>
        /// <returns>此次操作影响的行数</returns>
        public int InsertHisPathAlert(HisPathAlertModel hisPathAlert)
        {
            if (hisPathAlertDal == null)
            {
                hisPathAlertDal = new HisPathAlertDal();
            }

            int result = hisPathAlertDal.InsertHisPathAlert(hisPathAlert);

            return(result);
        }
コード例 #2
0
        /// <summary>
        /// 增加HisPathAlert
        /// </summary>
        /// <param name="hisPathAlert">历史线路报警类对象</param>
        /// <returns>此次操作影响的行数</returns>
        public int InsertHisPathAlert(HisPathAlertModel hisPathAlert)
        {
            SqlParameter[] para = new SqlParameter[] {
                new SqlParameter("@PathId", SqlDbType.Int),
                new SqlParameter("@StationHeadId", SqlDbType.Int),
                new SqlParameter("@EmpId", SqlDbType.Int),
                new SqlParameter("@AlertBeginTime", SqlDbType.DateTime),
                new SqlParameter("@AlertEndTime", SqlDbType.DateTime),
                new SqlParameter("@AlertTimeValue", SqlDbType.Int)
            };
            para[0].Value = hisPathAlert.PathId;
            para[1].Value = hisPathAlert.StationHeadId;
            para[2].Value = hisPathAlert.EmpId;
            para[3].Value = hisPathAlert.AlertBeginTime;
            para[4].Value = hisPathAlert.AlertEndTime;
            para[5].Value = hisPathAlert.AlertTimeValue;

            int result = help.RunProcedureByInt("insert_His_PathAlert", para, out outStr);

            return(result);
        }