View | Details | Raw Unified | Return to bug 36561
Collapse All | Expand All

(-)a/api/v1/swagger/paths/auth.yaml (-1 / +1 lines)
Lines 1183-1186 Link Here
1183
          $ref: ../swagger.yaml#/definitions/error
1183
          $ref: ../swagger.yaml#/definitions/error
1184
    x-koha-authorization:
1184
    x-koha-authorization:
1185
      permissions:
1185
      permissions:
1186
        borrowers: "1"
1186
        borrowers: api_validate_password
(-)a/t/db_dependent/api/v1/password_validation.t (-2 / +14 lines)
Lines 40-48 $schema->storage->txn_begin; Link Here
40
my $librarian = $builder->build_object(
40
my $librarian = $builder->build_object(
41
    {
41
    {
42
        class => 'Koha::Patrons',
42
        class => 'Koha::Patrons',
43
        value => { flags => 2**4 }    # borrowers flag = 4
43
        value => { flags => 0 }     # No top-level permissions
44
    }
44
    }
45
);
45
);
46
47
# Ensure our librarian can see users from all branches (once list_borrowers is added)
48
$builder->build(
49
    {
50
        source => 'UserPermission',
51
        value  => {
52
            borrowernumber => $librarian->borrowernumber,
53
            module_bit     => 4,
54
            code           => 'api_validate_password',
55
        },
56
    }
57
);
58
46
my $password = 'thePassword123';
59
my $password = 'thePassword123';
47
$librarian->set_password( { password => $password, skip_validation => 1 } );
60
$librarian->set_password( { password => $password, skip_validation => 1 } );
48
my $userid = $librarian->userid;
61
my $userid = $librarian->userid;
49
- 

Return to bug 36561