示例#1
0
        public virtual async Task <CustomerGroup> UpdateCustomerGroupModel(CustomerGroup customerGroup, CustomerGroupModel model)
        {
            customerGroup = model.ToEntity(customerGroup);
            await _groupService.UpdateCustomerGroup(customerGroup);

            //activity log
            await _customerActivityService.InsertActivity("EditCustomerGroup", customerGroup.Id, _translationService.GetResource("ActivityLog.EditCustomerGroup"), customerGroup.Name);

            return(customerGroup);
        }
示例#2
0
        public virtual async Task <CustomerGroup> InsertCustomerGroupModel(CustomerGroupModel model)
        {
            var customerGroup = model.ToEntity();
            await _groupService.InsertCustomerGroup(customerGroup);

            //activity log
            await _customerActivityService.InsertActivity("AddNewCustomerGroup", customerGroup.Id, _translationService.GetResource("ActivityLog.AddNewCustomerGroup"), customerGroup.Name);

            return(customerGroup);
        }