public static ERPPromotional_scheme Create(Applyon applyon, long disable, string items, string itemgroups, string brands, long mixedconditions, long iscumulative, Applyruleonother applyruleonother, string otheritemcode, string otheritemgroup, string otherbrand, long selling, long buying, Applicablefor applicablefor, string customer, string customergroup, string territory, string salespartner, string campaign, string supplier, string suppliergroup, string validfrom, string validupto, string company, string currency, string pricediscountslabs, string productdiscountslabs)

        {
            ERPPromotional_scheme obj = new ERPPromotional_scheme();

            obj.apply_on               = applyon;
            obj.disable                = disable;
            obj.items                  = items;
            obj.item_groups            = itemgroups;
            obj.brands                 = brands;
            obj.mixed_conditions       = mixedconditions;
            obj.is_cumulative          = iscumulative;
            obj.apply_rule_on_other    = applyruleonother;
            obj.other_item_code        = otheritemcode;
            obj.other_item_group       = otheritemgroup;
            obj.other_brand            = otherbrand;
            obj.selling                = selling;
            obj.buying                 = buying;
            obj.applicable_for         = applicablefor;
            obj.customer               = customer;
            obj.customer_group         = customergroup;
            obj.territory              = territory;
            obj.sales_partner          = salespartner;
            obj.campaign               = campaign;
            obj.supplier               = supplier;
            obj.supplier_group         = suppliergroup;
            obj.valid_from             = validfrom;
            obj.valid_upto             = validupto;
            obj.company                = company;
            obj.currency               = currency;
            obj.price_discount_slabs   = pricediscountslabs;
            obj.product_discount_slabs = productdiscountslabs;
            return(obj);
        }
        public static ERPPricing_rule Create(string title, Applyon applyon, Priceorproductdiscount priceorproductdiscount, string currency)

        {
            ERPPricing_rule obj = new ERPPricing_rule();

            obj.title    = title;
            obj.apply_on = applyon;
            obj.price_or_product_discount = priceorproductdiscount;
            obj.currency = currency;
            return(obj);
        }