Example #1
0
        /// <summary>
        /// set customer
        /// </summary>
        /// <param name="customer"></param>
        /// <exception cref="NotInValueRangeException"></exception>
        private void setCustomer(MasterDataIdentity customer)
        {
            if (customer == null)
            {
                throw new NotInValueRangeException(CUSTOMER, "");
            }
            if (!_mdMgmt.ContainsMasterData(customer, MasterDataType.CUSTOMER))
            {
                throw new NotInValueRangeException(CUSTOMER, customer);
            }

            _customer = customer;
        }
Example #2
0
        /// <summary>
        /// set business area
        /// </summary>
        /// <param name="businessArea"></param>
        /// <exception cref="NotInValueRangeException"></exception>
        private void setBusinessArea(MasterDataIdentity businessArea)
        {
            if (businessArea == null)
            {
                throw new NotInValueRangeException(BUSINESS_AREA, "");
            }

            if (!_mdMgmt.ContainsMasterData(businessArea,
                                            MasterDataType.BUSINESS_AREA))
            {
                throw new NotInValueRangeException(BUSINESS_AREA, businessArea);
            }

            _businessArea = businessArea;
        }