|
Lines 8553-8564
if (CheckVersion($DBversion)) {
Link Here
|
| 8553 |
|
8553 |
|
| 8554 |
$DBversion = "XXX"; |
8554 |
$DBversion = "XXX"; |
| 8555 |
if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { |
8555 |
if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { |
| 8556 |
$dbh->do(" |
8556 |
$dbh->do(q{ |
| 8557 |
INSERT IGNORE INTO permissions (module_bit, code, description) |
8557 |
INSERT IGNORE INTO permissions (module_bit, code, description) |
| 8558 |
VALUES (11, 'order_claim_for_all', 'Claim for all orders') |
8558 |
VALUES (11, 'order_claim_for_all', 'Claim for all orders') |
| 8559 |
"); |
8559 |
}); |
|
|
8560 |
|
| 8561 |
# Add this new permission to all users that have 'order_receive' permission |
| 8562 |
$dbh->do(q{ |
| 8563 |
INSERT INTO user_permissions (borrowernumber, module_bit, code) |
| 8564 |
SELECT borrowernumber, 11, 'order_claim_for_all' |
| 8565 |
FROM user_permissions |
| 8566 |
WHERE code = 'order_receive' |
| 8567 |
GROUP BY borrowernumber |
| 8568 |
}); |
| 8560 |
|
8569 |
|
| 8561 |
print "Upgrade to $DBversion done (Add permission order_claim_for_all)\n"; |
8570 |
print "Upgrade to $DBversion done (Bug 7292: Add permission order_claim_for_all)\n"; |
| 8562 |
SetVersion($DBversion); |
8571 |
SetVersion($DBversion); |
| 8563 |
} |
8572 |
} |
| 8564 |
|
8573 |
|
| 8565 |
- |
|
|