The PDF templates for purchase orders now live in the
directory koha-tmpl/intranet-tmpl/prog/pdf to separate
them from code. As no automatic translation system for
PDF files is currently implemented, I'm keeping them out
of the language subdirectories for now.
At present, there are two choices of templates for printing
purchase orders (AKA basket groups), controlled by setting
the OrderPdfFormat syspref:
pdfformat::layout2pages (two-page layout)
pdfformat::layout3pages (three-page layout)
To customize a template or to add a new one requires two steps:
* modifying the PDF; note that OpenOffice source files
are included as a way of generating the PDF
* modifying the code in acqui/pdfformat/layout*.pm to
position the order text onto the template
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Since new acquisition module workflow and specifications is not
documented, this fix is more an hypothesis than a patch.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
This patch unifies the search in neworder so that the same biblios should be sent back when searching from catalogue search or from box.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Perl generates depreciation warnings on compilation
caused by use of ambiguous syntax. Seemed that an
underlying confusion as to row's type
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
basket.pl calculates variables i, odd and count which are
no longer used in the template
removing them allows some simplification of the main loop
and cuts out on an extra db call
Loop through basketgroups also made more readable
Try to dimish the number of undef warnings filling the logs
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
We've checked the return for definedness and
assigned an empty string to it ao we don't want
to make it undef again
This is a good argument that cascading if-elses expecially with
long unstructured elses are a bad idea
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Script was written as though it had an array rather than
a single supplier. Replaced the excess punctuation with a single
supplier variable
replaced the C-style currency loop with a simpler perl-style one
we only need 1 loop not multiples
Changed variable name $GST to $tax_rate it's not magical and not a constant
and we all know what tax is
Fetch Contract data once rather than twice from two different modules
Correct size of discount data on display
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
when closing a basket without creating a basketgroup, the group is still created => corrected
+ replace "create a basketgroup?" by "create a purchase order now?" in confirmation step.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Basket.pl: withdrawal of the "can not close the basket"button. only Uncerain
prices button is displayed. And removing the "??" in the price columns,
replaced by "uncertain" in rrp column
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
* 'bug2505_patches' of git://git.catalyst.net.nz/koha: (24 commits)
Bug 2505 - use strict and warnings in sax_parser_test
Bug 2505 - enable warnings for link_bibs_to_authorities
Bug 2505 - add strict and warnings to perlmodule_ls
Bug 2505 - add strict and warnings to check_sysprefs
Bug 2505 - Add commented use warnings where missing in *.t
Bug 2505 - Add commented use warnings where missing in *.pm
Bug 2505 - Add commented use warnings where missing in the cataloguing/ directory
Bug 2505 - Add commented use warnings where missing in the misc/ directory
Bug 2505 - Add commented use warnings where missing in the tools/ directory
Bug 2505 - Add commented use warnings where missing in the installer/ directory
Bug 2505 - Add commented use warnings where missing in the rotating_collections/ directory
Bug 2505 - Add commented use warnings where missing in the C4/ directory
Bug 2505 - Add commented use warnings where missing in the serials/ directory
Bug 2505 - Add commented use warnings where missing in the catalogue/ directory
Bug 2505 - Add commented use warnings where missing in the sms/ directory
Bug 2505 - Add commented use warnings where missing in the opac/ directory
Bug 2505 - Add commented use warnings where missing in the virtualshelves/ directory
Bug 2505 - Add commented use warnings where missing in the suggestion/ directory
Bug 2505 - Add commented use warnings where missing in the admin/ directory
Bug 2505 - Add commented use warnings where missing in the circ/ directory
...
Conflicts:
C4/Auth_with_cas.pm
acqui/supplier.pl
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
on a new order, the branch limits for the budgets where not managed properly
if a budget had a limit on branch, it was not respected : the list displayed all budgets, including other branches than mine
Signed-off-by: Henri-Damien LAURENT <henridamien.laurent@biblibre.com>
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Previously, if the tax rate for a particular seller was '0.000' it
couldn't be edited. Now, the tax information always is shown if there
is a default system one, or one for that seller.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Fixes generation of empty index page when total_parcels is a multiple of pagesize
Remove some calculations whose results were not used
Make variable names meaningful (results and count arnt)
Fix errors in pod syntax
Make what code does clearer to readers who are not computers
Use a subroutine
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Remove unnecessary db calls and processing from acqui-home.pl
Do not duplicate processing of fields
Declare variables closer to use
Remove unnecessary holding vars
Replace some anonymous var names by something more meaningful
Do not generate a toggle variable use Template's LOOP vars
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
- moving some links to the left part of koha (currencies and suggestions)
- removed currency table
- changing supplier display
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Before formatting and doing arithmetic with them we should
ensure undefined numeric elements are numbers
(This should be enforced in the db)
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
New way, correct way to use GetMember is
GetMember(field => fieldvalue[, field2 => field2value ...]);
e.g.,
GetMember(borrowernumber => $borrowernumber);
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Fixed two calls where new interface was not used
Arguably new syntax allows more options than we require but it was not catching
error cases (when 0 or undef is passed). It also can now be called in ways
which would validly return multiple hits but explicitly does not
(nor does calling code expect this)
This patch should quieten the flood of errors
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
New version of patch to apply against 3.2alpha
Also remove related FIXME message that was displaying to the user
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
This patch fixes three bugs:
Bug 3965: gist sys pref not taken into account
changed it so that GST does not show on basket if gist pref set to 0
changed it so that GST fields don't appear on vendor record if gist pref=0
Bug 3979: gst options not lining up
fixed layout on vendor add/edit form so GST radio buttons line up right
Bug 3981: GST confusing in en-US
there is no GST in the US and so GST changed to 'Tax' in templates
Also, a small spacing fix was made to the path on the basket grouping
template.
Renamed pdfformat to OrderPdfFormat and created OrderPdfTemplate to stock the PDF in the database.
Added a new type of syspref nammed "Upload".
Rewritte, translation and cleaning of the PDF template.
Librarian are now able to select a different delivery place for each basketgroup. They can choose one from the branch list or manualy using a textarea.
Database schema and PDF generation have been modified to reflect these changes.
neworderempty : problems with data updates
booksellers.tmpl : TMPL_VAR not in comments
list_price becomes listprice in neworderempty script as in acq.js
- reindenting Suggestions.pm
- removing useless code in acqui-home.pl & fixing # of pending suggestion display
- add suggestion to order : displaying for selection suggestions accepted by the librarian (and reindenting)
- XHTMLing acqui-home (& removed useless parts)
NOTE ABOUT XHTML (could be useful) : <tfoot> must be BEFORE <tbody> in a <table>, even if, of course, it is displayed after.
- basket.pl: updating display, formatting dates,
- neworderempty: updating display, removing useless code, using ACQ framework if it exist. The ACQ framework will be used for creating items record during acquisitions. If it does not exist, default is used instead (which has many more informations, lot of them being irrelevant during acquisition, like the barcode)
- new order from imported batch: rewrite of the workflow. Now uses neworderempty and changing status of import_record to 'imported'
- s/copyrightdate/publicationyear/ as it's what libraries uses when ordering
- fixing some warnings
-
- removing useless fields from aqbooksellers table: specialty, deliverydays,followupdays,followupscancel,nocalc, invoicedisc They were in the DB schema, but unused for years
- reworked bookseller and contract gui
- no warning thrown
NOTE : updatedatabase not done for field removal in aqbooksellers table. Should have:
ALTER TABLE `aqbooksellers`
DROP `deliverydays`,
DROP `followupdays`,
DROP `followupscancel`,
DROP `specialty`,
DROP `nocalc`;
- I user has basket grouping permissions, don't display javascript popup for confirmation
- if user has basket grouping permissions, after closing the basket redirect him to a page which asks which basketgroup to affect the basket to (with possibility to create a new basketgroup)
- when done with this, redirect him to basketgrouping.pl to be able to print the basketgroup at once
- factor out basket closing code from booksellers.pl (what was it doing there anyways?)
* fix a bug for new orders budget : the Asort1 was displayed by default. Now, it's the sortN_authcat of the 1st budget (the one selected by default)
* change in GetBudgetAuthCats : returns all auth values used by at least one budget (not Asort* categories, as previously)
* code cleaning in GetAuthvalueDropbox (and select aqbudgets.* instead of *, to avoid data corruption due to duplicate column name)
* there can be more than 1 active period. This has been added to deal with temporary budgets (like "10000€ to spent in the next 3 months")
* all active budgets are retrieved
* budget available for everyone now displayed correctly
also :
* fixing some hardcoded values
* removing a warn
* the .odt contains the pages 1 & 2. Pages 3 to X contains the basket, and are generated on the fly. Page 1 contains a general header, and page 2 contains the list of baskets (with totals)
* the .pdf contains the pdf generated from the .odt
* the .pm contains the sub to generate the PDF from the .pdf file
* deal with import from staged file
* deal with z3950 import
* deal with granular permissions
* deal with uncertain price
* deal with create item if SysPref set to create items on ordering
lot of new things:
* basket now explicitely created
* they can have a name, a bookseller note, a private (library) note, a contract attached
* deal with granular permissions
* feature to delete a basket
* feature to close/reopen a basket
in template, add link to fill a basket from a z3950 search or from a staged file
Enhancing C4::SearchSuggestion
And changing its API
Changing C4::Suggestions API taking a hashref for NewSuggestion and ModSuggestion
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
This update the way Member is added and editing so that import and Edition
could be best automatized
GetMember evolves and allow ppl to serach on a hash of data
Adding SQLHelper A new package to deal with INSERT UPDATE and SELECT
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Fixes several xhtml in parcels.tmpl and enables highlighting within its data table. Removes unnecessary variable from parcels.pl.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Fixes alphabetization of library dropdown in New Order, and the shelf location, item type, and collection code in the Receive Items pages. This patch takes care of Joann's original purpose of creating the bug enhancement.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Removed unused toggle and line(even) variables from booksellers.pl. Added highlighting to the two display tables in booksellers.tmpl.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This has bearing on bugs 2905, 2665, 2514 and other "wide character" crashes
related to diacritics and Unicode. This should help open the door for reliable
input of diacriticals via acquisitions.
MARC21_utf8_flag_fix.pl diagnoses and fixes existing problems with MARC data
affected by the bug.
Adding SetMarcUnicodeFlag to TransformKohaToMarc prevents the bug from corrupting
further data.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
It looks like a lot of change, but it isn't much:
perltidy, removed unused "toggle" code, and corrected comments.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Convert to GetBranchesLoop, remove unused variables.
Pull out params that are assigned the same value in each loop and just assign them once.
Pull out params that are assigned the same value in each half of the conditional, and just assign them unconditionally.
Remove useless call of $template->param($count).
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
The javascript is malformed and therefore fails the onsubmit check if
gist does not receive a value. This patch allows failover to default 0.
Also removed an unused dbh.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
I've duplicated the "Add to Order" block on the search results page to display after a user has searched for an existing record to add to an order. This block is displayed whether or not results were found on the assumption that a non-empty result set may not contain the desired result. Changes to neworderbiblio.pl allow supplier name to appear in breadcrumb nav.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Most Perl scripts (as opposed to modules) do
not need to require Exporter.
No user-visible or documentation changes.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
It has to be reintroduced, as some (most in France) libraries don't create
items on recieve, but after "equipment" step.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
If a new order was created and no fund selected, a db error was thrown due to the
'bookfundid' field being set to NULL. This patch sets the first fund retrieved from
available funds as the default selection in the scrolling list.
A further enhancement might be to allow the library to choose which fund is the
default fund.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
&NewOrder did not save the branchcode posted with a new order. This patch adds that param.
Added code to select the branch the order is for in the branch dropdown list on
acqui/orderreceive.pl
Updating POD and tests
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
Added error catching for bad user input on number of days. I.E., if you
try to filter by "bAd", you now get an error message prompting for valid
digits. Also I updated highlighting to use loop_context_vars.
Fixed filtering to work on either days, vendor or both. Previously, if
you selected a number of days, you had to select a vendor or else got
empty results. DOCUMENTATION NOTE: this supplies the expected behavior,
so specifying vendor is no longer required.
Changed filters form to GET method.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
yesterday, the C4::Output::pagination_bar had a bug in it that I was crudely working around.
atz fixed that bug this morning. This patch removes the workaround. Thanks, atz!
I'm sending along atz's patch again with my signoff. It needs to be applied before this, as does the
other 1980 patch. I have sent that along (again), too, with a modified subject line. That makes a total of 3 patches for 1980.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
C4::Search::SimpleSearch was alredy patched to let you pass in the number of results you want back.
These instances were not using the new API. This patch makes all calls to SimpleSearch specify a limit.
I improved the documentation of SimpleSearch a bit to include the third returned value.
I believe there's a bug in C4::Output::pagination_bar, in that it doesn't deal well with URLs
with only one pair of parameter=value passed to it. I'm getting around this by passing in a second
pair that does nothing.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>