mirror of
				https://github.com/netbox-community/netbox.git
				synced 2024-05-10 07:54:54 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			67 lines
		
	
	
		
			2.6 KiB
		
	
	
	
		
			HTML
		
	
	
	
	
	
			
		
		
	
	
			67 lines
		
	
	
		
			2.6 KiB
		
	
	
	
		
			HTML
		
	
	
	
	
	
{% extends base_template %}
 | 
						|
{% load helpers %}
 | 
						|
{% load static %}
 | 
						|
 | 
						|
{% block title %}{{ block.super }} - Config Context{% endblock %}
 | 
						|
 | 
						|
{% block content %}
 | 
						|
    <div class="row">
 | 
						|
        <div class="col-md-6">
 | 
						|
            <div class="panel panel-default">
 | 
						|
                <div class="panel-heading">
 | 
						|
                    <strong>Rendered Context</strong>
 | 
						|
                    {% include 'extras/inc/configcontext_format.html' %}
 | 
						|
                </div>
 | 
						|
                <div class="panel-body">
 | 
						|
                    {% include 'extras/inc/configcontext_data.html' with data=rendered_context %}
 | 
						|
                </div>
 | 
						|
            </div>
 | 
						|
        </div>
 | 
						|
        <div class="col-md-6">
 | 
						|
            <div class="panel panel-default">
 | 
						|
                <div class="panel-heading">
 | 
						|
                    <strong>Local Context</strong>
 | 
						|
                </div>
 | 
						|
                <div class="panel-body">
 | 
						|
                    {% if obj.local_context_data %}
 | 
						|
                        {% include 'extras/inc/configcontext_data.html' with data=obj.local_context_data %}
 | 
						|
                    {% else %}
 | 
						|
                        <span class="text-muted">None</span>
 | 
						|
                    {% endif %}
 | 
						|
                </div>
 | 
						|
                <div class="panel-footer">
 | 
						|
                    <span class="help-block">
 | 
						|
                        <i class="fa fa-info-circle"></i>
 | 
						|
                        The local config context overwrites all source contexts.
 | 
						|
                    </span>
 | 
						|
                </div>
 | 
						|
            </div>
 | 
						|
            <div class="panel panel-default">
 | 
						|
                <div class="panel-heading">
 | 
						|
                    <strong>Source Contexts</strong>
 | 
						|
                </div>
 | 
						|
                {% for context in source_contexts %}
 | 
						|
                    <div class="panel-body">
 | 
						|
                        <div class="pull-right">
 | 
						|
                            <span class="text-muted">{{ context.weight }}</span>
 | 
						|
                        </div>
 | 
						|
                        <a href="{{ context.get_absolute_url }}"><strong>{{ context.name }}</strong></a>
 | 
						|
                        {% if context.description %}
 | 
						|
                            <br /><small>{{ context.description }}</small>
 | 
						|
                        {% endif %}
 | 
						|
                        {% include 'extras/inc/configcontext_data.html' with data=context.data %}
 | 
						|
                    </div>
 | 
						|
                {% empty %}
 | 
						|
                    <div class="panel-body">
 | 
						|
                        <span class="text-muted">None found</span>
 | 
						|
                    </div>
 | 
						|
                {% endfor %}
 | 
						|
            </div>
 | 
						|
        </div>
 | 
						|
    </div>
 | 
						|
{% endblock %}
 | 
						|
 | 
						|
{% block javascript %}
 | 
						|
<script src="{% static 'js/configcontext.js' %}?v{{ settings.VERSION }}"></script>
 | 
						|
{% endblock %}
 |