예제 #1
0
        public void SaveFirstForm(string RNA, string IBAN, string nom_association)
        {
            association Asso = new association()
            {
                RNA             = RNA,
                IBAN            = IBAN,
                nom_association = nom_association
            };

            CprojBdd.associations.Add(Asso);
            CprojBdd.SaveChanges();
        }
예제 #2
0
        public int CreerAssociation(string nom_association, string RNA, string IBAN)
        {
            association Asso = new association()
            {
                nom_association = nom_association,
                RNA             = RNA,
                IBAN            = IBAN
            };

            CprojBdd.associations.Add(Asso);
            CprojBdd.SaveChanges();

            return(Asso.id_association);
        }
예제 #3
0
        public void TestCreateAssociation(string RNA, string IBAN, string nom_association)
        {
            association AssociationTrouve = CprojBdd.associations.FirstOrDefault(association => association.nom_association == nom_association);

            if (AssociationTrouve == null)
            {
                CreerAssociation(RNA, IBAN, nom_association);
            }

            /* if (AssociationTrouve != null)
             * {
             *
             * }*/
        }