mirror of
https://github.com/Ekokumppanit/Lentolaskuri.git
synced 2026-01-26 11:13:58 +00:00
21 lines
339 B
JavaScript
21 lines
339 B
JavaScript
define([
|
|
'backbone'
|
|
], function (Backbone) {
|
|
|
|
var num = 1;
|
|
|
|
var Leg = Backbone.Model.extend({
|
|
initialize: function () {
|
|
this.set('airportId', this.get('id'));
|
|
this.set('id', num);
|
|
++num;
|
|
},
|
|
destroy: function () {
|
|
this.trigger('destroy', this, this.collection, {});
|
|
}
|
|
});
|
|
|
|
return Leg;
|
|
|
|
});
|