Exemple #1
0
 private void SacuvajArtikal(Artikal artikal)
 {
     if (artikal != null && artikal.Validator.IsValid(artikal))
     {
         var a = Mapper.Map(artikal);
         using (var svc = new BackendServiceClient())
         {
             svc.SacuvajArtikalCompleted += (s, e) => OnSendMessage(new MessageSaved());
             svc.SacuvajArtikalAsync(a);
         }
     }
 }
 private void Sacuvaj()
 {
     if (m_Artikal.Validator.IsValid(m_Artikal))
     {
         var a = Mapper.Map(m_Artikal);
         using (var svc = new BackendServiceClient())
         {
             svc.SacuvajArtikalCompleted += (s, e) =>
             {
                 m_Artikal.Id = e.Result;
                 Close();
             };
             svc.SacuvajArtikalAsync(a);
         }
     }
 }