mirror of
https://github.com/Esri/offline-editor-js.git
synced 2025-12-15 15:20:05 +00:00
fixed extend() in sample
This commit is contained in:
parent
a27ad858e1
commit
618d2281cf
@ -390,9 +390,16 @@
|
||||
offlineFeaturesManager.on(offlineFeaturesManager.events.EDITS_ENQUEUED, editsEnqueued);
|
||||
offlineFeaturesManager.on(offlineFeaturesManager.events.EDITS_SENT, updateStatus);
|
||||
offlineFeaturesManager.on(offlineFeaturesManager.events.ALL_EDITS_SENT, allEditsSent);
|
||||
offlineFeaturesManager.on(offlineFeaturesManager.events.EDITS_SENT_ERROR, editsError);
|
||||
|
||||
offlineFeaturesManager.extend(busStopFeatureLayer);
|
||||
console.log("offlineFeaturesManager initialized.");
|
||||
offlineFeaturesManager.extend(busStopFeatureLayer,function(result, error){
|
||||
if(result){
|
||||
console.log("offlineFeaturesManager initialized.");
|
||||
}
|
||||
else{
|
||||
alert("Unable to initialize the database. " + error);
|
||||
}
|
||||
});
|
||||
|
||||
Offline.check();
|
||||
Offline.on('up', goOnline);
|
||||
@ -758,6 +765,10 @@
|
||||
}
|
||||
}
|
||||
|
||||
function editsError(){
|
||||
alert("There was a problem. Not all edits were synced with the server.");
|
||||
}
|
||||
|
||||
function updateStatus(){
|
||||
if( editsStore.hasPendingEdits())
|
||||
{
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user