| Lines 20-26
          
      
      
        Link Here | 
        
          | 20 | # along with Koha; if not, see <http://www.gnu.org/licenses>. | 20 | # along with Koha; if not, see <http://www.gnu.org/licenses>. | 
        
          | 21 |  | 21 |  | 
        
          | 22 | use Modern::Perl; | 22 | use Modern::Perl; | 
            
              | 23 | use C4::Biblio qw/GetMarcFromKohaField/; |  |  | 
        
          | 24 | use Koha::DateUtils; | 23 | use Koha::DateUtils; | 
        
          | 25 |  | 24 |  | 
        
          | 26 | my $builder = sub { | 25 | my $builder = sub { | 
  
    | Lines 29-40
          my $builder = sub {
      
      
        Link Here | 
        
          | 29 |  | 28 |  | 
        
          | 30 |     my $date = output_pref({ dt => dt_from_string, dateformat => 'iso', dateonly => 1 }); | 29 |     my $date = output_pref({ dt => dt_from_string, dateformat => 'iso', dateonly => 1 }); | 
        
          | 31 |  | 30 |  | 
          
            
              | 32 | 	# find the tag/subfield mapped to items.dateaccessioned | 31 |     my $res  = <<END_OF_JS; | 
            
              | 33 | 	my ($tag,$subfield) =  GetMarcFromKohaField("items.dateaccessioned",""); | 32 | <script> | 
            
              | 34 | 	my $res  = <<END_OF_JS; |  |  | 
            
              | 35 | <script type="text/javascript"> | 
            
              | 36 | //<![CDATA[ | 
            
              | 37 | //   | 
        
          | 38 | // from: cataloguing/value_builder/dateaccessioned.pl | 33 | // from: cataloguing/value_builder/dateaccessioned.pl | 
        
          | 39 |  | 34 |  | 
        
          | 40 | function Focus$function_name(event) { | 35 | function Focus$function_name(event) { | 
  
    | Lines 53-59
          function set_to_today( id, force ) {
      
      
        Link Here | 
        
          | 53 |         \$("#" + id).val("$date"); | 48 |         \$("#" + id).val("$date"); | 
        
          | 54 |     } | 49 |     } | 
        
          | 55 | } | 50 | } | 
            
              | 56 | //]]> |  |  | 
        
          | 57 | </script> | 51 | </script> | 
        
          | 58 | END_OF_JS | 52 | END_OF_JS | 
        
          | 59 |     return $res; | 53 |     return $res; | 
            
              | 60 | -  |  |  |