'coust', 'description'),
'currency', null)
+,( 'cat.require_call_number_labels', 'cat',
+ oils_i18n_gettext('cat.require_call_number_labels',
+ 'Require call number labels in Copy Editor',
+ 'coust', 'label'),
+ oils_i18n_gettext('cat.require_call_number_labels',
+ 'Define whether Copy Editor requires Call Number labels',
+ 'coust', 'description'),
+ 'bool', null)
+
,( 'circ.min_item_price', 'finance',
oils_i18n_gettext('circ.min_item_price',
'Minimum Item Price',
,(1, 'cat.label.font.size', 10)
,(1, 'cat.label.font.weight', '"normal"')
,(1, 'circ.grace.extend', 'true')
+ ,(1, 'cat.require_call_number_labels', 'true')
;
--220.schema.rating.sql (Default badge for popularity ranking)
--- /dev/null
+BEGIN;
+
+SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
+
+INSERT into config.org_unit_setting_type
+( name, grp, label, description, datatype, fm_class ) VALUES
+( 'cat.require_call_number_labels', 'cat',
+ oils_i18n_gettext('cat.require_call_number_labels',
+ 'Require call number labels in Copy Editor',
+ 'coust', 'label'),
+ oils_i18n_gettext('cat.require_call_number_labels',
+ 'Define whether Copy Editor requires Call Number labels',
+ 'coust', 'description'),
+ 'bool', null);
+
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES
+ (1, 'cat.require_call_number_labels', 'true');
+
+COMMIT;
\ No newline at end of file
'</div>'+
'<div class="col-xs-2">'+
'<input class="form-control" type="text" ng-change="updateLabel()" ng-model="label"/>'+
- '<div class="label label-danger" ng-if="empty_label">{{empty_label_string}}</div>'+
+ '<div class="label label-danger" ng-if="empty_label && require_label">{{empty_label_string}}</div>'+
'</div>'+
'<div class="col-xs-1">'+
'<select class="form-control" ng-model="suffix" ng-change="updateSuffix()" ng-options="s.label() for s in suffix_list"></select>'+
if (!$scope.callNumber.label()) $scope.callNumber.empty_label = true;
$scope.empty_label = false;
+ egCore.org.settings('cat.require_call_number_labels').then(function(res) {
+ $scope.require_label = res['cat.require_call_number_labels'];
+ });
$scope.empty_label_string = window.empty_label_string;
$scope.idTracker = function (x) { if (x && x.id) return x.id() };
}
};
+ egCore.org.settings('cat.require_call_number_labels').then(function(res) {
+ $scope.require_label = res['cat.require_call_number_labels'];
+ });
+
$scope.new_lib_to_add = egCore.org.get(egCore.auth.user().ws_ou());
$scope.changeNewLib = function (org) {
$scope.new_lib_to_add = org;
itemSvc.copies,
function (i) {
if (!$scope.only_vols) {
- if (i.duplicate_barcode || i.empty_barcode || i.call_number().empty_label) {
+ if (i.duplicate_barcode || i.empty_barcode) {
+ can_save = false;
+ }
+ if (i.call_number().empty_label && $scope.require_label) {
can_save = false;
}
- } else if (i.call_number().empty_label) {
+ } else if (i.call_number().empty_label && $scope.require_label) {
can_save = false;
}
}