Пример #1
0
        public void SocieteUpdate
            (int no,
            string raisonSocial,
            string activite,
            string adresse,
            string codePostal,
            string ville,
            string pays,
            string numeroEmployeur,
            string cleEmployeur,
            string matriculFiscal,
            string matriculCle,
            string matriculCodeTva,
            string matriculCategorie,
            string matriculEtablissement,
            string codeBureau,
            string serverName,
            string databaseName,
            string user,
            string password,
            TypeAuthentification type,
            TypeMatriculCnss cnssTypeMatricule
            )
        {
            // checked if exist societe by same raison social
            Societe societe = _societeRepository.Get(no);

            if (societe == null)
            {
                throw new ApplicationException("Societe n'existe pas!");
            }
            societe.RaisonSocial          = raisonSocial;
            societe.CodePostal            = codePostal;
            societe.CodeBureau            = codeBureau;
            societe.Activite              = activite;
            societe.Adresse               = adresse;
            societe.CleEmployeur          = cleEmployeur;
            societe.MatriculCategorie     = matriculCategorie;
            societe.MatriculCodeTva       = matriculCodeTva;
            societe.MatriculEtablissement = matriculEtablissement;
            societe.NumeroEmployeur       = numeroEmployeur;
            societe.MatriculCle           = matriculCle;
            societe.MatriculFiscal        = matriculFiscal;
            societe.Pays              = pays;
            societe.Ville             = ville;
            societe.DatabaseName      = databaseName;
            societe.Password          = password;
            societe.ServerName        = serverName;
            societe.Type              = type;
            societe.User              = user;
            societe.CnssTypeMatricule = cnssTypeMatricule;

            _societeRepository.Update(societe);
            if (Societe.Id == no)
            {
                Societe = _societeRepository.Get(no);
            }
        }
Пример #2
0
 public void Update(int id, Societe entity)
 {
     _repos.Update(id, entity.ToDAL());
 }