X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/53e8b269113c3d06991224d2096c9a4a24d76f72..53593baa211863fbf66540cf1bcc36c8fb37257f:/SL/DB/Shop.pm diff --git a/SL/DB/Shop.pm b/SL/DB/Shop.pm index 6b0035067..bcae3214d 100644 --- a/SL/DB/Shop.pm +++ b/SL/DB/Shop.pm @@ -21,13 +21,15 @@ sub validate { push @errors, $::locale->text('The path is missing.') unless $self->{path}; push @errors, $::locale->text('The Host Name is missing') unless $self->{server}; push @errors, $::locale->text('The Host Name seems invalid') unless $self->{server} =~ m/[0-9A-Za-z].\.[0-9A-Za-z]/; - push @errors, $::locale->text('The Proxy Name seems invalid') unless $self->{proxy} =~ m/[0-9A-Za-z].\.[0-9A-Za-z]/; + push @errors, $::locale->text('The Protocol for Host Name seems invalid (expected: http:// or https://)!') + if ($self->{server} =~ m/:/ && $self->{server} !~ m/(^https:\/\/|^http:\/\/)/); + push @errors, $::locale->text('The Proxy Name seems invalid') . $self->{proxy} . ':' unless !$self->{proxy} || $self->{proxy} =~ m/[0-9A-Za-z].\.[0-9A-Za-z]/; push @errors, $::locale->text('Orders to fetch neeeds a positive Integer') unless $self->{orders_to_fetch} > 0; # not yet implemented checks - push @errors, $::locale->text('Transaction Description is not yet implemented') if $self->{transaction_description}; if ($self->{connector} eq 'shopware6') { + push @errors, $::locale->text('Transaction Description is not yet implemented') if $self->{transaction_description}; push @errors, $::locale->text('Shipping cost article is not implemented') if $self->{shipping_costs_parts_id}; push @errors, $::locale->text('Fetch from last order number is not implemented') if $self->{last_order_number}; } else {