summaryrefslogtreecommitdiff
path: root/www/js/rivendell.js
diff options
context:
space:
mode:
Diffstat (limited to 'www/js/rivendell.js')
-rw-r--r--www/js/rivendell.js11
1 files changed, 10 insertions, 1 deletions
diff --git a/www/js/rivendell.js b/www/js/rivendell.js
index 6e5d099..8566094 100644
--- a/www/js/rivendell.js
+++ b/www/js/rivendell.js
@@ -432,18 +432,27 @@ Rivendell.Cart.prototype.removeCut = function(cut) {
});
};
-Rivendell.Cut = function(name, description, cart) {
+Rivendell.Cut = function(name, description, cart, length, originDatetime,
+ playCounter, lastPlayDatetime) {
this.xml = null;
if (arguments.length === 2) {
this.xml = arguments[0];
this.name = $('cutName', this.xml).text();
this.description = $('description', this.xml).text();
+ this.length = $('length', this.xml).text();
+ this.originDatetime = $('originDatetime', this.xml).text();
+ this.playCounter = $('playCounter', this.xml).text();
+ this.lastPlayDatetime = $('lastPlayDatetime', this.xml).text();
this.cart = arguments[1];
} else {
this.name = name;
this.description = description;
this.cart = cart;
+ this.length = length;
+ this.originDatetime = originDatetime;
+ this.playCounter = playCounter;
+ this.lastPlayDatetime = lastPlayDatetime;
}
this.number = this.name.substr(-3);
this.cartNumber = this.cart.number;