oadrReportDescription.xml 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <oadr:oadrReportDescription xmlns:emix="http://docs.oasis-open.org/ns/emix/2011/06" xmlns:power="http://docs.oasis-open.org/ns/emix/2011/06/power">
  2. <ei:rID>{{ report_description.r_id }}</ei:rID>
  3. {% if report_description.report_subject and report_description.report_subject.end_device_asset.mrid %}
  4. <ei:reportSubject>
  5. <power:endDeviceAsset>
  6. <power:mrid>{{ report_description.report_subject.end_device_asset.mrid }}</power:mrid>
  7. </power:endDeviceAsset>
  8. </ei:reportSubject>
  9. {% endif %}
  10. {% if report_description.report_data_source %}
  11. <ei:reportDataSource>
  12. {% if report_description.report_data_source.emix_interfaces %}
  13. {% for emix_interface in target.emix_interface %}
  14. {% include 'parts/emixInterface.xml' %}
  15. {% endfor %}
  16. {% endif %}
  17. {% if report_description.report_data_source.group_id %}
  18. <ei:groupID>{{ report_description.report_data_source.group_id }}</ei:groupID>
  19. {% endif %}
  20. {% if report_description.report_data_source.group_name %}
  21. <ei:groupName>{{ report_description.report_data_source.group_name }}</ei:groupName>
  22. {% endif %}
  23. {% if report_description.report_data_source.resource_id %}
  24. <ei:resourceID>{{ report_description.report_data_source.resource_id }}</ei:resourceID>
  25. {% endif %}
  26. {% if report_description.report_data_source.ven_id %}
  27. <ei:venID>{{ report_description.report_data_source.ven_id }}</ei:venID>
  28. {% endif %}
  29. {% if report_description.report_data_source.party_id %}
  30. <ei:partyID>{{ report_description.report_data_source.party_id }}</ei:partyID>
  31. {% endif %}
  32. </ei:reportDataSource>
  33. {% endif %}
  34. <ei:reportType>{{ report_description.report_type }}</ei:reportType>
  35. {% include 'parts/reportDescriptionEmix.xml' %}
  36. <ei:readingType>{{ report_description.reading_type }}</ei:readingType>
  37. {% if report_description.market_context %}
  38. <emix:marketContext>{{ report_description.market_context }}</emix:marketContext>
  39. {% endif %}
  40. {% if report_description.sampling_rate %}
  41. <oadr:oadrSamplingRate>
  42. <oadr:oadrMinPeriod>{{ report_description.sampling_rate.min_period|timedeltaformat }}</oadr:oadrMinPeriod>
  43. <oadr:oadrMaxPeriod>{{ report_description.sampling_rate.max_period|timedeltaformat }}</oadr:oadrMaxPeriod>
  44. <oadr:oadrOnChange>{{ report_description.sampling_rate.on_change|booleanformat }}</oadr:oadrOnChange>
  45. </oadr:oadrSamplingRate>
  46. {% endif %}
  47. </oadr:oadrReportDescription>