mirror of
				https://github.com/encode/django-rest-framework.git
				synced 2025-11-04 01:47:59 +03:00 
			
		
		
		
	Merge branch 'master' of https://github.com/tomchristie/django-rest-framework
This commit is contained in:
		
						commit
						6bbd509f34
					
				| 
						 | 
				
			
			@ -1,11 +1,16 @@
 | 
			
		|||
{% load i18n %}
 | 
			
		||||
{% trans "No items to select." as no_items %}
 | 
			
		||||
 | 
			
		||||
<div class="form-group">
 | 
			
		||||
    {% if field.label %}
 | 
			
		||||
        <label class="col-sm-2 control-label {% if style.hide_label %}sr-only{% endif %}">{{ field.label }}</label>
 | 
			
		||||
    {% endif %}
 | 
			
		||||
    <div class="col-sm-10">
 | 
			
		||||
        <select multiple class="form-control" name="{{ field.name }}">
 | 
			
		||||
        <select multiple {{ field.choices|yesno:",disabled" }} class="form-control" name="{{ field.name }}">
 | 
			
		||||
            {% for key, text in field.choices.items %}
 | 
			
		||||
            <option value="{{ key }}" {% if key in field.value %}selected{% endif %}>{{ text }}</option>
 | 
			
		||||
                <option value="{{ key }}" {% if key in field.value %}selected{% endif %}>{{ text }}</option>
 | 
			
		||||
            {% empty %}
 | 
			
		||||
                <option>{{ no_items }}</option>
 | 
			
		||||
            {% endfor %}
 | 
			
		||||
        </select>
 | 
			
		||||
        {% if field.errors %}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -1,10 +1,15 @@
 | 
			
		|||
{% load i18n %}
 | 
			
		||||
{% trans "No items to select." as no_items %}
 | 
			
		||||
 | 
			
		||||
<div class="form-group {% if field.errors %}has-error{% endif %}">
 | 
			
		||||
    {% if field.label %}
 | 
			
		||||
        <label class="sr-only">{{ field.label }}</label>
 | 
			
		||||
    {% endif %}
 | 
			
		||||
    <select multiple class="form-control" name="{{ field.name }}">
 | 
			
		||||
    <select multiple {{ field.choices|yesno:",disabled" }} class="form-control" name="{{ field.name }}">
 | 
			
		||||
        {% for key, text in field.choices.items %}
 | 
			
		||||
        <option value="{{ key }}" {% if key in field.value %}selected{% endif %}>{{ text }}</option>
 | 
			
		||||
            <option value="{{ key }}" {% if key in field.value %}selected{% endif %}>{{ text }}</option>
 | 
			
		||||
        {% empty %}
 | 
			
		||||
            <option>{{ no_items }}</option>
 | 
			
		||||
        {% endfor %}
 | 
			
		||||
    </select>
 | 
			
		||||
</div>
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -1,10 +1,15 @@
 | 
			
		|||
{% load i18n %}
 | 
			
		||||
{% trans "No items to select." as no_items %}
 | 
			
		||||
 | 
			
		||||
<div class="form-group {% if field.errors %}has-error{% endif %}">
 | 
			
		||||
    {% if field.label %}
 | 
			
		||||
        <label {% if style.hide_label %}class="sr-only"{% endif %}>{{ field.label }}</label>
 | 
			
		||||
    {% endif %}
 | 
			
		||||
    <select multiple class="form-control" name="{{ field.name }}">
 | 
			
		||||
    <select multiple {{ field.choices|yesno:",disabled" }} class="form-control" name="{{ field.name }}">
 | 
			
		||||
        {% for key, text in field.choices.items %}
 | 
			
		||||
        <option value="{{ key }}" {% if key in field.value %}selected{% endif %}>{{ text }}</option>
 | 
			
		||||
            <option value="{{ key }}" {% if key in field.value %}selected{% endif %}>{{ text }}</option>
 | 
			
		||||
        {% empty %}
 | 
			
		||||
            <option>{{ no_items }}</option>
 | 
			
		||||
        {% endfor %}
 | 
			
		||||
    </select>
 | 
			
		||||
    {% if field.errors %}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue
	
	Block a user