コード例 #1
0
 public async Task <CustomerGroupResult> SaveAsync(string SessionKey, CustomerGroup[] AddList, CustomerGroup[] DeleteList)
 {
     return(await authorizationProcessor.DoAuthorizeAsync(SessionKey, async token =>
     {
         var item = new MasterImportData <CustomerGroup>();
         item.InsertItems = new List <CustomerGroup>(AddList);
         item.DeleteItems = new List <CustomerGroup>(DeleteList);
         var result = (await customerGroupProcessor.SaveAsync(item, token)).FirstOrDefault();
         return new CustomerGroupResult
         {
             ProcessResult = new ProcessResult {
                 Result = true
             },
             CustomerGroup = result,
         };
     }, logger));
 }
コード例 #2
0
 public async Task <ActionResult <IEnumerable <CustomerGroup> > > Save(MasterImportData <CustomerGroup> importData, CancellationToken token)
 => (await customerGroupProcessor.SaveAsync(importData, token)).ToArray();