use teh german date format
This commit is contained in:
		
							parent
							
								
									93ca5660e5
								
							
						
					
					
						commit
						57033858cd
					
				
					 2 changed files with 8 additions and 3 deletions
				
			
		| 
						 | 
					@ -25,7 +25,7 @@ attachment_filenames = {}
 | 
				
			||||||
class DownloadForm(FlaskForm):
 | 
					class DownloadForm(FlaskForm):
 | 
				
			||||||
    start_time = DateTimeField('Startzeit',
 | 
					    start_time = DateTimeField('Startzeit',
 | 
				
			||||||
                               validators=[InputRequired()],
 | 
					                               validators=[InputRequired()],
 | 
				
			||||||
                               format='%Y-%m-%d %H:%M')
 | 
					                               format='%d.%m.%Y %H:%M')
 | 
				
			||||||
    length = IntegerField('Länge',
 | 
					    length = IntegerField('Länge',
 | 
				
			||||||
                          validators=[
 | 
					                          validators=[
 | 
				
			||||||
                              InputRequired(),
 | 
					                              InputRequired(),
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -28,7 +28,12 @@
 | 
				
			||||||
        <div class="form-group required {% if form.start_time.errors %}has-error{% endif -%}">
 | 
					        <div class="form-group required {% if form.start_time.errors %}has-error{% endif -%}">
 | 
				
			||||||
            {{ form.start_time.label(class_="control-label") }}
 | 
					            {{ form.start_time.label(class_="control-label") }}
 | 
				
			||||||
            <div class='input-group' id='start_time_group'>
 | 
					            <div class='input-group' id='start_time_group'>
 | 
				
			||||||
                <input name='start_time' id='start_time_' class="form-control" value="{{ form.start_time.data }}"/>
 | 
					                <input name='start_time' id='start_time_' class="form-control"
 | 
				
			||||||
 | 
					                    placeholder="{{ form.start_time.format }}"
 | 
				
			||||||
 | 
					                    {% if form.start_time.data %}
 | 
				
			||||||
 | 
					                    value="{{ form.start_time.data.strftime(form.start_time.format) }}"
 | 
				
			||||||
 | 
					                    {% endif %}
 | 
				
			||||||
 | 
					                />
 | 
				
			||||||
                <span class="input-group-addon">
 | 
					                <span class="input-group-addon">
 | 
				
			||||||
                    <span class="glyphicon glyphicon-calendar"></span>
 | 
					                    <span class="glyphicon glyphicon-calendar"></span>
 | 
				
			||||||
                </span>
 | 
					                </span>
 | 
				
			||||||
| 
						 | 
					@ -67,7 +72,7 @@
 | 
				
			||||||
    $(document).ready(function() {
 | 
					    $(document).ready(function() {
 | 
				
			||||||
        $('#start_time_group').datetimepicker({
 | 
					        $('#start_time_group').datetimepicker({
 | 
				
			||||||
            locale: 'de',
 | 
					            locale: 'de',
 | 
				
			||||||
            format: 'YYYY-MM-DD HH:mm',
 | 
					            format: 'DD.MM.YYYY HH:mm',
 | 
				
			||||||
            sideBySide: true
 | 
					            sideBySide: true
 | 
				
			||||||
        });
 | 
					        });
 | 
				
			||||||
        $(".alert-success").delay(4000).fadeOut(500, function() {
 | 
					        $(".alert-success").delay(4000).fadeOut(500, function() {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue