1234567891011121314151617181920212223242526272829303132 |
- <oadr:oadrReportRequest>
- <ei:reportRequestID>{{ report_request.report_request_id }}</ei:reportRequestID>
- <ei:reportSpecifier xmlns:xcal="urn:ietf:params:xml:ns:icalendar-2.0">
- <ei:reportSpecifierID>{{ report_request.report_specifier.report_specifier_id }}</ei:reportSpecifierID>
- <xcal:granularity>
- <xcal:duration>{{ report_request.report_specifier.granularity|timedeltaformat }}</xcal:duration>
- </xcal:granularity>
- {% if report_request.report_specifier.report_back_duration is defined and report_request.report_specifier.report_back_duration is not none %}
- <ei:reportBackDuration>
- <xcal:duration>{{ report_request.report_specifier.report_back_duration|timedeltaformat }}</xcal:duration>
- </ei:reportBackDuration>
- {% endif %}
- {% if report_request.report_specifier.report_interval is defined and report_request.report_specifier.report_interval is not none %}
- <ei:reportInterval>
- <xcal:properties>
- <xcal:dtstart>
- <xcal:date-time>{{ report_request.report_specifier.report_interval.dtstart|datetimeformat }}</xcal:date-time>
- </xcal:dtstart>
- <xcal:duration>
- <xcal:duration>{{ report_request.report_specifier.report_interval.duration|timedeltaformat }}</xcal:duration>
- </xcal:duration>
- </xcal:properties>
- </ei:reportInterval>
- {% endif %}
- {% for specifier_payload in report_request.report_specifier.specifier_payloads %}
- <ei:specifierPayload>
- <ei:rID>{{ specifier_payload.r_id }}</ei:rID>
- <ei:readingType>{{ specifier_payload.reading_type }}</ei:readingType>
- </ei:specifierPayload>
- {% endfor %}
- </ei:reportSpecifier>
- </oadr:oadrReportRequest>
|