Example #1
0
        public async Task <List <Client> > DeleteClientAsync(List <Client> listClient)
        {
            List <Client> result = new List <Client>();

            checkServiceCommunication();
            List <Client> gateWayResultList = await _gateWayClient.DeleteClientAsync(listClient);

            if (gateWayResultList.Count == 0)
            {
                foreach (Client client in listClient)
                {
                    int returnResult = _dataSet.DeleteClient(client.ID);
                    if (returnResult > 0)
                    {
                        result.Add(client);
                    }
                }
            }
            return(result);
        }