Re: [Koha] Ajax call in self checkout not working in Koha 17.05

2017-12-06 Thread Graham, Stephen
Krishna - what does the Ajax call look like? A bit of sample code might help?

Stephen

-Original Message-
From: Koha [mailto:koha-boun...@lists.katipo.co.nz] On Behalf Of Krishna K
Sent: 06 December 2017 09:01
To: koha@lists.katipo.co.nz
Subject: Re: [Koha] Ajax call in self checkout not working in Koha 17.05

Hi all,

Resending this - any help on using Ajax call with Koha 17.05 would be 
appreciated. Please see the below mail I had sent earlier related to a 
customization in self checkout module that uses Ajax  call to query the book 
title - this was working fine in 16.11 but not working in 17.05. Thank you,

On Mon, Nov 27, 2017 at 3:50 PM Krishna K 
wrote:

>
> Hi all,
>
> We are currently running Koha 16.11.
>
> On a new hardware, we have installed Koha 17.05,  with Ubuntu 16.04 64 
> bit,  Mariadb 15.1 and Php 7.1.  We plan to use it as the production 
> machine shortly.  We have a small customization in self checkout that 
> that uses an ajax call to query the for the book title, to display the 
> book title at the time of self checkout. This is not working in the new 
> machine.
>
>
> But the same customization is working on our earlier version which 
> uses Ubuntu 14.04 32 bit, Koha 16.11, MySql 5.1 and Php 5.6.
>
>
> Could anyone help us with some hints on why the Ajax call is not 
> working in the new setup ?
>
>
> Thanks in advance,
>
> Krishna
>
> --
> Regards,
> Krishna
>
--
Regards,
Krishna
___
Koha mailing list  http://koha-community.org Koha@lists.katipo.co.nz 
https://lists.katipo.co.nz/mailman/listinfo/koha
___
Koha mailing list  http://koha-community.org
Koha@lists.katipo.co.nz
https://lists.katipo.co.nz/mailman/listinfo/koha


Re: [Koha] Koha & Primo link (sub-question: University of Tyler, TX are you around ?)

2017-11-09 Thread Graham, Stephen
I know it's not Primo, but we do something similar with Summon. We wrote a 
custom script which outputs some XML which Summon reads, and then renders the 
availability. The script can take one, or several Koha BIB IDs. If you look at:

http://herts.summon.serialssolutions.com/#!/search?ho=t=en-UK=perl%20cookbook

You'll see the functionality/script in action.  The first item in the list has 
a "Book" field which says:

Available, 005.133 CHR, College Lane LRC, Main Shelves (+3 More)

Clicking on (+3 More), shows all the availability. Under the bonnet it's using 
the output from this:

https://library.herts.ac.uk/cgi-bin/koha/UH/rtasummon2.pl?bibids=119683

The BIB IDS can be separated by a colon, so to get the "real time availability" 
for two BIB IDS you would call:

https://library.herts.ac.uk/cgi-bin/koha/UH/rtasummon2.pl?bibids=119683:23

Stephen

-Original Message-
From: Koha [mailto:koha-boun...@lists.katipo.co.nz] On Behalf Of Hugo Agud
Sent: 09 November 2017 09:06
To: Paul Poulain 
Cc: Koha list 
Subject: Re: [Koha] Koha & Primo link (sub-question: University of Tyler, TX 
are you around ?)

Hi Paul

I do not know how they have achieved that, but I can imagine is something very 
similar to vufind (opensource discovery)

Do you know Vufind? it is the same index the content and with the info indexed 
the system is able to check in real time the holdings and the availability.

In vufind there are two connectors, one usins ILS-DI and the other using mysql 
connect

Do you wish more info on Vufind in order to compare?

Hugo






2017-11-09 10:01 GMT+01:00 Paul Poulain :

> Hello,
>
> I'm trying to understand what can be done on Primo, regarding the link 
> with Koha.
>
> It seems that the University of Tyler, TX has succeeded to display the 
> availability of a document on primo search results:
>
> https://uttyler-primo.hosted.exlibrisgroup.com/primo-explore
> /search?query=any,contains,Cognitive%20therapy%20of%
> 20depression=default_tab_scope=default_scope=UTT
> =0
>
> The 1st result (for me, and now) shows: "checked out from", and points 
> to
>
> https://catalog.uttyler.edu/cgi-bin/koha/opac-detail.pl?biblionumber=1
> 3966
>
>
> On the other hand, a search on:
>
> https://uttyler-primo.hosted.exlibrisgroup.com/primo-explore
> /search?query=any,contains,handbook%20stress%20health&
> tab=default_tab_scope=default_scope=UTT=0
>
> says "Available at UT TYler Main Campus Stacks (BF575.S75 2017)", but 
> if you go to the Koha bib record: https://catalog.uttyler.edu/cg
> i-bin/koha/opac-detail.pl?biblionumber=978296
>
> it's checked out, so not available.
>
> *QUESTIONS*:
>
>  * has someone linked Koha & Primo & successfully displayed the
>availability in real time ? I have other exemples of Primo+Koha, but
>they are all saying "click here so see availability".
>  * if someone from Tyler is around, can you explain what you made ;)
>
> --
> Paul Poulain, Associé-gérant / co-owner BibLibre, Services en 
> logiciels libres pour les bibliothèques BibLibre, Open Source software 
> and services for libraries
>
> ___
> Koha mailing list  http://koha-community.org Koha@lists.katipo.co.nz 
> https://lists.katipo.co.nz/mailman/listinfo/koha
>



-- 

*Hugo Agud - Orex Digital *

*www.orex.es *


[image: www.orex.es/koha] 
   [image: www.orex.es/vufind] 



Director

Calle Sant Joaquin,117, 2º-3ª · 08922 Santa Coloma de Gramanet - Tel: 933
856 138   ha...@orex.es · http://www.orex.es/



No imprima este mensaje a no ser que sea necesario. Una tonelada de papel
implica la tala de 15 árboles y el consumo de 250.000 litros de agua.



Aviso de confidencialidad
Este mensaje contiene información que puede ser CONFIDENCIAL y/o de USO
RESTRINGIDO. Si usted no es el receptor deseado del mensaje (ni
está autorizado a recibirlo por el remitente), no está autorizado a copiar,
reenviar o divulgar el mensaje o su contenido. Si ha recibido este mensaje
por error, por favor, notifíquenoslo inmediatamente y bórrelo de su sistema.
___
Koha mailing list  http://koha-community.org
Koha@lists.katipo.co.nz
https://lists.katipo.co.nz/mailman/listinfo/koha
___
Koha mailing list  http://koha-community.org
Koha@lists.katipo.co.nz
https://lists.katipo.co.nz/mailman/listinfo/koha


[Koha] Holds and emails question

2016-10-19 Thread Graham, Stephen
Hi All - we've only just implemented holds, we went live 3 weeks ago. One thing 
we are grappling with is books which have holds on, going "missing" before they 
get to the holds shelf. At the moment if a user returns an item via the 
Selfcheck machines,which is on hold for another user, then an email (informing 
the user that their book is ready to collect) is automatically added to the 
message_queue table and then sent when the email cronjob runs. However, the 
user may not actually place the returning item in the holds bin, they may put 
it on the normal return trolley, where some else may take it to read in the 
Library and then anything can happen to it. In cases like these the email has 
already been generated and the book is NOT ready to collect even though we've 
told the user that it is.

This is happening often at the moment, and we are dealing with it in two ways - 
either removing the user's email address from their record, so the email cannot 
be sent, or deleting the message from the table at the SQL level. Neither of 
these are ideal. I'm just wondering how other people are handling this? We have 
two campuses, and when an on-hold item is returned which is for a user at the 
other campus, it goes into transit and the email does not get generated until 
the item is checked in at the other campus. Can the same be achieved with the 
Selfcheck machines? Creating a separate virtual library, adding the self check 
machine users to it, and then books will automatically go into transit, 
therefore the email will not get generated? Do other libraries do this?

Cheers, Stephen
Stephen Graham
Library Technology Consultant
Academic Resources
Library and Computing Services
University of Hertfordshire
Hatfield  AL10 9AB
UK
Tel. 01707 286111 Ext: 77751
Email s.grah...@herts.ac.uk

___
Koha mailing list  http://koha-community.org
Koha@lists.katipo.co.nz
https://lists.katipo.co.nz/mailman/listinfo/koha


[Koha] Updating 856 Field

2016-06-22 Thread Graham, Stephen
Hi All - we want to change the 856 field in over 18,000 records. The actual 
change itself is easy - simply URL encoding the existing URL, and then 
prefixing it with another value. I am thinking of scripting this job.


1.   Identity and retrieve the biblio IDs from a SQL query

2.   Iterate over the IDs and use C4::Biblio:: GetMarcBiblio to retrieve 
the MARC record

3.   Grab the 856, subfield u value and make the change

4.   Use C4::Biblio:: ModBiblio to update the record in Koha

The actual relevant code would look something like (this is inside a loop which 
is iterating over the array of BIB IDs):

my $marc_record = GetMarcBiblio($id);

if ($marc_record) {
my $url = $marc_record->field('856')->subfield('u');
my $field_856 = $marc_record->field('856');
my $encodedURL = ($url);
my $wURL = $eblPrefix . $encodedURL;
$field_856->update( u => $wURL);
my $updated = ModBiblio($marc_record,$id,'');
}

I've test this on 10 records and it seems to work OK. My main question is, are 
there any "gotchas" doing it this way - anything I need to look out 
for/anything I've missed?

I'm not explicitly indicating any encoding format - I'm assuming that what goes 
back into Koha , will be the same as what I took out (apart from the URL)  - 
with all the encoding the same. Is that assumption correct?

Is it OK to make this change to 18K in one go?

Before I run the script I'm make a dump of the biblioitems table (which I think 
is the only table effected by this update), and the script dumps out the BIB 
IDs and the MARC records to file for reference.

How does this sound/look?

Cheers, Stephen

Stephen Graham
Library Technology Consultant
Academic Resources
Library and Computing Services
University of Hertfordshire
Hatfield  AL10 9AB
UK
Tel. 01707 286111 Ext: 77751
Email s.grah...@herts.ac.uk

___
Koha mailing list  http://koha-community.org
Koha@lists.katipo.co.nz
https://lists.katipo.co.nz/mailman/listinfo/koha


Re: [Koha] Report question

2016-04-22 Thread Graham, Stephen
Thanks François, I suspected as much.  I've tried doing things like:

35','36','37

, but the report tool just escapes the ' with a backslash. Very frustrating!

I guess I could use an OR, but I don't know how many values would be passed 
each time.  I guess I'll need to write a custom cgi script which outputs some 
JSON for what I want. 

Cheers, Stephen

-Original Message-
From: Koha [mailto:koha-boun...@lists.katipo.co.nz] On Behalf Of Francois 
Charbonnier
Sent: 21 April 2016 17:14
To: koha@lists.katipo.co.nz
Subject: Re: [Koha] Report question

Hi Stephen,

I don't see any workaround but right now, it can't work.

Let's say the <> value is : 34,35,36

With the IN operator, you have to get the query this way : IN(34,35,36) but 
with the <>, you'll get IN('34,35,36') instead. The query will look for 
the expression '34,35,36' which is not a biblionumber. 
Therefore, you don't have any result.

I guess you could use multiple "OR"...

Hope it helps!

François Charbonnier,
Bibl. prof. / Chef de produits

Tél.  : (888) 604-2627
francois.charbonn...@inlibro.com <mailto:francois.charbonn...@inlibro.com>

inLibro | pour esprit libre | www.inLibro.com <http://www.inLibro.com> Le 
2016-04-21 11:16, Graham, Stephen a écrit :
> Hi All - I want to set up a SQL report that can take a variable number of the 
> same value. My SQL looks like:
>
> select
> biblionumber,
> concat (branchname, ', ', lib) as location, itemcallnumber, if(onloan 
> is null,'Available',onloan) onloan from 
> items,authorised_values,branches where biblionumber in (<>) 
> and authorised_values.category = 'LOC'
> and items.location = authorised_values.authorised_value
> and items.homebranch = branches.branchcode
>
> I want the <> value to be able to receive several values when I run 
> the report from the staff client, but I cannot get it to work. Any 
> advice/tips much welcome!
>
> Stephen
>
> Stephen Graham
> Online Information Manager
> Information Collections and Services
> Library and Computing Services
> University of Hertfordshire
> Hatfield  AL10 9AB
> UK
> Tel. 01707 286111 Ext: 77751
> Email s.grah...@herts.ac.uk
>
> ___
> Koha mailing list  http://koha-community.org Koha@lists.katipo.co.nz 
> https://lists.katipo.co.nz/mailman/listinfo/koha

___
Koha mailing list  http://koha-community.org Koha@lists.katipo.co.nz 
https://lists.katipo.co.nz/mailman/listinfo/koha
___
Koha mailing list  http://koha-community.org
Koha@lists.katipo.co.nz
https://lists.katipo.co.nz/mailman/listinfo/koha


[Koha] Report question

2016-04-21 Thread Graham, Stephen
Hi All - I want to set up a SQL report that can take a variable number of the 
same value. My SQL looks like:

select
biblionumber,
concat (branchname, ', ', lib) as location,
itemcallnumber,
if(onloan is null,'Available',onloan) onloan
from items,authorised_values,branches
where biblionumber in (<>)
and authorised_values.category = 'LOC'
and items.location = authorised_values.authorised_value
and items.homebranch = branches.branchcode

I want the <> value to be able to receive several values when I run the 
report from the staff client, but I cannot get it to work. Any advice/tips much 
welcome!

Stephen

Stephen Graham
Online Information Manager
Information Collections and Services
Library and Computing Services
University of Hertfordshire
Hatfield  AL10 9AB
UK
Tel. 01707 286111 Ext: 77751
Email s.grah...@herts.ac.uk

___
Koha mailing list  http://koha-community.org
Koha@lists.katipo.co.nz
https://lists.katipo.co.nz/mailman/listinfo/koha