コード例 #1
0
        public DataTable GetRecentActity(DO_ContentSummary objSummary, DA_ContentSummary.RecentActivities flag)
        {
            DataTable dt = new DataTable();

            SqlConnection conn = new SqlConnection();
            SQLManager    co   = new SQLManager();

            conn = co.GetConnection();

            SqlDataAdapter da = new SqlDataAdapter();

            da.SelectCommand             = new SqlCommand("Scrl_AddEditDelRecentActivities", conn);
            da.SelectCommand.CommandType = CommandType.StoredProcedure;
            da.SelectCommand.Parameters.Add("@FlagNo", SqlDbType.Int).Value       = flag;
            da.SelectCommand.Parameters.Add("@ContentId", SqlDbType.BigInt).Value = objSummary.ContentId;
            da.SelectCommand.Parameters.Add("@addedby", SqlDbType.BigInt).Value   = objSummary.addedby;
            da.Fill(dt);
            co.CloseConnection(conn);
            return(dt);
        }
コード例 #2
0
        public void AddEditDel_RecentActivities(DO_ContentSummary objSummary, DA_ContentSummary.RecentActivities flag)
        {
            SqlConnection conn = new SqlConnection();
            SQLManager    co   = new SQLManager();

            conn = co.GetConnection();

            cmd             = new SqlCommand("Scrl_AddEditDelRecentActivities", conn);
            cmd.CommandType = CommandType.StoredProcedure;
            cmd.Parameters.Add("@FlagNo", SqlDbType.Int).Value = flag;
            cmd.Parameters.Add("@intDocRecentActId", SqlDbType.BigInt).Value   = objSummary.SummaryId;
            cmd.Parameters.Add("@ContentId", SqlDbType.BigInt).Value           = objSummary.ContentId;
            cmd.Parameters.Add("@addedby", SqlDbType.BigInt).Value             = objSummary.addedby;
            cmd.Parameters.Add("@ContentTypeID", SqlDbType.BigInt).Value       = objSummary.ContentTypeID;
            cmd.Parameters.Add("@Descrption", SqlDbType.VarChar, 8000).Value   = objSummary.strDescrption;
            cmd.Parameters.Add("@strIPAddress", SqlDbType.VarChar, 8000).Value = objSummary.strIPAddress;
            cmd.Parameters.Add("@intTagType", SqlDbType.Int).Value             = objSummary.intTagType;
            cmd.Parameters.Add("@intUserTypeId", SqlDbType.Int).Value          = objSummary.intUserTypeId;
            cmd.Parameters.Add("@intPointId", SqlDbType.Int).Value             = objSummary.PointId;
            cmd.ExecuteNonQuery();

            co.CloseConnection(conn);
        }