Пример #1
0
        /// <summary>
        /// Update into CustomerSalary
        /// </summary>
        /// <param name="customersalary">CustomerSalary</param>
        public void UpdateCustomerSalary(CustomerSalary customersalary)
        {
            if (customersalary == null)
            {
                return;
            }

            if (this._context.IsAttached(customersalary))
            {
                this._context.CustomerSalaries.Attach(customersalary);
            }

            this._context.SaveChanges();
        }
Пример #2
0
        /// <summary>
        /// Insert into CustomerSalary
        /// </summary>
        /// <param name="customersalary">CustomerSalary</param>
        public void InsertCustomerSalary(CustomerSalary customersalary)
        {
            if (customersalary == null)
            {
                return;
            }

            if (!this._context.IsAttached(customersalary))
            {
                this._context.CustomerSalaries.AddObject(customersalary);
            }

            this._context.SaveChanges();
        }