</ng-pluralize>
</span>
<span> / [% l('Created {{bucket().create_time() | date}}') %]</span>
- <span ng-show="bucket()._owner_name"> / {{bucket()._owner_name}} @ {{bucket()._owner_ou}}</span>
+ <span ng-show="bucket()._owner_name"> /
+ {{bucket()._owner_name}}
+ <a target="_self" href="./circ/patron/{{bucket().owner()}}/checkout">
+ ({{bucket()._owner_ident}})
+ </a>
+ @ {{bucket()._owner_ou}}
+ </span>
<span ng-show="bucket().description()"> / {{bucket().description()}}</span>
</div>
return;
}
egCore.pcrud.retrieve(
- 'au', bucket.owner()
+ 'au', bucket.owner(),
+ {flesh : 1, flesh_fields : {au : ["card"]}}
).then(function(patron) {
- bucket._owner_name = patron.usrname();
+ // On the off chance no barcode is present (it's not
+ // required) use the patron username as the identifier.
+ bucket._owner_ident = patron.card() ?
+ patron.card().barcode() : patron.usrname();
+ bucket._owner_name = patron.family_name();
bucket._owner_ou = egCore.org.get(patron.home_ou()).shortname();
});
return;
}
egCore.pcrud.retrieve(
- 'au', bucket.owner()
+ 'au', bucket.owner(),
+ {flesh : 1, flesh_fields : {au : ["card"]}}
).then(function(patron) {
- bucket._owner_name = patron.usrname();
+ // On the off chance no barcode is present (it's not
+ // required) use the patron username as the identifier.
+ bucket._owner_ident = patron.card() ?
+ patron.card().barcode() : patron.usrname();
+ bucket._owner_name = patron.family_name();
bucket._owner_ou = egCore.org.get(patron.home_ou()).shortname();
});
+
service.currentBucket = bucket;
deferred.resolve(bucket);
});