Projet

Général

Profil

0001-maelis-add-child-month-planning-listing-48480.patch

Nicolas Roche, 22 décembre 2020 15:22

Télécharger (108 ko)

Voir les différences:

Subject: [PATCH] maelis: add child month planning listing (#48480)

 passerelle/apps/maelis/models.py              |   50 +-
 passerelle/apps/maelis/utils.py               |  153 +-
 .../child_planning_after_decomposition.json   |  383 +++++
 .../child_planning_before_decomposition.json  |  392 +++++
 ...hild_planning_readActivityListResponse.xml | 1355 +++++++++++++++++
 ...lanning_readChildMonthPlanningResponse.xml |  209 +++
 tests/test_maelis.py                          |  130 +-
 7 files changed, 2661 insertions(+), 11 deletions(-)
 create mode 100644 tests/data/maelis/child_planning_after_decomposition.json
 create mode 100644 tests/data/maelis/child_planning_before_decomposition.json
 create mode 100644 tests/data/maelis/child_planning_readActivityListResponse.xml
 create mode 100644 tests/data/maelis/child_planning_readChildMonthPlanningResponse.xml
passerelle/apps/maelis/models.py
20 20
from urllib.parse import urljoin
21 21

  
22 22
import zeep
23 23
from zeep.wsse.username import UsernameToken
24 24
from zeep.helpers import serialize_object
25 25

  
26 26
from django.db import models
27 27
from django.utils import timezone
28

  
28
from django.utils.dateparse import parse_date
29 29
from django.utils.translation import ugettext_lazy as _
30 30

  
31 31
from passerelle.base.models import BaseResource
32 32
from passerelle.utils.api import endpoint
33 33
from passerelle.utils.jsonresponse import APIError
34 34

  
35 35
from . import utils
36 36

  
......
392 392
            end_datetime = start_datetime + timezone.timedelta(days=62)
393 393
        r = self.call('ActivityService?wsdl', 'readActivityList',
394 394
                      schoolyear=school_year, numPerson=personID,
395 395
                      dateStartCalend=start_datetime,
396 396
                      dateEndCalend=end_datetime)
397 397
        activities = serialize_object(r)
398 398
        return {'data': [utils.normalize_activity(a) for a in activities]}
399 399

  
400
    @endpoint(
401
        display_category=_('Activities'),
402
        perm='can_access',
403
        display_order=3,
404
        description=_('Read child planning'),
405
        name='child-planning',
406
        parameters={
407
            'NameID': {'description': _('Publik ID')},
408
            'childID': {'description': _('Child ID')},
409
            'start_date': {'description': _('Start date (YYYY-MM-DD format)')},
410
            'end_date': {'description': _('End date (YYYY-MM-DD format)')},
411
    })
412
    def child_planning(self, request, NameID, childID, start_date=None, end_date=None):
413
        """ Return an events list sorted by id """
414
        link = self.get_link(NameID)
415
        family_data = self.get_family_data(link.family_id)
416
        if childID not in [c['id'] for c in family_data['childInfoList']]:
417
            raise APIError('Child not found', err_code='not-found')
418
        if start_date and end_date:
419
            start = parse_date(start_date)
420
            end = parse_date(end_date)
421
        else:
422
            start, end = utils.week_boundaries(start_date)
423
        school_year = utils.get_default_school_year(start)
424

  
425
        r = self.call('ActivityService?wsdl', 'readActivityList',
426
                      schoolyear=school_year, numPerson=childID,
427
                      dateStartCalend=start,
428
                      dateEndCalend=end)
429
        activities = serialize_object(r)
430
        events = {key: value
431
                       for a in activities
432
                       for (key, value) in utils.get_events(a, start, end)}
433

  
434
        for date in utils.month_range(start, end):
435
            r = self.call('ActivityService?wsdl', 'readChildMonthPlanning',
436
                          year=date.year,
437
                          numMonth=date.month,
438
                          numPerson=childID)
439
            planning = serialize_object(r['calendList'])
440
            for schedule in planning:
441
                utils.book_event(events, schedule, start, end)
442

  
443
        events = {x['id']: x  # dictionary is used de remove dupplicated events
444
                       for e in events.values()
445
                       for x in utils.decompose_event(e)}
446
        return {'data': [s[1] for s in sorted(events.items())]}
447

  
400 448

  
401 449
class Link(models.Model):
402 450
    resource = models.ForeignKey(Maelis, on_delete=models.CASCADE)
403 451
    name_id = models.CharField(blank=False, max_length=256)
404 452
    family_id = models.CharField(blank=False, max_length=128)
405 453
    created = models.DateTimeField(auto_now_add=True)
406 454
    updated = models.DateTimeField(auto_now=True)
407 455

  
passerelle/apps/maelis/utils.py
12 12
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 13
# GNU Affero General Public License for more details.
14 14
#
15 15
# You should have received a copy of the GNU Affero General Public License
16 16
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
17 17

  
18 18
from __future__ import unicode_literals
19 19

  
20
from copy import copy
21
from datetime import datetime
22
from dateutil.relativedelta import relativedelta
23

  
20 24
from django.utils import timezone
25
from django.utils.dateparse import parse_date
26

  
27
from passerelle.utils.jsonresponse import APIError
28

  
29
DATE_FORMAT = '%Y-%m-%d'
30
TIME_FORMAT = '%H:%M:%S'
31
DATETIME_FORMAT = DATE_FORMAT + ' ' + TIME_FORMAT
21 32

  
22
datetime_format = '%d/%m/%Y %H:%M:%S'
33
COMPONENTS = {
34
    'PART01': {
35
        'text': 'Matinée',
36
        'time': '08:00:00',
37
    },
38
    'PART02': {
39
        'text': 'Repas',
40
        'time': '12:00:00',
41
    },
42
    'PART03': {
43
        'text': 'Après-midi',
44
        'time': '14:00:00',
45
    }
46
}
47

  
48
COMPOSED_UNITS = {
49
    'A10003132034': {  # JOURNEE
50
        'virtual_unit': 'EO0001',
51
        'components': ['PART01', 'PART02', 'PART03'],
52
    },
53
    'A10003132036': {  # MATIN
54
        'virtual_unit': 'EO0001',
55
        'components': ['PART01'],
56
    },
57
    'A10003132038': {  # MATIN ET REPAS
58
        'virtual_unit': 'EO0001',
59
        'components': ['PART01', 'PART02'],
60
    },
61
    'A10003132040': {  # APRES MIDI
62
        'virtual_unit': 'EO0001',
63
        'components': ['PART03'],
64
    },
65
}
23 66

  
24 67

  
25 68
def normalize_invoice(invoice):
26 69
    data = {
27 70
        'id': '%s-%s' % (invoice.numFamily, invoice.numInvoice),
28 71
        'display_id': str(invoice.numInvoice),
29 72
        'label': invoice.TTFInfo.libelle,
30
        'created': invoice.dateInvoice.strftime(datetime_format),
73
        'created': invoice.dateInvoice.strftime(DATETIME_FORMAT),
31 74
        'amount': invoice.amountInvoice - invoice.amountPaid,
32 75
        'paid': invoice.amountInvoice == invoice.amountPaid,
33 76
        'total_amount': invoice.amountInvoice,
34
        'pay_limit_date': invoice.dateDeadline.strftime(datetime_format),
77
        'pay_limit_date': invoice.dateDeadline.strftime(DATETIME_FORMAT),
35 78
        'has_pdf': bool(invoice.pdfName),
36 79
        'amount_paid': invoice.amountPaid
37 80
    }
38 81
    if invoice.amountInvoice == invoice.amountPaid:
39 82
        data.update({
40 83
            'amount': 0,
41 84
            'pay_limit_date': '',
42 85
            'online_payment': False
......
52 95

  
53 96
def normalize_person(person):
54 97
    person['id'] = person['num']
55 98
    person['text'] = '{} {}'.format(
56 99
                person['firstname'], person['lastname']).strip()
57 100
    return person
58 101

  
59 102

  
60
def get_default_school_year():
61
    now = timezone.now()
62
    if now.strftime('%m-%d') >= '07-31':
63
        return now.year
103
def get_default_school_year(date=None):
104
    if not date:
105
        date = timezone.now()
106
    if date.strftime('%m-%d') >= '07-31':
107
        return date.year
108
    else:
109
        return date.year - 1
110

  
111

  
112
def week_boundaries(date_string=None):
113
    """ Return start and end of the week including the provided date,
114
    or the current week if no date is provided. """
115
    if date_string:
116
        date = parse_date(date_string)
64 117
    else:
65
        return now.year - 1
118
        date = timezone.now()
119
    datetime_string = date.strftime('%Y-W%W')
120
    monday = timezone.make_aware(datetime.strptime(datetime_string + '-1', "%Y-W%W-%w"))
121
    sunday = timezone.make_aware(datetime.strptime(datetime_string + '-0', "%Y-W%W-%w"))
122
    return monday, sunday
123

  
124

  
125
def month_range(start_date, end_date):
126
    """ Generate first days of month for the provided date range. """
127
    if end_date < start_date:
128
        return
129
    date = start_date.replace(day=1)
130
    while date.strftime('%Y-%m') <= end_date.strftime('%Y-%m'):
131
        yield date
132
        date = date + relativedelta(months=1)
133

  
134

  
135
def get_events(activity, start_date, end_date):
136
    """ Generate events from activity's open days
137
    the events looks like the chrono ones : /api/agenda/agenda-evenement/datetimes/
138
    (https://doc-publik.entrouvert.com/dev/api-chrono/#exemple) """
139
    activity_id = activity['activityPortail']['idAct']
140
    for unit in activity['unitPortailList']:
141
        unit_id = unit['idUnit']
142
        for day in activity['openDayList']:
143

  
144
            # readActivityList may return more days than requested
145
            if not start_date <= day <= end_date:
146
                continue
147

  
148
            date_string = day.strftime(DATE_FORMAT)
149
            time_string = day.strftime(TIME_FORMAT)
150
            event_id = '%s-%s-%s' % (date_string, activity_id, unit_id)
151
            yield event_id, {
152
                'id': event_id,
153
                'category_id': activity_id,
154
                'slot_id': unit_id,
155
                'datetime': '%s %s' % (date_string, time_string),
156
                'category': activity['activityPortail']['label'],
157
                'text': unit['label'],
158
                'user_booking_status': 'not-booked',
159
            }
160

  
161

  
162
def book_event(events, schedule, start_date, end_date):
163
    """ Book event matching the provided schedule. """
164
    activity_id = schedule['unit']['idActivity']
165
    unit_id = schedule['unit']['id']
166
    for day in schedule['listDays']:
167
        if not start_date <= day['datePlanning'] <= end_date:
168
            continue
169

  
170
        date_string = day['datePlanning'].strftime(DATE_FORMAT)
171
        event_id = '%s-%s-%s' % (date_string, activity_id, unit_id)
172

  
173
        # database may be corrupted by using updateScheduleCalendars
174
        try:
175
            event = events[event_id]
176
        except KeyError:
177
            raise APIError('The planning returns an unknow day on activities: %s'
178
                           % day['datePlanning'])
179

  
180
        event['user_booking_status'] = 'booked'
181

  
182

  
183
def decompose_event(event):
184
    """ Break down 'JOURNEE', 'MATIN', 'MATIN ET REPAS' and APRES MIDI' units
185
    into 'Matin', 'Repas' and 'Après-midi' virtual units.  """
186
    if event['slot_id'] not in COMPOSED_UNITS.keys():
187
        yield event
188
        return
189

  
190
    date = datetime.strptime(event['datetime'], DATETIME_FORMAT)
191
    date_string = date.strftime(DATE_FORMAT)
192
    composition = COMPOSED_UNITS[event['slot_id']]
193

  
194
    for component_id in composition['components']:
195
        component = COMPONENTS[component_id]
196
        new_event = copy(event)
197
        new_event['datetime'] = '%s %s' % (date_string, component['time'])
198
        new_event['slot_id'] = "%s%s" % (composition['virtual_unit'], component_id)
199
        new_event['id'] = '%s-%s-%s' % (
200
            date_string, event['category_id'], new_event['slot_id'])
201
        new_event['text'] = component['text']
202
        yield new_event
tests/data/maelis/child_planning_after_decomposition.json
1
{
2
   "data" : [
3
      {
4
         "category" : "MULTI ACCUEIL LES OLIVIERS",
5
         "category_id" : "A10000003840",
6
         "datetime" : "2020-12-14 00:00:00",
7
         "id" : "2020-12-14-A10000003840-A10000003844",
8
         "slot_id" : "A10000003844",
9
         "text" : "MULTI ACCUEIL LES OLIVIERS - Réguliers",
10
         "user_booking_status" : "not-booked"
11
      },
12
      {
13
         "category" : "MULTI ACCUEIL LES OLIVIERS",
14
         "category_id" : "A10000003840",
15
         "datetime" : "2020-12-14 00:00:00",
16
         "id" : "2020-12-14-A10000003840-A10000003845",
17
         "slot_id" : "A10000003845",
18
         "text" : "MULTI ACCUEIL LES OLIVIERS - Occasionnels",
19
         "user_booking_status" : "not-booked"
20
      },
21
      {
22
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
23
         "category_id" : "A10000006100",
24
         "datetime" : "2020-12-14 00:00:00",
25
         "id" : "2020-12-14-A10000006100-A10000006104",
26
         "slot_id" : "A10000006104",
27
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Réguliers",
28
         "user_booking_status" : "not-booked"
29
      },
30
      {
31
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
32
         "category_id" : "A10000006100",
33
         "datetime" : "2020-12-14 00:00:00",
34
         "id" : "2020-12-14-A10000006100-A10000006105",
35
         "slot_id" : "A10000006105",
36
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Occasionnels",
37
         "user_booking_status" : "not-booked"
38
      },
39
      {
40
         "category" : "1 2020-2021 GARDERIE MATIN",
41
         "category_id" : "A10003121692",
42
         "datetime" : "2020-12-14 00:00:00",
43
         "id" : "2020-12-14-A10003121692-A10003121694",
44
         "slot_id" : "A10003121694",
45
         "text" : "1 2020-2021 GARDERIE MATIN",
46
         "user_booking_status" : "booked"
47
      },
48
      {
49
         "category" : "2 2020-2021  RESTAURATION SCOLAIRE",
50
         "category_id" : "A10003123490",
51
         "datetime" : "2020-12-14 00:00:00",
52
         "id" : "2020-12-14-A10003123490-A10003123492",
53
         "slot_id" : "A10003123492",
54
         "text" : "2 2020-2021  RESTAURATION SCOLAIRE",
55
         "user_booking_status" : "booked"
56
      },
57
      {
58
         "category" : "3 2020-2021 GARDERIE SOIR",
59
         "category_id" : "A10003123507",
60
         "datetime" : "2020-12-14 00:00:00",
61
         "id" : "2020-12-14-A10003123507-A10003123509",
62
         "slot_id" : "A10003123509",
63
         "text" : "3 2020-2021 GARDERIE SOIR",
64
         "user_booking_status" : "not-booked"
65
      },
66
      {
67
         "category" : "COURS DE DANSE",
68
         "category_id" : "A10003132090",
69
         "datetime" : "2020-12-14 00:00:00",
70
         "id" : "2020-12-14-A10003132090-A10003132091",
71
         "slot_id" : "A10003132091",
72
         "text" : "COURS DE DANSE",
73
         "user_booking_status" : "not-booked"
74
      },
75
      {
76
         "category" : "ATELIER D'EXPRESSION THEATRALE",
77
         "category_id" : "A10003132293",
78
         "datetime" : "2020-12-14 00:00:00",
79
         "id" : "2020-12-14-A10003132293-A10003132295",
80
         "slot_id" : "A10003132295",
81
         "text" : "ATELIER D'EXPRESSION THEATRALE",
82
         "user_booking_status" : "not-booked"
83
      },
84
      {
85
         "category" : "MULTI ACCUEIL LES OLIVIERS",
86
         "category_id" : "A10000003840",
87
         "datetime" : "2020-12-15 00:00:00",
88
         "id" : "2020-12-15-A10000003840-A10000003844",
89
         "slot_id" : "A10000003844",
90
         "text" : "MULTI ACCUEIL LES OLIVIERS - Réguliers",
91
         "user_booking_status" : "not-booked"
92
      },
93
      {
94
         "category" : "MULTI ACCUEIL LES OLIVIERS",
95
         "category_id" : "A10000003840",
96
         "datetime" : "2020-12-15 00:00:00",
97
         "id" : "2020-12-15-A10000003840-A10000003845",
98
         "slot_id" : "A10000003845",
99
         "text" : "MULTI ACCUEIL LES OLIVIERS - Occasionnels",
100
         "user_booking_status" : "not-booked"
101
      },
102
      {
103
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
104
         "category_id" : "A10000006100",
105
         "datetime" : "2020-12-15 00:00:00",
106
         "id" : "2020-12-15-A10000006100-A10000006104",
107
         "slot_id" : "A10000006104",
108
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Réguliers",
109
         "user_booking_status" : "not-booked"
110
      },
111
      {
112
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
113
         "category_id" : "A10000006100",
114
         "datetime" : "2020-12-15 00:00:00",
115
         "id" : "2020-12-15-A10000006100-A10000006105",
116
         "slot_id" : "A10000006105",
117
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Occasionnels",
118
         "user_booking_status" : "not-booked"
119
      },
120
      {
121
         "category" : "1 2020-2021 GARDERIE MATIN",
122
         "category_id" : "A10003121692",
123
         "datetime" : "2020-12-15 00:00:00",
124
         "id" : "2020-12-15-A10003121692-A10003121694",
125
         "slot_id" : "A10003121694",
126
         "text" : "1 2020-2021 GARDERIE MATIN",
127
         "user_booking_status" : "booked"
128
      },
129
      {
130
         "category" : "2 2020-2021  RESTAURATION SCOLAIRE",
131
         "category_id" : "A10003123490",
132
         "datetime" : "2020-12-15 00:00:00",
133
         "id" : "2020-12-15-A10003123490-A10003123492",
134
         "slot_id" : "A10003123492",
135
         "text" : "2 2020-2021  RESTAURATION SCOLAIRE",
136
         "user_booking_status" : "booked"
137
      },
138
      {
139
         "category" : "3 2020-2021 GARDERIE SOIR",
140
         "category_id" : "A10003123507",
141
         "datetime" : "2020-12-15 00:00:00",
142
         "id" : "2020-12-15-A10003123507-A10003123509",
143
         "slot_id" : "A10003123509",
144
         "text" : "3 2020-2021 GARDERIE SOIR",
145
         "user_booking_status" : "not-booked"
146
      },
147
      {
148
         "category" : "COURS DE DANSE",
149
         "category_id" : "A10003132090",
150
         "datetime" : "2020-12-15 00:00:00",
151
         "id" : "2020-12-15-A10003132090-A10003132091",
152
         "slot_id" : "A10003132091",
153
         "text" : "COURS DE DANSE",
154
         "user_booking_status" : "not-booked"
155
      },
156
      {
157
         "category" : "MULTI ACCUEIL LES OLIVIERS",
158
         "category_id" : "A10000003840",
159
         "datetime" : "2020-12-16 00:00:00",
160
         "id" : "2020-12-16-A10000003840-A10000003844",
161
         "slot_id" : "A10000003844",
162
         "text" : "MULTI ACCUEIL LES OLIVIERS - Réguliers",
163
         "user_booking_status" : "not-booked"
164
      },
165
      {
166
         "category" : "MULTI ACCUEIL LES OLIVIERS",
167
         "category_id" : "A10000003840",
168
         "datetime" : "2020-12-16 00:00:00",
169
         "id" : "2020-12-16-A10000003840-A10000003845",
170
         "slot_id" : "A10000003845",
171
         "text" : "MULTI ACCUEIL LES OLIVIERS - Occasionnels",
172
         "user_booking_status" : "not-booked"
173
      },
174
      {
175
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
176
         "category_id" : "A10000006100",
177
         "datetime" : "2020-12-16 00:00:00",
178
         "id" : "2020-12-16-A10000006100-A10000006104",
179
         "slot_id" : "A10000006104",
180
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Réguliers",
181
         "user_booking_status" : "not-booked"
182
      },
183
      {
184
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
185
         "category_id" : "A10000006100",
186
         "datetime" : "2020-12-16 00:00:00",
187
         "id" : "2020-12-16-A10000006100-A10000006105",
188
         "slot_id" : "A10000006105",
189
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Occasionnels",
190
         "user_booking_status" : "not-booked"
191
      },
192
      {
193
         "category" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
194
         "category_id" : "A10003132030",
195
         "datetime" : "2020-12-16 00:00:00",
196
         "id" : "2020-12-16-A10003132030-A10003132032",
197
         "slot_id" : "A10003132032",
198
         "text" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
199
         "user_booking_status" : "booked"
200
      },
201
      {
202
         "category" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
203
         "category_id" : "A10003132030",
204
         "datetime" : "2020-12-16 08:00:00",
205
         "id" : "2020-12-16-A10003132030-EO0001PART01",
206
         "slot_id" : "EO0001PART01",
207
         "text" : "Matinée",
208
         "user_booking_status" : "not-booked"
209
      },
210
      {
211
         "category" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
212
         "category_id" : "A10003132030",
213
         "datetime" : "2020-12-16 12:00:00",
214
         "id" : "2020-12-16-A10003132030-EO0001PART02",
215
         "slot_id" : "EO0001PART02",
216
         "text" : "Repas",
217
         "user_booking_status" : "not-booked"
218
      },
219
      {
220
         "category" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
221
         "category_id" : "A10003132030",
222
         "datetime" : "2020-12-16 14:00:00",
223
         "id" : "2020-12-16-A10003132030-EO0001PART03",
224
         "slot_id" : "EO0001PART03",
225
         "text" : "Après-midi",
226
         "user_booking_status" : "not-booked"
227
      },
228
      {
229
         "category" : "COURS DE DANSE",
230
         "category_id" : "A10003132090",
231
         "datetime" : "2020-12-16 00:00:00",
232
         "id" : "2020-12-16-A10003132090-A10003132091",
233
         "slot_id" : "A10003132091",
234
         "text" : "COURS DE DANSE",
235
         "user_booking_status" : "not-booked"
236
      },
237
      {
238
         "category" : "MULTI ACCUEIL LES OLIVIERS",
239
         "category_id" : "A10000003840",
240
         "datetime" : "2020-12-17 00:00:00",
241
         "id" : "2020-12-17-A10000003840-A10000003844",
242
         "slot_id" : "A10000003844",
243
         "text" : "MULTI ACCUEIL LES OLIVIERS - Réguliers",
244
         "user_booking_status" : "not-booked"
245
      },
246
      {
247
         "category" : "MULTI ACCUEIL LES OLIVIERS",
248
         "category_id" : "A10000003840",
249
         "datetime" : "2020-12-17 00:00:00",
250
         "id" : "2020-12-17-A10000003840-A10000003845",
251
         "slot_id" : "A10000003845",
252
         "text" : "MULTI ACCUEIL LES OLIVIERS - Occasionnels",
253
         "user_booking_status" : "not-booked"
254
      },
255
      {
256
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
257
         "category_id" : "A10000006100",
258
         "datetime" : "2020-12-17 00:00:00",
259
         "id" : "2020-12-17-A10000006100-A10000006104",
260
         "slot_id" : "A10000006104",
261
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Réguliers",
262
         "user_booking_status" : "not-booked"
263
      },
264
      {
265
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
266
         "category_id" : "A10000006100",
267
         "datetime" : "2020-12-17 00:00:00",
268
         "id" : "2020-12-17-A10000006100-A10000006105",
269
         "slot_id" : "A10000006105",
270
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Occasionnels",
271
         "user_booking_status" : "not-booked"
272
      },
273
      {
274
         "category" : "1 2020-2021 GARDERIE MATIN",
275
         "category_id" : "A10003121692",
276
         "datetime" : "2020-12-17 00:00:00",
277
         "id" : "2020-12-17-A10003121692-A10003121694",
278
         "slot_id" : "A10003121694",
279
         "text" : "1 2020-2021 GARDERIE MATIN",
280
         "user_booking_status" : "booked"
281
      },
282
      {
283
         "category" : "2 2020-2021  RESTAURATION SCOLAIRE",
284
         "category_id" : "A10003123490",
285
         "datetime" : "2020-12-17 00:00:00",
286
         "id" : "2020-12-17-A10003123490-A10003123492",
287
         "slot_id" : "A10003123492",
288
         "text" : "2 2020-2021  RESTAURATION SCOLAIRE",
289
         "user_booking_status" : "booked"
290
      },
291
      {
292
         "category" : "3 2020-2021 GARDERIE SOIR",
293
         "category_id" : "A10003123507",
294
         "datetime" : "2020-12-17 00:00:00",
295
         "id" : "2020-12-17-A10003123507-A10003123509",
296
         "slot_id" : "A10003123509",
297
         "text" : "3 2020-2021 GARDERIE SOIR",
298
         "user_booking_status" : "not-booked"
299
      },
300
      {
301
         "category" : "COURS DE DANSE",
302
         "category_id" : "A10003132090",
303
         "datetime" : "2020-12-17 00:00:00",
304
         "id" : "2020-12-17-A10003132090-A10003132091",
305
         "slot_id" : "A10003132091",
306
         "text" : "COURS DE DANSE",
307
         "user_booking_status" : "not-booked"
308
      },
309
      {
310
         "category" : "MULTI ACCUEIL LES OLIVIERS",
311
         "category_id" : "A10000003840",
312
         "datetime" : "2020-12-18 00:00:00",
313
         "id" : "2020-12-18-A10000003840-A10000003844",
314
         "slot_id" : "A10000003844",
315
         "text" : "MULTI ACCUEIL LES OLIVIERS - Réguliers",
316
         "user_booking_status" : "not-booked"
317
      },
318
      {
319
         "category" : "MULTI ACCUEIL LES OLIVIERS",
320
         "category_id" : "A10000003840",
321
         "datetime" : "2020-12-18 00:00:00",
322
         "id" : "2020-12-18-A10000003840-A10000003845",
323
         "slot_id" : "A10000003845",
324
         "text" : "MULTI ACCUEIL LES OLIVIERS - Occasionnels",
325
         "user_booking_status" : "not-booked"
326
      },
327
      {
328
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
329
         "category_id" : "A10000006100",
330
         "datetime" : "2020-12-18 00:00:00",
331
         "id" : "2020-12-18-A10000006100-A10000006104",
332
         "slot_id" : "A10000006104",
333
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Réguliers",
334
         "user_booking_status" : "not-booked"
335
      },
336
      {
337
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
338
         "category_id" : "A10000006100",
339
         "datetime" : "2020-12-18 00:00:00",
340
         "id" : "2020-12-18-A10000006100-A10000006105",
341
         "slot_id" : "A10000006105",
342
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Occasionnels",
343
         "user_booking_status" : "not-booked"
344
      },
345
      {
346
         "category" : "1 2020-2021 GARDERIE MATIN",
347
         "category_id" : "A10003121692",
348
         "datetime" : "2020-12-18 00:00:00",
349
         "id" : "2020-12-18-A10003121692-A10003121694",
350
         "slot_id" : "A10003121694",
351
         "text" : "1 2020-2021 GARDERIE MATIN",
352
         "user_booking_status" : "booked"
353
      },
354
      {
355
         "category" : "2 2020-2021  RESTAURATION SCOLAIRE",
356
         "category_id" : "A10003123490",
357
         "datetime" : "2020-12-18 00:00:00",
358
         "id" : "2020-12-18-A10003123490-A10003123492",
359
         "slot_id" : "A10003123492",
360
         "text" : "2 2020-2021  RESTAURATION SCOLAIRE",
361
         "user_booking_status" : "booked"
362
      },
363
      {
364
         "category" : "3 2020-2021 GARDERIE SOIR",
365
         "category_id" : "A10003123507",
366
         "datetime" : "2020-12-18 00:00:00",
367
         "id" : "2020-12-18-A10003123507-A10003123509",
368
         "slot_id" : "A10003123509",
369
         "text" : "3 2020-2021 GARDERIE SOIR",
370
         "user_booking_status" : "not-booked"
371
      },
372
      {
373
         "category" : "COURS DE DANSE",
374
         "category_id" : "A10003132090",
375
         "datetime" : "2020-12-18 00:00:00",
376
         "id" : "2020-12-18-A10003132090-A10003132091",
377
         "slot_id" : "A10003132091",
378
         "text" : "COURS DE DANSE",
379
         "user_booking_status" : "not-booked"
380
      }
381
   ],
382
   "err" : 0
383
}
tests/data/maelis/child_planning_before_decomposition.json
1
{
2
   "data" : [
3
      {
4
         "category" : "MULTI ACCUEIL LES OLIVIERS",
5
         "category_id" : "A10000003840",
6
         "datetime" : "2020-12-14 00:00:00",
7
         "id" : "2020-12-14-A10000003840-A10000003844",
8
         "slot_id" : "A10000003844",
9
         "text" : "MULTI ACCUEIL LES OLIVIERS - Réguliers",
10
         "user_booking_status" : "not-booked"
11
      },
12
      {
13
         "category" : "MULTI ACCUEIL LES OLIVIERS",
14
         "category_id" : "A10000003840",
15
         "datetime" : "2020-12-14 00:00:00",
16
         "id" : "2020-12-14-A10000003840-A10000003845",
17
         "slot_id" : "A10000003845",
18
         "text" : "MULTI ACCUEIL LES OLIVIERS - Occasionnels",
19
         "user_booking_status" : "not-booked"
20
      },
21
      {
22
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
23
         "category_id" : "A10000006100",
24
         "datetime" : "2020-12-14 00:00:00",
25
         "id" : "2020-12-14-A10000006100-A10000006104",
26
         "slot_id" : "A10000006104",
27
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Réguliers",
28
         "user_booking_status" : "not-booked"
29
      },
30
      {
31
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
32
         "category_id" : "A10000006100",
33
         "datetime" : "2020-12-14 00:00:00",
34
         "id" : "2020-12-14-A10000006100-A10000006105",
35
         "slot_id" : "A10000006105",
36
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Occasionnels",
37
         "user_booking_status" : "not-booked"
38
      },
39
      {
40
         "category" : "1 2020-2021 GARDERIE MATIN",
41
         "category_id" : "A10003121692",
42
         "datetime" : "2020-12-14 00:00:00",
43
         "id" : "2020-12-14-A10003121692-A10003121694",
44
         "slot_id" : "A10003121694",
45
         "text" : "1 2020-2021 GARDERIE MATIN",
46
         "user_booking_status" : "booked"
47
      },
48
      {
49
         "category" : "2 2020-2021  RESTAURATION SCOLAIRE",
50
         "category_id" : "A10003123490",
51
         "datetime" : "2020-12-14 00:00:00",
52
         "id" : "2020-12-14-A10003123490-A10003123492",
53
         "slot_id" : "A10003123492",
54
         "text" : "2 2020-2021  RESTAURATION SCOLAIRE",
55
         "user_booking_status" : "booked"
56
      },
57
      {
58
         "category" : "3 2020-2021 GARDERIE SOIR",
59
         "category_id" : "A10003123507",
60
         "datetime" : "2020-12-14 00:00:00",
61
         "id" : "2020-12-14-A10003123507-A10003123509",
62
         "slot_id" : "A10003123509",
63
         "text" : "3 2020-2021 GARDERIE SOIR",
64
         "user_booking_status" : "not-booked"
65
      },
66
      {
67
         "category" : "COURS DE DANSE",
68
         "category_id" : "A10003132090",
69
         "datetime" : "2020-12-14 00:00:00",
70
         "id" : "2020-12-14-A10003132090-A10003132091",
71
         "slot_id" : "A10003132091",
72
         "text" : "COURS DE DANSE",
73
         "user_booking_status" : "not-booked"
74
      },
75
      {
76
         "category" : "ATELIER D'EXPRESSION THEATRALE",
77
         "category_id" : "A10003132293",
78
         "datetime" : "2020-12-14 00:00:00",
79
         "id" : "2020-12-14-A10003132293-A10003132295",
80
         "slot_id" : "A10003132295",
81
         "text" : "ATELIER D'EXPRESSION THEATRALE",
82
         "user_booking_status" : "not-booked"
83
      },
84
      {
85
         "category" : "MULTI ACCUEIL LES OLIVIERS",
86
         "category_id" : "A10000003840",
87
         "datetime" : "2020-12-15 00:00:00",
88
         "id" : "2020-12-15-A10000003840-A10000003844",
89
         "slot_id" : "A10000003844",
90
         "text" : "MULTI ACCUEIL LES OLIVIERS - Réguliers",
91
         "user_booking_status" : "not-booked"
92
      },
93
      {
94
         "category" : "MULTI ACCUEIL LES OLIVIERS",
95
         "category_id" : "A10000003840",
96
         "datetime" : "2020-12-15 00:00:00",
97
         "id" : "2020-12-15-A10000003840-A10000003845",
98
         "slot_id" : "A10000003845",
99
         "text" : "MULTI ACCUEIL LES OLIVIERS - Occasionnels",
100
         "user_booking_status" : "not-booked"
101
      },
102
      {
103
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
104
         "category_id" : "A10000006100",
105
         "datetime" : "2020-12-15 00:00:00",
106
         "id" : "2020-12-15-A10000006100-A10000006104",
107
         "slot_id" : "A10000006104",
108
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Réguliers",
109
         "user_booking_status" : "not-booked"
110
      },
111
      {
112
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
113
         "category_id" : "A10000006100",
114
         "datetime" : "2020-12-15 00:00:00",
115
         "id" : "2020-12-15-A10000006100-A10000006105",
116
         "slot_id" : "A10000006105",
117
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Occasionnels",
118
         "user_booking_status" : "not-booked"
119
      },
120
      {
121
         "category" : "1 2020-2021 GARDERIE MATIN",
122
         "category_id" : "A10003121692",
123
         "datetime" : "2020-12-15 00:00:00",
124
         "id" : "2020-12-15-A10003121692-A10003121694",
125
         "slot_id" : "A10003121694",
126
         "text" : "1 2020-2021 GARDERIE MATIN",
127
         "user_booking_status" : "booked"
128
      },
129
      {
130
         "category" : "2 2020-2021  RESTAURATION SCOLAIRE",
131
         "category_id" : "A10003123490",
132
         "datetime" : "2020-12-15 00:00:00",
133
         "id" : "2020-12-15-A10003123490-A10003123492",
134
         "slot_id" : "A10003123492",
135
         "text" : "2 2020-2021  RESTAURATION SCOLAIRE",
136
         "user_booking_status" : "booked"
137
      },
138
      {
139
         "category" : "3 2020-2021 GARDERIE SOIR",
140
         "category_id" : "A10003123507",
141
         "datetime" : "2020-12-15 00:00:00",
142
         "id" : "2020-12-15-A10003123507-A10003123509",
143
         "slot_id" : "A10003123509",
144
         "text" : "3 2020-2021 GARDERIE SOIR",
145
         "user_booking_status" : "not-booked"
146
      },
147
      {
148
         "category" : "COURS DE DANSE",
149
         "category_id" : "A10003132090",
150
         "datetime" : "2020-12-15 00:00:00",
151
         "id" : "2020-12-15-A10003132090-A10003132091",
152
         "slot_id" : "A10003132091",
153
         "text" : "COURS DE DANSE",
154
         "user_booking_status" : "not-booked"
155
      },
156
      {
157
         "category" : "MULTI ACCUEIL LES OLIVIERS",
158
         "category_id" : "A10000003840",
159
         "datetime" : "2020-12-16 00:00:00",
160
         "id" : "2020-12-16-A10000003840-A10000003844",
161
         "slot_id" : "A10000003844",
162
         "text" : "MULTI ACCUEIL LES OLIVIERS - Réguliers",
163
         "user_booking_status" : "not-booked"
164
      },
165
      {
166
         "category" : "MULTI ACCUEIL LES OLIVIERS",
167
         "category_id" : "A10000003840",
168
         "datetime" : "2020-12-16 00:00:00",
169
         "id" : "2020-12-16-A10000003840-A10000003845",
170
         "slot_id" : "A10000003845",
171
         "text" : "MULTI ACCUEIL LES OLIVIERS - Occasionnels",
172
         "user_booking_status" : "not-booked"
173
      },
174
      {
175
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
176
         "category_id" : "A10000006100",
177
         "datetime" : "2020-12-16 00:00:00",
178
         "id" : "2020-12-16-A10000006100-A10000006104",
179
         "slot_id" : "A10000006104",
180
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Réguliers",
181
         "user_booking_status" : "not-booked"
182
      },
183
      {
184
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
185
         "category_id" : "A10000006100",
186
         "datetime" : "2020-12-16 00:00:00",
187
         "id" : "2020-12-16-A10000006100-A10000006105",
188
         "slot_id" : "A10000006105",
189
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Occasionnels",
190
         "user_booking_status" : "not-booked"
191
      },
192
      {
193
         "category" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
194
         "category_id" : "A10003132030",
195
         "datetime" : "2020-12-16 00:00:00",
196
         "id" : "2020-12-16-A10003132030-A10003132032",
197
         "slot_id" : "A10003132032",
198
         "text" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
199
         "user_booking_status" : "booked"
200
      },
201
      {
202
         "category" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
203
         "category_id" : "A10003132030",
204
         "datetime" : "2020-12-16 00:00:00",
205
         "id" : "2020-12-16-A10003132030-A10003132034",
206
         "slot_id" : "A10003132034",
207
         "text" : "JOURNEE",
208
         "user_booking_status" : "not-booked"
209
      },
210
      {
211
         "category" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
212
         "category_id" : "A10003132030",
213
         "datetime" : "2020-12-16 00:00:00",
214
         "id" : "2020-12-16-A10003132030-A10003132036",
215
         "slot_id" : "A10003132036",
216
         "text" : "MATIN",
217
         "user_booking_status" : "not-booked"
218
      },
219
      {
220
         "category" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
221
         "category_id" : "A10003132030",
222
         "datetime" : "2020-12-16 00:00:00",
223
         "id" : "2020-12-16-A10003132030-A10003132038",
224
         "slot_id" : "A10003132038",
225
         "text" : "MATIN ET REPAS",
226
         "user_booking_status" : "not-booked"
227
      },
228
      {
229
         "category" : "2020-2021 CENTRE DE LOISIRS MERCREDI",
230
         "category_id" : "A10003132030",
231
         "datetime" : "2020-12-16 00:00:00",
232
         "id" : "2020-12-16-A10003132030-A10003132040",
233
         "slot_id" : "A10003132040",
234
         "text" : "APRES MIDI",
235
         "user_booking_status" : "not-booked"
236
      },
237
      {
238
         "category" : "COURS DE DANSE",
239
         "category_id" : "A10003132090",
240
         "datetime" : "2020-12-16 00:00:00",
241
         "id" : "2020-12-16-A10003132090-A10003132091",
242
         "slot_id" : "A10003132091",
243
         "text" : "COURS DE DANSE",
244
         "user_booking_status" : "not-booked"
245
      },
246
      {
247
         "category" : "MULTI ACCUEIL LES OLIVIERS",
248
         "category_id" : "A10000003840",
249
         "datetime" : "2020-12-17 00:00:00",
250
         "id" : "2020-12-17-A10000003840-A10000003844",
251
         "slot_id" : "A10000003844",
252
         "text" : "MULTI ACCUEIL LES OLIVIERS - Réguliers",
253
         "user_booking_status" : "not-booked"
254
      },
255
      {
256
         "category" : "MULTI ACCUEIL LES OLIVIERS",
257
         "category_id" : "A10000003840",
258
         "datetime" : "2020-12-17 00:00:00",
259
         "id" : "2020-12-17-A10000003840-A10000003845",
260
         "slot_id" : "A10000003845",
261
         "text" : "MULTI ACCUEIL LES OLIVIERS - Occasionnels",
262
         "user_booking_status" : "not-booked"
263
      },
264
      {
265
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
266
         "category_id" : "A10000006100",
267
         "datetime" : "2020-12-17 00:00:00",
268
         "id" : "2020-12-17-A10000006100-A10000006104",
269
         "slot_id" : "A10000006104",
270
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Réguliers",
271
         "user_booking_status" : "not-booked"
272
      },
273
      {
274
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
275
         "category_id" : "A10000006100",
276
         "datetime" : "2020-12-17 00:00:00",
277
         "id" : "2020-12-17-A10000006100-A10000006105",
278
         "slot_id" : "A10000006105",
279
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Occasionnels",
280
         "user_booking_status" : "not-booked"
281
      },
282
      {
283
         "category" : "1 2020-2021 GARDERIE MATIN",
284
         "category_id" : "A10003121692",
285
         "datetime" : "2020-12-17 00:00:00",
286
         "id" : "2020-12-17-A10003121692-A10003121694",
287
         "slot_id" : "A10003121694",
288
         "text" : "1 2020-2021 GARDERIE MATIN",
289
         "user_booking_status" : "booked"
290
      },
291
      {
292
         "category" : "2 2020-2021  RESTAURATION SCOLAIRE",
293
         "category_id" : "A10003123490",
294
         "datetime" : "2020-12-17 00:00:00",
295
         "id" : "2020-12-17-A10003123490-A10003123492",
296
         "slot_id" : "A10003123492",
297
         "text" : "2 2020-2021  RESTAURATION SCOLAIRE",
298
         "user_booking_status" : "booked"
299
      },
300
      {
301
         "category" : "3 2020-2021 GARDERIE SOIR",
302
         "category_id" : "A10003123507",
303
         "datetime" : "2020-12-17 00:00:00",
304
         "id" : "2020-12-17-A10003123507-A10003123509",
305
         "slot_id" : "A10003123509",
306
         "text" : "3 2020-2021 GARDERIE SOIR",
307
         "user_booking_status" : "not-booked"
308
      },
309
      {
310
         "category" : "COURS DE DANSE",
311
         "category_id" : "A10003132090",
312
         "datetime" : "2020-12-17 00:00:00",
313
         "id" : "2020-12-17-A10003132090-A10003132091",
314
         "slot_id" : "A10003132091",
315
         "text" : "COURS DE DANSE",
316
         "user_booking_status" : "not-booked"
317
      },
318
      {
319
         "category" : "MULTI ACCUEIL LES OLIVIERS",
320
         "category_id" : "A10000003840",
321
         "datetime" : "2020-12-18 00:00:00",
322
         "id" : "2020-12-18-A10000003840-A10000003844",
323
         "slot_id" : "A10000003844",
324
         "text" : "MULTI ACCUEIL LES OLIVIERS - Réguliers",
325
         "user_booking_status" : "not-booked"
326
      },
327
      {
328
         "category" : "MULTI ACCUEIL LES OLIVIERS",
329
         "category_id" : "A10000003840",
330
         "datetime" : "2020-12-18 00:00:00",
331
         "id" : "2020-12-18-A10000003840-A10000003845",
332
         "slot_id" : "A10000003845",
333
         "text" : "MULTI ACCUEIL LES OLIVIERS - Occasionnels",
334
         "user_booking_status" : "not-booked"
335
      },
336
      {
337
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
338
         "category_id" : "A10000006100",
339
         "datetime" : "2020-12-18 00:00:00",
340
         "id" : "2020-12-18-A10000006100-A10000006104",
341
         "slot_id" : "A10000006104",
342
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Réguliers",
343
         "user_booking_status" : "not-booked"
344
      },
345
      {
346
         "category" : "HALTE GARDERIE LES MAGNOLIAS",
347
         "category_id" : "A10000006100",
348
         "datetime" : "2020-12-18 00:00:00",
349
         "id" : "2020-12-18-A10000006100-A10000006105",
350
         "slot_id" : "A10000006105",
351
         "text" : "HALTE GARDERIE LES MAGNOLIAS - Occasionnels",
352
         "user_booking_status" : "not-booked"
353
      },
354
      {
355
         "category" : "1 2020-2021 GARDERIE MATIN",
356
         "category_id" : "A10003121692",
357
         "datetime" : "2020-12-18 00:00:00",
358
         "id" : "2020-12-18-A10003121692-A10003121694",
359
         "slot_id" : "A10003121694",
360
         "text" : "1 2020-2021 GARDERIE MATIN",
361
         "user_booking_status" : "booked"
362
      },
363
      {
364
         "category" : "2 2020-2021  RESTAURATION SCOLAIRE",
365
         "category_id" : "A10003123490",
366
         "datetime" : "2020-12-18 00:00:00",
367
         "id" : "2020-12-18-A10003123490-A10003123492",
368
         "slot_id" : "A10003123492",
369
         "text" : "2 2020-2021  RESTAURATION SCOLAIRE",
370
         "user_booking_status" : "booked"
371
      },
372
      {
373
         "category" : "3 2020-2021 GARDERIE SOIR",
374
         "category_id" : "A10003123507",
375
         "datetime" : "2020-12-18 00:00:00",
376
         "id" : "2020-12-18-A10003123507-A10003123509",
377
         "slot_id" : "A10003123509",
378
         "text" : "3 2020-2021 GARDERIE SOIR",
379
         "user_booking_status" : "not-booked"
380
      },
381
      {
382
         "category" : "COURS DE DANSE",
383
         "category_id" : "A10003132090",
384
         "datetime" : "2020-12-18 00:00:00",
385
         "id" : "2020-12-18-A10003132090-A10003132091",
386
         "slot_id" : "A10003132091",
387
         "text" : "COURS DE DANSE",
388
         "user_booking_status" : "not-booked"
389
      }
390
   ],
391
   "err" : 0
392
}
tests/data/maelis/child_planning_readActivityListResponse.xml
1
<?xml version="1.0"?>
2
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
3
  <soap:Body>
4
    <ns1:readActivityListResponse xmlns:ns1="activity.ws.maelis.sigec.com">
5
      <ReadActivityPortailListResultBean>
6
        <activityUnitPlacePortailList>
7
          <activityPortail>
8
            <idAct>A10000003840</idAct>
9
            <label>MULTI ACCUEIL LES OLIVIERS</label>
10
            <dateStart>2011-01-01T00:00:00+01:00</dateStart>
11
            <codeConso>ENF</codeConso>
12
            <schoolYear>2020</schoolYear>
13
            <calendarGeneration>
14
              <code>FORBIDDEN</code>
15
              <value>I</value>
16
            </calendarGeneration>
17
            <dateStartPubli>2017-11-01T16:54:01+01:00</dateStartPubli>
18
            <calendarMode>N</calendarMode>
19
            <activityType>
20
              <code>PE</code>
21
              <libelle>Petite Enfance</libelle>
22
              <natureSpec>
23
                <code>E</code>
24
                <libelle>Petite Enfance</libelle>
25
              </natureSpec>
26
            </activityType>
27
            <weeklyCalendarActivityList>
28
              <yearCalendar>2020</yearCalendar>
29
              <weeklyCalendarStr>0000011</weeklyCalendarStr>
30
            </weeklyCalendarActivityList>
31
            <birthControl>N</birthControl>
32
            <waitIfComplete>N</waitIfComplete>
33
          </activityPortail>
34
          <openDayList>2020-12-14T00:00:00+01:00</openDayList>
35
          <openDayList>2020-12-15T00:00:00+01:00</openDayList>
36
          <openDayList>2020-12-16T00:00:00+01:00</openDayList>
37
          <openDayList>2020-12-17T00:00:00+01:00</openDayList>
38
          <openDayList>2020-12-18T00:00:00+01:00</openDayList>
39
          <unitPortailList>
40
            <idUnit>A10000003844</idUnit>
41
            <label>MULTI ACCUEIL LES OLIVIERS - R&#xE9;guliers</label>
42
            <dateStart>2011-01-01T00:00:00+01:00</dateStart>
43
            <consoTarifList>
44
              <commune>X</commune>
45
              <tarif>
46
                <code>PE</code>
47
                <label>PETITE ENFANCE</label>
48
              </tarif>
49
              <conso>
50
                <code>ENF</code>
51
                <label>ENFANT</label>
52
              </conso>
53
            </consoTarifList>
54
            <calendarLetter>A</calendarLetter>
55
            <subscribePublication>N</subscribePublication>
56
            <numOrder>0</numOrder>
57
            <placeList>
58
              <id>A10000003843</id>
59
              <lib>MULTI ACCUEIL LES OLIVIERS</lib>
60
              <adresse>
61
                <num>0</num>
62
              </adresse>
63
              <typeCtrlPlace>N</typeCtrlPlace>
64
              <nbPlace>80</nbPlace>
65
              <nbPlaceBoy>0</nbPlaceBoy>
66
              <nbPlaceGirl>0</nbPlaceGirl>
67
            </placeList>
68
            <typeCtrlPlace>N</typeCtrlPlace>
69
            <nbPlace>0</nbPlace>
70
            <nbPlaceBoy>0</nbPlaceBoy>
71
            <nbPlaceGirl>0</nbPlaceGirl>
72
            <idUnitEnemyList>A10002721671</idUnitEnemyList>
73
            <topCESU>O</topCESU>
74
          </unitPortailList>
75
          <unitPortailList>
76
            <idUnit>A10000003845</idUnit>
77
            <label>MULTI ACCUEIL LES OLIVIERS - Occasionnels</label>
78
            <dateStart>2011-01-01T00:00:00+01:00</dateStart>
79
            <consoTarifList>
80
              <commune>X</commune>
81
              <tarif>
82
                <code>PE</code>
83
                <label>PETITE ENFANCE</label>
84
              </tarif>
85
              <conso>
86
                <code>ENF</code>
87
                <label>ENFANT</label>
88
              </conso>
89
            </consoTarifList>
90
            <calendarLetter>B</calendarLetter>
91
            <subscribePublication>N</subscribePublication>
92
            <numOrder>0</numOrder>
93
            <placeList>
94
              <id>A10000003843</id>
95
              <lib>MULTI ACCUEIL LES OLIVIERS</lib>
96
              <adresse>
97
                <num>0</num>
98
              </adresse>
99
              <typeCtrlPlace>N</typeCtrlPlace>
100
              <nbPlace>0</nbPlace>
101
              <nbPlaceBoy>0</nbPlaceBoy>
102
              <nbPlaceGirl>0</nbPlaceGirl>
103
            </placeList>
104
            <typeCtrlPlace>N</typeCtrlPlace>
105
            <nbPlace>0</nbPlace>
106
            <nbPlaceBoy>0</nbPlaceBoy>
107
            <nbPlaceGirl>0</nbPlaceGirl>
108
            <topCESU>O</topCESU>
109
          </unitPortailList>
110
        </activityUnitPlacePortailList>
111
        <activityUnitPlacePortailList>
112
          <activityPortail>
113
            <idAct>A10000006100</idAct>
114
            <label>HALTE GARDERIE LES MAGNOLIAS</label>
115
            <dateStart>2011-01-01T00:00:00+01:00</dateStart>
116
            <codeConso>ENF</codeConso>
117
            <schoolYear>2020</schoolYear>
118
            <calendarGeneration>
119
              <code>FORBIDDEN</code>
120
              <value>I</value>
121
            </calendarGeneration>
122
            <dateStartPubli>2017-11-01T09:28:02+01:00</dateStartPubli>
123
            <calendarMode>N</calendarMode>
124
            <activityType>
125
              <code>PE</code>
126
              <libelle>Petite Enfance</libelle>
127
              <natureSpec>
128
                <code>E</code>
129
                <libelle>Petite Enfance</libelle>
130
              </natureSpec>
131
            </activityType>
132
            <weeklyCalendarActivityList>
133
              <yearCalendar>2020</yearCalendar>
134
              <weeklyCalendarStr>0000011</weeklyCalendarStr>
135
            </weeklyCalendarActivityList>
136
            <birthControl>N</birthControl>
137
            <waitIfComplete>N</waitIfComplete>
138
          </activityPortail>
139
          <openDayList>2020-12-14T00:00:00+01:00</openDayList>
140
          <openDayList>2020-12-15T00:00:00+01:00</openDayList>
141
          <openDayList>2020-12-16T00:00:00+01:00</openDayList>
142
          <openDayList>2020-12-17T00:00:00+01:00</openDayList>
143
          <openDayList>2020-12-18T00:00:00+01:00</openDayList>
144
          <unitPortailList>
145
            <idUnit>A10000006104</idUnit>
146
            <label>HALTE GARDERIE LES MAGNOLIAS - R&#xE9;guliers</label>
147
            <dateStart>2011-01-01T00:00:00+01:00</dateStart>
148
            <consoTarifList>
149
              <commune>X</commune>
150
              <tarif>
151
                <code>PE</code>
152
                <label>PETITE ENFANCE</label>
153
              </tarif>
154
              <conso>
155
                <code>ENF</code>
156
                <label>ENFANT</label>
157
              </conso>
158
            </consoTarifList>
159
            <calendarLetter>B</calendarLetter>
160
            <subscribePublication>N</subscribePublication>
161
            <numOrder>0</numOrder>
162
            <placeList>
163
              <id>A10000006103</id>
164
              <lib>HALTE GARDERIE LES MAGNOLIAS</lib>
165
              <adresse>
166
                <num>0</num>
167
              </adresse>
168
              <typeCtrlPlace>N</typeCtrlPlace>
169
              <nbPlace>15</nbPlace>
170
              <nbPlaceBoy>0</nbPlaceBoy>
171
              <nbPlaceGirl>0</nbPlaceGirl>
172
            </placeList>
173
            <typeCtrlPlace>N</typeCtrlPlace>
174
            <nbPlace>15</nbPlace>
175
            <nbPlaceBoy>0</nbPlaceBoy>
176
            <nbPlaceGirl>0</nbPlaceGirl>
177
            <topCESU>O</topCESU>
178
          </unitPortailList>
179
          <unitPortailList>
180
            <idUnit>A10000006105</idUnit>
181
            <label>HALTE GARDERIE LES MAGNOLIAS - Occasionnels</label>
182
            <dateStart>2011-01-01T00:00:00+01:00</dateStart>
183
            <consoTarifList>
184
              <commune>X</commune>
185
              <tarif>
186
                <code>PE</code>
187
                <label>PETITE ENFANCE</label>
188
              </tarif>
189
              <conso>
190
                <code>ENF</code>
191
                <label>ENFANT</label>
192
              </conso>
193
            </consoTarifList>
194
            <calendarLetter>A</calendarLetter>
195
            <subscribePublication>N</subscribePublication>
196
            <numOrder>0</numOrder>
197
            <placeList>
198
              <id>A10000006103</id>
199
              <lib>HALTE GARDERIE LES MAGNOLIAS</lib>
200
              <adresse>
201
                <num>0</num>
202
              </adresse>
203
              <typeCtrlPlace>N</typeCtrlPlace>
204
              <nbPlace>0</nbPlace>
205
              <nbPlaceBoy>0</nbPlaceBoy>
206
              <nbPlaceGirl>0</nbPlaceGirl>
207
            </placeList>
208
            <typeCtrlPlace>N</typeCtrlPlace>
209
            <nbPlace>5</nbPlace>
210
            <nbPlaceBoy>0</nbPlaceBoy>
211
            <nbPlaceGirl>0</nbPlaceGirl>
212
            <topCESU>O</topCESU>
213
          </unitPortailList>
214
        </activityUnitPlacePortailList>
215
        <activityUnitPlacePortailList>
216
          <activityPortail>
217
            <idAct>A10003121692</idAct>
218
            <label>1 2020-2021 GARDERIE MATIN</label>
219
            <dateStart>2020-09-01T00:00:00+01:00</dateStart>
220
            <dateEnd>2021-07-06T00:00:00+01:00</dateEnd>
221
            <codeConso>ENF</codeConso>
222
            <schoolYear>2020</schoolYear>
223
            <calendarGeneration>
224
              <code>NOT_REQUIRED</code>
225
              <value>F</value>
226
            </calendarGeneration>
227
            <dateStartPubli>2018-07-01T15:12:18+01:00</dateStartPubli>
228
            <calendarMode>C</calendarMode>
229
            <activityType>
230
              <code>ACCMAT</code>
231
              <libelle>Accueil du matin</libelle>
232
              <natureSpec>
233
                <code>A</code>
234
                <libelle>Accueil P&#xE9;riscolaire</libelle>
235
              </natureSpec>
236
            </activityType>
237
            <weeklyCalendarActivityList>
238
              <yearCalendar>2020</yearCalendar>
239
              <weeklyCalendarStr>0010011</weeklyCalendarStr>
240
            </weeklyCalendarActivityList>
241
            <birthControl>N</birthControl>
242
            <waitIfComplete>N</waitIfComplete>
243
          </activityPortail>
244
          <openDayList>2020-12-14T00:00:00+01:00</openDayList>
245
          <openDayList>2020-12-15T00:00:00+01:00</openDayList>
246
          <openDayList>2020-12-17T00:00:00+01:00</openDayList>
247
          <openDayList>2020-12-18T00:00:00+01:00</openDayList>
248
          <unitPortailList>
249
            <idUnit>A10003121694</idUnit>
250
            <label>1 2020-2021 GARDERIE MATIN</label>
251
            <dateStart>2020-09-01T00:00:00+01:00</dateStart>
252
            <dateEnd>2021-07-06T00:00:00+01:00</dateEnd>
253
            <consoTarifList>
254
              <commune>X</commune>
255
              <tarif>
256
                <code>GPSMAT</code>
257
                <label>GPS MATIN</label>
258
              </tarif>
259
              <conso>
260
                <code>ENF</code>
261
                <label>ENFANT</label>
262
              </conso>
263
            </consoTarifList>
264
            <calendarLetter>X</calendarLetter>
265
            <subscribePublication>E</subscribePublication>
266
            <dateStartSubscribe>2017-09-01T00:00:00+01:00</dateStartSubscribe>
267
            <numOrder>1</numOrder>
268
            <placeList>
269
              <id>A10000000201</id>
270
              <lib>3 JEAN GIONO</lib>
271
              <adresse>
272
                <num>0</num>
273
              </adresse>
274
              <typeCtrlPlace>N</typeCtrlPlace>
275
              <nbPlace>0</nbPlace>
276
              <nbPlaceBoy>0</nbPlaceBoy>
277
              <nbPlaceGirl>0</nbPlaceGirl>
278
            </placeList>
279
            <placeList>
280
              <id>A10000000211</id>
281
              <lib>2 FRANCOIS FABIE</lib>
282
              <adresse>
283
                <num>0</num>
284
              </adresse>
285
              <typeCtrlPlace>N</typeCtrlPlace>
286
              <nbPlace>0</nbPlace>
287
              <nbPlaceBoy>0</nbPlaceBoy>
288
              <nbPlaceGirl>0</nbPlaceGirl>
289
            </placeList>
290
            <typeCtrlPlace>N</typeCtrlPlace>
291
            <nbPlace>0</nbPlace>
292
            <nbPlaceBoy>0</nbPlaceBoy>
293
            <nbPlaceGirl>0</nbPlaceGirl>
294
            <topCESU>O</topCESU>
295
          </unitPortailList>
296
        </activityUnitPlacePortailList>
297
        <activityUnitPlacePortailList>
298
          <activityPortail>
299
            <idAct>A10003123490</idAct>
300
            <label>2 2020-2021  RESTAURATION SCOLAIRE</label>
301
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
302
            <dateEnd>2021-07-03T00:00:00+01:00</dateEnd>
303
            <codeConso>ENF</codeConso>
304
            <schoolYear>2020</schoolYear>
305
            <calendarGeneration>
306
              <code>FORBIDDEN</code>
307
              <value>I</value>
308
            </calendarGeneration>
309
            <dateStartPubli>2017-07-01T15:23:09+01:00</dateStartPubli>
310
            <calendarMode>C</calendarMode>
311
            <activityType>
312
              <code>RESTSCOL</code>
313
              <libelle>Restauration scolaire</libelle>
314
              <natureSpec>
315
                <code>R</code>
316
                <libelle>Restauration Scolaire</libelle>
317
              </natureSpec>
318
            </activityType>
319
            <weeklyCalendarActivityList>
320
              <yearCalendar>2020</yearCalendar>
321
              <weeklyCalendarStr>0010011</weeklyCalendarStr>
322
            </weeklyCalendarActivityList>
323
            <birthControl>N</birthControl>
324
            <waitIfComplete>N</waitIfComplete>
325
          </activityPortail>
326
          <openDayList>2020-12-14T00:00:00+01:00</openDayList>
327
          <openDayList>2020-12-15T00:00:00+01:00</openDayList>
328
          <openDayList>2020-12-17T00:00:00+01:00</openDayList>
329
          <openDayList>2020-12-18T00:00:00+01:00</openDayList>
330
          <unitPortailList>
331
            <idUnit>A10003123492</idUnit>
332
            <label>2 2020-2021  RESTAURATION SCOLAIRE</label>
333
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
334
            <dateEnd>2021-07-03T00:00:00+01:00</dateEnd>
335
            <consoTarifList>
336
              <commune>X</commune>
337
              <tarif>
338
                <code>FAMACC</code>
339
                <label>FAMILLE D'ACCUEIL</label>
340
              </tarif>
341
              <conso>
342
                <code>ACCUE</code>
343
                <label>FAMILLE ACCUEIL</label>
344
              </conso>
345
            </consoTarifList>
346
            <consoTarifList>
347
              <commune>X</commune>
348
              <tarif>
349
                <code>PR</code>
350
                <label>PANIER REPAS</label>
351
              </tarif>
352
              <conso>
353
                <code>PR</code>
354
                <label>PANIER REPAS</label>
355
              </conso>
356
            </consoTarifList>
357
            <consoTarifList>
358
              <commune>X</commune>
359
              <tarif>
360
                <code>REST</code>
361
                <label>RESTAURATION SCOLAIRE</label>
362
              </tarif>
363
              <conso>
364
                <code>ENF</code>
365
                <label>ENFANT</label>
366
              </conso>
367
            </consoTarifList>
368
            <calendarLetter>X</calendarLetter>
369
            <subscribePublication>E</subscribePublication>
370
            <dateStartSubscribe>2017-05-01T00:00:00+01:00</dateStartSubscribe>
371
            <numOrder>2</numOrder>
372
            <placeList>
373
              <id>A10000000211</id>
374
              <lib>2 FRANCOIS FABIE</lib>
375
              <adresse>
376
                <num>0</num>
377
              </adresse>
378
              <schoolInfoList>
379
                <idSchool>A10000003597</idSchool>
380
                <schoolName>2  FRANCOIS FABIE</schoolName>
381
                <adress>
382
                  <street1>AVENUE ARISTIDE BRIAND</street1>
383
                  <idStreet>8301440048</idStreet>
384
                  <zipcode>83160</zipcode>
385
                  <town>LA VALETTE-DU-VAR</town>
386
                </adress>
387
                <headmaster> </headmaster>
388
              </schoolInfoList>
389
              <typeCtrlPlace>N</typeCtrlPlace>
390
              <nbPlace>0</nbPlace>
391
              <nbPlaceBoy>0</nbPlaceBoy>
392
              <nbPlaceGirl>0</nbPlaceGirl>
393
            </placeList>
394
            <typeCtrlPlace>N</typeCtrlPlace>
395
            <nbPlace>0</nbPlace>
396
            <nbPlaceBoy>0</nbPlaceBoy>
397
            <nbPlaceGirl>0</nbPlaceGirl>
398
            <topCESU>N</topCESU>
399
          </unitPortailList>
400
        </activityUnitPlacePortailList>
401
        <activityUnitPlacePortailList>
402
          <activityPortail>
403
            <idAct>A10003123507</idAct>
404
            <label>3 2020-2021 GARDERIE SOIR</label>
405
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
406
            <dateEnd>2021-07-03T00:00:00+01:00</dateEnd>
407
            <codeConso>ENF</codeConso>
408
            <schoolYear>2020</schoolYear>
409
            <calendarGeneration>
410
              <code>NOT_REQUIRED</code>
411
              <value>F</value>
412
            </calendarGeneration>
413
            <dateStartPubli>2018-07-01T15:11:47+01:00</dateStartPubli>
414
            <calendarMode>C</calendarMode>
415
            <activityType>
416
              <code>ACCSOIR</code>
417
              <libelle>Accueil du soir</libelle>
418
              <natureSpec>
419
                <code>A</code>
420
                <libelle>Accueil P&#xE9;riscolaire</libelle>
421
              </natureSpec>
422
            </activityType>
423
            <weeklyCalendarActivityList>
424
              <yearCalendar>2020</yearCalendar>
425
              <weeklyCalendarStr>0010011</weeklyCalendarStr>
426
            </weeklyCalendarActivityList>
427
            <birthControl>N</birthControl>
428
            <waitIfComplete>N</waitIfComplete>
429
          </activityPortail>
430
          <openDayList>2020-12-14T00:00:00+01:00</openDayList>
431
          <openDayList>2020-12-15T00:00:00+01:00</openDayList>
432
          <openDayList>2020-12-17T00:00:00+01:00</openDayList>
433
          <openDayList>2020-12-18T00:00:00+01:00</openDayList>
434
          <unitPortailList>
435
            <idUnit>A10003123509</idUnit>
436
            <label>3 2020-2021 GARDERIE SOIR</label>
437
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
438
            <dateEnd>2021-07-03T00:00:00+01:00</dateEnd>
439
            <consoTarifList>
440
              <commune>X</commune>
441
              <tarif>
442
                <code>GPSSOI</code>
443
                <label>GPS SOIR</label>
444
              </tarif>
445
              <conso>
446
                <code>ENF</code>
447
                <label>ENFANT</label>
448
              </conso>
449
            </consoTarifList>
450
            <calendarLetter>X</calendarLetter>
451
            <subscribePublication>E</subscribePublication>
452
            <dateStartSubscribe>2018-07-01T00:00:00+01:00</dateStartSubscribe>
453
            <numOrder>3</numOrder>
454
            <placeList>
455
              <id>A10000000201</id>
456
              <lib>3 JEAN GIONO</lib>
457
              <adresse>
458
                <num>0</num>
459
              </adresse>
460
              <typeCtrlPlace>N</typeCtrlPlace>
461
              <nbPlace>0</nbPlace>
462
              <nbPlaceBoy>0</nbPlaceBoy>
463
              <nbPlaceGirl>0</nbPlaceGirl>
464
            </placeList>
465
            <placeList>
466
              <id>A10000000211</id>
467
              <lib>2 FRANCOIS FABIE</lib>
468
              <adresse>
469
                <num>0</num>
470
              </adresse>
471
              <typeCtrlPlace>N</typeCtrlPlace>
472
              <nbPlace>0</nbPlace>
473
              <nbPlaceBoy>0</nbPlaceBoy>
474
              <nbPlaceGirl>0</nbPlaceGirl>
475
            </placeList>
476
            <typeCtrlPlace>N</typeCtrlPlace>
477
            <nbPlace>0</nbPlace>
478
            <nbPlaceBoy>0</nbPlaceBoy>
479
            <nbPlaceGirl>0</nbPlaceGirl>
480
            <topCESU>O</topCESU>
481
          </unitPortailList>
482
        </activityUnitPlacePortailList>
483
        <activityUnitPlacePortailList>
484
          <activityPortail>
485
            <idAct>A10003131850</idAct>
486
            <label>2020-2021 ALSH VACANCES PAGNOL (CAPA)</label>
487
            <dateStart>2020-07-01T00:00:00+01:00</dateStart>
488
            <dateEnd>2021-07-02T00:00:00+01:00</dateEnd>
489
            <codeConso>ENF</codeConso>
490
            <schoolYear>2020</schoolYear>
491
            <calendarGeneration>
492
              <code>NOT_REQUIRED</code>
493
              <value>F</value>
494
            </calendarGeneration>
495
            <dateStartPubli>2020-07-01T11:16:21+01:00</dateStartPubli>
496
            <dateEndPubli>2021-08-31T11:16:21+01:00</dateEndPubli>
497
            <calendarMode>N</calendarMode>
498
            <weeklyCalendarActivityList>
499
              <yearCalendar>2020</yearCalendar>
500
              <weeklyCalendarStr>0000011</weeklyCalendarStr>
501
            </weeklyCalendarActivityList>
502
            <birthControl>N</birthControl>
503
            <waitIfComplete>O</waitIfComplete>
504
          </activityPortail>
505
          <unitPortailList>
506
            <idUnit>A10003131861</idUnit>
507
            <label>HIVER 2EME SEMAINE</label>
508
            <dateStart>2021-02-28T00:00:00+01:00</dateStart>
509
            <dateEnd>2021-03-05T00:00:00+01:00</dateEnd>
510
            <consoTarifList>
511
              <commune>H</commune>
512
              <tarif>
513
                <code>ACCLOI</code>
514
                <label>ACCUEIL LOISIRS</label>
515
              </tarif>
516
              <conso>
517
                <code>ENF</code>
518
                <label>ENFANT</label>
519
              </conso>
520
            </consoTarifList>
521
            <consoTarifList>
522
              <commune>C</commune>
523
              <tarif>
524
                <code>ACCLOI</code>
525
                <label>ACCUEIL LOISIRS</label>
526
              </tarif>
527
              <conso>
528
                <code>ENF</code>
529
                <label>ENFANT</label>
530
              </conso>
531
            </consoTarifList>
532
            <calendarLetter>c</calendarLetter>
533
            <subscribePublication>E</subscribePublication>
534
            <dateStartSubscribe>2020-11-01T00:00:00+01:00</dateStartSubscribe>
535
            <dateEndSubscribe>2020-12-31T00:00:00+01:00</dateEndSubscribe>
536
            <numOrder>3</numOrder>
537
            <placeList>
538
              <id>A10000000212</id>
539
              <lib>ALSH PAGNOL</lib>
540
              <adresse>
541
                <num>0</num>
542
                <street1>PLACE MARCEL PAGNOL</street1>
543
                <zipcode>83160</zipcode>
544
                <town>LA VALETTE DU VAR</town>
545
              </adresse>
546
              <typeCtrlPlace>N</typeCtrlPlace>
547
              <nbPlace>0</nbPlace>
548
              <nbPlaceBoy>0</nbPlaceBoy>
549
              <nbPlaceGirl>0</nbPlaceGirl>
550
            </placeList>
551
            <placeList>
552
              <id>A10002132200</id>
553
              <lib>ALSH MISTRAL</lib>
554
              <adresse>
555
                <num>0</num>
556
                <zipcode>83160</zipcode>
557
                <town>LA VALETTE-DU-VAR</town>
558
              </adresse>
559
              <typeCtrlPlace>N</typeCtrlPlace>
560
              <nbPlace>0</nbPlace>
561
              <nbPlaceBoy>0</nbPlaceBoy>
562
              <nbPlaceGirl>0</nbPlaceGirl>
563
            </placeList>
564
            <typeCtrlPlace>N</typeCtrlPlace>
565
            <nbPlace>0</nbPlace>
566
            <nbPlaceBoy>0</nbPlaceBoy>
567
            <nbPlaceGirl>0</nbPlaceGirl>
568
            <topCESU>N</topCESU>
569
          </unitPortailList>
570
          <unitPortailList>
571
            <idUnit>A10003131879</idUnit>
572
            <label>TOUSSAINT 2EME SEMAINE</label>
573
            <dateStart>2020-10-26T00:00:00+01:00</dateStart>
574
            <dateEnd>2020-10-30T00:00:00+01:00</dateEnd>
575
            <consoTarifList>
576
              <commune>H</commune>
577
              <tarif>
578
                <code>ACCLOI</code>
579
                <label>ACCUEIL LOISIRS</label>
580
              </tarif>
581
              <conso>
582
                <code>ENF</code>
583
                <label>ENFANT</label>
584
              </conso>
585
            </consoTarifList>
586
            <consoTarifList>
587
              <commune>C</commune>
588
              <tarif>
589
                <code>ACCLOI</code>
590
                <label>ACCUEIL LOISIRS</label>
591
              </tarif>
592
              <conso>
593
                <code>ENF</code>
594
                <label>ENFANT</label>
595
              </conso>
596
            </consoTarifList>
597
            <calendarLetter>D</calendarLetter>
598
            <subscribePublication>E</subscribePublication>
599
            <dateStartSubscribe>2020-07-01T00:00:00+01:00</dateStartSubscribe>
600
            <dateEndSubscribe>2020-10-30T00:00:00+01:00</dateEndSubscribe>
601
            <numOrder>2</numOrder>
602
            <placeList>
603
              <id>A10000000212</id>
604
              <lib>ALSH PAGNOL</lib>
605
              <adresse>
606
                <num>0</num>
607
                <street1>PLACE MARCEL PAGNOL</street1>
608
                <zipcode>83160</zipcode>
609
                <town>LA VALETTE DU VAR</town>
610
              </adresse>
611
              <typeCtrlPlace>N</typeCtrlPlace>
612
              <nbPlace>0</nbPlace>
613
              <nbPlaceBoy>0</nbPlaceBoy>
614
              <nbPlaceGirl>0</nbPlaceGirl>
615
            </placeList>
616
            <placeList>
617
              <id>A10002132200</id>
618
              <lib>ALSH MISTRAL</lib>
619
              <adresse>
620
                <num>0</num>
621
                <zipcode>83160</zipcode>
622
                <town>LA VALETTE-DU-VAR</town>
623
              </adresse>
624
              <typeCtrlPlace>N</typeCtrlPlace>
625
              <nbPlace>0</nbPlace>
626
              <nbPlaceBoy>0</nbPlaceBoy>
627
              <nbPlaceGirl>0</nbPlaceGirl>
628
            </placeList>
629
            <typeCtrlPlace>N</typeCtrlPlace>
630
            <nbPlace>0</nbPlace>
631
            <nbPlaceBoy>0</nbPlaceBoy>
632
            <nbPlaceGirl>0</nbPlaceGirl>
633
            <topCESU>N</topCESU>
634
          </unitPortailList>
635
          <unitPortailList>
636
            <idUnit>A10003131882</idUnit>
637
            <label>TOUSSAINT 1 ERE SEMAINE</label>
638
            <dateStart>2020-10-19T00:00:00+01:00</dateStart>
639
            <dateEnd>2020-10-23T00:00:00+01:00</dateEnd>
640
            <consoTarifList>
641
              <commune>H</commune>
642
              <tarif>
643
                <code>ACCLOI</code>
644
                <label>ACCUEIL LOISIRS</label>
645
              </tarif>
646
              <conso>
647
                <code>ENF</code>
648
                <label>ENFANT</label>
649
              </conso>
650
            </consoTarifList>
651
            <consoTarifList>
652
              <commune>C</commune>
653
              <tarif>
654
                <code>ACCLOI</code>
655
                <label>ACCUEIL LOISIRS</label>
656
              </tarif>
657
              <conso>
658
                <code>ENF</code>
659
                <label>ENFANT</label>
660
              </conso>
661
            </consoTarifList>
662
            <calendarLetter>C</calendarLetter>
663
            <subscribePublication>E</subscribePublication>
664
            <dateStartSubscribe>2020-07-01T07:20:00+01:00</dateStartSubscribe>
665
            <dateEndSubscribe>2020-10-30T00:00:00+01:00</dateEndSubscribe>
666
            <numOrder>1</numOrder>
667
            <placeList>
668
              <id>A10000000212</id>
669
              <lib>ALSH PAGNOL</lib>
670
              <adresse>
671
                <num>0</num>
672
                <street1>PLACE MARCEL PAGNOL</street1>
673
                <zipcode>83160</zipcode>
674
                <town>LA VALETTE DU VAR</town>
675
              </adresse>
676
              <typeCtrlPlace>N</typeCtrlPlace>
677
              <nbPlace>0</nbPlace>
678
              <nbPlaceBoy>0</nbPlaceBoy>
679
              <nbPlaceGirl>0</nbPlaceGirl>
680
            </placeList>
681
            <placeList>
682
              <id>A10002132200</id>
683
              <lib>ALSH MISTRAL</lib>
684
              <adresse>
685
                <num>0</num>
686
                <zipcode>83160</zipcode>
687
                <town>LA VALETTE-DU-VAR</town>
688
              </adresse>
689
              <typeCtrlPlace>N</typeCtrlPlace>
690
              <nbPlace>0</nbPlace>
691
              <nbPlaceBoy>0</nbPlaceBoy>
692
              <nbPlaceGirl>0</nbPlaceGirl>
693
            </placeList>
694
            <typeCtrlPlace>N</typeCtrlPlace>
695
            <nbPlace>0</nbPlace>
696
            <nbPlaceBoy>0</nbPlaceBoy>
697
            <nbPlaceGirl>0</nbPlaceGirl>
698
            <topCESU>N</topCESU>
699
          </unitPortailList>
700
          <unitPortailList>
701
            <idUnit>A10003131897</idUnit>
702
            <label>2020-2021 ALSH VACANCES PAGNOL (CAPA)</label>
703
            <dateStart>2020-07-01T00:00:00+01:00</dateStart>
704
            <dateEnd>2021-07-02T00:00:00+01:00</dateEnd>
705
            <consoTarifList>
706
              <commune>H</commune>
707
              <tarif>
708
                <code>ACCLOI</code>
709
                <label>ACCUEIL LOISIRS</label>
710
              </tarif>
711
              <conso>
712
                <code>ENF</code>
713
                <label>ENFANT</label>
714
              </conso>
715
            </consoTarifList>
716
            <consoTarifList>
717
              <commune>C</commune>
718
              <tarif>
719
                <code>ACCLOI</code>
720
                <label>ACCUEIL LOISIRS</label>
721
              </tarif>
722
              <conso>
723
                <code>ENF</code>
724
                <label>ENFANT</label>
725
              </conso>
726
            </consoTarifList>
727
            <calendarLetter>X</calendarLetter>
728
            <subscribePublication>L</subscribePublication>
729
            <dateStartSubscribe>2020-06-01T00:00:00+01:00</dateStartSubscribe>
730
            <dateEndSubscribe>2020-08-31T00:00:00+01:00</dateEndSubscribe>
731
            <numOrder>0</numOrder>
732
            <placeList>
733
              <id>A10000000212</id>
734
              <lib>ALSH PAGNOL</lib>
735
              <adresse>
736
                <num>0</num>
737
                <street1>PLACE MARCEL PAGNOL</street1>
738
                <zipcode>83160</zipcode>
739
                <town>LA VALETTE DU VAR</town>
740
              </adresse>
741
              <typeCtrlPlace>N</typeCtrlPlace>
742
              <nbPlace>0</nbPlace>
743
              <nbPlaceBoy>0</nbPlaceBoy>
744
              <nbPlaceGirl>0</nbPlaceGirl>
745
            </placeList>
746
            <typeCtrlPlace>N</typeCtrlPlace>
747
            <nbPlace>0</nbPlace>
748
            <nbPlaceBoy>0</nbPlaceBoy>
749
            <nbPlaceGirl>0</nbPlaceGirl>
750
            <topCESU>O</topCESU>
751
          </unitPortailList>
752
          <unitPortailList>
753
            <idUnit>A10003131903</idUnit>
754
            <label>NOEL 2EME SEMAINE</label>
755
            <dateStart>2020-12-28T00:00:00+01:00</dateStart>
756
            <dateEnd>2020-12-31T00:00:00+01:00</dateEnd>
757
            <consoTarifList>
758
              <commune>H</commune>
759
              <tarif>
760
                <code>ACCLOI</code>
761
                <label>ACCUEIL LOISIRS</label>
762
              </tarif>
763
              <conso>
764
                <code>ENF</code>
765
                <label>ENFANT</label>
766
              </conso>
767
            </consoTarifList>
768
            <consoTarifList>
769
              <commune>C</commune>
770
              <tarif>
771
                <code>ACCLOI</code>
772
                <label>ACCUEIL LOISIRS</label>
773
              </tarif>
774
              <conso>
775
                <code>ENF</code>
776
                <label>ENFANT</label>
777
              </conso>
778
            </consoTarifList>
779
            <calendarLetter>B</calendarLetter>
780
            <subscribePublication>E</subscribePublication>
781
            <dateStartSubscribe>2020-11-01T00:00:00+01:00</dateStartSubscribe>
782
            <dateEndSubscribe>2020-12-31T00:00:00+01:00</dateEndSubscribe>
783
            <numOrder>4</numOrder>
784
            <placeList>
785
              <id>A10000000212</id>
786
              <lib>ALSH PAGNOL</lib>
787
              <adresse>
788
                <num>0</num>
789
                <street1>PLACE MARCEL PAGNOL</street1>
790
                <zipcode>83160</zipcode>
791
                <town>LA VALETTE DU VAR</town>
792
              </adresse>
793
              <typeCtrlPlace>N</typeCtrlPlace>
794
              <nbPlace>0</nbPlace>
795
              <nbPlaceBoy>0</nbPlaceBoy>
796
              <nbPlaceGirl>0</nbPlaceGirl>
797
            </placeList>
798
            <placeList>
799
              <id>A10002132200</id>
800
              <lib>ALSH MISTRAL</lib>
801
              <adresse>
802
                <num>0</num>
803
                <zipcode>83160</zipcode>
804
                <town>LA VALETTE-DU-VAR</town>
805
              </adresse>
806
              <typeCtrlPlace>N</typeCtrlPlace>
807
              <nbPlace>0</nbPlace>
808
              <nbPlaceBoy>0</nbPlaceBoy>
809
              <nbPlaceGirl>0</nbPlaceGirl>
810
            </placeList>
811
            <typeCtrlPlace>N</typeCtrlPlace>
812
            <nbPlace>0</nbPlace>
813
            <nbPlaceBoy>0</nbPlaceBoy>
814
            <nbPlaceGirl>0</nbPlaceGirl>
815
            <topCESU>O</topCESU>
816
          </unitPortailList>
817
          <unitPortailList>
818
            <idUnit>A10003131909</idUnit>
819
            <label>NOEL 1ERE SEMAINE</label>
820
            <dateStart>2020-12-21T00:00:00+01:00</dateStart>
821
            <dateEnd>2020-12-24T00:00:00+01:00</dateEnd>
822
            <consoTarifList>
823
              <commune>H</commune>
824
              <tarif>
825
                <code>ACCLOI</code>
826
                <label>ACCUEIL LOISIRS</label>
827
              </tarif>
828
              <conso>
829
                <code>ENF</code>
830
                <label>ENFANT</label>
831
              </conso>
832
            </consoTarifList>
833
            <consoTarifList>
834
              <commune>C</commune>
835
              <tarif>
836
                <code>ACCLOI</code>
837
                <label>ACCUEIL LOISIRS</label>
838
              </tarif>
839
              <conso>
840
                <code>ENF</code>
841
                <label>ENFANT</label>
842
              </conso>
843
            </consoTarifList>
844
            <calendarLetter>J</calendarLetter>
845
            <subscribePublication>E</subscribePublication>
846
            <dateStartSubscribe>2020-11-01T00:00:00+01:00</dateStartSubscribe>
847
            <dateEndSubscribe>2020-12-31T00:00:00+01:00</dateEndSubscribe>
848
            <numOrder>3</numOrder>
849
            <placeList>
850
              <id>A10000000212</id>
851
              <lib>ALSH PAGNOL</lib>
852
              <adresse>
853
                <num>0</num>
854
                <street1>PLACE MARCEL PAGNOL</street1>
855
                <zipcode>83160</zipcode>
856
                <town>LA VALETTE DU VAR</town>
857
              </adresse>
858
              <typeCtrlPlace>N</typeCtrlPlace>
859
              <nbPlace>0</nbPlace>
860
              <nbPlaceBoy>0</nbPlaceBoy>
861
              <nbPlaceGirl>0</nbPlaceGirl>
862
            </placeList>
863
            <placeList>
864
              <id>A10002132200</id>
865
              <lib>ALSH MISTRAL</lib>
866
              <adresse>
867
                <num>0</num>
868
                <zipcode>83160</zipcode>
869
                <town>LA VALETTE-DU-VAR</town>
870
              </adresse>
871
              <typeCtrlPlace>N</typeCtrlPlace>
872
              <nbPlace>0</nbPlace>
873
              <nbPlaceBoy>0</nbPlaceBoy>
874
              <nbPlaceGirl>0</nbPlaceGirl>
875
            </placeList>
876
            <typeCtrlPlace>N</typeCtrlPlace>
877
            <nbPlace>0</nbPlace>
878
            <nbPlaceBoy>0</nbPlaceBoy>
879
            <nbPlaceGirl>0</nbPlaceGirl>
880
            <topCESU>N</topCESU>
881
          </unitPortailList>
882
        </activityUnitPlacePortailList>
883
        <activityUnitPlacePortailList>
884
          <activityPortail>
885
            <idAct>A10003132030</idAct>
886
            <label>2020-2021 CENTRE DE LOISIRS MERCREDI</label>
887
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
888
            <dateEnd>2021-07-03T00:00:00+01:00</dateEnd>
889
            <codeConso>ENF</codeConso>
890
            <schoolYear>2020</schoolYear>
891
            <calendarGeneration>
892
              <code>NOT_REQUIRED</code>
893
              <value>F</value>
894
            </calendarGeneration>
895
            <dateStartPubli>2020-07-01T10:51:07+01:00</dateStartPubli>
896
            <calendarMode>C</calendarMode>
897
            <activityType>
898
              <code>LOIVAC</code>
899
              <libelle>(Loisirs Vacances)</libelle>
900
              <natureSpec>
901
                <code>L</code>
902
                <libelle>Loisirs/Vacances</libelle>
903
              </natureSpec>
904
            </activityType>
905
            <weeklyCalendarActivityList>
906
              <yearCalendar>2020</yearCalendar>
907
              <weeklyCalendarStr>1101111</weeklyCalendarStr>
908
            </weeklyCalendarActivityList>
909
            <birthControl>N</birthControl>
910
            <waitIfComplete>N</waitIfComplete>
911
          </activityPortail>
912
          <openDayList>2020-12-16T00:00:00+01:00</openDayList>
913
          <unitPortailList>
914
            <idUnit>A10003132032</idUnit>
915
            <label>2020-2021 CENTRE DE LOISIRS MERCREDI</label>
916
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
917
            <dateEnd>2021-07-03T00:00:00+01:00</dateEnd>
918
            <consoTarifList>
919
              <commune>X</commune>
920
              <tarif>
921
                <code>ACCLOI</code>
922
                <label>ACCUEIL LOISIRS</label>
923
              </tarif>
924
              <conso>
925
                <code>ENF</code>
926
                <label>ENFANT</label>
927
              </conso>
928
            </consoTarifList>
929
            <calendarLetter>X</calendarLetter>
930
            <subscribePublication>N</subscribePublication>
931
            <dateStartSubscribe>2019-05-01T00:00:00+01:00</dateStartSubscribe>
932
            <numOrder>0</numOrder>
933
            <placeList>
934
              <id>A10000000212</id>
935
              <lib>ALSH PAGNOL</lib>
936
              <adresse>
937
                <num>0</num>
938
                <street1>PLACE MARCEL PAGNOL</street1>
939
                <zipcode>83160</zipcode>
940
                <town>LA VALETTE DU VAR</town>
941
              </adresse>
942
              <typeCtrlPlace>N</typeCtrlPlace>
943
              <nbPlace>0</nbPlace>
944
              <nbPlaceBoy>0</nbPlaceBoy>
945
              <nbPlaceGirl>0</nbPlaceGirl>
946
            </placeList>
947
            <typeCtrlPlace>N</typeCtrlPlace>
948
            <nbPlace>0</nbPlace>
949
            <nbPlaceBoy>0</nbPlaceBoy>
950
            <nbPlaceGirl>0</nbPlaceGirl>
951
            <topCESU>O</topCESU>
952
          </unitPortailList>
953
          <unitPortailList>
954
            <idUnit>A10003132034</idUnit>
955
            <label>JOURNEE</label>
956
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
957
            <dateEnd>2021-07-03T00:00:00+01:00</dateEnd>
958
            <consoTarifList>
959
              <commune>X</commune>
960
              <tarif>
961
                <code>ACCLOI</code>
962
                <label>ACCUEIL LOISIRS</label>
963
              </tarif>
964
              <conso>
965
                <code>ENF</code>
966
                <label>ENFANT</label>
967
              </conso>
968
            </consoTarifList>
969
            <calendarLetter>A</calendarLetter>
970
            <subscribePublication>E</subscribePublication>
971
            <dateStartSubscribe>2020-07-01T00:00:00+01:00</dateStartSubscribe>
972
            <numOrder>4</numOrder>
973
            <placeList>
974
              <id>A10000000212</id>
975
              <lib>ALSH PAGNOL</lib>
976
              <adresse>
977
                <num>0</num>
978
                <street1>PLACE MARCEL PAGNOL</street1>
979
                <zipcode>83160</zipcode>
980
                <town>LA VALETTE DU VAR</town>
981
              </adresse>
982
              <typeCtrlPlace>N</typeCtrlPlace>
983
              <nbPlace>0</nbPlace>
984
              <nbPlaceBoy>0</nbPlaceBoy>
985
              <nbPlaceGirl>0</nbPlaceGirl>
986
            </placeList>
987
            <typeCtrlPlace>C</typeCtrlPlace>
988
            <nbPlace>0</nbPlace>
989
            <nbPlaceBoy>0</nbPlaceBoy>
990
            <nbPlaceGirl>0</nbPlaceGirl>
991
            <topCESU>N</topCESU>
992
          </unitPortailList>
993
          <unitPortailList>
994
            <idUnit>A10003132036</idUnit>
995
            <label>MATIN</label>
996
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
997
            <dateEnd>2021-07-03T00:00:00+01:00</dateEnd>
998
            <consoTarifList>
999
              <commune>X</commune>
1000
              <tarif>
1001
                <code>ACCLOI</code>
1002
                <label>ACCUEIL LOISIRS</label>
1003
              </tarif>
1004
              <conso>
1005
                <code>ENF</code>
1006
                <label>ENFANT</label>
1007
              </conso>
1008
            </consoTarifList>
1009
            <calendarLetter>B</calendarLetter>
1010
            <subscribePublication>E</subscribePublication>
1011
            <dateStartSubscribe>2020-07-01T00:00:00+01:00</dateStartSubscribe>
1012
            <numOrder>1</numOrder>
1013
            <placeList>
1014
              <id>A10000000212</id>
1015
              <lib>ALSH PAGNOL</lib>
1016
              <adresse>
1017
                <num>0</num>
1018
                <street1>PLACE MARCEL PAGNOL</street1>
1019
                <zipcode>83160</zipcode>
1020
                <town>LA VALETTE DU VAR</town>
1021
              </adresse>
1022
              <typeCtrlPlace>N</typeCtrlPlace>
1023
              <nbPlace>0</nbPlace>
1024
              <nbPlaceBoy>0</nbPlaceBoy>
1025
              <nbPlaceGirl>0</nbPlaceGirl>
1026
            </placeList>
1027
            <typeCtrlPlace>N</typeCtrlPlace>
1028
            <nbPlace>0</nbPlace>
1029
            <nbPlaceBoy>0</nbPlaceBoy>
1030
            <nbPlaceGirl>0</nbPlaceGirl>
1031
            <topCESU>N</topCESU>
1032
          </unitPortailList>
1033
          <unitPortailList>
1034
            <idUnit>A10003132038</idUnit>
1035
            <label>MATIN ET REPAS</label>
1036
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
1037
            <dateEnd>2021-07-03T00:00:00+01:00</dateEnd>
1038
            <consoTarifList>
1039
              <commune>X</commune>
1040
              <tarif>
1041
                <code>ACCLOI</code>
1042
                <label>ACCUEIL LOISIRS</label>
1043
              </tarif>
1044
              <conso>
1045
                <code>ENF</code>
1046
                <label>ENFANT</label>
1047
              </conso>
1048
            </consoTarifList>
1049
            <calendarLetter>C</calendarLetter>
1050
            <subscribePublication>E</subscribePublication>
1051
            <dateStartSubscribe>2020-07-01T00:00:00+01:00</dateStartSubscribe>
1052
            <numOrder>2</numOrder>
1053
            <placeList>
1054
              <id>A10000000212</id>
1055
              <lib>ALSH PAGNOL</lib>
1056
              <adresse>
1057
                <num>0</num>
1058
                <street1>PLACE MARCEL PAGNOL</street1>
1059
                <zipcode>83160</zipcode>
1060
                <town>LA VALETTE DU VAR</town>
1061
              </adresse>
1062
              <typeCtrlPlace>N</typeCtrlPlace>
1063
              <nbPlace>0</nbPlace>
1064
              <nbPlaceBoy>0</nbPlaceBoy>
1065
              <nbPlaceGirl>0</nbPlaceGirl>
1066
            </placeList>
1067
            <typeCtrlPlace>N</typeCtrlPlace>
1068
            <nbPlace>0</nbPlace>
1069
            <nbPlaceBoy>0</nbPlaceBoy>
1070
            <nbPlaceGirl>0</nbPlaceGirl>
1071
            <topCESU>N</topCESU>
1072
          </unitPortailList>
1073
          <unitPortailList>
1074
            <idUnit>A10003132040</idUnit>
1075
            <label>APRES MIDI</label>
1076
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
1077
            <dateEnd>2021-07-03T00:00:00+01:00</dateEnd>
1078
            <consoTarifList>
1079
              <commune>X</commune>
1080
              <tarif>
1081
                <code>ACCLOI</code>
1082
                <label>ACCUEIL LOISIRS</label>
1083
              </tarif>
1084
              <conso>
1085
                <code>ENF</code>
1086
                <label>ENFANT</label>
1087
              </conso>
1088
            </consoTarifList>
1089
            <calendarLetter>D</calendarLetter>
1090
            <subscribePublication>E</subscribePublication>
1091
            <dateStartSubscribe>2020-07-01T00:00:00+01:00</dateStartSubscribe>
1092
            <numOrder>3</numOrder>
1093
            <placeList>
1094
              <id>A10000000212</id>
1095
              <lib>ALSH PAGNOL</lib>
1096
              <adresse>
1097
                <num>0</num>
1098
                <street1>PLACE MARCEL PAGNOL</street1>
1099
                <zipcode>83160</zipcode>
1100
                <town>LA VALETTE DU VAR</town>
1101
              </adresse>
1102
              <typeCtrlPlace>N</typeCtrlPlace>
1103
              <nbPlace>0</nbPlace>
1104
              <nbPlaceBoy>0</nbPlaceBoy>
1105
              <nbPlaceGirl>0</nbPlaceGirl>
1106
            </placeList>
1107
            <typeCtrlPlace>N</typeCtrlPlace>
1108
            <nbPlace>0</nbPlace>
1109
            <nbPlaceBoy>0</nbPlaceBoy>
1110
            <nbPlaceGirl>0</nbPlaceGirl>
1111
            <topCESU>N</topCESU>
1112
          </unitPortailList>
1113
        </activityUnitPlacePortailList>
1114
        <activityUnitPlacePortailList>
1115
          <activityPortail>
1116
            <idAct>A10003132090</idAct>
1117
            <label>COURS DE DANSE</label>
1118
            <dateStart>2020-01-01T00:00:00+01:00</dateStart>
1119
            <schoolYear>2020</schoolYear>
1120
            <calendarGeneration>
1121
              <code>FORBIDDEN</code>
1122
              <value>I</value>
1123
            </calendarGeneration>
1124
            <dateStartPubli>2020-07-01T10:43:16+01:00</dateStartPubli>
1125
            <calendarMode>N</calendarMode>
1126
            <activityType>
1127
              <code>LOIVAC</code>
1128
              <libelle>(Loisirs Vacances)</libelle>
1129
              <natureSpec>
1130
                <code>L</code>
1131
                <libelle>Loisirs/Vacances</libelle>
1132
              </natureSpec>
1133
            </activityType>
1134
            <weeklyCalendarActivityList>
1135
              <yearCalendar>2020</yearCalendar>
1136
              <weeklyCalendarStr>0000011</weeklyCalendarStr>
1137
            </weeklyCalendarActivityList>
1138
            <birthControl>N</birthControl>
1139
            <waitIfComplete>N</waitIfComplete>
1140
          </activityPortail>
1141
          <openDayList>2020-12-14T00:00:00+01:00</openDayList>
1142
          <openDayList>2020-12-15T00:00:00+01:00</openDayList>
1143
          <openDayList>2020-12-16T00:00:00+01:00</openDayList>
1144
          <openDayList>2020-12-17T00:00:00+01:00</openDayList>
1145
          <openDayList>2020-12-18T00:00:00+01:00</openDayList>
1146
          <unitPortailList>
1147
            <idUnit>A10003132091</idUnit>
1148
            <label>COURS DE DANSE</label>
1149
            <dateStart>2020-01-01T00:00:00+01:00</dateStart>
1150
            <calendarLetter>X</calendarLetter>
1151
            <subscribePublication>E</subscribePublication>
1152
            <dateStartSubscribe>2020-07-01T00:00:00+01:00</dateStartSubscribe>
1153
            <numOrder>0</numOrder>
1154
            <placeList>
1155
              <id>A10000000212</id>
1156
              <lib>ALSH PAGNOL</lib>
1157
              <adresse>
1158
                <num>0</num>
1159
                <street1>PLACE MARCEL PAGNOL</street1>
1160
                <zipcode>83160</zipcode>
1161
                <town>LA VALETTE DU VAR</town>
1162
              </adresse>
1163
              <typeCtrlPlace>N</typeCtrlPlace>
1164
              <nbPlace>0</nbPlace>
1165
              <nbPlaceBoy>0</nbPlaceBoy>
1166
              <nbPlaceGirl>0</nbPlaceGirl>
1167
            </placeList>
1168
            <typeCtrlPlace>N</typeCtrlPlace>
1169
            <nbPlace>0</nbPlace>
1170
            <nbPlaceBoy>0</nbPlaceBoy>
1171
            <nbPlaceGirl>0</nbPlaceGirl>
1172
            <topCESU>N</topCESU>
1173
          </unitPortailList>
1174
        </activityUnitPlacePortailList>
1175
        <activityUnitPlacePortailList>
1176
          <activityPortail>
1177
            <idAct>A10003132150</idAct>
1178
            <label>LASERQUEST</label>
1179
            <dateStart>2020-01-01T00:00:00+01:00</dateStart>
1180
            <schoolYear>2020</schoolYear>
1181
            <calendarGeneration>
1182
              <code>FORBIDDEN</code>
1183
              <value>I</value>
1184
            </calendarGeneration>
1185
            <dateStartPubli>2020-07-01T10:43:16+01:00</dateStartPubli>
1186
            <calendarMode>N</calendarMode>
1187
            <activityType>
1188
              <code>LOIVAC</code>
1189
              <libelle>(Loisirs Vacances)</libelle>
1190
              <natureSpec>
1191
                <code>L</code>
1192
                <libelle>Loisirs/Vacances</libelle>
1193
              </natureSpec>
1194
            </activityType>
1195
            <birthControl>N</birthControl>
1196
            <waitIfComplete>N</waitIfComplete>
1197
          </activityPortail>
1198
          <unitPortailList>
1199
            <idUnit>A10003132152</idUnit>
1200
            <label>LASERQUEST</label>
1201
            <dateStart>2020-01-01T00:00:00+01:00</dateStart>
1202
            <calendarLetter>X</calendarLetter>
1203
            <subscribePublication>E</subscribePublication>
1204
            <dateStartSubscribe>2020-07-01T00:00:00+01:00</dateStartSubscribe>
1205
            <numOrder>1</numOrder>
1206
            <placeList>
1207
              <id>A10000000212</id>
1208
              <lib>ALSH PAGNOL</lib>
1209
              <adresse>
1210
                <num>0</num>
1211
                <street1>PLACE MARCEL PAGNOL</street1>
1212
                <zipcode>83160</zipcode>
1213
                <town>LA VALETTE DU VAR</town>
1214
              </adresse>
1215
              <typeCtrlPlace>N</typeCtrlPlace>
1216
              <nbPlace>0</nbPlace>
1217
              <nbPlaceBoy>0</nbPlaceBoy>
1218
              <nbPlaceGirl>0</nbPlaceGirl>
1219
            </placeList>
1220
            <typeCtrlPlace>N</typeCtrlPlace>
1221
            <nbPlace>0</nbPlace>
1222
            <nbPlaceBoy>0</nbPlaceBoy>
1223
            <nbPlaceGirl>0</nbPlaceGirl>
1224
            <topCESU>N</topCESU>
1225
          </unitPortailList>
1226
        </activityUnitPlacePortailList>
1227
        <activityUnitPlacePortailList>
1228
          <activityPortail>
1229
            <idAct>A10003132271</idAct>
1230
            <label>EQUITATION</label>
1231
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
1232
            <schoolYear>2020</schoolYear>
1233
            <calendarGeneration>
1234
              <code>FORBIDDEN</code>
1235
              <value>I</value>
1236
            </calendarGeneration>
1237
            <dateStartPubli>2020-07-01T10:43:16+01:00</dateStartPubli>
1238
            <calendarMode>N</calendarMode>
1239
            <activityType>
1240
              <code>LOIVAC</code>
1241
              <libelle>(Loisirs Vacances)</libelle>
1242
              <natureSpec>
1243
                <code>L</code>
1244
                <libelle>Loisirs/Vacances</libelle>
1245
              </natureSpec>
1246
            </activityType>
1247
            <birthControl>B</birthControl>
1248
            <waitIfComplete>N</waitIfComplete>
1249
          </activityPortail>
1250
          <unitPortailList>
1251
            <idUnit>A10003132273</idUnit>
1252
            <label>EQUITATION</label>
1253
            <dateStart>2020-09-02T00:00:00+01:00</dateStart>
1254
            <calendarLetter>X</calendarLetter>
1255
            <subscribePublication>E</subscribePublication>
1256
            <dateStartSubscribe>2020-07-01T00:00:00+01:00</dateStartSubscribe>
1257
            <numOrder>0</numOrder>
1258
            <placeList>
1259
              <id>A10000000212</id>
1260
              <lib>ALSH PAGNOL</lib>
1261
              <adresse>
1262
                <num>0</num>
1263
                <street1>PLACE MARCEL PAGNOL</street1>
1264
                <zipcode>83160</zipcode>
1265
                <town>LA VALETTE DU VAR</town>
1266
              </adresse>
1267
              <typeCtrlPlace>N</typeCtrlPlace>
1268
              <nbPlace>0</nbPlace>
1269
              <nbPlaceBoy>0</nbPlaceBoy>
1270
              <nbPlaceGirl>0</nbPlaceGirl>
1271
            </placeList>
1272
            <birthDateStart>1970-01-01T00:00:00+01:00</birthDateStart>
1273
            <birthDateEnd>2014-12-31T00:00:00+01:00</birthDateEnd>
1274
            <typeCtrlPlace>N</typeCtrlPlace>
1275
            <nbPlace>0</nbPlace>
1276
            <nbPlaceBoy>0</nbPlaceBoy>
1277
            <nbPlaceGirl>0</nbPlaceGirl>
1278
            <topCESU>N</topCESU>
1279
          </unitPortailList>
1280
        </activityUnitPlacePortailList>
1281
        <activityUnitPlacePortailList>
1282
          <activityPortail>
1283
            <idAct>A10003132293</idAct>
1284
            <label>ATELIER D'EXPRESSION THEATRALE</label>
1285
            <dateStart>2020-10-05T00:00:00+01:00</dateStart>
1286
            <dateEnd>2020-12-15T00:00:00+01:00</dateEnd>
1287
            <codeConso>SEN</codeConso>
1288
            <schoolYear>2020</schoolYear>
1289
            <calendarGeneration>
1290
              <code>FORBIDDEN</code>
1291
              <value>I</value>
1292
            </calendarGeneration>
1293
            <dateStartPubli>2020-07-01T10:43:16+01:00</dateStartPubli>
1294
            <calendarMode>N</calendarMode>
1295
            <activityType>
1296
              <code>LOIVAC</code>
1297
              <libelle>(Loisirs Vacances)</libelle>
1298
              <natureSpec>
1299
                <code>L</code>
1300
                <libelle>Loisirs/Vacances</libelle>
1301
              </natureSpec>
1302
            </activityType>
1303
            <weeklyCalendarActivityList>
1304
              <yearCalendar>2020</yearCalendar>
1305
              <weeklyCalendarStr>0010011</weeklyCalendarStr>
1306
            </weeklyCalendarActivityList>
1307
            <birthControl>N</birthControl>
1308
            <waitIfComplete>N</waitIfComplete>
1309
          </activityPortail>
1310
          <openDayList>2020-12-14T00:00:00+01:00</openDayList>
1311
          <unitPortailList>
1312
            <idUnit>A10003132295</idUnit>
1313
            <label>ATELIER D'EXPRESSION THEATRALE</label>
1314
            <dateStart>2020-10-05T00:00:00+01:00</dateStart>
1315
            <dateEnd>2020-12-15T00:00:00+01:00</dateEnd>
1316
            <consoTarifList>
1317
              <commune>X</commune>
1318
              <tarif>
1319
                <code>BOXE</code>
1320
                <label>BOXE</label>
1321
              </tarif>
1322
              <conso>
1323
                <code>SEN</code>
1324
                <label>SENIOR</label>
1325
              </conso>
1326
            </consoTarifList>
1327
            <calendarLetter>X</calendarLetter>
1328
            <subscribePublication>E</subscribePublication>
1329
            <dateStartSubscribe>2020-07-01T00:00:00+01:00</dateStartSubscribe>
1330
            <numOrder>0</numOrder>
1331
            <placeList>
1332
              <id>A10000000212</id>
1333
              <lib>ALSH PAGNOL</lib>
1334
              <adresse>
1335
                <num>0</num>
1336
                <street1>PLACE MARCEL PAGNOL</street1>
1337
                <zipcode>83160</zipcode>
1338
                <town>LA VALETTE DU VAR</town>
1339
              </adresse>
1340
              <typeCtrlPlace>N</typeCtrlPlace>
1341
              <nbPlace>0</nbPlace>
1342
              <nbPlaceBoy>0</nbPlaceBoy>
1343
              <nbPlaceGirl>0</nbPlaceGirl>
1344
            </placeList>
1345
            <typeCtrlPlace>N</typeCtrlPlace>
1346
            <nbPlace>0</nbPlace>
1347
            <nbPlaceBoy>0</nbPlaceBoy>
1348
            <nbPlaceGirl>0</nbPlaceGirl>
1349
            <topCESU>N</topCESU>
1350
          </unitPortailList>
1351
        </activityUnitPlacePortailList>
1352
      </ReadActivityPortailListResultBean>
1353
    </ns1:readActivityListResponse>
1354
  </soap:Body>
1355
</soap:Envelope>
tests/data/maelis/child_planning_readChildMonthPlanningResponse.xml
1
<?xml version="1.0"?>
2
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
3
  <soap:Body>
4
    <ns1:readChildMonthPlanningResponse xmlns:ns1="activity.ws.maelis.sigec.com">
5
      <ResultCalendarList>
6
        <person>
7
          <idMaelis>W20885</idMaelis>
8
          <num>21293</num>
9
          <lastname>JOHANN</lastname>
10
          <firstname>AURELIE</firstname>
11
        </person>
12
        <calendList>
13
          <unit>
14
            <id>A10003121694</id>
15
            <idActivity>A10003121692</idActivity>
16
            <libelle>1 2020-2021 GARDERIE MATIN</libelle>
17
            <motif>X</motif>
18
          </unit>
19
          <listDays>
20
            <datePlanning>2020-12-01T02:50:44.508+01:00</datePlanning>
21
            <dayType>
22
              <code>DAY</code>
23
            </dayType>
24
          </listDays>
25
          <listDays>
26
            <datePlanning>2020-12-03T02:50:44.508+01:00</datePlanning>
27
            <dayType>
28
              <code>DAY</code>
29
            </dayType>
30
          </listDays>
31
          <listDays>
32
            <datePlanning>2020-12-04T02:50:44.508+01:00</datePlanning>
33
            <dayType>
34
              <code>DAY</code>
35
            </dayType>
36
          </listDays>
37
          <listDays>
38
            <datePlanning>2020-12-07T02:50:44.508+01:00</datePlanning>
39
            <dayType>
40
              <code>DAY</code>
41
            </dayType>
42
          </listDays>
43
          <listDays>
44
            <datePlanning>2020-12-08T02:50:44.508+01:00</datePlanning>
45
            <dayType>
46
              <code>DAY</code>
47
            </dayType>
48
          </listDays>
49
          <listDays>
50
            <datePlanning>2020-12-10T02:50:44.508+01:00</datePlanning>
51
            <dayType>
52
              <code>DAY</code>
53
            </dayType>
54
          </listDays>
55
          <listDays>
56
            <datePlanning>2020-12-11T02:50:44.508+01:00</datePlanning>
57
            <dayType>
58
              <code>DAY</code>
59
            </dayType>
60
          </listDays>
61
          <listDays>
62
            <datePlanning>2020-12-14T02:50:44.508+01:00</datePlanning>
63
            <dayType>
64
              <code>DAY</code>
65
            </dayType>
66
          </listDays>
67
          <listDays>
68
            <datePlanning>2020-12-15T02:50:44.508+01:00</datePlanning>
69
            <dayType>
70
              <code>DAY</code>
71
            </dayType>
72
          </listDays>
73
          <listDays>
74
            <datePlanning>2020-12-17T02:50:44.508+01:00</datePlanning>
75
            <dayType>
76
              <code>DAY</code>
77
            </dayType>
78
          </listDays>
79
          <listDays>
80
            <datePlanning>2020-12-18T02:50:44.508+01:00</datePlanning>
81
            <dayType>
82
              <code>DAY</code>
83
            </dayType>
84
          </listDays>
85
        </calendList>
86
        <calendList>
87
          <unit>
88
            <id>A10003123492</id>
89
            <idActivity>A10003123490</idActivity>
90
            <libelle>2 2020-2021  RESTAURATION SCOLAIRE</libelle>
91
            <motif>X</motif>
92
          </unit>
93
          <listDays>
94
            <datePlanning>2020-12-01T02:50:44.508+01:00</datePlanning>
95
            <dayType>
96
              <code>DAY</code>
97
            </dayType>
98
          </listDays>
99
          <listDays>
100
            <datePlanning>2020-12-03T02:50:44.508+01:00</datePlanning>
101
            <dayType>
102
              <code>DAY</code>
103
            </dayType>
104
          </listDays>
105
          <listDays>
106
            <datePlanning>2020-12-04T02:50:44.508+01:00</datePlanning>
107
            <dayType>
108
              <code>DAY</code>
109
            </dayType>
110
          </listDays>
111
          <listDays>
112
            <datePlanning>2020-12-07T02:50:44.508+01:00</datePlanning>
113
            <dayType>
114
              <code>DAY</code>
115
            </dayType>
116
          </listDays>
117
          <listDays>
118
            <datePlanning>2020-12-08T02:50:44.508+01:00</datePlanning>
119
            <dayType>
120
              <code>DAY</code>
121
            </dayType>
122
          </listDays>
123
          <listDays>
124
            <datePlanning>2020-12-10T02:50:44.508+01:00</datePlanning>
125
            <dayType>
126
              <code>DAY</code>
127
            </dayType>
128
          </listDays>
129
          <listDays>
130
            <datePlanning>2020-12-11T02:50:44.508+01:00</datePlanning>
131
            <dayType>
132
              <code>DAY</code>
133
            </dayType>
134
          </listDays>
135
          <listDays>
136
            <datePlanning>2020-12-14T02:50:44.508+01:00</datePlanning>
137
            <dayType>
138
              <code>DAY</code>
139
            </dayType>
140
          </listDays>
141
          <listDays>
142
            <datePlanning>2020-12-15T02:50:44.508+01:00</datePlanning>
143
            <dayType>
144
              <code>DAY</code>
145
            </dayType>
146
          </listDays>
147
          <listDays>
148
            <datePlanning>2020-12-17T02:50:44.508+01:00</datePlanning>
149
            <dayType>
150
              <code>DAY</code>
151
            </dayType>
152
          </listDays>
153
          <listDays>
154
            <datePlanning>2020-12-18T02:50:44.508+01:00</datePlanning>
155
            <dayType>
156
              <code>DAY</code>
157
            </dayType>
158
          </listDays>
159
        </calendList>
160
        <calendList>
161
          <unit>
162
            <id>A10003132032</id>
163
            <idActivity>A10003132030</idActivity>
164
            <libelle>2020-2021 CENTRE DE LOISIRS MERCREDI</libelle>
165
            <motif>X</motif>
166
          </unit>
167
          <listDays>
168
            <datePlanning>2020-12-02T02:50:44.508+01:00</datePlanning>
169
            <dayType>
170
              <code>DAY</code>
171
            </dayType>
172
          </listDays>
173
          <listDays>
174
            <datePlanning>2020-12-09T02:50:44.508+01:00</datePlanning>
175
            <dayType>
176
              <code>DAY</code>
177
            </dayType>
178
          </listDays>
179
          <listDays>
180
            <datePlanning>2020-12-16T02:50:44.508+01:00</datePlanning>
181
            <dayType>
182
              <code>DAY</code>
183
            </dayType>
184
          </listDays>
185
        </calendList>
186
        <calendList>
187
          <unit>
188
            <id>A10003132038</id>
189
            <idActivity>A10003132030</idActivity>
190
            <libelle>MATIN ET REPAS</libelle>
191
            <motif>C</motif>
192
          </unit>
193
          <listDays>
194
            <datePlanning>2020-12-23T02:50:44.508+01:00</datePlanning>
195
            <dayType>
196
              <code>DAY</code>
197
            </dayType>
198
          </listDays>
199
          <listDays>
200
            <datePlanning>2020-12-25T02:50:44.508+01:00</datePlanning>
201
            <dayType>
202
              <code>DAY</code>
203
            </dayType>
204
          </listDays>
205
        </calendList>
206
      </ResultCalendarList>
207
    </ns1:readChildMonthPlanningResponse>
208
  </soap:Body>
209
</soap:Envelope>
tests/test_maelis.py
1 1
# -*- coding: utf-8 -*-
2 2

  
3
import json
3 4
import mock
4 5
import os
5 6
import pytest
6 7

  
8
from django.test import override_settings
9
from django.utils.dateparse import parse_date
10

  
7 11
from passerelle.apps.maelis.models import Maelis, Link
8 12

  
9 13
from passerelle.utils.jsonresponse import APIError
14
from passerelle.apps.maelis.utils import (
15
    get_default_school_year, week_boundaries, month_range, decompose_event)
10 16

  
11 17
import utils
12 18

  
13 19
pytestmark = pytest.mark.django_db
14 20

  
21
TEST_BASE_DIR = os.path.join(os.path.dirname(__file__), 'data', 'maelis')
22

  
15 23

  
16 24
def get_xml_file(filename):
17
    return open(os.path.join(os.path.dirname(__file__),
18
                             'data', 'maelis', filename), 'rb').read()
25
    with open(os.path.join(TEST_BASE_DIR, filename), 'rb') as desc:
26
        return desc.read()
27

  
28

  
29
def get_json_file(filename):
30
    with open(os.path.join(TEST_BASE_DIR, "%s.json" % filename)) as fd:
31
        return json.load(fd)
19 32

  
20 33

  
21 34
@pytest.fixture
22 35
def family_service_wsdl():
23 36
    return get_xml_file('FamilyService.wsdl')
24 37

  
25 38

  
26 39
@pytest.fixture
......
193 206
                                         status_code=200,
194 207
                                         headers={'Content-Type': 'text/xml'}
195 208
                                         )
196 209
    Link.objects.create(resource=connector, family_id='3264', name_id='local')
197 210
    resp = app.get('/maelis/test/regie/1/invoice/3264-53186?NameID=local')
198 211
    assert resp.json['data']
199 212
    assert resp.json['data']['label'] == 'FACTURATION SEPTEMBRE 2014'
200 213
    assert resp.json['data']['display_id'] == '53186'
214

  
215

  
216
@pytest.mark.parametrize('date, schoolyear', [
217
    ('2020-07-30', 2019),
218
    ('2020-07-31', 2020),
219
])
220
def test_get_default_school_year(date, schoolyear):
221
    date = parse_date(date)
222
    assert schoolyear == get_default_school_year(date)
223

  
224

  
225
@pytest.mark.parametrize('date, monday, sunday', [
226
    ('2020-12-27', '2020-12-21', '2020-12-27'),
227
    ('2020-12-28', '2020-12-28', '2021-01-03'),
228
    ('2020-12-31', '2020-12-28', '2021-01-03'),
229
    ('2021-01-01', '2020-12-28', '2021-01-03'),
230
    ('2021-01-03', '2020-12-28', '2021-01-03'),
231
])
232
def test_week_boundaries(date, monday, sunday):
233
    start, end = week_boundaries(date)
234
    assert start.strftime('%Y-%m-%d') == monday
235
    assert end.strftime('%Y-%m-%d') == sunday
236

  
237

  
238
@pytest.mark.parametrize('start, end, items', [
239
    ('2020-10-22', '2020-12-06', ['2020-10-01', '2020-11-01', '2020-12-01']),
240
    ('2020-12-31', '2021-01-03', ['2020-12-01', '2021-01-01']),
241
    ('2020-12-28', '2020-12-28', ['2020-12-01']),
242
    ('2021-01-03', '2020-12-01', []),
243
])
244
def test_month_range(start, end, items):
245
    start = parse_date(start)
246
    end = parse_date(end)
247
    assert [x.strftime('%Y-%m-%d') for x in month_range(start, end)] == items
248

  
249

  
250
def test_decompose_event():
251
    resp = get_json_file('child_planning_before_decomposition')
252
    data = resp['data']
253
    assert len(data) == 43
254
    assert data[22]['text'] == 'JOURNEE'
255
    assert data[23]['text'] == 'MATIN'
256
    assert data[24]['text'] == 'MATIN ET REPAS'
257
    assert data[25]['text'] == 'APRES MIDI'
258
    assert not [x for x in data if x['text'] == 'REPAS']
259

  
260
    # unit is break down into its components
261
    assert [x['text'] for x in decompose_event(data[22])] == [
262
        'Matinée', 'Repas', 'Après-midi']
263
    assert [x['text'] for x in decompose_event(data[23])] == [
264
        'Matinée']
265
    assert [x['text'] for x in decompose_event(data[24])] == [
266
        'Matinée', 'Repas']
267
    assert [x['text'] for x in decompose_event(data[25])] == [
268
        'Après-midi']
269

  
270
    # child_planning function use a dict to remove dupplicated components
271
    data = {x['id']: x for e in data for x in decompose_event(e)}.values()
272
    assert len(data) == 42
273
    assert len([x for x in data if x['text'] == 'Repas']) == 1
274
    assert len([x for x in data if 'EO0001' in x['slot_id']]) == 3
275

  
276

  
277
@override_settings(TIME_ZONE='Europe/Paris')
278
@mock.patch('passerelle.utils.Request.get')
279
@mock.patch('passerelle.utils.Request.post')
280
def test_get_child_planning(mocked_post, mocked_get, family_service_wsdl,
281
                            activity_service_wsdl, app, connector):
282
    mocked_get.side_effect = (
283
        utils.FakedResponse(
284
            content=family_service_wsdl,
285
            status_code=200,
286
            headers={'Content-Type': 'text/xml'}),
287
        utils.FakedResponse(
288
            content=activity_service_wsdl,
289
            status_code=200,
290
            headers={'Content-Type': 'text/xml'}),
291
        utils.FakedResponse(
292
            content=activity_service_wsdl,
293
            status_code=200,
294
            headers={'Content-Type': 'text/xml'})
295
    )
296
    mocked_post.side_effect = (
297
        utils.FakedResponse(
298
            content=get_xml_file('readFamily.xml'),
299
            status_code=200,
300
            headers={'Content-Type': 'text/xml'}),
301
        utils.FakedResponse(
302
            content=get_xml_file('child_planning_readActivityListResponse.xml'),
303
            status_code=200,
304
            headers={'Content-Type': 'text/xml'}),
305
        utils.FakedResponse(
306
            content=get_xml_file('child_planning_readChildMonthPlanningResponse.xml'),
307
            status_code=200,
308
            headers={'Content-Type': 'text/xml'})
309
    )
310
    Link.objects.create(resource=connector, family_id='3264', name_id='local')
311
    resp = app.get(
312
        '/maelis/test/child-planning?NameID=local&childID=21293&start_date=2020-12-19')
313
    data = resp.json['data']
314
    previous_event = {}
315
    for event in data:
316
        assert event['category']
317
        assert event['text']
318
        if previous_event:
319
            assert previous_event['id'] <= event['id']
320
        previous_event = event
321
    assert len(data) == 42
322
    assert len([s for s in data if s['user_booking_status'] == 'not-booked']) == 33
323
    assert len([s for s in data if s['user_booking_status'] == 'booked']) == 9
324
    assert not [x for x in data if x['text'] == 'MATIN']
325
    assert len([x for x in data if x['text'] == 'Matinée']) == 1
326
    assert resp.json == get_json_file('child_planning_after_decomposition')
201
-