up planing familal properties
This commit is contained in:
parent
e6a14ba84d
commit
61098395e1
File diff suppressed because it is too large
Load Diff
@ -20,6 +20,12 @@ antennes = []
|
|||||||
for article in articles:
|
for article in articles:
|
||||||
titre = article.find("button", class_="nsb action-title").text.strip()
|
titre = article.find("button", class_="nsb action-title").text.strip()
|
||||||
adresse = article.find("p", class_="address").text.strip()
|
adresse = article.find("p", class_="address").text.strip()
|
||||||
|
website = article.find("a", class_="icon arrow").get("href").strip()
|
||||||
|
violences = article.find("li", class_="icon violences")
|
||||||
|
sexualities = article.find("li", class_="icon sexualities")
|
||||||
|
detection = article.find("li", class_="icon detection")
|
||||||
|
contraception = article.find("li", class_="icon contraception")
|
||||||
|
abortion = article.find("li", class_="icon abortion")
|
||||||
|
|
||||||
# Gérer les articles qui n'ont pas de numéro de téléphone
|
# Gérer les articles qui n'ont pas de numéro de téléphone
|
||||||
telephone = ""
|
telephone = ""
|
||||||
@ -35,16 +41,18 @@ for article in articles:
|
|||||||
antenne = {
|
antenne = {
|
||||||
"type": "Feature",
|
"type": "Feature",
|
||||||
"geometry":geometry,
|
"geometry":geometry,
|
||||||
"properties": {
|
"nom": titre,
|
||||||
"nom": titre,
|
"adresse": adresse,
|
||||||
"adresse": adresse,
|
"contact:phone": telephone,
|
||||||
"telephone": telephone
|
"contact:website": 'https://www.planning-familial.org/fr/'+website,
|
||||||
},
|
"family_planning:handles:violences": ('yes' if violences else 'no'),
|
||||||
|
"family_planning:handles:sexualities": ('yes' if sexualities else 'no'),
|
||||||
|
"family_planning:handles:detection": ('yes' if detection else 'no'),
|
||||||
|
"family_planning:handles:abortion": ('yes' if abortion else 'no'),
|
||||||
|
"family_planning:handles:contraception": ('yes' if contraception else 'no'),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# print(antenne)
|
||||||
print(antenne)
|
|
||||||
|
|
||||||
antennes.append(antenne)
|
antennes.append(antenne)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user