Fix various Multi-Domain bugs

This commit is contained in:
Gary Sharp
2014-04-16 13:16:08 +10:00
parent 2281313966
commit d86280ae3e
15 changed files with 220 additions and 224 deletions
@@ -168,13 +168,18 @@
self.assignedDataUrl = ko.computed(function () {
var t = self.assignedDataType();
var dId = self.assignedDataId();
switch (t) {
case 'Device':
return urlDeviceShow + dId;
case 'Job':
return urlJobShow + dId;
case 'User':
return urlUserShow + dId;
if (dId !== undefined) {
switch (t) {
case 'Device':
return urlDeviceShow + dId;
case 'Job':
return urlJobShow + dId;
case 'User':
if (dId.indexOf('\\') < 0)
return urlUserShow + dId;
else
return urlUserShow + dId.substr(dId.indexOf('\\') + 1) + '?domain=' + dId.substr(0, dId.indexOf('\\'));
}
}
return null;
});