[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2014-08-07 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Fridolin SOMERS fridolyn.som...@biblibre.com changed:

   What|Removed |Added

 Status|Pushed to Master|Pushed to Stable
 CC||fridolyn.som...@biblibre.co
   ||m

--- Comment #37 from Fridolin SOMERS fridolyn.som...@biblibre.com ---
Pushed to 3.14.x, will be in 3.14.10

This enhancement applies perfectly to 3.14.x and is use in many patches so I
decided in the end to integrate it.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2014-01-24 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Jonathan Druart jonathan.dru...@biblibre.com changed:

   What|Removed |Added

 Blocks||11587

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-30 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Galen Charlton gmcha...@gmail.com changed:

   What|Removed |Added

 Status|Passed QA   |Pushed to Master

--- Comment #36 from Galen Charlton gmcha...@gmail.com ---
Pushed to master.  Thanks, Kyle and Jonathan!

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-30 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Galen Charlton gmcha...@gmail.com changed:

   What|Removed |Added

 Blocks||7002

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #34 from Katrin Fischer katrin.fisc...@bsz-bw.de ---
Created attachment 23861
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=23861action=edit
[PASSED QA] Bug 10277: Add UT for C4::Context::IsSuperLibrarian

Note that I modify the return value. Before this patch, it returned an
empty string or 1. Now it returns 0 or 1.

Test plan:
- same as the original patch
- verify that unit tests pass:
prove t/Context.t

Signed-off-by: Kyle M Hall k...@bywatersolutions.com
Signed-off-by: Katrin Fischer katrin.fischer...@web.de
Passes all tests and QA script, including new tests.
Checked the code and tested superlibrarian behaviour in some places:

moremember.pl:
With IndyBranches only superlibrarian can delete borrowers from
other branches. Accessing the borrower with a direct link.
OK

C4/Members.pm
With IndyBranches only superlibrarian can search for borrowres
from other branches.
OK

tools/holidays.pl
With IndyBranches only superlibrarian can edit holidays for other
branches.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Katrin Fischer katrin.fisc...@bsz-bw.de changed:

   What|Removed |Added

  Attachment #23523|0   |1
is obsolete||
  Attachment #23635|0   |1
is obsolete||

--- Comment #33 from Katrin Fischer katrin.fisc...@bsz-bw.de ---
Created attachment 23860
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=23860action=edit
[PASSED QA] Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

Test Plan:
1) Apply this patch
2) Verify superlibrarian behavior remains unchanged

Signed-off-by: Joel Sasse jsa...@plumcreeklibrary.net
Signed-off-by: Katrin Fischer katrin.fischer...@web.de
Comments on second patch.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Katrin Fischer katrin.fisc...@bsz-bw.de changed:

   What|Removed |Added

 Status|Signed Off  |Passed QA
   Patch complexity|--- |Medium patch

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Katrin Fischer katrin.fisc...@bsz-bw.de changed:

   What|Removed |Added

 CC||katrin.fisc...@bsz-bw.de
   See Also||http://bugs.koha-community.
   ||org/bugzilla3/show_bug.cgi?
   ||id=7002

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #35 from Katrin Fischer katrin.fisc...@bsz-bw.de ---
Hi Kyle, I found bug 7002 - it looks like there could be some more occurences
to fix.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-18 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #29 from Jonathan Druart jonathan.dru...@biblibre.com ---
Created attachment 23634
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=23634action=edit
Bug 10277: Add UT for C4::Context::IsSuperLibrarian

Note that I modify the return value. Before this patch, it returned an
empty string or 1. Now it returns 0 or 1.

Test plan:
- same as the original patch
- verify that unit tests pass:
prove t/Context.t

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-18 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Jonathan Druart jonathan.dru...@biblibre.com changed:

   What|Removed |Added

 Status|Signed Off  |Needs Signoff

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-18 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #30 from Jonathan Druart jonathan.dru...@biblibre.com ---
(In reply to Kyle M Hall from comment #26)
 I have been unable to find a good way to UT this sub. MockModule doesn't
 seem to work in this context, since we are trying to mock a subroutine
 outside the module and then use the mocked sub inside the module.

It seems to work using MockModule. Have a look at my patch.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-18 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

 Status|Needs Signoff   |Signed Off

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-18 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #23634|0   |1
is obsolete||

--- Comment #31 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 23635
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=23635action=edit
Bug 10277: Add UT for C4::Context::IsSuperLibrarian

Note that I modify the return value. Before this patch, it returned an
empty string or 1. Now it returns 0 or 1.

Test plan:
- same as the original patch
- verify that unit tests pass:
prove t/Context.t

Signed-off-by: Kyle M Hall k...@bywatersolutions.com

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-18 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #32 from Kyle M Hall k...@bywatersolutions.com ---
Great work! Thanks! I had attempted a UT using MockModule, but I must have been
setting it up incorrectly.


(In reply to Jonathan Druart from comment #30)
 (In reply to Kyle M Hall from comment #26)
  I have been unable to find a good way to UT this sub. MockModule doesn't
  seem to work in this context, since we are trying to mock a subroutine
  outside the module and then use the mocked sub inside the module.
 
 It seems to work using MockModule. Have a look at my patch.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-13 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Jonathan Druart jonathan.dru...@biblibre.com changed:

   What|Removed |Added

 CC||jonathan.dru...@biblibre.co
   ||m

--- Comment #24 from Jonathan Druart jonathan.dru...@biblibre.com ---
unit tests should be provided for the new IsSuperLibrarian routine.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-13 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #23480|0   |1
is obsolete||
  Attachment #23482|0   |1
is obsolete||

--- Comment #25 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 23518
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=23518action=edit
Squashed the two patches together. No reason to keep them separate.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-13 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

 CC||k...@bywatersolutions.com

--- Comment #26 from Kyle M Hall k...@bywatersolutions.com ---
(In reply to Jonathan Druart from comment #24)
 unit tests should be provided for the new IsSuperLibrarian routine.

I have been unable to find a good way to UT this sub. MockModule doesn't seem
to work in this context, since we are trying to mock a subroutine outside the
module and then use the mocked sub inside the module.

On the other hand, this subroutine is literally two lines. If you have an idea
on how to unit test this sub, please let me know!

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-13 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #23518|Squashed the two patches|Bug 10277 - Add
description|together. No reason to keep |C4::Context-IsSuperLibrari
   |them separate.  |an()

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-13 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Joel Sasse jsa...@plumcreeklibrary.net changed:

   What|Removed |Added

 Status|Needs Signoff   |Signed Off

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-13 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

sandbo...@biblibre.com sandbo...@biblibre.com changed:

   What|Removed |Added

 CC||sandbo...@biblibre.com

--- Comment #27 from sandbo...@biblibre.com sandbo...@biblibre.com ---
Patch tested with a sandbox, by Joel Sasse jsa...@plumcreeklibrary.net

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-13 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #28 from sandbo...@biblibre.com sandbo...@biblibre.com ---
Created attachment 23523
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=23523action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

Test Plan:
1) Apply this patch
2) Verify superlibrarian behavior remains unchanged

Signed-off-by: Joel Sasse jsa...@plumcreeklibrary.net

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-13 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

sandbo...@biblibre.com sandbo...@biblibre.com changed:

   What|Removed |Added

  Attachment #23518|0   |1
is obsolete||

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #21144|0   |1
is obsolete||

--- Comment #20 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 23479
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=23479action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

Test Plan:
1) Apply this patch
2) Verify superlibrarian behavior remains unchanged

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

 Status|Failed QA   |Needs Signoff

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #23479|0   |1
is obsolete||

--- Comment #21 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 23480
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=23480action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

Test Plan:
1) Apply this patch
2) Verify superlibrarian behavior remains unchanged

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #22 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 23481
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=23481action=edit
Bug 10277 [Followup] - Replace all remaining userenv checks with
IsSuperLibrarian()

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #23481|0   |1
is obsolete||

--- Comment #23 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 23482
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=23482action=edit
Bug 10277 [Followup] - Replace all remaining userenv checks with
IsSuperLibrarian()

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

 Blocks||10502

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

 Blocks|10278   |

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-12-12 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

 Blocks|10502   |

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-11-24 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Joel Sasse jsa...@plumcreeklibrary.net changed:

   What|Removed |Added

 CC||jsa...@plumcreeklibrary.net

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-09-24 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Julian Maurice julian.maur...@biblibre.com changed:

   What|Removed |Added

 CC||julian.maur...@biblibre.com

--- Comment #18 from Julian Maurice julian.maur...@biblibre.com ---
Hi,

I just wanted to report that it remains files where IsSuperLibrarian could be
used:

$ git grep '{flags}' | grep 1
C4/Acquisition.pm:if ( ($userenv)  ( $userenv-{flags} != 1 ) ) {
C4/Acquisition.pm:if ( ($userenv)  ( $userenv-{flags} != 1 ) ) {
C4/Acquisition.pm: C4::Context-userenv-{flags} != 1 ) {
C4/Acquisition.pm:if ( $userenv  ($userenv-{flags} || 0) != 1 ) {
C4/Branch.pm:C4::Context-userenv-{flags} %2 != 1  
C4/Context.pm:return $userenv-{flags} % 2 == 1;
C4/Items.pm:elsif ( !( C4::Context-userenv-{flags}  1 )
acqui/basket.pl:unless ( $userenv-{flags} == 1 ) {
acqui/basket.pl:unless ( $userenv-{flags} == 1 ) {
acqui/neworderempty.pl:C4::Context-userenv-{flags}!=1  
cataloguing/additem.pl:   C4::Context-userenv-{flags}!=1 
  
circ/ysearch.pl:   (C4::Context-userenv-{flags} % 2) !=1
suggestion/suggestion.pl:C4::Context-userenv-{flags}!=1  
tools/export.pl:   !( C4::Context-userenv-{flags}  1 )
tools/export.pl: !( C4::Context-userenv-{flags}  1 ) )

and I think Srdjan is right: 'if' should become 'unless' in C4/Circulation.pm

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-09-24 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Julian Maurice julian.maur...@biblibre.com changed:

   What|Removed |Added

 Status|Needs Signoff   |Failed QA

--- Comment #19 from Julian Maurice julian.maur...@biblibre.com ---
Setting to Failed QA for the if/unless problem.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-09-18 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #17 from Srdjan Jankovic srd...@catalyst.net.nz ---
Kyle, did you check C4/Circulation.pm please?

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-09-17 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #20776|0   |1
is obsolete||

--- Comment #16 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 21144
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=21144action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

Test Plan:
1) Apply this patch
2) Verify superlibrarian behavior remains unchanged

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-09-04 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #19229|0   |1
is obsolete||

--- Comment #14 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 20776
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=20776action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

Test Plan:
1) Apply this patch
2) Verify superlibrarian behavior remains unchanged

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-09-04 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #15 from Srdjan Jankovic srd...@catalyst.net.nz ---
I could be wrong with those, so please double check: C4/Circulation.pm - if
should become unless ?

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-06-25 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #18518|0   |1
is obsolete||

--- Comment #13 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 19229
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=19229action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

Test Plan:
1) Apply this patch
2) Verify superlibrarian behavior remains unchanged

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-06-03 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #11 from Galen Charlton gmcha...@gmail.com ---
(In reply to comment #10)
 my $userenv = C4::Context-userenv or carp(...);
 return C4::Context-userenv-{flags} % 2 == 1;
 
 It saves one C4::Context-userenv call.

Does it?  Did you mean

my $userenv = C4::Context-userenv or carp(...);
return $userenv-{flags} % 2 == 1;

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-06-03 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #12 from Srdjan Jankovic srd...@catalyst.net.nz ---

 Does it?  Did you mean
 
 my $userenv = C4::Context-userenv or carp(...);
 return $userenv-{flags} % 2 == 1;

Sure, sorry, not enough coffee I guess...

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-06-02 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Srdjan Jankovic srd...@catalyst.net.nz changed:

   What|Removed |Added

 CC||srd...@catalyst.net.nz

--- Comment #10 from Srdjan Jankovic srd...@catalyst.net.nz ---
I believe it would be slightly better to write

my $userenv = C4::Context-userenv or carp(...);
return C4::Context-userenv-{flags} % 2 == 1;

It saves one C4::Context-userenv call.

I admire this kind of work, having C4::Context-userenv-{flags} % 2 != 1 all
over the place is just scandalous.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-30 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall kyle.m.h...@gmail.com changed:

   What|Removed |Added

 Blocks||10263

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-30 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall kyle.m.h...@gmail.com changed:

   What|Removed |Added

 Blocks||10276

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-30 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #18427|0   |1
is obsolete||

--- Comment #9 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 18518
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18518action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

Test Plan:
1) Apply this patch
2) Verify superlibrarian behavior remains unchanged

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-28 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #18206|0   |1
is obsolete||

--- Comment #3 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 18421
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18421action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-28 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #18421|0   |1
is obsolete||

--- Comment #4 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 18422
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18422action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-28 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #5 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 18425
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18425action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian() - Followup - Use
IsSuperLibrarian()

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-28 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall kyle.m.h...@gmail.com changed:

   What|Removed |Added

 Status|Failed QA   |Needs Signoff

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-28 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #6 from Kyle M Hall kyle.m.h...@gmail.com ---
 - I'm pretty sure terminating (via confess) is not the right thing to do if
 the userenv isn't set up yet; in particular, this has the potential to break
 command-line scripts for no good reason.

Good point, switched the confess to a carp!

 - Doing it via confess() without loading the Carp module is wrong regardless.

I've added a use Carp to C4::Context. I think this is the best way to do it,
but the BEGIN block does some stuff with CGI::Carp. I don't believe it will
cause problems, but I just wanted to point this out.

 - A patch that introduces a new C4::Context method but never uses it is
 untestable.  It should, at the very least, attempt to replace some of the
 opaque userenv flags tests, and ideally should aim to replace them all.  In
 other words, if we're going to refactor this, let's refactor this all the
 way.

I totally agree! I had originally split this off from another patch that uses
it, but I'm in total agreement. I've attached a followup that switches all
known code for superlibrarian checks to use IsSuperLibrarian.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-28 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #7 from Kyle M Hall kyle.m.h...@gmail.com ---
Test Plan:
1) Apply these patches
2) Verify superlibrarian behavior remains unchanged

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-28 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall k...@bywatersolutions.com changed:

   What|Removed |Added

  Attachment #18422|0   |1
is obsolete||
  Attachment #18425|0   |1
is obsolete||

--- Comment #8 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 18427
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18427action=edit
Squashed both patches together. There is really no need to have them separated.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-28 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall kyle.m.h...@gmail.com changed:

   What|Removed |Added

  Attachment #18427|Squashed both patches   |Bug 10277 - Add
description|together. There is really   |C4::Context-IsSuperLibrari
   |no need to have them|an()
   |separated.  |

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-20 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Galen Charlton gmcha...@gmail.com changed:

   What|Removed |Added

 Status|Needs Signoff   |Failed QA
 CC||gmcha...@gmail.com

--- Comment #2 from Galen Charlton gmcha...@gmail.com ---
I agree with the notion that the method for checking whether a session has
superlibrarian privileges should be more clear.

The patch is problematic, however:

- I'm pretty sure terminating (via confess) is not the right thing to do if the
userenv isn't set up yet; in particular, this has the potential to break
command-line scripts for no good reason.
- Doing it via confess() without loading the Carp module is wrong regardless.
- A patch that introduces a new C4::Context method but never uses it is
untestable.  It should, at the very least, attempt to replace some of the
opaque userenv flags tests, and ideally should aim to replace them all.  In
other words, if we're going to refactor this, let's refactor this all the way.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-17 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

--- Comment #1 from Kyle M Hall k...@bywatersolutions.com ---
Created attachment 18206
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18206action=edit
Bug 10277 - Add C4::Context-IsSuperLibrarian()

The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv  $userenv-{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-17 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall kyle.m.h...@gmail.com changed:

   What|Removed |Added

 Status|NEW |Needs Signoff

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-17 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall kyle.m.h...@gmail.com changed:

   What|Removed |Added

 Blocks||10278

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/


[Koha-bugs] [Bug 10277] Add C4::Context-IsSuperLibrarian()

2013-05-17 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10277

Kyle M Hall kyle.m.h...@gmail.com changed:

   What|Removed |Added

   Assignee|gmcha...@gmail.com  |kyle.m.h...@gmail.com

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/