Change the generic tax driver to remove spaces around commas when adding a new row. Add tests and a convenience method for getting one line of tax information. Upgrade sub fixes any information already in the db.
This commit is contained in:
parent
6ac46be8bd
commit
2bcda0c9f5
5 changed files with 69 additions and 7 deletions
|
|
@ -1,10 +1,9 @@
|
|||
7.10.20
|
||||
- fixed: Do not call group methods on an undefined value.
|
||||
- fixed #12178: random deletion of columns may happen when a schema is saved
|
||||
(Amir Plivatsky)
|
||||
- fixed #12179: DataTable Field types get reset to "Text" in Edit Schema
|
||||
(Amir Plivatsky)
|
||||
- fixed #12178: random deletion of columns may happen when a schema is saved (Amir Plivatsky)
|
||||
- fixed #12179: DataTable Field types get reset to "Text" in Edit Schema (Amir Plivatsky)
|
||||
- added: FormField macro for rendering Form objects directly from templates
|
||||
- fixed: Generic Tax driver does not like spaces around commas
|
||||
|
||||
7.10.19
|
||||
- fixed #12169: extras uploads symlink export
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ finish($session); # this line required
|
|||
# print "DONE!\n" unless $quiet;
|
||||
#}
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
# Fix calendar feed urls that had adminId attached to them until they blew up
|
||||
sub fixBrokenCalendarFeedUrls {
|
||||
my $session = shift;
|
||||
|
|
|
|||
|
|
@ -32,6 +32,7 @@ my $session = start(); # this line required
|
|||
addFormFieldMacroToConfig();
|
||||
|
||||
# upgrade functions go here
|
||||
fixSpacesInTaxInfo ( $session );
|
||||
|
||||
sub addFormFieldMacroToConfig {
|
||||
print "\tAdd FormField macro to config... " unless $quiet;
|
||||
|
|
@ -51,6 +52,22 @@ finish($session); # this line required
|
|||
# print "DONE!\n" unless $quiet;
|
||||
#}
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
# Fix calendar feed urls that had adminId attached to them until they blew up
|
||||
sub fixSpacesInTaxInfo {
|
||||
my $session = shift;
|
||||
print "\tRemoving spaces around commas in generic tax rate information... " unless $quiet;
|
||||
use WebGUI::Shop::TaxDriver::Generic;
|
||||
my $taxer = WebGUI::Shop::TaxDriver::Generic->new($session);
|
||||
my $taxIterator = $taxer->getItems;
|
||||
while (my $taxInfo = $taxIterator->hashRef) {
|
||||
my $taxId = $taxInfo->{taxId};
|
||||
$taxer->add($taxInfo); ##Automatically removes spaces now.
|
||||
$taxer->delete({taxId => $taxId});
|
||||
}
|
||||
print "DONE!\n" unless $quiet;
|
||||
}
|
||||
|
||||
|
||||
# -------------- DO NOT EDIT BELOW THIS LINE --------------------------------
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue