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

(-)a/cataloguing/value_builder/marc21_field_003.pl (-2 / +2 lines)
Lines 32-39 my $builder = sub { Link Here
32
<script type=\"text/javascript\">
32
<script type=\"text/javascript\">
33
//<![CDATA[
33
//<![CDATA[
34
34
35
function Focus$function_name(subfield_managed) {
35
function Focus$function_name(event) {
36
    document.getElementById(\"$params->{id}\").value='$org';
36
    document.getElementById(event.data.id).value='$org';
37
    return 0;
37
    return 0;
38
}
38
}
39
39
(-)a/cataloguing/value_builder/marc21_field_005.pl (-2 / +2 lines)
Lines 33-40 my $builder = sub { Link Here
33
<script type=\"text/javascript\">
33
<script type=\"text/javascript\">
34
//<![CDATA[
34
//<![CDATA[
35
35
36
function Focus$function_name(subfield_managed) {
36
function Focus$function_name(event) {
37
    document.getElementById(\"$params->{id}\").value='$date';
37
    document.getElementById(event.data.id).value='$date';
38
    return 0;
38
    return 0;
39
}
39
}
40
40
(-)a/cataloguing/value_builder/marc21_field_006.pl (-3 / +3 lines)
Lines 36-44 my $builder = sub { Link Here
36
<script type=\"text/javascript\">
36
<script type=\"text/javascript\">
37
//<![CDATA[
37
//<![CDATA[
38
38
39
function Click$function_name(i) {
39
function Click$function_name(event) {
40
    defaultvalue=document.getElementById(\"$params->{id}\").value;
40
    defaultvalue=document.getElementById(event.data.id).value;
41
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_006.pl&index=$params->{id}&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
41
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_006.pl&index=\"+ event.data.id +\"&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
42
42
43
}
43
}
44
//]]>
44
//]]>
(-)a/cataloguing/value_builder/marc21_field_007.pl (-3 / +3 lines)
Lines 35-43 my $builder = sub { Link Here
35
<script type=\"text/javascript\">
35
<script type=\"text/javascript\">
36
//<![CDATA[
36
//<![CDATA[
37
37
38
function Click$function_name(i) {
38
function Click$function_name(event) {
39
    defaultvalue=document.getElementById(\"$params->{id}\").value;
39
    defaultvalue=document.getElementById(event.data.id).value;
40
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_007.pl&index=$params->{id}&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
40
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_007.pl&index=\"+ event.data.id +\"&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
41
41
42
}
42
}
43
//]]>
43
//]]>
(-)a/cataloguing/value_builder/marc21_field_008.pl (-6 / +6 lines)
Lines 50-66 my $builder = sub { Link Here
50
<script type=\"text/javascript\">
50
<script type=\"text/javascript\">
51
//<![CDATA[
51
//<![CDATA[
52
52
53
function Focus$function_name(subfield_managed) {
53
function Focus$function_name(event) {
54
    if ( document.getElementById(\"$params->{id}\").value ) {
54
    if ( document.getElementById(event.data.id).value ) {
55
	}
55
	}
56
	else {
56
	else {
57
        document.getElementById(\"$params->{id}\").value='$dateentered' + 'b        xxu||||| |||| 00| 0 $lang d';
57
        document.getElementById(event.data.id).value='$dateentered' + 'b        xxu||||| |||| 00| 0 $lang d';
58
	}
58
	}
59
    return 1;
59
    return 1;
60
}
60
}
61
61
62
function Click$function_name(i) {
62
function Click$function_name(event) {
63
    defaultvalue=document.getElementById(\"$params->{id}\").value;
63
    defaultvalue=document.getElementById(event.data.id).value;
64
    //Retrieve full leader string and pass it to the 008 tag editor
64
    //Retrieve full leader string and pass it to the 008 tag editor
65
    var leader_value = \$(\"input[id^='tag_000']\").val();
65
    var leader_value = \$(\"input[id^='tag_000']\").val();
66
    var leader_parameter = \"\";
66
    var leader_parameter = \"\";
Lines 68-74 function Click$function_name(i) { Link Here
68
        //Only add the parameter to the URL if there is a value to add
68
        //Only add the parameter to the URL if there is a value to add
69
        leader_parameter = \"&leader=\"+leader_value;
69
        leader_parameter = \"&leader=\"+leader_value;
70
    }
70
    }
71
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_008.pl&index=$params->{id}&result=\"+defaultvalue+leader_parameter,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
71
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_008.pl&index=\"+ event.data.id +\"&result=\"+defaultvalue+leader_parameter,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
72
72
73
}
73
}
74
//]]>
74
//]]>
(-)a/cataloguing/value_builder/marc21_field_008_authorities.pl (-6 / +6 lines)
Lines 47-68 my $builder = sub { Link Here
47
<script type=\"text/javascript\">
47
<script type=\"text/javascript\">
48
//<![CDATA[
48
//<![CDATA[
49
49
50
function Focus$function_name(subfield_managed) {
50
function Focus$function_name(event) {
51
    if (!document.getElementById(\"$params->{id}\").value) {
51
    if (!document.getElementById(event.data.id).value) {
52
    var authtype=document.forms['f'].elements['authtypecode'].value;
52
    var authtype=document.forms['f'].elements['authtypecode'].value;
53
    var fieldval='$dateentered$defaultval';
53
    var fieldval='$dateentered$defaultval';
54
    if(authtype && (authtype == 'TOPIC_TERM' || authtype == 'GENRE/FORM' || authtype == 'CHRON_TERM')) {
54
    if(authtype && (authtype == 'TOPIC_TERM' || authtype == 'GENRE/FORM' || authtype == 'CHRON_TERM')) {
55
      fieldval= fieldval.substr(0,14)+'b'+fieldval.substr(15);
55
      fieldval= fieldval.substr(0,14)+'b'+fieldval.substr(15);
56
    }
56
    }
57
        document.getElementById(\"$params->{id}\").value=fieldval;
57
        document.getElementById(event.data.id).value=fieldval;
58
    }
58
    }
59
    return 1;
59
    return 1;
60
}
60
}
61
61
62
function Click$function_name(i) {
62
function Click$function_name(event) {
63
    var authtype=document.forms['f'].elements['authtypecode'].value;
63
    var authtype=document.forms['f'].elements['authtypecode'].value;
64
    defaultvalue=document.getElementById(\"$params->{id}\").value;
64
    defaultvalue=document.getElementById(event.data.id).value;
65
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_008_authorities.pl&index=$params->{id}&result=\"+defaultvalue+\"&authtypecode=\"+authtype,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
65
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_008_authorities.pl&index=\"+ event.data.id +\"&result=\"+defaultvalue+\"&authtypecode=\"+authtype,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
66
66
67
}
67
}
68
//]]>
68
//]]>
(-)a/cataloguing/value_builder/marc21_field_040c.pl (-2 / +2 lines)
Lines 31-38 my $builder = sub { Link Here
31
<script type=\"text/javascript\">
31
<script type=\"text/javascript\">
32
//<![CDATA[
32
//<![CDATA[
33
33
34
function Focus$function_name(subfield_managed) {
34
function Focus$function_name(event) {
35
    document.getElementById(\"$params->{id}\").value='$org';
35
    document.getElementById(event.data.id).value='$org';
36
    return 0;
36
    return 0;
37
}
37
}
38
38
(-)a/cataloguing/value_builder/marc21_field_040d.pl (-2 / +2 lines)
Lines 31-38 my $builder = sub { Link Here
31
<script type=\"text/javascript\">
31
<script type=\"text/javascript\">
32
//<![CDATA[
32
//<![CDATA[
33
33
34
function Focus$function_name(subfield_managed) {
34
function Focus$function_name(event) {
35
    document.getElementById(\"$params->{id}\").value='$org';
35
    document.getElementById(event.data.id).value='$org';
36
    return 0;
36
    return 0;
37
}
37
}
38
38
(-)a/cataloguing/value_builder/marc21_field_245h.pl (-3 / +3 lines)
Lines 30-42 my $builder = sub { Link Here
30
<script type=\"text/javascript\">
30
<script type=\"text/javascript\">
31
//<![CDATA[
31
//<![CDATA[
32
32
33
function Blur$function_name(index) {
33
function Blur$function_name(event) {
34
    var fieldValue = document.getElementById(\"$params->{id}\").value;
34
    var fieldValue = document.getElementById(event.data.id).value;
35
    if (  fieldValue.substring(0,1) != '[' 
35
    if (  fieldValue.substring(0,1) != '[' 
36
          &&
36
          &&
37
          fieldValue.substring(fieldValue.length-1) != '[' 
37
          fieldValue.substring(fieldValue.length-1) != '[' 
38
        ) {
38
        ) {
39
      document.getElementById(\"$params->{id}\").value = '[' + fieldValue + ']';
39
      document.getElementById(event.data.id).value = '[' + fieldValue + ']';
40
    }
40
    }
41
    return 0;
41
    return 0;
42
}
42
}
(-)a/cataloguing/value_builder/marc21_leader.pl (-6 / +6 lines)
Lines 35-50 my $builder = sub { Link Here
35
<script type=\"text/javascript\">
35
<script type=\"text/javascript\">
36
//<![CDATA[
36
//<![CDATA[
37
37
38
function Focus$function_name(subfield_managed) {
38
function Focus$function_name(event) {
39
    if(!document.getElementById(\"$params->{id}\").value){
39
    if(!document.getElementById(event.data.id).value){
40
        document.getElementById(\"$params->{id}\").value = '     nam a22     7a 4500';
40
        document.getElementById(event.data.id).value = '     nam a22     7a 4500';
41
    }
41
    }
42
    return 1;
42
    return 1;
43
}
43
}
44
44
45
function Click$function_name(i) {
45
function Click$function_name(event) {
46
    defaultvalue=document.getElementById(\"$params->{id}\").value;
46
    defaultvalue=document.getElementById(event.data.id).value;
47
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_leader.pl&index=$params->{id}&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
47
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_leader.pl&index=\"+ event.data.id +\"&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
48
48
49
}
49
}
50
//]]>
50
//]]>
(-)a/cataloguing/value_builder/marc21_leader_authorities.pl (-6 / +6 lines)
Lines 35-50 my $builder = sub { Link Here
35
<script type=\"text/javascript\">
35
<script type=\"text/javascript\">
36
//<![CDATA[
36
//<![CDATA[
37
37
38
function Focus$function_name(subfield_managed) {
38
function Focus$function_name(event) {
39
    if(!document.getElementById(\"$params->{id}\").value){
39
    if(!document.getElementById(event.data.id).value){
40
        document.getElementById(\"$params->{id}\").value = '     nz  a22     n  4500';
40
        document.getElementById(event.data.id).value = '     nz  a22     n  4500';
41
    }
41
    }
42
    return 1;
42
    return 1;
43
}
43
}
44
44
45
function Click$function_name(i) {
45
function Click$function_name(event) {
46
    defaultvalue=document.getElementById(\"$params->{id}\").value;
46
    defaultvalue=document.getElementById(event.data.id).value;
47
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_leader_authorities.pl&index=$params->{id}&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
47
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_leader_authorities.pl&index=\"+ event.data.id +\"&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
48
48
49
}
49
}
50
//]]>
50
//]]>
(-)a/cataloguing/value_builder/marc21_leader_book.pl (-3 / +3 lines)
Lines 35-43 my $builder = sub { Link Here
35
<script type=\"text/javascript\">
35
<script type=\"text/javascript\">
36
//<![CDATA[
36
//<![CDATA[
37
37
38
function Click$function_name(i) {
38
function Click$function_name(event) {
39
    defaultvalue=document.getElementById(\"$params->{id}\").value;
39
    defaultvalue=document.getElementById(event.data.id).value;
40
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_leader.pl&index=$params->{id}&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
40
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_leader.pl&index=\"+ event.data.id +\"&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
41
41
42
}
42
}
43
//]]>
43
//]]>
(-)a/cataloguing/value_builder/marc21_leader_computerfile.pl (-3 / +3 lines)
Lines 35-43 my $builder = sub { Link Here
35
<script type=\"text/javascript\">
35
<script type=\"text/javascript\">
36
//<![CDATA[
36
//<![CDATA[
37
37
38
function Click$function_name(i) {
38
function Click$function_name(event) {
39
    defaultvalue=document.getElementById(\"$params->{id}\").value;
39
    defaultvalue=document.getElementById(event.data.id).value;
40
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_leader.pl&index=$params->{id}&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
40
    newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_leader.pl&index=\"+ event.data.id +\"&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
41
41
42
}
42
}
43
//]]>
43
//]]>
(-)a/cataloguing/value_builder/marc21_leader_video.pl (-3 / +3 lines)
Lines 35-43 my $builder = sub { Link Here
35
<script type=\"text/javascript\">
35
<script type=\"text/javascript\">
36
//<![CDATA[
36
//<![CDATA[
37
37
38
function Click$function_name(i) {
38
function Click$function_name(event) {
39
    defaultvalue=document.getElementById(\"$params->{id}\").value;
39
    defaultvalue=document.getElementById(event.data.id).value;
40
	newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_leader.pl&index=\"+i+\"&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
40
	newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_leader.pl&index=\"+ event.data.id +\"&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
41
41
42
}
42
}
43
//]]>
43
//]]>
(-)a/cataloguing/value_builder/marc21_linking_section.pl (-4 / +3 lines)
Lines 39-47 my $builder = sub { Link Here
39
    my $function_name = $params->{id};
39
    my $function_name = $params->{id};
40
    my $res           = "
40
    my $res           = "
41
  <script type='text/javascript'>
41
  <script type='text/javascript'>
42
             function Click$function_name(i) {
42
             function Click$function_name(event) {
43
                       defaultvalue=document.getElementById(\"$params->{id}\").value;
43
                       defaultvalue=document.getElementById(event.data.id).value;
44
                 window.open(\"/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl&index=\" + i + \"&result=\"+defaultvalue,\"marc21_field_7\"+i+\"\",'width=900,height=700,toolbar=false,scrollbars=yes');
44
                 window.open(\"/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl&index=\" + event.data.id + \"&result=\"+defaultvalue,\"marc21_field_7\"+ event.data.id +\"\",'width=900,height=700,toolbar=false,scrollbars=yes');
45
45
46
             }
46
             }
47
      </script>
47
      </script>
48
- 

Return to bug 13437