var filiInfo = { css: null, exports: { onBeforeMount(props, state) { }, updateFiliStats() { let list = this.props.schoolList; let avg = list.reduce((s, e) => s + e.fields.moyenne, 0) / list.length; let avgCap = list.reduce((s, e) => s + e.fields.capa_fin, 0) / list.length; let avgSlc = list.reduce((s, e) => s + (e.fields.taux_acces_ens || 0), 0) / list.filter(e => e.fields.taux_acces_ens).length; this.state.courseNumber = list.length; this.state.average = Math.round(avg * 100) / 100; this.state.capacity = Math.floor(avgCap); this.state.selectivity = Math.floor(avgSlc); let pctFemmes = Math.round(list.reduce((s, e) => s + (e.fields.pct_f || 0), 0) / list.filter(e => e.fields.pct_f).length); this.state.genreStats = [{ name: "Hommes", short: "H", value: 100 - pctFemmes }, { name: "Femmes", short: "F", value: pctFemmes }]; let pctBG = Math.round(list.reduce((s, e) => s + (e.fields.part_acces_gen || 0), 0) / list.filter(e => e.fields.part_acces_gen).length); let pctBT = Math.round(list.reduce((s, e) => s + (e.fields.part_acces_tec || 0), 0) / list.filter(e => e.fields.part_acces_tec).length); let pctBP = Math.round(list.reduce((s, e) => s + (e.fields.part_acces_pro || 0), 0) / list.filter(e => e.fields.part_acces_pro).length); if (!pctBG) pctBG = 0; if (!pctBT) pctBT = 0; if (!pctBP) pctBP = 0; this.state.bacStats = [{ name: "Général", short: "Gen.", value: pctBG }, { name: "Technologique", short: "Tech.", value: pctBT }, { name: "Professionnel", short: "Pro.", value: pctBP }, { name: "Autre", short: "Au.", value: 100 - (pctBG + pctBT + pctBP) }]; let pctSM = Math.round(list.reduce((s, e) => s + e.fields.pct_sansmention, 0) / list.length); let pctAB = Math.round(list.reduce((s, e) => s + e.fields.pct_ab, 0) / list.length); let pctB = Math.round(list.reduce((s, e) => s + e.fields.pct_b, 0) / list.length); let pctTB = Math.round(list.reduce((s, e) => s + e.fields.pct_tb, 0) / list.length); let pctTBF = Math.round(list.reduce((s, e) => s + e.fields.pct_tbf, 0) / list.length); this.state.mentionStats = [{ name: "Sans Mention", short: "SM", value: pctSM }, { name: "Assez Bien", short: "AB", value: pctAB }, { name: "Bien", short: "B", value: pctB }, { name: "Très Bien", short: "TB", value: pctTB }, { name: "Très Bien + Félicitations", short: "TBF", value: pctTBF }, { name: "Non Spécifié", short: "NS", value: 100 - (pctSM + pctAB + pctB + pctTB + pctTBF) }]; }, onBeforeUpdate(props, state) { if (!props.schoolList || !props.schoolList.length) return; this.updateFiliStats(); } }, template: (template, expressionTypes, bindingTypes, getComponent) => template('
', [{ type: bindingTypes.IF, evaluate: _scope => _scope.props.shouldShowInfos, redundantAttribute: 'expr2138', selector: '[expr2138]', template: template('Moyenne des admis
Nombre de formations
Capacité