Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

550 ajouter traage des liens formations mtiers #554

Merged
merged 2 commits into from
Oct 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ public static String capitalizeFirstLetter(String sentence) {
}

extraUrls.forEach((key, extraLinks) -> {
val cleanupExtraLinks = extraLinks.stream().map(String::trim).filter(String::isBlank).toList();
val cleanupExtraLinks = extraLinks.stream().map(String::trim).filter(s -> !s.isBlank()).toList();
if(!cleanupExtraLinks.isEmpty()) {
val cleanedupKey = Constants.cleanup(key);
cleanupExtraLinks.forEach(e -> addUrl(cleanedupKey, e, getLabel(labels, cleanedupKey, e), AJOUTS_MPS, urls));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@

public class CsvTools implements Closeable {

public static final String MISSING_HEADER = "Missing header ";
public static final String IN_LINE = " in line ";

private final @NotNull ICSVWriter csvWriter;
private CsvTools(String filename, char separator, Charset charset) throws IOException {
Path filePath = Paths.get(filename);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@ public class DataSources {
/* Ideo data */

public static final String IDEO_OD_FORMATIONS_FICHES_PATH = "ideo/5fe07a9ecc960.zip";
public static final String IDEO_OD_FORMATIONS_FICHES_URL = "https://api.opendata.onisep.fr/downloads/5fe07a9ecc960/5fe07a9ecc960.zip";
public static final String IDEO_OD_FORMATIONS_SIMPLE_PATH = "ideo/5fa591127f501.json";
public static final String IDEO_OD_FORMATIONS_SIMPLE_URL = "https://api.opendata.onisep.fr/downloads/5fa591127f501/5fa591127f501.json";

public static final String IDEO_OD_METIERS_SIMPLE_PATH = "ideo/5fa5949243f97.json";
public static final String IDEO_OD_METIERS_FICHES_PATH = "ideo/5fe0808a2da6f.zip";
public static final String IDEO_OD_DOMAINES_PATH = "ideo/5fa58d750a60c.json";
Expand Down Expand Up @@ -50,7 +53,7 @@ public class DataSources {
public static final String LIENS_MPS_PATH_HEADER_EXTRAS = "ajouts";
public static final String DOMAINES_MPS_PATH = "mps/Domaines MPS Onisep.csv";
public static final String INTERETS_GROUPES_PATH = "mps/centres_d_interets_MPS_-_Feuille_1.csv";
public static final String PSUP_TO_IDEO_CORRESPONDANCE_PATH = "onisep_ideo_hotline/liensPSUP_ONISEP_2024_09_06_V1_HG.csv";
public static final String PSUP_TO_IDEO_CORRESPONDANCE_PATH = "onisep_ideo_hotline/liensPSUP_ONISEP_2024_09_06_V1.csv";
public static final String PSUP_TO_METIERS_CORRESPONDANCE_PATH_PSUP_HEADER = "MPS_ID";
public static final String PSUP_TO_METIERS_CORRESPONDANCE_PATH_FORMATION_IDEO_HEADER = "FOR_ID";
public static final String PSUP_TO_METIERS_CORRESPONDANCE_PATH_METIER_IDEO_HEADER = "MET_ID";
Expand Down
Loading