Commit graph

7845 commits

Author SHA1 Message Date
Galen Charlton
cafaa26b45 granular permissions - created DB tables
First big commit in a project to add more granular
staff user permissions to Koha.

* Created two new database tables

permissions:
  stores a list of defined permissions; each
  permission is to be interpreted as a child
  of a top-level permission defined in the
  existing user flags.  For example, Tools (bit 13)
  now has a separate sub-permission for each
  individual tool.

  The columns are
    module_bit  = FK referencing userflags.bit
    code        = code, e.g., import_patrons
    description = e.g., "Import patron data"

user_permissions:
  stores a list of the specific permissions that
  a staff user actually has.   For example, if
  staff user 123 has only the 'import_patrons' subpermission
  of 'Tools' (module_bit = 13), that would be represented
  by having (123, 13, 'import_patrons' in user_permissions.

  user_permissions and borrowers.flags are now interpreted
  as follows (assuming the CheckSpecificUserPermissions syspref
  is ON):
    * If the appropriate bit (e.g., bit 13 for Tools) is set
      in borrowers.flags, the staff user can access all
      Tools functions.  There should be no rows in user_permissions
      for that staff user and userflag bit combination.
    * If the bit is not set in borrowers.flags, but one or
      more rows are present in user_permissions for that
      staff user and bit combination, the staff user can
      access the specified sub-functions.
    * If the bit is not set in borrower.flags and there are
      no rows in user_permissions for that staff user and
      bit combination, the user cannot access any of the functions.

  Note that this means that if a staff user can access all
  functions for a module (because the bit is set in borrowers.flags),
  the user will automatically be able access any new subfunctions
  added to permissions by a database update.

  The columns are:
    borrowernumber = FK referencing borrowers.borrowernumber
    module_bit, code = FK referencing permissions

* Added a new system preference, CheckSpecificUserPermissions

If this system preference is ON, staff users can be assigned
specific permissions which will be respected during
authorization checks.  If this system preference is OFF, the
current userflags semantics will continue to apply.

* Defined sub-permissions for Tools.  The list of specific
  tools permissions is now:

  edit_news          Write news for the OPAC and staff interfaces
  label_creator      Create printable labels and barcodes from catalog and patron data
  edit_calendar      Define days when the library is closed
  moderate_comments  Moderate patron comments
  edit_notices       Define notices
  edit_notice_status_triggers     Set notice/status triggers for overdue items
  view_system_logs   Browse the system logs
  inventory          Perform inventory (stocktaking) of your catalogue
  stage_marc_import  Stage MARC records into the reservoir
  manage_staged_marc Manage staged MARC records, including completing and reversing imports
  export_catalog     Export bibliographic and holdings data
  import_patrons     Import patron data
  delete_anonymize_patrons    Delete old borrowers and anonymize circulation history (deletes borrower reading history)
  batch_upload_patron_images  Upload patron images in batch or one at a time
  schedule_tasks     Schedule tasks to run

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 15:53:08 -05:00
Galen Charlton
2173ee7b9e fixed XHTML error
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 15:53:02 -05:00
Galen Charlton
90290c4551 bug 2006: do not crash when paying a lost item fine
Qualified call to MarkIssueReturned with 'C4::Circulation'.
It looks like there is still a subtle bug with exporting
subs between modules that use each other.

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 15:52:55 -05:00
Joshua Ferraro
3c030be172 Fix for installer languages so that only the staff client languages are visible to the installer
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 15:52:49 -05:00
Joshua Ferraro
201204e865 improving english of maintenance page
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 15:52:41 -05:00
Andrew Moore
e8da5f250d bug 1953: removing potential SQL injection in C4::Acquisition::GetParcels
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 03:00:40 -05:00
Andrew Moore
b5d356e6be bug 2009: fix to include "type" so that adding items to label batches works.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 03:00:36 -05:00
12273aa88d Include file required after modifications to opac-topissues.tmpl
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:42 -05:00
14249c0082 Changes to "Most Popular" interface: adding some default parameters to link so that page displays results right away. When results are shown, search form is moved into side bar, like facets. Adding tablesorter and 'place hold' links.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:40 -05:00
5c2c039854 Adding whitespace to allow wrapping of long subject hierarchies
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:38 -05:00
6594407b73 Formatting patron expiration date output (or was there a reason why this was commented out previously?)
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:32 -05:00
28e9427c0e Fix for Bug 1828 (
Edit Details link for expired member in circulation.pl incorrect)

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:31 -05:00
193207c614 Identifying "waiting at" branch on screen.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:29 -05:00
25e6c961fb Adding auto-focus to patrons resident search; Highlighting overdues count in patron list.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:28 -05:00
b9584d34c0 Prettying up holds print/confirm button, correcting markup in transfer slip.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:27 -05:00
c32e55259b Highlight waiting and transfered items in the user's holds list. Statuses on transfered items not working properly, though (Bug 2002).
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:25 -05:00
Ryan Higgins
ce41d8d27a add items.enumchron to _koha_new_item.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:23 -05:00
Chris Nighswonger
7fbcb6a784 Bugfix: Correcting misspelled variable
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:22 -05:00
Chris Nighswonger
a16d450555 Adding use of C4::Debug for debugging
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:59:21 -05:00
Paul POULAIN
e30d1d6844 bugfix : independantbranches behaviour
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:55:50 -05:00
Paul POULAIN
91fca4a9ab BiblioAddsAuthorities improvement/fix
this commit restore a better behaviour :
- if ON : the librarian can enter manually an authority-linked marc field. and if it does not exist in the authorities file, it will be created automatically
- if OFF : the authority must exist in the authority file, and the librarian can't enter if manually in the MARC editor

This patch just deals with the OFF case (the ON was already here). With OFF the behaviour is now the same as in 2.2

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:55:08 -05:00
Paul POULAIN
b5f7ff2e45 Adding OPACItemHolds syspref in sql syspref, added by owen on april 1st
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:54:47 -05:00
Paul POULAIN
f5674f953a reintroducing the limit on itemtype when searching a biblio in subscription add
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:52:56 -05:00
Paul POULAIN
854c6f8005 Reintroducing history dates for serial-issue (see previous commit for staff // feature)
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:52:54 -05:00
Paul POULAIN
fa4cead909 reintroducing history manual modification feature
The history start date and enddate is also useful to modify manually for the same reason : your serial collection may be older than your Koha serial management.

This commit reintroduce the feature.

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:52:52 -05:00
Paul POULAIN
b2c04e7c20 bugfix for saving issuing rules
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:52:50 -05:00
paul
0bf436a0ea use HomeOrHoldingBranch to determine if a return is valid or not
in fact, i'm not 100% sure of this bugfix : I don't see the case where a return should be done directly to homebranch, when the check out has been done at holdingbranch
so maybe we could hardcode 'holdingbranch' instead of using HomeOrHoldingBranch

the patch as written won't break anything existing.

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-10 02:52:49 -05:00
Joshua Ferraro
32cfac05cf Fixing bug 2005: ISBN Search
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-09 05:46:03 -05:00
Joe Atzberger
42e81b4cdb AddRenewal - handle opac-renewal, empty branch arg.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 19:49:17 -05:00
Joe Atzberger
c13c16bf99 Allow param "bornum" as in template, not just "borrowernumber". Added FIXMEs.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 19:49:06 -05:00
Joshua Ferraro
4d3519dffd Partial fixes to enable unapi for non-zebra and non-public-facing sru
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 19:48:55 -05:00
Galen Charlton
cdddac6c9b bug 2004: changes to guided reports on items
* Added items.location and items.ccode to list of
  columns available for limiting
* choice of item type column (i.e., biblioitems.itemtype
  or items.itype) to limit by now respects
  item-level_itypes syspref

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 17:00:12 -05:00
Andrew Moore
73d904a3bf bug 1980: changes to label-item-search.pl to allow pagination over large result sets
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 17:00:10 -05:00
Andrew Moore
f4725d5059 Bug 1980: some cleanup, getting ready to add pagination to label-item-search.pl
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 17:00:08 -05:00
Joe Atzberger
931830af1e Dates.pm - trivial perldoc corrections
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 17:00:07 -05:00
Chris Nighswonger
9a55637760 NOTE: REQUIRES INSTALLATION OF Image::Magick; Adding image scaling/resizing capability to picture-upload.pl
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 17:00:05 -05:00
Joe Atzberger
d1601b26a6 Quell 7 warnings: "my" variable $irule masks earlier declaration in same scope.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 17:00:03 -05:00
fa9a411a2f Adding max-width to patron image in sidebar, correcting some markup in picture uploads.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 08:37:12 -05:00
f9de575250 Adding COinS support to cart pop-up; Hide similar items in opac-details if no similar items are found.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 08:37:11 -05:00
51c106bb58 Fixes for tablesorter problems when there are no checkouts from today; Other markup corrections.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 08:37:09 -05:00
78ffc76fad Some minor markup corrections, style fixes.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 08:37:06 -05:00
8363da8b09 Tweaking display of resident search form; Tweaking labels breakcrumbs; Formatting tools menu.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 08:37:05 -05:00
2412574844 Completing table sort js integration for checkouts and holds.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 08:37:04 -05:00
be99aba949 Some formatting changes, bringing displays in circ and moremember more in line with each other
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 08:37:03 -05:00
Ryan Higgins
2eed36a08e Fix calls to CalcFine, and make fines obey CircControl syspref (get homebranch withssue data).
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-08 08:37:01 -05:00
Joshua Ferraro
a5a0378f92 adding MARC21 record descriptions as per loc.gov//marc/bibliographic/
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-07 21:20:59 -05:00
Joshua Ferraro
eee5289de5 adding additional statuses display for XSL
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-07 21:20:50 -05:00
Joshua Ferraro
d5559cb766 adding Library of Congress Classification to display
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-07 21:20:41 -05:00
Joshua Ferraro
ecbbb20123 removing escape=url as it broke '=' for q=query
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-07 21:20:32 -05:00
Joshua Ferraro
faa9a39694 adding famfamfam iconset, improving isbn for amazon content, etc.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
2008-04-07 21:20:22 -05:00