version 1.33, 2004/01/14 16:47:39
|
version 1.34, 2004/01/15 21:20:07
|
Line 1557 sub outsheet_xml {
|
Line 1557 sub outsheet_xml {
|
## But not on this day |
## But not on this day |
my $Str = '<spreadsheet type="'.$self->{'type'}.'">'."\n"; |
my $Str = '<spreadsheet type="'.$self->{'type'}.'">'."\n"; |
while (my ($cell,$formula) = each(%{$self->{'formulas'}})) { |
while (my ($cell,$formula) = each(%{$self->{'formulas'}})) { |
if ($cell =~ /^template_(\d+)/) { |
if ($cell =~ /^template_(\w+)/) { |
my $col = $1; |
my $col = $1; |
$Str .= '<template col="'.$col.'">'.$formula.'</template>'."\n"; |
$Str .= '<template col="'.$col.'">'.$formula.'</template>'."\n"; |
} else { |
} else { |
Line 1570 sub outsheet_xml {
|
Line 1570 sub outsheet_xml {
|
} |
} |
} |
} |
$Str.="</spreadsheet>"; |
$Str.="</spreadsheet>"; |
# $r->print("<pre>\n\n\n".$Str."\n\n\n</pre>"); |
$r->print("<pre>\n\n\n".$Str."\n\n\n</pre>"); |
return $Str; |
return $Str; |
} |
} |
|
|
Line 1597 sub parse_sheet {
|
Line 1597 sub parse_sheet {
|
$formulas{$cell} = $formula; |
$formulas{$cell} = $formula; |
$sources{$cell} = $source if (defined($source)); |
$sources{$cell} = $source if (defined($source)); |
$parser->get_text('/field'); |
$parser->get_text('/field'); |
} |
} elsif ($token->[1] eq 'template') { |
if ($token->[1] eq 'template') { |
|
$formulas{'template_'.$token->[2]->{'col'}}= |
$formulas{'template_'.$token->[2]->{'col'}}= |
$parser->get_text('/template'); |
$parser->get_text('/template'); |
} |
} |