Changeset 781913f in osmose-frontend


Ignore:
Timestamp:
Mar 18, 2014 10:08:58 PM (6 years ago)
Author:
Frédéric Rodrigo <fred.rodrigo@…>
Branches:
master
Children:
4c01ef1
Parents:
4734d02
git-author:
Frédéric Rodrigo <fred.rodrigo@…> (07/03/2014 15:38:07)
git-committer:
Frédéric Rodrigo <fred.rodrigo@…> (18/03/2014 22:08:58)
Message:

Mark error as done from editor

Location:
static/map
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • static/map/Osmose.Editor.js

    ra6b90bb r781913f  
    2323  }, 
    2424 
    25   edit: function (error, type, id, fix) { 
     25  edit: function (errors, layer, error, type, id, fix) { 
    2626    this.show(); 
    2727    if (this._$container.data().user != "True") { 
     
    4343      $("#corrected", self._$container).click(function () { 
    4444        self._validate(this); 
    45         $("#popup-" + error + " .corrected").click(); 
     45        $.ajax({ 
     46          url: '../api/0.2/error/' + error + '/done' 
     47        }).done(function (data) { 
     48          errors.removeLayer(layer); 
     49        }); 
    4650      }); 
    4751      $("#cancel", self._$container).click(function () { 
  • static/map/Osmose.Marker.js

    r257c4fb r781913f  
    7171                }); 
    7272                content.on('click', '.editor_edit, .editor_fix', function() { 
    73                   self._editor.edit(this.getAttribute('data-error'), this.getAttribute('data-type'), this.getAttribute('data-id'), this.getAttribute('data-fix')); 
     73                  self._editor.edit(self, layer, this.getAttribute('data-error'), this.getAttribute('data-type'), this.getAttribute('data-id'), this.getAttribute('data-fix')); 
    7474                }); 
    7575                e.popup.setContent(content[0]); 
Note: See TracChangeset for help on using the changeset viewer.