[Article] Intégration Pronote : cours, devoirs, notes, etc (archive)

Hello, yes je vais regarder par contre je ne suis pas chez moi du week-end donc ça sera pas avant dimanche soir voire lundi :slight_smile:

je n’ai pas de choix multiples dans les menus proposés :thinking:(tu as le menu de ma fille pour la semaine en exemple sur mon post au dessus )

Ok
Dans le college de ma fille ils ont le choix au niveau des entrées etc…c’est pour ca que j’ai fait la carte que j’ai proposé.

bonjour,
@Alpin38 une idée du problème? lorsque je colle le code je récupere bien le menu mais l’affichage est ko


Merci par avance
Fred

As tu l’extension card-mod ?

Personne a une carte pour les notes ? car la il y a les evaluations mais les notes non

type: markdown
content: |2-
    <table>
      {% set items = state_attr('sensor.pronote_XYZ_grades','grades')%}
    <tr>
    <td><h4>Date<h3></td>
    <td><h4>Course</td>
    <td><h4>Grade</td>
    <td><h4>Class</td>
    <td><h4>Max</td>
    <td><h4>Min</td>
    <td><h4>Coeff</td>
    </tr>
    {% for i in range(0, items | count, 1) %}
    <tr>    
    <td>{{ items[i].date }}</td>
    <td>{{ items[i].subject }}</td>
    <td>{{ items[i].grade_out_of }}</td>
    <td>{{ items[i].class_average }}</td>
    <td>{{ items[i].max }}</td>
    <td>{{ items[i].min }}</td>
    <td>{{ items[i].coefficient }}</td>
   </tr>
  {% endfor %}
title: Grades
card_mod:
  style:
    .: |
      ha-card ha-markdown {
                padding:0px
                border-top: 1px groove var(--divider-color);
                overflow-y: scroll;
                height: 300px;
              }
      ha-card ha-markdown.no-header {
        padding:0px
      }
    $: |
      h1.card-header {
        background-color:rgb(100, 100, 100);
          padding: 0px 0px 0px 12px !important;
          color: white !important;
          font-weight: normal;
          font-size: 1.5em !important;
          border-top-left-radius: 5px; 
          border-top-right-radius: 5px; 
          height: 100%;
      }        
    ha-markdown $: |
      h1 {
          font-weight: normal;
          font-size: 24px;
      }
      div {
          background-color:rgb(100, 100, 100);
          padding: 12px 12px;
          color:white;
          font-weight:normal;
          font-size:1.2em;
            border-top-left-radius: 5px; 
            border-top-right-radius: 5px; 
      }
      table{
        border-collapse: collapse;
        font-size: 0.9em;
        font-family: Roboto;
        width: 100%;
        outline: 0px solid #393c3d;
        margin-top: 10px;
      } caption {
          text-align: center;
          font-weight: bold;
          font-size: 1.2em;
      } td {
          padding: 5px 5px 5px 5px;
          text-align: left;
          border-bottom: 0px solid #1c2020;
      }
      tr {
          border-bottom: 0px solid #1c2020;
      }
      tr:last-of-type {
          border-bottom: transparent;
      }
      tr:nth-of-type(even) {
          background-color: rgb(54, 54, 54, 0.3);
      }
      mark {
          background: lightgreen;
          border-color: green;
          border-radius: 10px;
          padding: 5px;
      }
      span {
          background: orange;
          color: #222627;
          border-radius: 5px;
          padding: 5px;
      }
      tr:nth-child(n+2) > td:nth-child(2) {
        text-align: left;
      }

@Sigalou

Une question, j’ai bien accès à pronote, j’ai également installer card Mod via HACS.

Si j’ai bien compris, Il faut rajouter une carte markdown à mon dashboard, de copier le code que tu a mis a dispo sur ton blog et c’est tout ? Super boulot au passage :clap:
Bien sur, je change le nom du sensore pronote pour qu’il corresponde a celui que j’ai dans mon HA ?
Et après, idem pour les cartes que je souhaite avoir en visu (en fonction des différents code sur ton blog) ?
Merci par avance pour ton retour

Si moi @barto_95

type: markdown
content: |2-
   <div>Note</div><table> 
      {% set items = state_attr('sensor.pronote_xxxxxxxx_grades','grades')%}
    <tr>
    <td><h4>Date<h3></td>
    <td><h4>Cours</td>
    <td><h4>Note</td>
    <td><h4>Class</td>
    <td><h4>Max</td>
    <td><h4>Min</td>
    <td><h4>Coeff</td>
    </tr>
    {% for i in range(0, items | count, 1) %}
    <tr>    
    <td>{{ items[i].date }}</td>
    <td>{{ items[i].subject }}</td>
    <td>{{ items[i].grade_out_of }}</td>
    <td>{{ items[i].class_average }}</td>
    <td>{{ items[i].max }}</td>
    <td>{{ items[i].min }}</td>
    <td>{{ items[i].coefficient }}</td>
   </tr>
  {% endfor %}
card_mod:
  style:
    .: |
      ha-card ha-markdown {
        padding:0px
      }
      ha-card ha-markdown.no-header {
        padding:0px
      }
    ha-markdown$: |
      h1 {
          font-weight: normal;
          font-size: 24px;
      }
      div {
          background-color:rgb(100, 100, 100);
          padding: 12px 12px;
          color:white;
          font-weight:normal;
          font-size:1.2em;
          border-top-left-radius: 5px; 
          border-top-right-radius: 5px; 
      }
      table{
        border-collapse: collapse;
        font-weight:normal;
        font-size:1.em;
        font-family: Roboto;
        width: auto;
        outline: 0px solid #393c3d;
        margin-top: 10px;
      } caption {
          text-align: center;
          font-weight: bold;
          font-size: 1.2em;
      } td {
          padding: 0px 5px 0px 5px;
          text-align: center;
          border-bottom: 0px solid #1c2020;
      }
      tr {
          border-bottom: 0px solid #1c2020;
          line-height: 25px;
      }
      tr:nth-of-type(even) {
          background-color: rgb(54, 54, 54, 0.3);
      }
      tr:last-of-type {
          border-bottom: transparent;
      }
      mark {
          background: #009767;
          color: #222627;
          border-radius: 10px;
          padding: 5px;
      }
      span {
          background: #EC4B34;
          color: #222627;
          border-radius: 10px;
          padding: 5px;
      }
      span {
          padding: 5px;
      }
      tr:nth-child(n+2) > td:nth-child(2) {
        text-align: left;
      }

et tu te retrouve avec les meme carte que sur le site de @Sigalou

Je suis dans le même cas que toi alors qu’il y a bien les menus sur l’application Pronote.

@barto_95 et @Jean-Michel , c’est peu etre normale, es que dans votre pronote( je ne parle par du pronote de home assistant, mes de app pronote android ou la pomme), il y a les menus. chez moi le sensor ne remonte rien car les menus sont pas dans app pronote
.

les menus sont bien dans l’app

Pour la part non dans PRONOTE il n’y a rien et en faite pour avoir les menu chez nous faut aller sur l’ENT et c’est un fichier PDF pour la cantine :man_facepalming:

comme chez moi @barto_95

Et après quoi ? stp reformule ta question.

J’ai mis à jour les cartes pour corriger homework et avoir les menus de la cantine

Je suis désolé pour les notes, impossible pour moi à tester, je n’ai pas de notes sur mes données.

Ha oui, ben là, c’est la tuile, impossible effectivement à récupérer :rofl:

Je voulais juste demander si la méthode pour tous les autres markdown était identique à la première que j’ai décris rapidement dans mon message

Je réponds à beaucoup de messages et suis beaucoup de conversation. Si les questions ne sont pas plus directes, plus simples ou plus complètes, attends toi à ne pas avoir de réponse.

1 « J'aime »

Bien compris et c’est normal. Je vais tester de mon coté et je reviendrais vers toi si besoin. Merci du temps que tu m’accorde

1 « J'aime »