From: Werner Hahn Date: Fri, 22 Sep 2017 00:40:35 +0000 (+0200) Subject: WebshopApi: ShopConnector Base und ALL X-Git-Tag: release-3.5.4~785 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=e01550a6900d0a126f1f40d56a09345f5b23dd27;p=kivitendo-erp.git WebshopApi: ShopConnector Base und ALL --- diff --git a/SL/ShopConnector/ALL.pm b/SL/ShopConnector/ALL.pm new file mode 100644 index 000000000..809f74ad1 --- /dev/null +++ b/SL/ShopConnector/ALL.pm @@ -0,0 +1,34 @@ +package SL::ShopConnector::ALL; + +use strict; + +my %shop_connector_by_name = ( +); + +my %shop_connector_by_connector = ( +); + +my @shop_connector_order = qw( + shopware +); + +my @shop_connectors = ( +); + + +sub all_shop_connectors { + map { $shop_connector_by_name{$_} } @shop_connector_order; +} + +sub shop_connector_class_by_name { + $shop_connector_by_name{$_[1]}; +} + +sub shop_connector_class_by_connector { + $shop_connector_by_connector{$_[1]}; +} + +sub connectors { + \@shop_connectors; +} +1; diff --git a/SL/ShopConnector/Base.pm b/SL/ShopConnector/Base.pm new file mode 100644 index 000000000..19a712f86 --- /dev/null +++ b/SL/ShopConnector/Base.pm @@ -0,0 +1,68 @@ +package SL::ShopConnector::Base; + +use strict; + +use parent qw(SL::DB::Object); +use Rose::Object::MakeMethods::Generic ( + scalar => [ qw(config) ], +); + +sub get_order { die 'get_order needs to be implemented' } + +sub get_new_orders { die 'get_order needs to be implemented' } + +sub update_part { die 'update_part needs to be implemented' } + +sub get_article { die 'get_article needs to be implemented' } + +sub get_categories { die 'get_order needs to be implemented' } + +sub get_version { die 'get_order needs to be implemented' } + +1; + +__END__ + +=encoding utf-8 + +=head1 NAME + + SL::ShopConnectorBase - this is the base class for shop connectors + +=head1 SYNOPSIS + + +=head1 DESCRIPTION + +=head1 AVAILABLE METHODS + +=over 4 + +=item C + +=item C + +=item C + +=item C + +=item C + +=item C + +=back + +=head1 SEE ALSO + +L + +=head1 BUGS + +None yet. :) + +=head1 AUTHOR + +G. Richardson information@kivitendo-premium.deE +W. Hahn Ewh@futureworldsearch.netE + +=cut