Project

General

Profile

« Previous | Next » 

Revision ce41c769

Added by Serghei Mihai over 9 years ago

agenda: highlight last saved updated act

Closes #3148

View differences:

calebasse/agenda/views.py
365 365
                else:
366 366
                    state_name = request.POST.get('act_state')
367 367
                    act.set_state(state_name, request.user)
368
                    messages.add_message(self.request, messages.INFO, u'Acte modifié avec succès')
368 369
            except Act.DoesNotExist:
369 370
                pass
370 371
            return HttpResponseRedirect('#acte-frame-'+acte_id)
calebasse/static/css/agenda.css
288 288
    float: right;
289 289
}
290 290

  
291
div .changed {
291
.frame.acte:target {
292 292
    box-shadow: 2px 2px .5em 5px #db9595;
293 293
}
calebasse/static/js/calebasse.agenda.js
344 344

  
345 345
(function($) {
346 346
  $(function() {
347
      $('#actes .frame select').on('change', function() {
348
          var container = $(this).closest('.frame');
349
          if ($(this).data('previous') != $(this).val()) {
350
              container.addClass('changed');
351
          } else {
352
              container.removeClass('changed');
353
          }
354

  
355
      });
356

  
357 347
      $('#tabs').tabs({
358 348
          load: function(event, ui) {
359 349
              var tab = $(ui.tab).attr('id').split('-');

Also available in: Unified diff