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

(-)a/C4/Biblio.pm (-5 / +7 lines)
Lines 1103-1125 sub GetMarcStructure { Link Here
1103
    return $cached if $cached;
1103
    return $cached if $cached;
1104
1104
1105
    my $sth = $dbh->prepare(
1105
    my $sth = $dbh->prepare(
1106
        "SELECT tagfield,liblibrarian,libopac,mandatory,repeatable 
1106
        "SELECT tagfield,liblibrarian,libopac,mandatory,repeatable,important
1107
        FROM marc_tag_structure 
1107
        FROM marc_tag_structure 
1108
        WHERE frameworkcode=? 
1108
        WHERE frameworkcode=? 
1109
        ORDER BY tagfield"
1109
        ORDER BY tagfield"
1110
    );
1110
    );
1111
    $sth->execute($frameworkcode);
1111
    $sth->execute($frameworkcode);
1112
    my ( $liblibrarian, $libopac, $tag, $res, $tab, $mandatory, $repeatable );
1112
    my ( $liblibrarian, $libopac, $tag, $res, $tab, $mandatory, $repeatable, $important );
1113
1113
1114
    while ( ( $tag, $liblibrarian, $libopac, $mandatory, $repeatable ) = $sth->fetchrow ) {
1114
    while ( ( $tag, $liblibrarian, $libopac, $mandatory, $repeatable, $important ) = $sth->fetchrow ) {
1115
        $res->{$tag}->{lib}        = ( $forlibrarian or !$libopac ) ? $liblibrarian : $libopac;
1115
        $res->{$tag}->{lib}        = ( $forlibrarian or !$libopac ) ? $liblibrarian : $libopac;
1116
        $res->{$tag}->{tab}        = "";
1116
        $res->{$tag}->{tab}        = "";
1117
        $res->{$tag}->{mandatory}  = $mandatory;
1117
        $res->{$tag}->{mandatory}  = $mandatory;
1118
        $res->{$tag}->{important}  = $important;
1118
        $res->{$tag}->{repeatable} = $repeatable;
1119
        $res->{$tag}->{repeatable} = $repeatable;
1119
    }
1120
    }
1120
1121
1121
    $sth = $dbh->prepare(
1122
    $sth = $dbh->prepare(
1122
        "SELECT tagfield,tagsubfield,liblibrarian,libopac,tab,mandatory,repeatable,authorised_value,authtypecode,value_builder,kohafield,seealso,hidden,isurl,link,defaultvalue,maxlength
1123
        "SELECT tagfield,tagsubfield,liblibrarian,libopac,tab,mandatory,repeatable,authorised_value,authtypecode,value_builder,kohafield,seealso,hidden,isurl,link,defaultvalue,maxlength,important
1123
         FROM   marc_subfield_structure 
1124
         FROM   marc_subfield_structure 
1124
         WHERE  frameworkcode=? 
1125
         WHERE  frameworkcode=? 
1125
         ORDER BY tagfield,tagsubfield
1126
         ORDER BY tagfield,tagsubfield
Lines 1143-1155 sub GetMarcStructure { Link Here
1143
    while (
1144
    while (
1144
        (   $tag,          $subfield,      $liblibrarian, $libopac, $tab,    $mandatory, $repeatable, $authorised_value,
1145
        (   $tag,          $subfield,      $liblibrarian, $libopac, $tab,    $mandatory, $repeatable, $authorised_value,
1145
            $authtypecode, $value_builder, $kohafield,    $seealso, $hidden, $isurl,     $link,       $defaultvalue,
1146
            $authtypecode, $value_builder, $kohafield,    $seealso, $hidden, $isurl,     $link,       $defaultvalue,
1146
            $maxlength
1147
            $maxlength, $important
1147
        )
1148
        )
1148
        = $sth->fetchrow
1149
        = $sth->fetchrow
1149
      ) {
1150
      ) {
1150
        $res->{$tag}->{$subfield}->{lib}              = ( $forlibrarian or !$libopac ) ? $liblibrarian : $libopac;
1151
        $res->{$tag}->{$subfield}->{lib}              = ( $forlibrarian or !$libopac ) ? $liblibrarian : $libopac;
1151
        $res->{$tag}->{$subfield}->{tab}              = $tab;
1152
        $res->{$tag}->{$subfield}->{tab}              = $tab;
1152
        $res->{$tag}->{$subfield}->{mandatory}        = $mandatory;
1153
        $res->{$tag}->{$subfield}->{mandatory}        = $mandatory;
1154
        $res->{$tag}->{$subfield}->{important}        = $important;
1153
        $res->{$tag}->{$subfield}->{repeatable}       = $repeatable;
1155
        $res->{$tag}->{$subfield}->{repeatable}       = $repeatable;
1154
        $res->{$tag}->{$subfield}->{authorised_value} = $authorised_value;
1156
        $res->{$tag}->{$subfield}->{authorised_value} = $authorised_value;
1155
        $res->{$tag}->{$subfield}->{authtypecode}     = $authtypecode;
1157
        $res->{$tag}->{$subfield}->{authtypecode}     = $authtypecode;
(-)a/admin/marc_subfields_structure.pl (-3 / +21 lines)
Lines 229-234 if ( $op eq 'add_form' ) { Link Here
229
            -label    => '',
229
            -label    => '',
230
            -id       => "mandatory$i"
230
            -id       => "mandatory$i"
231
        );
231
        );
232
        $row_data{important} = CGI::checkbox(
233
            -name     => "important$i",
234
            -checked  => $data->{'important'} ? 'checked' : '',
235
            -value    => 1,
236
            -label    => '',
237
            -id       => "important$i"
238
        );
232
        $row_data{hidden} = CGI::escapeHTML( $data->{hidden} );
239
        $row_data{hidden} = CGI::escapeHTML( $data->{hidden} );
233
        $row_data{isurl}  = CGI::checkbox(
240
        $row_data{isurl}  = CGI::checkbox(
234
            -name     => "isurl$i",
241
            -name     => "isurl$i",
Lines 280-285 if ( $op eq 'add_form' ) { Link Here
280
            -value    => 1,
287
            -value    => 1,
281
            -label    => ''
288
            -label    => ''
282
        );
289
        );
290
        $row_data{important} = CGI::checkbox(
291
            -name     => "important$i",
292
            -id       => "important$i",
293
            -checked  => '',
294
            -value    => 1,
295
            -label    => ''
296
        );
283
        $row_data{isurl} = CGI::checkbox(
297
        $row_data{isurl} = CGI::checkbox(
284
            -name     => "isurl$i",
298
            -name     => "isurl$i",
285
            -id       => "isurl$i",
299
            -id       => "isurl$i",
Lines 328-338 elsif ( $op eq 'add_validate' ) { Link Here
328
#                                     values (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)"
342
#                                     values (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)"
329
#     );
343
#     );
330
    my $sth_insert = $dbh->prepare(qq{
344
    my $sth_insert = $dbh->prepare(qq{
331
        insert into marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,seealso,authorised_value,authtypecode,value_builder,hidden,isurl,frameworkcode, link,defaultvalue,maxlength)
345
        insert into marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,important,kohafield,tab,seealso,authorised_value,authtypecode,value_builder,hidden,isurl,frameworkcode, link,defaultvalue,maxlength)
332
        values (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
346
        values (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
333
    });
347
    });
334
    my $sth_update = $dbh->prepare(qq{
348
    my $sth_update = $dbh->prepare(qq{
335
        update marc_subfield_structure set tagfield=?, tagsubfield=?, liblibrarian=?, libopac=?, repeatable=?, mandatory=?, kohafield=?, tab=?, seealso=?, authorised_value=?, authtypecode=?, value_builder=?, hidden=?, isurl=?, frameworkcode=?,  link=?, defaultvalue=?, maxlength=?
349
        update marc_subfield_structure set tagfield=?, tagsubfield=?, liblibrarian=?, libopac=?, repeatable=?, mandatory=?, important=?, kohafield=?, tab=?, seealso=?, authorised_value=?, authtypecode=?, value_builder=?, hidden=?, isurl=?, frameworkcode=?,  link=?, defaultvalue=?, maxlength=?
336
        where tagfield=? and tagsubfield=? and frameworkcode=?
350
        where tagfield=? and tagsubfield=? and frameworkcode=?
337
    });
351
    });
338
    my @tagsubfield       = $input->param('tagsubfield');
352
    my @tagsubfield       = $input->param('tagsubfield');
Lines 358-363 elsif ( $op eq 'add_validate' ) { Link Here
358
        my $libopac          = $libopac[$i];
372
        my $libopac          = $libopac[$i];
359
        my $repeatable       = $input->param("repeatable$i") ? 1 : 0;
373
        my $repeatable       = $input->param("repeatable$i") ? 1 : 0;
360
        my $mandatory        = $input->param("mandatory$i") ? 1 : 0;
374
        my $mandatory        = $input->param("mandatory$i") ? 1 : 0;
375
        my $important        = $input->param("important$i") ? 1 : 0;
361
        my $kohafield        = $kohafield[$i];
376
        my $kohafield        = $kohafield[$i];
362
        my $tab              = $tab[$i];
377
        my $tab              = $tab[$i];
363
        my $seealso          = $seealso[$i];
378
        my $seealso          = $seealso[$i];
Lines 380-385 elsif ( $op eq 'add_validate' ) { Link Here
380
                        $libopac,
395
                        $libopac,
381
                        $repeatable,
396
                        $repeatable,
382
                        $mandatory,
397
                        $mandatory,
398
                        $important,
383
                        $kohafield,
399
                        $kohafield,
384
                        $tab,
400
                        $tab,
385
                        $seealso,
401
                        $seealso,
Lines 406-411 elsif ( $op eq 'add_validate' ) { Link Here
406
                        $libopac,
422
                        $libopac,
407
                        $repeatable,
423
                        $repeatable,
408
                        $mandatory,
424
                        $mandatory,
425
                        $important,
409
                        $kohafield,
426
                        $kohafield,
410
                        $tab,
427
                        $tab,
411
                        $seealso,
428
                        $seealso,
Lines 490-495 else { # DEFAULT Link Here
490
        $row_data{kohafield}        = $results->[$i]{'kohafield'};
507
        $row_data{kohafield}        = $results->[$i]{'kohafield'};
491
        $row_data{repeatable}       = $results->[$i]{'repeatable'};
508
        $row_data{repeatable}       = $results->[$i]{'repeatable'};
492
        $row_data{mandatory}        = $results->[$i]{'mandatory'};
509
        $row_data{mandatory}        = $results->[$i]{'mandatory'};
510
        $row_data{important}        = $results->[$i]{'important'};
493
        $row_data{tab}              = $results->[$i]{'tab'};
511
        $row_data{tab}              = $results->[$i]{'tab'};
494
        $row_data{seealso}          = $results->[$i]{'seealso'};
512
        $row_data{seealso}          = $results->[$i]{'seealso'};
495
        $row_data{authorised_value} = $results->[$i]{'authorised_value'};
513
        $row_data{authorised_value} = $results->[$i]{'authorised_value'};
(-)a/admin/marctagstructure.pl (-5 / +13 lines)
Lines 98-104 if ($op eq 'add_form') { Link Here
98
	#---- if primkey exists, it's a modify action, so read values to modify...
98
	#---- if primkey exists, it's a modify action, so read values to modify...
99
	my $data;
99
	my $data;
100
	if ($searchfield) {
100
	if ($searchfield) {
101
		$sth=$dbh->prepare("select tagfield,liblibrarian,libopac,repeatable,mandatory,authorised_value from marc_tag_structure where tagfield=? and frameworkcode=?");
101
        $sth=$dbh->prepare("select tagfield,liblibrarian,libopac,repeatable,mandatory,authorised_value, important from marc_tag_structure where tagfield=? and frameworkcode=?");
102
		$sth->execute($searchfield,$frameworkcode);
102
		$sth->execute($searchfield,$frameworkcode);
103
		$data=$sth->fetchrow_hashref;
103
		$data=$sth->fetchrow_hashref;
104
	}
104
	}
Lines 123-128 if ($op eq 'add_form') { Link Here
123
			libopac => $data->{'libopac'},
123
			libopac => $data->{'libopac'},
124
            repeatable => $data->{'repeatable'},
124
            repeatable => $data->{'repeatable'},
125
            mandatory => $data->{'mandatory'},
125
            mandatory => $data->{'mandatory'},
126
            important => $data->{'important'},
126
			authorised_value => $authorised_value,
127
			authorised_value => $authorised_value,
127
			frameworkcode => $frameworkcode,
128
			frameworkcode => $frameworkcode,
128
    );  # FIXME: move checkboxes to presentation layer
129
    );  # FIXME: move checkboxes to presentation layer
Lines 135-157 if ($op eq 'add_form') { Link Here
135
	my $libopac          = $input->param('libopac');
136
	my $libopac          = $input->param('libopac');
136
	my $repeatable       = $input->param('repeatable') ? 1 : 0;
137
	my $repeatable       = $input->param('repeatable') ? 1 : 0;
137
	my $mandatory        = $input->param('mandatory')  ? 1 : 0;
138
	my $mandatory        = $input->param('mandatory')  ? 1 : 0;
139
    my $important        = $input->param('important')  ? 1 : 0;
138
	my $authorised_value = $input->param('authorised_value');
140
	my $authorised_value = $input->param('authorised_value');
139
    unless (C4::Context->config('demo')) {
141
    unless (C4::Context->config('demo')) {
140
        if ($input->param('modif')) {
142
        if ($input->param('modif')) {
141
            $sth = $dbh->prepare(
143
            $sth = $dbh->prepare(
142
            "UPDATE marc_tag_structure SET liblibrarian=? ,libopac=? ,repeatable=? ,mandatory=? ,authorised_value=? WHERE frameworkcode=? AND tagfield=?"
144
            "UPDATE marc_tag_structure SET liblibrarian=? ,libopac=? ,repeatable=? ,mandatory=? ,important=?, authorised_value=? WHERE frameworkcode=? AND tagfield=?"
143
            );
145
            );
144
            $sth->execute(  $liblibrarian,
146
            $sth->execute(  $liblibrarian,
145
                            $libopac,
147
                            $libopac,
146
                            $repeatable,
148
                            $repeatable,
147
                            $mandatory,
149
                            $mandatory,
150
                            $important,
148
                            $authorised_value,
151
                            $authorised_value,
149
                            $frameworkcode,
152
                            $frameworkcode,
150
                            $tagfield
153
                            $tagfield
151
            );
154
            );
152
        } else {
155
        } else {
153
            $sth = $dbh->prepare(
156
            $sth = $dbh->prepare(
154
            "INSERT INTO marc_tag_structure (tagfield,liblibrarian,libopac,repeatable,mandatory,authorised_value,frameworkcode) values (?,?,?,?,?,?,?)"
157
            "INSERT INTO marc_tag_structure (tagfield,liblibrarian,libopac,repeatable,mandatory,authorised_value,frameworkcode,important) values (?,?,?,?,?,?,?,?)"
155
            );
158
            );
156
            $sth->execute($tagfield,
159
            $sth->execute($tagfield,
157
                          $liblibrarian,
160
                          $liblibrarian,
Lines 159-165 if ($op eq 'add_form') { Link Here
159
                          $repeatable,
162
                          $repeatable,
160
                          $mandatory,
163
                          $mandatory,
161
                          $authorised_value,
164
                          $authorised_value,
162
                          $frameworkcode
165
                          $frameworkcode,
166
                          $important
163
            );
167
            );
164
        }
168
        }
165
        $cache->clear_from_cache("MarcStructure-0-$frameworkcode");
169
        $cache->clear_from_cache("MarcStructure-0-$frameworkcode");
Lines 231-236 if ($op eq 'add_form') { Link Here
231
		              marc_tag_structure.libopac as mts_libopac,
235
		              marc_tag_structure.libopac as mts_libopac,
232
		              marc_tag_structure.repeatable as mts_repeatable,
236
		              marc_tag_structure.repeatable as mts_repeatable,
233
		              marc_tag_structure.mandatory as mts_mandatory,
237
		              marc_tag_structure.mandatory as mts_mandatory,
238
                      marc_tag_structure.important as mts_important,
234
		              marc_tag_structure.authorised_value as mts_authorized_value,
239
		              marc_tag_structure.authorised_value as mts_authorized_value,
235
		              marc_subfield_structure.*
240
		              marc_subfield_structure.*
236
                FROM marc_tag_structure 
241
                FROM marc_tag_structure 
Lines 252-257 if ($op eq 'add_form') { Link Here
252
			$row_data{liblibrarian}     = $results[$i]->{'mts_liblibrarian'};
257
			$row_data{liblibrarian}     = $results[$i]->{'mts_liblibrarian'};
253
			$row_data{repeatable}       = $results[$i]->{'mts_repeatable'};
258
			$row_data{repeatable}       = $results[$i]->{'mts_repeatable'};
254
			$row_data{mandatory}        = $results[$i]->{'mts_mandatory'};
259
			$row_data{mandatory}        = $results[$i]->{'mts_mandatory'};
260
            $row_data{important}        = $results[$i]->{'mts_important'};
255
			$row_data{authorised_value} = $results[$i]->{'mts_authorised_value'};
261
			$row_data{authorised_value} = $results[$i]->{'mts_authorised_value'};
256
			$row_data{subfield_link} = "marc_subfields_structure.pl?op=add_form&tagfield=".$results[$i]->{'mts_tagfield'}."&frameworkcode=".$frameworkcode;
262
			$row_data{subfield_link} = "marc_subfields_structure.pl?op=add_form&tagfield=".$results[$i]->{'mts_tagfield'}."&frameworkcode=".$frameworkcode;
257
			$row_data{edit}          = "$script_name?op=add_form&searchfield="            .$results[$i]->{'mts_tagfield'}."&frameworkcode=".$frameworkcode;
263
			$row_data{edit}          = "$script_name?op=add_form&searchfield="            .$results[$i]->{'mts_tagfield'}."&frameworkcode=".$frameworkcode;
Lines 265-270 if ($op eq 'add_form') { Link Here
265
				$subfield_data{kohafield}        = $results[$j]->{'kohafield'};
271
				$subfield_data{kohafield}        = $results[$j]->{'kohafield'};
266
				$subfield_data{repeatable}       = $results[$j]->{'repeatable'};
272
				$subfield_data{repeatable}       = $results[$j]->{'repeatable'};
267
				$subfield_data{mandatory}        = $results[$j]->{'mandatory'};
273
				$subfield_data{mandatory}        = $results[$j]->{'mandatory'};
274
                $subfield_data{important}        = $results[$j]->{'important'};
268
				$subfield_data{tab}              = $results[$j]->{'tab'};
275
				$subfield_data{tab}              = $results[$j]->{'tab'};
269
				$subfield_data{seealso}          = $results[$j]->{'seealso'};
276
				$subfield_data{seealso}          = $results[$j]->{'seealso'};
270
				$subfield_data{authorised_value} = $results[$j]->{'authorised_value'};
277
				$subfield_data{authorised_value} = $results[$j]->{'authorised_value'};
Lines 291-296 if ($op eq 'add_form') { Link Here
291
			$row_data{liblibrarian}     = $results->[$i]{'liblibrarian'};
298
			$row_data{liblibrarian}     = $results->[$i]{'liblibrarian'};
292
			$row_data{repeatable}       = $results->[$i]{'repeatable'};
299
			$row_data{repeatable}       = $results->[$i]{'repeatable'};
293
			$row_data{mandatory}        = $results->[$i]{'mandatory'};
300
			$row_data{mandatory}        = $results->[$i]{'mandatory'};
301
            $row_data{important}        = $results->[$i]{'important'};
294
			$row_data{authorised_value} = $results->[$i]{'authorised_value'};
302
			$row_data{authorised_value} = $results->[$i]{'authorised_value'};
295
			$row_data{subfield_link}    = "marc_subfields_structure.pl?tagfield="          .$results->[$i]{'tagfield'}."&frameworkcode=".$frameworkcode;
303
			$row_data{subfield_link}    = "marc_subfields_structure.pl?tagfield="          .$results->[$i]{'tagfield'}."&frameworkcode=".$frameworkcode;
296
			$row_data{edit}             = "$script_name?op=add_form&searchfield="      .$results->[$i]{'tagfield'}."&frameworkcode=".$frameworkcode;
304
			$row_data{edit}             = "$script_name?op=add_form&searchfield="      .$results->[$i]{'tagfield'}."&frameworkcode=".$frameworkcode;
Lines 324-330 output_html_with_http_headers $input, $cookie, $template->output; Link Here
324
sub StringSearch  {
332
sub StringSearch  {
325
	my ($searchstring,$frameworkcode)=@_;
333
	my ($searchstring,$frameworkcode)=@_;
326
	my $sth = C4::Context->dbh->prepare("
334
	my $sth = C4::Context->dbh->prepare("
327
    SELECT tagfield,liblibrarian,libopac,repeatable,mandatory,authorised_value
335
    SELECT tagfield,liblibrarian,libopac,repeatable,mandatory,authorised_value,important
328
     FROM  marc_tag_structure
336
     FROM  marc_tag_structure
329
     WHERE (tagfield >= ? and frameworkcode=?)
337
     WHERE (tagfield >= ? and frameworkcode=?)
330
    ORDER BY tagfield
338
    ORDER BY tagfield
(-)a/cataloguing/addbiblio.pl (-2 / +7 lines)
Lines 326-331 sub create_input { Link Here
326
        marc_lib_plain => $tagslib->{$tag}->{$subfield}->{lib}, 
326
        marc_lib_plain => $tagslib->{$tag}->{$subfield}->{lib}, 
327
        tag_mandatory  => $tagslib->{$tag}->{mandatory},
327
        tag_mandatory  => $tagslib->{$tag}->{mandatory},
328
        mandatory      => $tagslib->{$tag}->{$subfield}->{mandatory},
328
        mandatory      => $tagslib->{$tag}->{$subfield}->{mandatory},
329
        important      => $tagslib->{$tag}->{$subfield}->{important},
329
        repeatable     => $tagslib->{$tag}->{$subfield}->{repeatable},
330
        repeatable     => $tagslib->{$tag}->{$subfield}->{repeatable},
330
        kohafield      => $tagslib->{$tag}->{$subfield}->{kohafield},
331
        kohafield      => $tagslib->{$tag}->{$subfield}->{kohafield},
331
        index          => $index_tag,
332
        index          => $index_tag,
Lines 339-351 sub create_input { Link Here
339
        $subfield_data{z3950_mandatory} = $mandatory_z3950->{$tag.$subfield};
340
        $subfield_data{z3950_mandatory} = $mandatory_z3950->{$tag.$subfield};
340
    }
341
    }
341
    # Subfield is hidden depending of hidden and mandatory flag, and is always
342
    # Subfield is hidden depending of hidden and mandatory flag, and is always
342
    # shown if it contains anything or if its field is mandatory.
343
    # shown if it contains anything or if its field is mandatory or important.
343
    my $tdef = $tagslib->{$tag};
344
    my $tdef = $tagslib->{$tag};
344
    $subfield_data{visibility} = "display:none;"
345
    $subfield_data{visibility} = "display:none;"
345
        if $tdef->{$subfield}->{hidden} % 2 == 1 &&
346
        if $tdef->{$subfield}->{hidden} % 2 == 1 &&
346
           $value eq '' &&
347
           $value eq '' &&
347
           !$tdef->{$subfield}->{mandatory} &&
348
           !$tdef->{$subfield}->{mandatory} &&
348
           !$tdef->{mandatory};
349
           !$tdef->{mandatory} &&
350
           !$tdef->{$subfield}->{important} &&
351
           !$tdef->{important};
349
    # expand all subfields of 773 if there is a host item provided in the input
352
    # expand all subfields of 773 if there is a host item provided in the input
350
    $subfield_data{visibility} ="" if ($tag eq 773 and $cgi->param('hostitemnumber'));
353
    $subfield_data{visibility} ="" if ($tag eq 773 and $cgi->param('hostitemnumber'));
351
354
Lines 634-639 sub build_tabs { Link Here
634
                            tag_lib       => $tagslib->{$tag}->{lib},
637
                            tag_lib       => $tagslib->{$tag}->{lib},
635
                            repeatable       => $tagslib->{$tag}->{repeatable},
638
                            repeatable       => $tagslib->{$tag}->{repeatable},
636
                            mandatory       => $tagslib->{$tag}->{mandatory},
639
                            mandatory       => $tagslib->{$tag}->{mandatory},
640
                            important       => $tagslib->{$tag}->{important},
637
                            subfield_loop => \@subfields_data,
641
                            subfield_loop => \@subfields_data,
638
                            fixedfield    => $tag < 10?1:0,
642
                            fixedfield    => $tag < 10?1:0,
639
                            random        => CreateKey,
643
                            random        => CreateKey,
Lines 680-685 sub build_tabs { Link Here
680
                        tag_lib          => $tagslib->{$tag}->{lib},
684
                        tag_lib          => $tagslib->{$tag}->{lib},
681
                        repeatable       => $tagslib->{$tag}->{repeatable},
685
                        repeatable       => $tagslib->{$tag}->{repeatable},
682
                        mandatory       => $tagslib->{$tag}->{mandatory},
686
                        mandatory       => $tagslib->{$tag}->{mandatory},
687
                        important       => $tagslib->{$tag}->{important},
683
                        indicator1       => $indicator1,
688
                        indicator1       => $indicator1,
684
                        indicator2       => $indicator2,
689
                        indicator2       => $indicator2,
685
                        subfield_loop    => \@subfields_data,
690
                        subfield_loop    => \@subfields_data,
(-)a/installer/data/mysql/kohastructure.sql
Lines 2-8 Link Here
2
--
2
--
3
-- Host: localhost    Database: koha30test
3
-- Host: localhost    Database: koha30test
4
-- ------------------------------------------------------
4
-- ------------------------------------------------------
(-)Server version (-11 / +12 lines)
Lines 1376-1381 CREATE TABLE `marc_subfield_structure` ( Link Here
1376
  `libopac` varchar(255) NOT NULL default '',
1376
  `libopac` varchar(255) NOT NULL default '',
1377
  `repeatable` tinyint(4) NOT NULL default 0,
1377
  `repeatable` tinyint(4) NOT NULL default 0,
1378
  `mandatory` tinyint(4) NOT NULL default 0,
1378
  `mandatory` tinyint(4) NOT NULL default 0,
1379
  `important` tinyint(4) NOT NULL DEFAULT '0',
1379
  `kohafield` varchar(40) default NULL,
1380
  `kohafield` varchar(40) default NULL,
1380
  `tab` tinyint(1) default NULL,
1381
  `tab` tinyint(1) default NULL,
1381
  `authorised_value` varchar(20) default NULL,
1382
  `authorised_value` varchar(20) default NULL,
Lines 1407-1412 CREATE TABLE `marc_tag_structure` ( Link Here
1407
  `mandatory` tinyint(4) NOT NULL default 0,
1408
  `mandatory` tinyint(4) NOT NULL default 0,
1408
  `authorised_value` varchar(10) default NULL,
1409
  `authorised_value` varchar(10) default NULL,
1409
  `frameworkcode` varchar(4) NOT NULL default '',
1410
  `frameworkcode` varchar(4) NOT NULL default '',
1411
  `important` tinyint(4) NOT NULL DEFAULT '0',
1410
  PRIMARY KEY  (`frameworkcode`,`tagfield`)
1412
  PRIMARY KEY  (`frameworkcode`,`tagfield`)
1411
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
1413
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
1412
1414
Lines 2174-2183 CREATE TABLE `suggestions` ( -- purchase suggestions Link Here
2174
   branchcode VARCHAR(10) default NULL, -- foreign key linking the suggested branch to the branches table
2176
   branchcode VARCHAR(10) default NULL, -- foreign key linking the suggested branch to the branches table
2175
   collectiontitle text default NULL, -- collection name for the suggested item
2177
   collectiontitle text default NULL, -- collection name for the suggested item
2176
   itemtype VARCHAR(30) default NULL, -- suggested item type 
2178
   itemtype VARCHAR(30) default NULL, -- suggested item type 
2177
	quantity SMALLINT(6) default NULL, -- suggested quantity to be purchased
2179
    quantity SMALLINT(6) default NULL, -- suggested quantity to be purchased
2178
	currency VARCHAR(3) default NULL, -- suggested currency for the suggested price
2180
    currency VARCHAR(3) default NULL, -- suggested currency for the suggested price
2179
	price DECIMAL(28,6) default NULL, -- suggested price
2181
    price DECIMAL(28,6) default NULL, -- suggested price
2180
	total DECIMAL(28,6) default NULL, -- suggested total cost (price*quantity updated for currency)
2182
    total DECIMAL(28,6) default NULL, -- suggested total cost (price*quantity updated for currency)
2181
  PRIMARY KEY  (`suggestionid`),
2183
  PRIMARY KEY  (`suggestionid`),
2182
  KEY `suggestedby` (`suggestedby`),
2184
  KEY `suggestedby` (`suggestedby`),
2183
  KEY `managedby` (`managedby`)
2185
  KEY `managedby` (`managedby`)
Lines 2475-2486 CREATE TABLE `permissions` ( Link Here
2475
2477
2476
DROP TABLE IF EXISTS `serialitems`;
2478
DROP TABLE IF EXISTS `serialitems`;
2477
CREATE TABLE `serialitems` (
2479
CREATE TABLE `serialitems` (
2478
	`itemnumber` int(11) NOT NULL,
2480
    `itemnumber` int(11) NOT NULL,
2479
	`serialid` int(11) NOT NULL,
2481
    `serialid` int(11) NOT NULL,
2480
	UNIQUE KEY `serialitemsidx` (`itemnumber`),
2482
    UNIQUE KEY `serialitemsidx` (`itemnumber`),
2481
	KEY `serialitems_sfk_1` (`serialid`),
2483
    KEY `serialitems_sfk_1` (`serialid`),
2482
	CONSTRAINT `serialitems_sfk_1` FOREIGN KEY (`serialid`) REFERENCES `serial` (`serialid`) ON DELETE CASCADE ON UPDATE CASCADE,
2484
    CONSTRAINT `serialitems_sfk_1` FOREIGN KEY (`serialid`) REFERENCES `serial` (`serialid`) ON DELETE CASCADE ON UPDATE CASCADE,
2483
	CONSTRAINT `serialitems_sfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE
2485
    CONSTRAINT `serialitems_sfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE
2484
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
2486
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
2485
2487
2486
--
2488
--
Lines 3430-3433 CREATE TABLE IF NOT EXISTS `misc_files` ( -- miscellaneous files attached to rec Link Here
3430
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
3432
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
3431
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
3433
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
3432
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
3434
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
3433
(-)a/installer/data/mysql/updatedatabase.pl (+9 lines)
Lines 8603-8608 if ( CheckVersion($DBversion) ) { Link Here
8603
    SetVersion($DBversion);
8603
    SetVersion($DBversion);
8604
}
8604
}
8605
8605
8606
8606
$DBversion = '3.17.00.014';
8607
$DBversion = '3.17.00.014';
8607
if ( CheckVersion($DBversion) ) {
8608
if ( CheckVersion($DBversion) ) {
8608
    $dbh->do("
8609
    $dbh->do("
Lines 8613-8618 if ( CheckVersion($DBversion) ) { Link Here
8613
    SetVersion($DBversion);
8614
    SetVersion($DBversion);
8614
}
8615
}
8615
8616
8617
$DBversion = "XXX";
8618
if ( CheckVersion($DBversion) ) {
8619
    $dbh->do("ALTER TABLE `marc_subfield_structure` ADD COLUMN `important` TINYINT(4) NOT NULL DEFAULT 0  AFTER `mandatory`");
8620
    $dbh->do("ALTER TABLE `marc_tag_structure` ADD COLUMN `important` TINYINT(4) NOT NULL DEFAULT 0  AFTER `frameworkcode`");
8621
    print "Upgrade to $DBversion done (Bug 8643 - Add important constraint to marc subfields)\n";
8622
    SetVersion($DBversion);
8623
}
8624
8616
=head1 FUNCTIONS
8625
=head1 FUNCTIONS
8617
8626
8618
=head2 TableExists($table)
8627
=head2 TableExists($table)
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/marc_subfields_structure.tt (+2 lines)
Lines 229-234 function populateHiddenCheckboxes(tab) { Link Here
229
                		<li><label for="libopac[% loo.row %]">Text for OPAC: </label><input type="text" id="libopac[% loo.row %]" name="libopac" value="[% loo.libopac %]" size="40" maxlength="80" /></li>
229
                		<li><label for="libopac[% loo.row %]">Text for OPAC: </label><input type="text" id="libopac[% loo.row %]" name="libopac" value="[% loo.libopac %]" size="40" maxlength="80" /></li>
230
                		<li><label for="repeatable[% loo.row %]">Repeatable: </label>[% loo.repeatable %]</li>
230
                		<li><label for="repeatable[% loo.row %]">Repeatable: </label>[% loo.repeatable %]</li>
231
                		<li><label for="mandatory[% loo.row %]">Mandatory: </label>[% loo.mandatory %]</li>
231
                		<li><label for="mandatory[% loo.row %]">Mandatory: </label>[% loo.mandatory %]</li>
232
                        <li><label for="important[% loo.row %]">Important: </label>[% loo.important %]</li>
232
                        <li><label for="tab[% loo.row %]">Managed in tab: </label>
233
                        <li><label for="tab[% loo.row %]">Managed in tab: </label>
233
                            <select name="tab" tabindex="" size="1" id="[% loo.tab.id %]">
234
                            <select name="tab" tabindex="" size="1" id="[% loo.tab.id %]">
234
                            [%- IF ( loo.tab.default ==  -1 ) -%]
235
                            [%- IF ( loo.tab.default ==  -1 ) -%]
Lines 412-417 function populateHiddenCheckboxes(tab) { Link Here
412
            [% IF ( loo.kohafield ) %] | Koha field: [% loo.kohafield %], [% END %]
413
            [% IF ( loo.kohafield ) %] | Koha field: [% loo.kohafield %], [% END %]
413
            [% IF ( loo.repeatable ) %]Repeatable, [% ELSE %]Not repeatable,[% END %]
414
            [% IF ( loo.repeatable ) %]Repeatable, [% ELSE %]Not repeatable,[% END %]
414
            [% IF ( loo.mandatory ) %]Mandatory, [% ELSE %]Not mandatory,[% END %]
415
            [% IF ( loo.mandatory ) %]Mandatory, [% ELSE %]Not mandatory,[% END %]
416
            [% IF ( loo.important ) %]Important, [% ELSE %]Not important,[% END %]
415
            [% IF ( loo.seealso ) %] | See Also: [% loo.seealso %],[% END %]
417
            [% IF ( loo.seealso ) %] | See Also: [% loo.seealso %],[% END %]
416
            [% IF ( loo.hidden ) %]hidden,[% END %]
418
            [% IF ( loo.hidden ) %]hidden,[% END %]
417
            [% IF ( loo.isurl ) %]is a URL,[% END %]
419
            [% IF ( loo.isurl ) %]is a URL,[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/marctagstructure.tt (-1 / +12 lines)
Lines 103-108 $(document).ready(function() { Link Here
103
        [% END %]
103
        [% END %]
104
        </select>
104
        </select>
105
        (if you select a value here, the indicators will be limited to the authorized value list)</li>
105
        (if you select a value here, the indicators will be limited to the authorized value list)</li>
106
    <li><label for="important">Important: </label>
107
        [% IF ( important ) %]
108
            <input type="checkbox" name="important" id="important" value="1" checked="checked" />
109
        [% ELSE %]
110
            <input type="checkbox" name="important" id="important" value="1" />
111
        [% END %]
112
    </li>
113
    <li><label for="authorised_value">Authorized value: </label>[% authorised_value %] (if you select a value here, the indicators will be limited to the authorized value list)</li>
106
</ol></fieldset> 
114
</ol></fieldset> 
107
    <fieldset class="action">
115
    <fieldset class="action">
108
        <input type="submit" value="Save changes" />
116
        <input type="submit" value="Save changes" />
Lines 183-188 $(document).ready(function() { Link Here
183
        <th>Lib</th>
191
        <th>Lib</th>
184
        <th>Repeatable</th>
192
        <th>Repeatable</th>
185
        <th>Mandatory</th>
193
        <th>Mandatory</th>
194
        <th>Important</th>
186
        <th>Auth value</th>
195
        <th>Auth value</th>
187
        <th>Subfields</th>
196
        <th>Subfields</th>
188
        <th>Edit</th>
197
        <th>Edit</th>
Lines 197-202 $(document).ready(function() { Link Here
197
            <td>[% loo.liblibrarian %]</td>
206
            <td>[% loo.liblibrarian %]</td>
198
            <td>[% IF ( loo.repeatable ) %]Yes[% ELSE %]No[% END %]</td>
207
            <td>[% IF ( loo.repeatable ) %]Yes[% ELSE %]No[% END %]</td>
199
            <td>[% IF ( loo.mandatory ) %]Yes[% ELSE %]No[% END %]</td>
208
            <td>[% IF ( loo.mandatory ) %]Yes[% ELSE %]No[% END %]</td>
209
            <td>[% IF ( loo.important ) %]Yes[% ELSE %]No[% END %]</td>
200
            <td>[% loo.authorised_value %]</td>
210
            <td>[% loo.authorised_value %]</td>
201
            <td><a href="[% loo.subfield_link %]">subfields</a></td>
211
            <td><a href="[% loo.subfield_link %]">subfields</a></td>
202
            <td><a href="[% loo.edit %]">Edit</a></td>
212
            <td><a href="[% loo.edit %]">Edit</a></td>
Lines 207-213 $(document).ready(function() { Link Here
207
            <td colspan="7">
217
            <td colspan="7">
208
                [% FOREACH subfield IN loo.subfields %]
218
                [% FOREACH subfield IN loo.subfields %]
209
                    <p>	Tab:[% subfield.tab %] | $[% subfield.tagsubfield %]
219
                    <p>	Tab:[% subfield.tab %] | $[% subfield.tagsubfield %]
210
                            [% subfield.liblibrarian %] [% IF ( subfield.kohafield ) %][% subfield.kohafield %][% END %][% IF ( subfield.repeatable ) %], repeatable[% END %][% IF ( subfield.mandatory ) %], Mandatory[% END %][% IF ( subfield.seealso ) %], See [% subfield.seealso %][% END %][% IF ( subfield.authorised_value ) %], [% subfield.authorised_value %][% END %][% IF ( subfield.authtypecode ) %], [% subfield.authtypecode %][% END %][% IF ( subfield.value_builder ) %], [% subfield.value_builder %][% END %]
220
                            [% subfield.liblibrarian %] [% IF ( subfield.kohafield ) %][% subfield.kohafield %][% END %][% IF ( subfield.repeatable ) %], repeatable[% END %][% IF ( subfield.mandatory ) %], Mandatory[% END %][% IF ( subfield.important ) %], Important[% END %][% IF ( subfield.seealso ) %], See [% subfield.seealso %][% END %][% IF ( subfield.authorised_value ) %], [% subfield.authorised_value %][% END %][% IF ( subfield.authtypecode ) %], [% subfield.authtypecode %][% END %][% IF ( subfield.value_builder ) %], [% subfield.value_builder %][% END %]
211
                    </p>
221
                    </p>
212
                [% END %]
222
                [% END %]
213
            </td>
223
            </td>
Lines 220-225 $(document).ready(function() { Link Here
220
        <td>[% loo.liblibrarian %]</td>
230
        <td>[% loo.liblibrarian %]</td>
221
        <td>[% IF ( loo.repeatable ) %]Yes[% ELSE %]No[% END %]</td>
231
        <td>[% IF ( loo.repeatable ) %]Yes[% ELSE %]No[% END %]</td>
222
        <td>[% IF ( loo.mandatory ) %]Yes[% ELSE %]No[% END %]</td>
232
        <td>[% IF ( loo.mandatory ) %]Yes[% ELSE %]No[% END %]</td>
233
        <td>[% IF ( loo.important ) %]Yes[% ELSE %]No[% END %]</td>
223
        <td>[% loo.authorised_value %]</td>
234
        <td>[% loo.authorised_value %]</td>
224
        <td><a href="[% loo.subfield_link %]">Subfields</a></td>
235
        <td><a href="[% loo.subfield_link %]">Subfields</a></td>
225
        <td><a href="[% loo.edit %]">Edit</a></td>
236
        <td><a href="[% loo.edit %]">Edit</a></td>
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbiblio.tt (-3 / +117 lines)
Lines 222-228 function AreMandatoriesNotOk(){ Link Here
222
    var flag=0;
222
    var flag=0;
223
    var tabflag= new Array();  
223
    var tabflag= new Array();  
224
    [% FOREACH BIG_LOO IN BIG_LOOP %]
224
    [% FOREACH BIG_LOO IN BIG_LOOP %]
225
    	[% FOREACH innerloo IN BIG_LOO.innerloop %]
225
        [% FOREACH innerloo IN BIG_LOO.innerloop %]
226
	        [% IF ( innerloo.mandatory ) %]
226
	        [% IF ( innerloo.mandatory ) %]
227
    	    	mandatoriesfields.push(new Array("[% innerloo.tag %]","[% innerloo.index %][% innerloo.random %]","[% innerloo.index %]"));
227
    	    	mandatoriesfields.push(new Array("[% innerloo.tag %]","[% innerloo.index %][% innerloo.random %]","[% innerloo.index %]"));
228
        	[% END %]
228
        	[% END %]
Lines 308-314 function AreMandatoriesNotOk(){ Link Here
308
    	
308
    	
309
    	if(isempty){
309
    	if(isempty){
310
    		flag = 1;
310
    		flag = 1;
311
                StrAlert += "\t* " + _("Field %s is mandatory, at least one of its subfields must be filled.").format(arr[0]) + "\n";
311
            StrAlert += "\t* " + _("Field %s is mandatory, at least one of its subfields must be filled.").format(arr[0]) + "\n";
312
    	}
312
    	}
313
    	
313
    	
314
    }
314
    }
Lines 327-332 function AreMandatoriesNotOk(){ Link Here
327
function Check(){
327
function Check(){
328
    var StrAlert = AreMandatoriesNotOk();
328
    var StrAlert = AreMandatoriesNotOk();
329
    if( ! StrAlert ){
329
    if( ! StrAlert ){
330
        var StrWarning = AreImportantsNotOk();
331
        if (StrWarning){
332
            var r=confirm(StrWarning);
333
            if (! r){
334
                return false;
335
            }
336
        }
330
        document.f.submit();
337
        document.f.submit();
331
        return true;
338
        return true;
332
    } else {
339
    } else {
Lines 336-341 function Check(){ Link Here
336
}
343
}
337
344
338
/** 
345
/** 
346
 * check if mandatory subfields are written
347
 */
348
function AreImportantsNotOk(){
349
    var importants = new Array();
350
    var importantsfields = new Array();
351
    var tab = new Array();
352
    var label = new Array();
353
    var flag=0;
354
    var tabflag= new Array();
355
    [% FOREACH BIG_LOO IN BIG_LOOP %]
356
    [% FOREACH innerloo IN BIG_LOO.innerloop %]
357
        [% IF ( innerloo.important ) %]
358
           importantsfields.push(new Array("[% innerloo.tag %]","[% innerloo.index %][% innerloo.random %]","[% innerloo.index %]"));
359
        [% END %]
360
        [% FOREACH subfield_loo IN innerloo.subfield_loop %]
361
            [% IF ( subfield_loo.important ) %]importants.push("[% subfield_loo.id %]");
362
                tab.push("[% subfield_loo.number %]");
363
                label.push("[% subfield_loo.marc_lib %]");
364
                [% END %]
365
            [% END %]
366
        [% END %]
367
    [% END %]
368
    var StrWarning = _("A few important fields are not filled:");
369
    StrWarning += "\n\n";
370
    for(var i=0,len=importants.length; i<len ; i++){
371
        var tag=importants[i].substr(4,3);
372
        var subfield=importants[i].substr(17,1);
373
        var tagnumber=importants[i].substr(19,importants[i].lastIndexOf("_")-19);
374
        tabflag[tag+subfield+tagnumber]=new Array();
375
        tabflag[tag+subfield+tagnumber][0]=0;
376
        if( ! document.getElementById(importants[i]).value){
377
            tabflag[tag+subfield+tagnumber][0] = 0 + tabflag[tag+subfield+tagnumber] ;
378
            document.getElementById(importants[i]).setAttribute('class','subfield_not_filled');
379
            document.getElementById(importants[i]).focus();
380
            tabflag[tag+subfield+tagnumber][1]=label[i];
381
            tabflag[tag+subfield+tagnumber][2]=tab[i];
382
        } else {
383
            tabflag[tag+subfield+tagnumber][0] = 1;
384
        }
385
    }
386
    for (var tagsubfieldid in tabflag){
387
      if (tabflag[tagsubfieldid][0]==0){
388
        var tag=tagsubfieldid.substr(0,3);
389
        var subfield=tagsubfieldid.substr(3,1);
390
        StrWarning += "\t* "+_("tag ")+tag+_(" subfield ")+subfield+" "+tabflag[tagsubfieldid][1]+_(" in tab ")+tabflag[tagsubfieldid][2]+"\n";
391
        //StrAlert += "\t* "+label[i]+_(" in tab ")+tab[i]+"\n";
392
        flag=1;
393
      }
394
    }
395
396
    /* Check for mandatories field(not subfields) */
397
    for(var i=0,len=importantsfields.length; i<len; i++){
398
        isempty  = true;
399
        arr      = importantsfields[i];
400
        divid    = "tag_" + arr[0] + "_" + arr[1];
401
        varegexp = new RegExp("^tag_" + arr[0] + "_code_");
402
403
        if(parseInt(arr[0]) >= 10){
404
           elem = document.getElementById(divid);
405
           eleminputs = elem.getElementsByTagName('input');
406
           for(var j=0,len2=eleminputs.length; j<len2; j++){
407
408
              if(eleminputs[j].name.match(varegexp) && eleminputs[j].value){
409
                 inputregexp = new RegExp("^tag_" + arr[0] + "_subfield_" + eleminputs[j].value + "_" + arr[2]);
410
411
                   for( var k=0; k<len2; k++){
412
                        if(eleminputs[k].id.match(inputregexp) && eleminputs[k].value){
413
                            isempty = false
414
                        }
415
                    }
416
417
                    elemselect = elem.getElementsByTagName('select');
418
                    for( var k=0; k<elemselect.length; k++){
419
                        if(elemselect[k].id.match(inputregexp) && elemselect[k].value){
420
                           isempty = false
421
                        }
422
                    }
423
              }
424
           }
425
426
           elemtextareas = elem.getElementsByTagName('textarea');
427
           for(var j=0,len2=elemtextareas.length; j<len2; j++){
428
                // this bit assumes that the only textareas in this context would be for subfields
429
               if (elemtextareas[j].value) {
430
                   isempty = false;
431
               }
432
           }
433
       }else{
434
          isempty = false;
435
       }
436
437
       if(isempty){
438
          flag = 1;
439
          StrWarning += _("\t* Field ") + arr[0] + _(" is important, at least one of its subfields should be filled.") + "\n";
440
       }
441
    }
442
443
    StrWarning += "\n" + _("Are you sure you want to save?");
444
445
    if(flag){
446
        return StrWarning;
447
    } else {
448
        return flag;
449
    }
450
}
451
452
/**
339
 * check if z3950 mandatories are set or not
453
 * check if z3950 mandatories are set or not
340
 */
454
 */
341
function GetZ3950Terms(){
455
function GetZ3950Terms(){
Lines 606-611 function Changefwk(FwkList) { Link Here
606
                    [% IF ( subfield_loo.mandatory ) %]<span class="subfield subfield_mandatory">[% ELSE %]<span class="subfield">[% END %]
720
                    [% IF ( subfield_loo.mandatory ) %]<span class="subfield subfield_mandatory">[% ELSE %]<span class="subfield">[% END %]
607
                        [% subfield_loo.marc_lib_plain %]
721
                        [% subfield_loo.marc_lib_plain %]
608
                        [% IF ( subfield_loo.mandatory ) %]<span class="mandatory_marker" title="This field is mandatory">*</span>[% END %]
722
                        [% IF ( subfield_loo.mandatory ) %]<span class="mandatory_marker" title="This field is mandatory">*</span>[% END %]
723
                        [% IF ( subfield_loo.important ) %]<span style="color:black" title="This field is important">*</span>[% END %]
609
                    </span>
724
                    </span>
610
                    </label>
725
                    </label>
611
                [% END %]
726
                [% END %]
612
- 

Return to bug 8643