Переглянути джерело

Recupération des données Educ'facile OK

olivier.massot 7 роки тому
батько
коміт
00e42193af

+ 6 - 0
CD67.FicheCollege.Entity/CD67.FicheCollege.Entity.csproj

@@ -120,6 +120,9 @@
       <DesignTime>True</DesignTime>
       <DependentUpon>EducfModel.edmx</DependentUpon>
     </Compile>
+    <Compile Include="eleveannee.cs">
+      <DependentUpon>EducfModel.tt</DependentUpon>
+    </Compile>
     <Compile Include="EntityModel.Context.cs">
       <AutoGen>True</AutoGen>
       <DesignTime>True</DesignTime>
@@ -141,6 +144,9 @@
     <Compile Include="etablissement.cs">
       <DependentUpon>EducfModel.tt</DependentUpon>
     </Compile>
+    <Compile Include="etablissementannee.cs">
+      <DependentUpon>EducfModel.tt</DependentUpon>
+    </Compile>
     <Compile Include="etaboptionsannee.cs">
       <DependentUpon>EducfModel.tt</DependentUpon>
     </Compile>

+ 2 - 0
CD67.FicheCollege.Entity/EducfModel.Context.cs

@@ -34,5 +34,7 @@ namespace CD67.FicheCollege.Entity
         public virtual DbSet<mef> mefs { get; set; }
         public virtual DbSet<etaboptionsannee> etaboptionsannees { get; set; }
         public virtual DbSet<matiereoption> matiereoptions { get; set; }
+        public virtual DbSet<eleveannee> eleveannees { get; set; }
+        public virtual DbSet<etablissementannee> etablissementannees { get; set; }
     }
 }

+ 327 - 0
CD67.FicheCollege.Entity/EducfModel.edmx

@@ -27,6 +27,42 @@
           <Property Name="web" Type="varchar" MaxLength="100" />
           <Property Name="idcanton" Type="int4" />
         </EntityType>
+        <EntityType Name="eleveannee">
+          <Key>
+            <PropertyRef Name="code" />
+            <PropertyRef Name="annee" />
+          </Key>
+          <Property Name="code" Type="varchar" MaxLength="50" Nullable="false" />
+          <Property Name="idetablissement" Type="float8" />
+          <Property Name="annee" Type="float8" Nullable="false" />
+          <Property Name="idniveau" Type="float8" />
+          <Property Name="inscritrs" Type="float8" />
+          <Property Name="inscritts" Type="float8" />
+          <Property Name="interne" Type="float8" />
+          <Property Name="ititransport" Type="float8" />
+          <Property Name="arret8h" Type="float8" />
+          <Property Name="arret12h" Type="float8" />
+          <Property Name="arret14h" Type="float8" />
+          <Property Name="arret17h" Type="float8" />
+          <Property Name="classe" Type="varchar" MaxLength="30" />
+          <Property Name="idfiliere" Type="float8" />
+          <Property Name="optboursier" Type="numeric" Precision="1" Scale="0" />
+          <Property Name="typebourse" Type="numeric" Precision="1" Scale="0" />
+          <Property Name="optderogation" Type="numeric" Precision="1" Scale="0" />
+          <Property Name="optcl" Type="numeric" Precision="1" Scale="0" />
+          <Property Name="idetabprec" Type="numeric" Precision="10" Scale="0" />
+          <Property Name="idniveauprec" Type="numeric" Precision="10" Scale="0" />
+          <Property Name="idoption1" Type="numeric" Precision="10" Scale="0" />
+          <Property Name="idoption2" Type="numeric" Precision="10" Scale="0" />
+          <Property Name="idoption3" Type="numeric" Precision="10" Scale="0" />
+          <Property Name="idoption4" Type="numeric" Precision="10" Scale="0" />
+          <Property Name="nonredoublant" Type="numeric" Precision="1" Scale="0" />
+          <Property Name="idclasse" Type="numeric" Precision="10" Scale="0" />
+          <Property Name="idsousgroupe" Type="numeric" Precision="10" Scale="0" />
+          <Property Name="qf" Type="numeric" Precision="10" Scale="0" />
+          <Property Name="idoption5" Type="numeric" Precision="10" Scale="0" />
+          <Property Name="idmef" Type="numeric" Precision="5" Scale="0" />
+        </EntityType>
         <EntityType Name="etabeffectifannee">
           <Key>
             <PropertyRef Name="id" />
@@ -85,6 +121,59 @@
           <Property Name="libellecarte1" Type="varchar" MaxLength="200" />
           <Property Name="libellecarte2" Type="varchar" MaxLength="200" />
         </EntityType>
+        <EntityType Name="etablissementannee">
+          <Key>
+            <PropertyRef Name="idetablissement" />
+            <PropertyRef Name="annee" />
+          </Key>
+          <Property Name="idetablissement" Type="int4" Nullable="false" />
+          <Property Name="annee" Type="float8" Nullable="false" />
+          <Property Name="nbeleves" Type="float8" />
+          <Property Name="capaciteinternes" Type="float8" />
+          <Property Name="capacitedemipension" Type="float8" />
+          <Property Name="capaciteeleves" Type="float8" />
+          <Property Name="effectifmaximal" Type="float8" />
+          <Property Name="classesprevues" Type="float8" />
+          <Property Name="elevessecteur" Type="float8" />
+          <Property Name="eleveshorssecteur" Type="float8" />
+          <Property Name="niveauremplissage" Type="float8" />
+          <Property Name="demipensionnaires" Type="float8" />
+          <Property Name="responsable" Type="varchar" MaxLength="250" />
+          <Property Name="gestionnaire" Type="varchar" MaxLength="250" />
+          <Property Name="nbenseignants" Type="float8" />
+          <Property Name="nbadministratifs" Type="float8" />
+          <Property Name="nbautrepersonnel" Type="float8" />
+          <Property Name="optzep" Type="numeric" Precision="1" Scale="0" />
+          <Property Name="optrep" Type="numeric" Precision="1" Scale="0" />
+          <Property Name="capacitearchi" Type="int4" />
+          <Property Name="optrar" Type="numeric" Precision="1" Scale="0" />
+          <Property Name="ien" Type="varchar" MaxLength="200" />
+          <Property Name="capacitesegpa" Type="int4" />
+          <Property Name="internes" Type="int4" />
+          <Property Name="nbsegpa" Type="int4" />
+          <Property Name="rpi" Type="varchar" MaxLength="50" />
+          <Property Name="optrpi" Type="numeric" Precision="1" Scale="0" />
+          <Property Name="nbhandi" Type="int4" />
+          <Property Name="nbtechno" Type="int4" />
+          <Property Name="nbupi" Type="int4" />
+          <Property Name="nbcham" Type="int4" />
+          <Property Name="nbsport" Type="int4" />
+          <Property Name="capacitedivisions" Type="int4" />
+          <Property Name="nbdivisions" Type="int4" />
+          <Property Name="nbgene" Type="int4" />
+          <Property Name="nbulis" Type="int4" />
+          <Property Name="nbdima" Type="int4" />
+          <Property Name="principaladjoint" Type="varchar" MaxLength="100" />
+          <Property Name="mailgestionnaire" Type="varchar" MaxLength="100" />
+          <Property Name="mailresponsable" Type="varchar" MaxLength="100" />
+          <Property Name="nbupe2a" Type="int4" />
+          <Property Name="dotation" Type="numeric" Precision="12" Scale="0" />
+          <Property Name="nbcpsfavorisea" Type="int4" />
+          <Property Name="nbcpsfavoriseb" Type="int4" />
+          <Property Name="nbcpsdefavorise" Type="int4" />
+          <Property Name="nbcpsmoyenne" Type="int4" />
+          <Property Name="optrpiconcentre" Type="varchar" MaxLength="1" />
+        </EntityType>
         <EntityType Name="etaboptionsannee">
           <Key>
             <PropertyRef Name="id" />
@@ -145,6 +234,20 @@
           <Property Name="typerue" Type="varchar" MaxLength="100" />
           <Property Name="rivoli" Type="varchar" MaxLength="10" />
         </EntityType>
+        <Association Name="FK_EtabAnnee">
+          <End Role="etablissement" Type="Self.etablissement" Multiplicity="1">
+            <OnDelete Action="Cascade" />
+          </End>
+          <End Role="etablissementannee" Type="Self.etablissementannee" Multiplicity="*" />
+          <ReferentialConstraint>
+            <Principal Role="etablissement">
+              <PropertyRef Name="id" />
+            </Principal>
+            <Dependent Role="etablissementannee">
+              <PropertyRef Name="idetablissement" />
+            </Dependent>
+          </ReferentialConstraint>
+        </Association>
         <Association Name="FK_EtabEffectifAnnee">
           <End Role="etablissement" Type="Self.etablissement" Multiplicity="0..1">
             <OnDelete Action="Cascade" />
@@ -189,14 +292,20 @@
         </Association>
         <EntityContainer Name="educfModelStoreContainer">
           <EntitySet Name="commune" EntityType="Self.commune" Schema="educf" store:Type="Tables" />
+          <EntitySet Name="eleveannee" EntityType="Self.eleveannee" Schema="educf" store:Type="Tables" />
           <EntitySet Name="etabeffectifannee" EntityType="Self.etabeffectifannee" Schema="educf" store:Type="Tables" />
           <EntitySet Name="etablissement" EntityType="Self.etablissement" Schema="educf" store:Type="Tables" />
+          <EntitySet Name="etablissementannee" EntityType="Self.etablissementannee" Schema="educf" store:Type="Tables" />
           <EntitySet Name="etaboptionsannee" EntityType="Self.etaboptionsannee" Schema="educf" store:Type="Tables" />
           <EntitySet Name="filiere" EntityType="Self.filiere" Schema="educf" store:Type="Tables" />
           <EntitySet Name="matiereoption" EntityType="Self.matiereoption" Schema="educf" store:Type="Tables" />
           <EntitySet Name="mef" EntityType="Self.mef" Schema="educf" store:Type="Tables" />
           <EntitySet Name="niveau" EntityType="Self.niveau" Schema="educf" store:Type="Tables" />
           <EntitySet Name="rues" EntityType="Self.rues" Schema="educf" store:Type="Tables" />
+          <AssociationSet Name="FK_EtabAnnee" Association="Self.FK_EtabAnnee">
+            <End Role="etablissement" EntitySet="etablissement" />
+            <End Role="etablissementannee" EntitySet="etablissementannee" />
+          </AssociationSet>
           <AssociationSet Name="FK_EtabEffectifAnnee" Association="Self.FK_EtabEffectifAnnee">
             <End Role="etablissement" EntitySet="etablissement" />
             <End Role="etabeffectifannee" EntitySet="etabeffectifannee" />
@@ -299,6 +408,8 @@
           <NavigationProperty Name="etabeffectifannees" Relationship="Self.FK_EtabEffectifAnnee" FromRole="etablissement" ToRole="etabeffectifannee" />
           <NavigationProperty Name="rue" Relationship="educfModel.etablissementrue" FromRole="etablissement" ToRole="rue" />
           <NavigationProperty Name="etaboptionsannees" Relationship="educfModel.FK_EtabOptionsAnnee" FromRole="etablissement" ToRole="etaboptionsannee" />
+          <NavigationProperty Name="etablissementannees" Relationship="educfModel.FK_EtabAnnee" FromRole="etablissement" ToRole="etablissementannee" />
+          <NavigationProperty Name="eleveannees" Relationship="educfModel.etablissementeleveannee" FromRole="etablissement" ToRole="eleveannee" />
         </EntityType>
         <EntityType Name="niveau">
           <Key>
@@ -391,6 +502,16 @@
             <End Role="etaboptionsannee" EntitySet="etaboptionsannees" />
             <End Role="matiereoption" EntitySet="matiereoptions" />
           </AssociationSet>
+          <EntitySet Name="eleveannees" EntityType="educfModel.eleveannee" />
+          <EntitySet Name="etablissementannees" EntityType="educfModel.etablissementannee" />
+          <AssociationSet Name="FK_EtabAnnee" Association="educfModel.FK_EtabAnnee">
+            <End Role="etablissement" EntitySet="etablissements" />
+            <End Role="etablissementannee" EntitySet="etablissementannees" />
+          </AssociationSet>
+          <AssociationSet Name="etablissementeleveannee" Association="educfModel.etablissementeleveannee">
+            <End Role="etablissement" EntitySet="etablissements" />
+            <End Role="eleveannee" EntitySet="eleveannees" />
+          </AssociationSet>
         </EntityContainer>
         <Association Name="etablissementrue">
           <End Type="educfModel.etablissement" Role="etablissement" Multiplicity="*" />
@@ -497,6 +618,123 @@
             </Dependent>
           </ReferentialConstraint>
         </Association>
+        <EntityType Name="eleveannee">
+          <Key>
+            <PropertyRef Name="code" />
+            <PropertyRef Name="annee" />
+          </Key>
+          <Property Name="code" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="true" />
+          <Property Name="idetablissement" Type="Int32" />
+          <Property Name="annee" Type="Double" Nullable="false" />
+          <Property Name="idniveau" Type="Double" />
+          <Property Name="inscritrs" Type="Double" />
+          <Property Name="inscritts" Type="Double" />
+          <Property Name="interne" Type="Double" />
+          <Property Name="ititransport" Type="Double" />
+          <Property Name="arret8h" Type="Double" />
+          <Property Name="arret12h" Type="Double" />
+          <Property Name="arret14h" Type="Double" />
+          <Property Name="arret17h" Type="Double" />
+          <Property Name="classe" Type="String" MaxLength="30" FixedLength="false" Unicode="true" />
+          <Property Name="idfiliere" Type="Double" />
+          <Property Name="optboursier" Type="Decimal" Precision="1" Scale="0" />
+          <Property Name="typebourse" Type="Decimal" Precision="1" Scale="0" />
+          <Property Name="optderogation" Type="Decimal" Precision="1" Scale="0" />
+          <Property Name="optcl" Type="Decimal" Precision="1" Scale="0" />
+          <Property Name="idetabprec" Type="Decimal" Precision="10" Scale="0" />
+          <Property Name="idniveauprec" Type="Decimal" Precision="10" Scale="0" />
+          <Property Name="idoption1" Type="Decimal" Precision="10" Scale="0" />
+          <Property Name="idoption2" Type="Decimal" Precision="10" Scale="0" />
+          <Property Name="idoption3" Type="Decimal" Precision="10" Scale="0" />
+          <Property Name="idoption4" Type="Decimal" Precision="10" Scale="0" />
+          <Property Name="nonredoublant" Type="Decimal" Precision="1" Scale="0" />
+          <Property Name="idclasse" Type="Decimal" Precision="10" Scale="0" />
+          <Property Name="idsousgroupe" Type="Decimal" Precision="10" Scale="0" />
+          <Property Name="qf" Type="Decimal" Precision="10" Scale="0" />
+          <Property Name="idoption5" Type="Decimal" Precision="10" Scale="0" />
+          <Property Name="idmef" Type="Decimal" Precision="5" Scale="0" />
+          <NavigationProperty Name="etablissement" Relationship="educfModel.etablissementeleveannee" FromRole="eleveannee" ToRole="etablissement" />
+        </EntityType>
+        <EntityType Name="etablissementannee">
+          <Key>
+            <PropertyRef Name="idetablissement" />
+            <PropertyRef Name="annee" />
+          </Key>
+          <Property Name="idetablissement" Type="Int32" Nullable="false" />
+          <Property Name="annee" Type="Double" Nullable="false" />
+          <Property Name="nbeleves" Type="Double" />
+          <Property Name="capaciteinternes" Type="Double" />
+          <Property Name="capacitedemipension" Type="Double" />
+          <Property Name="capaciteeleves" Type="Double" />
+          <Property Name="effectifmaximal" Type="Double" />
+          <Property Name="classesprevues" Type="Double" />
+          <Property Name="elevessecteur" Type="Double" />
+          <Property Name="eleveshorssecteur" Type="Double" />
+          <Property Name="niveauremplissage" Type="Double" />
+          <Property Name="demipensionnaires" Type="Double" />
+          <Property Name="responsable" Type="String" MaxLength="250" FixedLength="false" Unicode="true" />
+          <Property Name="gestionnaire" Type="String" MaxLength="250" FixedLength="false" Unicode="true" />
+          <Property Name="nbenseignants" Type="Double" />
+          <Property Name="nbadministratifs" Type="Double" />
+          <Property Name="nbautrepersonnel" Type="Double" />
+          <Property Name="optzep" Type="Decimal" Precision="1" Scale="0" />
+          <Property Name="optrep" Type="Decimal" Precision="1" Scale="0" />
+          <Property Name="capacitearchi" Type="Int32" />
+          <Property Name="optrar" Type="Decimal" Precision="1" Scale="0" />
+          <Property Name="ien" Type="String" MaxLength="200" FixedLength="false" Unicode="true" />
+          <Property Name="capacitesegpa" Type="Int32" />
+          <Property Name="internes" Type="Int32" />
+          <Property Name="nbsegpa" Type="Int32" />
+          <Property Name="rpi" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
+          <Property Name="optrpi" Type="Decimal" Precision="1" Scale="0" />
+          <Property Name="nbhandi" Type="Int32" />
+          <Property Name="nbtechno" Type="Int32" />
+          <Property Name="nbupi" Type="Int32" />
+          <Property Name="nbcham" Type="Int32" />
+          <Property Name="nbsport" Type="Int32" />
+          <Property Name="capacitedivisions" Type="Int32" />
+          <Property Name="nbdivisions" Type="Int32" />
+          <Property Name="nbgene" Type="Int32" />
+          <Property Name="nbulis" Type="Int32" />
+          <Property Name="nbdima" Type="Int32" />
+          <Property Name="principaladjoint" Type="String" MaxLength="100" FixedLength="false" Unicode="true" />
+          <Property Name="mailgestionnaire" Type="String" MaxLength="100" FixedLength="false" Unicode="true" />
+          <Property Name="mailresponsable" Type="String" MaxLength="100" FixedLength="false" Unicode="true" />
+          <Property Name="nbupe2a" Type="Int32" />
+          <Property Name="dotation" Type="Decimal" Precision="12" Scale="0" />
+          <Property Name="nbcpsfavorisea" Type="Int32" />
+          <Property Name="nbcpsfavoriseb" Type="Int32" />
+          <Property Name="nbcpsdefavorise" Type="Int32" />
+          <Property Name="nbcpsmoyenne" Type="Int32" />
+          <Property Name="optrpiconcentre" Type="String" MaxLength="1" FixedLength="false" Unicode="true" />
+          <NavigationProperty Name="etablissement" Relationship="educfModel.FK_EtabAnnee" FromRole="etablissementannee" ToRole="etablissement" />
+        </EntityType>
+        <Association Name="FK_EtabAnnee">
+          <End Type="educfModel.etablissement" Role="etablissement" Multiplicity="1">
+            <OnDelete Action="Cascade" />
+          </End>
+          <End Type="educfModel.etablissementannee" Role="etablissementannee" Multiplicity="*" />
+          <ReferentialConstraint>
+            <Principal Role="etablissement">
+              <PropertyRef Name="id" />
+            </Principal>
+            <Dependent Role="etablissementannee">
+              <PropertyRef Name="idetablissement" />
+            </Dependent>
+          </ReferentialConstraint>
+        </Association>
+        <Association Name="etablissementeleveannee">
+          <End Type="educfModel.etablissement" Role="etablissement" Multiplicity="0..1" />
+          <End Type="educfModel.eleveannee" Role="eleveannee" Multiplicity="*" />
+          <ReferentialConstraint>
+            <Principal Role="etablissement">
+              <PropertyRef Name="id" />
+            </Principal>
+            <Dependent Role="eleveannee">
+              <PropertyRef Name="idetablissement" />
+            </Dependent>
+          </ReferentialConstraint>
+        </Association>
       </Schema>
     </edmx:ConceptualModels>
     <!-- C-S mapping content -->
@@ -652,6 +890,95 @@
               </MappingFragment>
             </EntityTypeMapping>
           </EntitySetMapping>
+          <EntitySetMapping Name="eleveannees">
+            <EntityTypeMapping TypeName="educfModel.eleveannee">
+              <MappingFragment StoreEntitySet="eleveannee">
+                <ScalarProperty Name="idmef" ColumnName="idmef" />
+                <ScalarProperty Name="idoption5" ColumnName="idoption5" />
+                <ScalarProperty Name="qf" ColumnName="qf" />
+                <ScalarProperty Name="idsousgroupe" ColumnName="idsousgroupe" />
+                <ScalarProperty Name="idclasse" ColumnName="idclasse" />
+                <ScalarProperty Name="nonredoublant" ColumnName="nonredoublant" />
+                <ScalarProperty Name="idoption4" ColumnName="idoption4" />
+                <ScalarProperty Name="idoption3" ColumnName="idoption3" />
+                <ScalarProperty Name="idoption2" ColumnName="idoption2" />
+                <ScalarProperty Name="idoption1" ColumnName="idoption1" />
+                <ScalarProperty Name="idniveauprec" ColumnName="idniveauprec" />
+                <ScalarProperty Name="idetabprec" ColumnName="idetabprec" />
+                <ScalarProperty Name="optcl" ColumnName="optcl" />
+                <ScalarProperty Name="optderogation" ColumnName="optderogation" />
+                <ScalarProperty Name="typebourse" ColumnName="typebourse" />
+                <ScalarProperty Name="optboursier" ColumnName="optboursier" />
+                <ScalarProperty Name="idfiliere" ColumnName="idfiliere" />
+                <ScalarProperty Name="classe" ColumnName="classe" />
+                <ScalarProperty Name="arret17h" ColumnName="arret17h" />
+                <ScalarProperty Name="arret14h" ColumnName="arret14h" />
+                <ScalarProperty Name="arret12h" ColumnName="arret12h" />
+                <ScalarProperty Name="arret8h" ColumnName="arret8h" />
+                <ScalarProperty Name="ititransport" ColumnName="ititransport" />
+                <ScalarProperty Name="interne" ColumnName="interne" />
+                <ScalarProperty Name="inscritts" ColumnName="inscritts" />
+                <ScalarProperty Name="inscritrs" ColumnName="inscritrs" />
+                <ScalarProperty Name="idniveau" ColumnName="idniveau" />
+                <ScalarProperty Name="annee" ColumnName="annee" />
+                <ScalarProperty Name="idetablissement" ColumnName="idetablissement" />
+                <ScalarProperty Name="code" ColumnName="code" />
+              </MappingFragment>
+            </EntityTypeMapping>
+          </EntitySetMapping>
+          <EntitySetMapping Name="etablissementannees">
+            <EntityTypeMapping TypeName="educfModel.etablissementannee">
+              <MappingFragment StoreEntitySet="etablissementannee">
+                <ScalarProperty Name="optrpiconcentre" ColumnName="optrpiconcentre" />
+                <ScalarProperty Name="nbcpsmoyenne" ColumnName="nbcpsmoyenne" />
+                <ScalarProperty Name="nbcpsdefavorise" ColumnName="nbcpsdefavorise" />
+                <ScalarProperty Name="nbcpsfavoriseb" ColumnName="nbcpsfavoriseb" />
+                <ScalarProperty Name="nbcpsfavorisea" ColumnName="nbcpsfavorisea" />
+                <ScalarProperty Name="dotation" ColumnName="dotation" />
+                <ScalarProperty Name="nbupe2a" ColumnName="nbupe2a" />
+                <ScalarProperty Name="mailresponsable" ColumnName="mailresponsable" />
+                <ScalarProperty Name="mailgestionnaire" ColumnName="mailgestionnaire" />
+                <ScalarProperty Name="principaladjoint" ColumnName="principaladjoint" />
+                <ScalarProperty Name="nbdima" ColumnName="nbdima" />
+                <ScalarProperty Name="nbulis" ColumnName="nbulis" />
+                <ScalarProperty Name="nbgene" ColumnName="nbgene" />
+                <ScalarProperty Name="nbdivisions" ColumnName="nbdivisions" />
+                <ScalarProperty Name="capacitedivisions" ColumnName="capacitedivisions" />
+                <ScalarProperty Name="nbsport" ColumnName="nbsport" />
+                <ScalarProperty Name="nbcham" ColumnName="nbcham" />
+                <ScalarProperty Name="nbupi" ColumnName="nbupi" />
+                <ScalarProperty Name="nbtechno" ColumnName="nbtechno" />
+                <ScalarProperty Name="nbhandi" ColumnName="nbhandi" />
+                <ScalarProperty Name="optrpi" ColumnName="optrpi" />
+                <ScalarProperty Name="rpi" ColumnName="rpi" />
+                <ScalarProperty Name="nbsegpa" ColumnName="nbsegpa" />
+                <ScalarProperty Name="internes" ColumnName="internes" />
+                <ScalarProperty Name="capacitesegpa" ColumnName="capacitesegpa" />
+                <ScalarProperty Name="ien" ColumnName="ien" />
+                <ScalarProperty Name="optrar" ColumnName="optrar" />
+                <ScalarProperty Name="capacitearchi" ColumnName="capacitearchi" />
+                <ScalarProperty Name="optrep" ColumnName="optrep" />
+                <ScalarProperty Name="optzep" ColumnName="optzep" />
+                <ScalarProperty Name="nbautrepersonnel" ColumnName="nbautrepersonnel" />
+                <ScalarProperty Name="nbadministratifs" ColumnName="nbadministratifs" />
+                <ScalarProperty Name="nbenseignants" ColumnName="nbenseignants" />
+                <ScalarProperty Name="gestionnaire" ColumnName="gestionnaire" />
+                <ScalarProperty Name="responsable" ColumnName="responsable" />
+                <ScalarProperty Name="demipensionnaires" ColumnName="demipensionnaires" />
+                <ScalarProperty Name="niveauremplissage" ColumnName="niveauremplissage" />
+                <ScalarProperty Name="eleveshorssecteur" ColumnName="eleveshorssecteur" />
+                <ScalarProperty Name="elevessecteur" ColumnName="elevessecteur" />
+                <ScalarProperty Name="classesprevues" ColumnName="classesprevues" />
+                <ScalarProperty Name="effectifmaximal" ColumnName="effectifmaximal" />
+                <ScalarProperty Name="capaciteeleves" ColumnName="capaciteeleves" />
+                <ScalarProperty Name="capacitedemipension" ColumnName="capacitedemipension" />
+                <ScalarProperty Name="capaciteinternes" ColumnName="capaciteinternes" />
+                <ScalarProperty Name="nbeleves" ColumnName="nbeleves" />
+                <ScalarProperty Name="annee" ColumnName="annee" />
+                <ScalarProperty Name="idetablissement" ColumnName="idetablissement" />
+              </MappingFragment>
+            </EntityTypeMapping>
+          </EntitySetMapping>
         </EntityContainerMapping>
       </Mapping>
     </edmx:Mappings>

+ 4 - 0
CD67.FicheCollege.Entity/EducfModel.edmx.diagram

@@ -21,6 +21,10 @@
         <EntityTypeShape EntityType="educfModel.matiereoption" Width="1.5" PointX="0.75" PointY="8.5" />
         <AssociationConnector Association="educfModel.FK_EtabOptionsAnnee" />
         <AssociationConnector Association="educfModel.matiereoptionetaboptionsannee" />
+        <EntityTypeShape EntityType="educfModel.eleveannee" Width="1.5" PointX="7.375" PointY="11.625" />
+        <EntityTypeShape EntityType="educfModel.etablissementannee" Width="2" PointX="3.625" PointY="11.375" />
+        <AssociationConnector Association="educfModel.FK_EtabAnnee" />
+        <AssociationConnector Association="educfModel.etablissementeleveannee" />
       </Diagram>
     </edmx:Diagrams>
   </edmx:Designer>

+ 50 - 0
CD67.FicheCollege.Entity/eleveannee.cs

@@ -0,0 +1,50 @@
+//------------------------------------------------------------------------------
+// <auto-generated>
+//     Ce code a été généré à partir d'un modèle.
+//
+//     Des modifications manuelles apportées à ce fichier peuvent conduire à un comportement inattendu de votre application.
+//     Les modifications manuelles apportées à ce fichier sont remplacées si le code est régénéré.
+// </auto-generated>
+//------------------------------------------------------------------------------
+
+namespace CD67.FicheCollege.Entity
+{
+    using System;
+    using System.Collections.Generic;
+    
+    public partial class eleveannee
+    {
+        public string code { get; set; }
+        public Nullable<int> idetablissement { get; set; }
+        public double annee { get; set; }
+        public Nullable<double> idniveau { get; set; }
+        public Nullable<double> inscritrs { get; set; }
+        public Nullable<double> inscritts { get; set; }
+        public Nullable<double> interne { get; set; }
+        public Nullable<double> ititransport { get; set; }
+        public Nullable<double> arret8h { get; set; }
+        public Nullable<double> arret12h { get; set; }
+        public Nullable<double> arret14h { get; set; }
+        public Nullable<double> arret17h { get; set; }
+        public string classe { get; set; }
+        public Nullable<double> idfiliere { get; set; }
+        public Nullable<decimal> optboursier { get; set; }
+        public Nullable<decimal> typebourse { get; set; }
+        public Nullable<decimal> optderogation { get; set; }
+        public Nullable<decimal> optcl { get; set; }
+        public Nullable<decimal> idetabprec { get; set; }
+        public Nullable<decimal> idniveauprec { get; set; }
+        public Nullable<decimal> idoption1 { get; set; }
+        public Nullable<decimal> idoption2 { get; set; }
+        public Nullable<decimal> idoption3 { get; set; }
+        public Nullable<decimal> idoption4 { get; set; }
+        public Nullable<decimal> nonredoublant { get; set; }
+        public Nullable<decimal> idclasse { get; set; }
+        public Nullable<decimal> idsousgroupe { get; set; }
+        public Nullable<decimal> qf { get; set; }
+        public Nullable<decimal> idoption5 { get; set; }
+        public Nullable<decimal> idmef { get; set; }
+    
+        public virtual etablissement etablissement { get; set; }
+    }
+}

+ 6 - 0
CD67.FicheCollege.Entity/etablissement.cs

@@ -19,6 +19,8 @@ namespace CD67.FicheCollege.Entity
         {
             this.etabeffectifannees = new HashSet<etabeffectifannee>();
             this.etaboptionsannees = new HashSet<etaboptionsannee>();
+            this.etablissementannees = new HashSet<etablissementannee>();
+            this.eleveannees = new HashSet<eleveannee>();
         }
     
         public int id { get; set; }
@@ -64,5 +66,9 @@ namespace CD67.FicheCollege.Entity
         public virtual rue rue { get; set; }
         [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
         public virtual ICollection<etaboptionsannee> etaboptionsannees { get; set; }
+        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+        public virtual ICollection<etablissementannee> etablissementannees { get; set; }
+        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+        public virtual ICollection<eleveannee> eleveannees { get; set; }
     }
 }

+ 67 - 0
CD67.FicheCollege.Entity/etablissementannee.cs

@@ -0,0 +1,67 @@
+//------------------------------------------------------------------------------
+// <auto-generated>
+//     Ce code a été généré à partir d'un modèle.
+//
+//     Des modifications manuelles apportées à ce fichier peuvent conduire à un comportement inattendu de votre application.
+//     Les modifications manuelles apportées à ce fichier sont remplacées si le code est régénéré.
+// </auto-generated>
+//------------------------------------------------------------------------------
+
+namespace CD67.FicheCollege.Entity
+{
+    using System;
+    using System.Collections.Generic;
+    
+    public partial class etablissementannee
+    {
+        public int idetablissement { get; set; }
+        public double annee { get; set; }
+        public Nullable<double> nbeleves { get; set; }
+        public Nullable<double> capaciteinternes { get; set; }
+        public Nullable<double> capacitedemipension { get; set; }
+        public Nullable<double> capaciteeleves { get; set; }
+        public Nullable<double> effectifmaximal { get; set; }
+        public Nullable<double> classesprevues { get; set; }
+        public Nullable<double> elevessecteur { get; set; }
+        public Nullable<double> eleveshorssecteur { get; set; }
+        public Nullable<double> niveauremplissage { get; set; }
+        public Nullable<double> demipensionnaires { get; set; }
+        public string responsable { get; set; }
+        public string gestionnaire { get; set; }
+        public Nullable<double> nbenseignants { get; set; }
+        public Nullable<double> nbadministratifs { get; set; }
+        public Nullable<double> nbautrepersonnel { get; set; }
+        public Nullable<decimal> optzep { get; set; }
+        public Nullable<decimal> optrep { get; set; }
+        public Nullable<int> capacitearchi { get; set; }
+        public Nullable<decimal> optrar { get; set; }
+        public string ien { get; set; }
+        public Nullable<int> capacitesegpa { get; set; }
+        public Nullable<int> internes { get; set; }
+        public Nullable<int> nbsegpa { get; set; }
+        public string rpi { get; set; }
+        public Nullable<decimal> optrpi { get; set; }
+        public Nullable<int> nbhandi { get; set; }
+        public Nullable<int> nbtechno { get; set; }
+        public Nullable<int> nbupi { get; set; }
+        public Nullable<int> nbcham { get; set; }
+        public Nullable<int> nbsport { get; set; }
+        public Nullable<int> capacitedivisions { get; set; }
+        public Nullable<int> nbdivisions { get; set; }
+        public Nullable<int> nbgene { get; set; }
+        public Nullable<int> nbulis { get; set; }
+        public Nullable<int> nbdima { get; set; }
+        public string principaladjoint { get; set; }
+        public string mailgestionnaire { get; set; }
+        public string mailresponsable { get; set; }
+        public Nullable<int> nbupe2a { get; set; }
+        public Nullable<decimal> dotation { get; set; }
+        public Nullable<int> nbcpsfavorisea { get; set; }
+        public Nullable<int> nbcpsfavoriseb { get; set; }
+        public Nullable<int> nbcpsdefavorise { get; set; }
+        public Nullable<int> nbcpsmoyenne { get; set; }
+        public string optrpiconcentre { get; set; }
+    
+        public virtual etablissement etablissement { get; set; }
+    }
+}

+ 6 - 0
CD67.FicheCollege.MVC/Controllers/CollegesController.cs

@@ -50,6 +50,11 @@ namespace CD67.FicheCollege.MVC.Controllers
                 if (educf_etablissement != null)
                 {
                     college.educfData.Add("Effectifs", educf_etablissement.etabeffectifannees.Where(e=>e.annee== college.Annee.AnneeRentree).Sum(e => e.effectif).ToString());
+                    college.educfData.Add("Effectif Bilingue", educf_etablissement.eleveannees.Where(e=>e.annee== college.Annee.AnneeRentree & e.idetablissement == 3 & e.idfiliere == 6).Count().ToString());
+                    college.educfData.Add("Demi-pensionnaires", educf_etablissement.etablissementannees.Where(e=>e.annee== college.Annee.AnneeRentree).First().demipensionnaires.ToString());
+                    college.educfData.Add("Internes", educf_etablissement.etablissementannees.Where(e=>e.annee== college.Annee.AnneeRentree).First().capaciteeleves.ToString());
+                    college.educfData.Add("Accessibilité handicapés", educf_etablissement.accueilhandicape != 0 ? "Oui" : "Non");
+                    college.educfData.Add("Capacité Théorique", educf_etablissement.etablissementannees.Where(e => e.annee == college.Annee.AnneeRentree).First().internes.ToString());
 
                     List<string> liste_niveaux = new List<string>();
                     foreach(etabeffectifannee effectif in educf_etablissement.etabeffectifannees.Where(e => e.annee == college.Annee.AnneeRentree).OrderBy(e=>e.niveau.ordre))
@@ -65,6 +70,7 @@ namespace CD67.FicheCollege.MVC.Controllers
                     }
                     college.educfData.Add("Options", string.Join(" - ", liste_options));
 
+
                 }
                 else
                 {

+ 1 - 1
CD67.FicheCollege.MVC/Web.config

@@ -76,7 +76,7 @@
   </system.webServer>
   <system.data>
     <DbProviderFactories>
-      <add name="Npgsql Data Provider" invariant="Npgsql" description="Data Provider for PostgreSQL" type="Npgsql.NpgsqlFactory, Npgsql" />
+      <add name="Npgsql Data Provider" invariant="Npgsql" description="Data Provider for PostgreSQL" type="Npgsql.NpgsqlFactory, Npgsql, Culture=neutral, PublicKeyToken=5d8b90d52f46fda7" />
       <!--<add name="dotConnect for PostgreSQL" invariant="Devart.Data.PostgreSql" description="Devart dotConnect for PostgreSQL" type="Devart.Data.PostgreSql.PgSqlProviderFactory, Devart.Data.PostgreSql, Version= 7.10.1134.0, Culture=neutral, PublicKeyToken=09af7300eec23701" />-->
     </DbProviderFactories>
   </system.data>