REPORTS = {
    "nat_report": {
        "dst_filename": "nat_report.md.jinja2",
        "coll": ("\n# NAT Report for {{ device_ip }}"
                 "\n\n***Report generated at {{ report_time }} UTC***"
                 "\n\n## NAT Session License information\n\n"
                 "- Total qty: {{ nat_session_license.total }}\n"
                 "- Used qty: {{ nat_session_license.used }}\n\n"
                 "## NAT Sessions qty (2M per license)\n\n"
                 "- Free: {{ nat_session_qty.free }} M\n"
                 "- Used: {{ nat_session_qty.used }} M\n"
                 "- Total: {{ nat_session_qty.total }} M\n\n"
                 "## Service cards information\n\n"
                 "{% for slot, info in slots.items() %}\n"
                 "### Slot {{ slot }} main information\n\n"
                 "- Board: {{ info.board }}\n"
                 "- NAT BW Licenses on: {{ info.bw_license }}\n\n"
                 "  {% for cpu, value in info.items() %}\n"
                 "    {% if value is not none and "
                 "cpu in ['cpu0', 'cpu1', 'pic0', 'pic1'] %}\n"
                 "#### Slot {{ slot }} {{ value.cpu_type }} {{ value.cpu_id }}"
                 "\n\n- Binded to service-location: {{ value.serv_loc }}\n"
                 "- Service-instange-group name: {{ value.sig }}\n"
                 "      {% if value.nat_bw_lic %}\n- Max BW for this unit:"
                 " {{ value.default_bw + 20 }} Gbps\n      {% else %}\n"
                 "- Max BW for this unit: {{ value.default_bw }} Gbps\n"
                 "      {% endif %}\n- Current qty of allocated sessions:"
                 " {{ value.cur_sess_qty }} M\n- Payload information:\n"
                 "  - Current RX, Mbps: {{ value.payload.curr_rx_mbps }}\n"
                 "  - Current RX, pps: {{ value.payload.curr_rx_pps }}\n"
                 "  - Current TX, Mbps: {{ value.payload.curr_tx_mbps }}\n"
                 "  - Current TX, pps: {{ value.payload.curr_tx_pps }}\n"
                 "  - Historical Max RX, Mbps: "
                 "{{ value.payload.hist_max_rx_mbps}}\n"
                 "  - Historical Max RX Date: "
                 "{{ value.payload.hist_max_rx_bps_date}}\n"
                 "  - Historical Max TX, Mbps: "
                 "{{ value.payload.hist_max_tx_mbps}}\n  "
                 "- Historical Max TX Date: "
                 "{{ value.payload.hist_max_tx_bps_date}}\n"
                 "  - Current total NAT session: {{ value.total_session }}\n"
                 "  - Historical Max total NAT session qty: "
                 "{{ value.max_session_qty }}\n"
                 "  - Historical Max total NAT session date:"
                 " {{ value.max_session_date }}\n"
                 "      {% if value.instances %}\n"
                 "- **Binded NAT instances**:\n"
                 "        {% for instance in value.instances %}\n"
                 "          {% for ni_name, ni_info in instance.items() %}\n"
                 "  - NAT Instance name: {{ ni_name }}\n"
                 "    - NAT Instance ID: {{ ni_info.ni_id }}\n"
                 "    - Enabled ALG: {{ ni_info.alg }}\n"
                 "            {% if ni_info['nat-pools'] %}\n"
                 "              {% for pool in ni_info['nat-pools'] %}\n"
                 "    - IP Pool: {{ pool }}\n              {% endfor %}\n"
                 "            {% endif %}\n            {% if ni_info.limits %}"
                 "\n              {% for prot, lim in ni_info.limits.items() %}"
                 "\n    - Limit for {{ prot }}: {{ lim }}\n"
                 "              {% endfor %}\n"
                 "            {% endif %}\n            {% if ni_info.ports %}\n"
                 "              {% for port_v, val in ni_info.ports.items() %}"
                 "\n    - {{ port_v }}: {{ val }}\n              {% endfor %}\n"
                 "            {% endif %}\n          {% endfor %}\n"
                 "        {% endfor %}\n      {% endif %}\n    {% endif %}\n"
                 "  {% endfor %}\n{% endfor %}\n"),
        "format": "text"
    },
    "bas_report": {
        "dst_filename": "bas_report.md.jinja2",
        "coll": ("\n# BAS Report for {{ device_ip }}\n\n"
                 "***Report generated at {{ report_time }} UTC***\n\n"
                 "## Quick reminder for Huawei-specific terms\n\n"
                 "- **bind** - (authentication method) IPoE (Opt82/QinQ)\n"
                 "- **ppp** - (authentication method) PPPoE/L2TP\n"
                 "- **Normal** - users without HA session backup\n-"
                 " **RUI Local** - locally terminated access users\n-"
                 " **RUI Remote** - sessions received via remote backup"
                 " services\n\n"
                 "## Summary users information\n\n"
                 "{% for ip_type, info in total_users.items() %}\n"
                 "- Qty of {{ ip_type }} users\n"
                 "  - Normal: {{ info.normal }}\n"
                 "  - RUI Local: {{ info.rui_local }}\n"
                 "  - RUI Remote: {{ info.rui_remote }}\n"
                 "  - RADIUS authentication: {{ info.radius_auth }}\n"
                 "  - No authentication: {{ info.no_auth }}\n"
                 "  - Total: {{ info.total }}\n{% endfor %}\n\n"
                 "## BAS Licenses information\n\n{% if licenses%}\n"
                 "|   License   |                   Description"
                 "                   |  Type  | Qty |\n"
                 "|-------------|-------------------------------"
                 "------------------|--------|-----|\n"
                 "  {% for license in licenses %}\n"
                 "|{{ license.name }}|{{ license.description }}|"
                 "{{ license.type }}|{{license.qty}}|\n"
                 "  {% endfor %}\n{% endif %}\n\n"
                 "## BAS Interfaces information\n\n"
                 "{% if bas_interfaces %}\n"
                 "|    BAS Interface    | Preauthentication domain |"
                 "  Authentication domain   | Method |     GRT/VRF     |"
                 " Online |      RBP      | Static users qty |\n"
                 "|---------------------|--------------------------|"
                 "--------------------------|--------|-----------------|"
                 "--------|---------------|------------------|\n"
                 "  {% for intf in bas_interfaces %}\n|{{ intf.name }}|"
                 "{{ intf.preauth_domain }}|{{ intf.authen_domain }}|"
                 "{{ intf.authen_method }}|{{ intf.vrf }}|{{ intf.online }}|"
                 "{{ intf.rbp_name }}|{{ intf.static_qty }}|\n"
                 "  {% endfor %}\n{% endif %}\n\n"
                 "## BAS Domains information\n\n"
                 "{% if domains_info %}\n"
                 "  {% for domain in domains_info %}\n"
                 "- {{ domain.name }}\n"
                 "  - Online users: {{ domain.online }}\n"
                 "  - Authentication scheme: {{ domain.authen_scheme}}\n"
                 "  - Accounting scheme: {{ domain.account_scheme }}\n"
                 "    {% if domain.author_scheme %}\n"
                 "  - Authorization scheme: {{ domain.author_scheme }}\n"
                 "    {% endif %}\n    {% if domain.radius_server %}\n"
                 "  - RADIUS Server Template: {{ domain.radius_server }}\n"
                 "    {% endif %}\n"
                 "    {% if domain.tacacs_server %}\n"
                 "  - TACACS+ Server Template: {{ domain.tacacs_server }}\n"
                 "    {% endif %}\n"
                 "    {% if domain.redirect_url %}\n"
                 "  - Redirect url: {{ domain.redirect_url }}\n"
                 "    {% endif %}\n"
                 "    {% if domain.default_ip_pool %}\n"
                 "  - Default IP Pool name: {{ domain.default_ip_pool }}\n"
                 "    {% endif %}\n"
                 "    {% if domain.nat_user_group %}\n"
                 "  - Binded NAT User-group: {{ domain.nat_user_group }}\n"
                 "    {% endif %}\n"
                 "    {% if domain.nat_instance %}\n"
                 "  - Binded NAT Instance: {{ domain.nat_instance }}\n"
                 "    {% endif %}\n\n"
                 "  {% endfor %}\n"
                 "{% endif%}\n"
                 "## Used RADIUS servers information\n\n"
                 "{% if radius_info %}\n"
                 "  {% for radius in radius_info %}\n"
                 "- RADIUS server template: {{ radius.name }}\n"
                 "    {% for srv in radius.authen_servers %}\n"
                 "  - Authentication server {{ srv.ip }}:\n"
                 "    - Port: {{ srv. port }}\n"
                 "    - Weight: {{ srv.weight }}\n"
                 "    - VRF: {{ srv.vrf }}\n"
                 "    {% endfor %}\n"
                 "    {% for srv in radius.account_servers %}\n"
                 "  - Accounting server {{ srv.ip }}\n"
                 "    - Port: {{ srv. port }}\n"
                 "    - Weight: {{ srv.weight }}\n"
                 "    - VRF: {{ srv.vrf }}\n"
                 "    {% endfor %}\n"
                 "  - Source interface: {{ radius.src_interface }}\n"
                 "  - Calling-station-ID format:"
                 " {{ radius.call_station_id }}\n\n"
                 "  {% endfor %}\n"
                 "{% endif %}\n"),
        "format": "text"
    }
}
