Ejemplo n.º 1
0
        /// <summary>
        /// Update into BannedIpAddress
        /// </summary>
        /// <param name="bannedipaddress">BannedIpAddress</param>
        public void UpdateBannedIpAddress(BannedIpAddress bannedipaddress)
        {
            if (bannedipaddress == null)
            {
                return;
            }

            if (this._context.IsAttached(bannedipaddress))
            {
                this._context.BannedIpAddresses.Attach(bannedipaddress);
            }

            this._context.SaveChanges();
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Insert into BannedIpAddress
        /// </summary>
        /// <param name="bannedipaddress">BannedIpAddress</param>
        public void InsertBannedIpAddress(BannedIpAddress bannedipaddress)
        {
            if (bannedipaddress == null)
            {
                return;
            }

            if (!this._context.IsAttached(bannedipaddress))
            {
                this._context.BannedIpAddresses.AddObject(bannedipaddress);
            }

            this._context.SaveChanges();
        }