Skip to content
This repository has been archived by the owner on May 30, 2019. It is now read-only.

Commit

Permalink
Store + Shipping + Menus
Browse files Browse the repository at this point in the history
* Using new Store feature from Elcodi
* Added Store management in Admin
* Changed all definitions that was depending on such implementation
* Removed under construction logic and tests

* Removed menu fixtures
* Defined them as dynamic content. Some of them are generated dinamically, and
  some of them statically.
* Added neede menu builders in every Admin bundle
* Changed the way menu is loaded in Admin

* Removed dependency with Configuration and Configuration annotation, in order to use
  new implementation.
* Removed configuration elements
* Removed all `elcodi_config` twig extension usage

* Moved custom shipping logic from elcodi/elcodi to elcodi-plugins/*
* Added full repo inside Plugin folder
* Using new Shipping engine

* Updated some code in order to be compatible with Sf2.7 deprecations

Ready for Elcodi Beta! Auu! Auu!
  • Loading branch information
mmoreram committed Jun 8, 2015
1 parent 8e55243 commit 8905b3e
Show file tree
Hide file tree
Showing 279 changed files with 7,463 additions and 3,641 deletions.
1 change: 0 additions & 1 deletion .gitsplit.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
split:
# Split definition for http://gitsplit.com
src/Elcodi/Template/*: [email protected]:elcodi-templates/$i.git
src/Elcodi/Plugin/*: [email protected]:elcodi-plugins/$i.git
8 changes: 4 additions & 4 deletions app/AppKernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ public function registerBundles()
new Elcodi\Bundle\TaxBundle\ElcodiTaxBundle(),
new Elcodi\Bundle\EntityTranslatorBundle\ElcodiEntityTranslatorBundle(),
new Elcodi\Bundle\StateTransitionMachineBundle\ElcodiStateTransitionMachineBundle(),
new Elcodi\Bundle\ConfigurationBundle\ElcodiConfigurationBundle(),
new Elcodi\Bundle\PageBundle\ElcodiPageBundle(),
new Elcodi\Bundle\MetricBundle\ElcodiMetricBundle(),
new Elcodi\Bundle\PluginBundle\ElcodiPluginBundle($this),
Expand All @@ -95,6 +94,7 @@ public function registerBundles()
new Elcodi\Bundle\ShippingBundle\ElcodiShippingBundle(),
new Elcodi\Bundle\SitemapBundle\ElcodiSitemapBundle(),
new Elcodi\Bundle\PaymentBundle\ElcodiPaymentBundle(),
new Elcodi\Bundle\StoreBundle\ElcodiStoreBundle(),

/**
* Elcodi store bundle
Expand Down Expand Up @@ -133,15 +133,14 @@ public function registerBundles()
new Elcodi\Admin\PluginBundle\AdminPluginBundle(),
new Elcodi\Admin\ShippingBundle\AdminShippingBundle(),
new Elcodi\Admin\GeoBundle\AdminGeoBundle(),
new Elcodi\Admin\ConfigurationBundle\AdminConfigurationBundle(),
new Elcodi\Admin\PaymentBundle\AdminPaymentBundle(),
new Elcodi\Admin\StoreBundle\AdminStoreBundle(),

/**
* Elcodi common bundle
*/
new Elcodi\Common\FirewallBundle\ElcodiFirewallBundle(),
new Elcodi\Common\BambooBundle\ElcodiBambooBundle(),
new Elcodi\Common\ConfigurationBundle\ConfigurationAnnotationBundle(),
new Elcodi\Common\CommonBundle\ElcodiCommonBundle(),

/**
* Elcodi Plugins
Expand All @@ -157,6 +156,7 @@ public function registerBundles()
new Elcodi\Plugin\PaypalWebCheckoutBundle\ElcodiPaypalWebCheckoutBundle(),
new Elcodi\Plugin\FreePaymentBundle\ElcodiFreePaymentBundle(),
new Elcodi\Plugin\StripeBundle\ElcodiStripeBundle(),
new Elcodi\Plugin\CustomShippingBundle\ElcodiCustomShippingBundle(),
);

if (in_array($this->getEnvironment(), array('dev', 'test'))) {
Expand Down
2 changes: 1 addition & 1 deletion app/Resources/views/_base.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>{% block title elcodi_config('store.name') %}</title>
<title>{% block title store.name %}</title>
{% block meta_tags "" %}
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<script type="text/javascript">document.documentElement.className = document.documentElement.className.replace(/\bno-js\b/,'js');</script>
Expand Down
7 changes: 0 additions & 7 deletions app/config/common/cache.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,6 @@ doctrine_cache:
type: redis
namespace: %elcodi.core.bamboo.cache_prefix%menus

#
# Configuration values cache
#
elcodi_configurations:
type: redis
namespace: %elcodi.core.bamboo.cache_prefix%configuration

#
# Entity translations cache
#
Expand Down
115 changes: 0 additions & 115 deletions app/config/common/configuration.yml

This file was deleted.

18 changes: 1 addition & 17 deletions app/config/common/services.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,20 +26,4 @@ services:
arguments:
- @templating.engine.twig
- "Layout:_static.html.twig"
- [@=elcodi_config("store.template")]

#
# Store tracker
#
elcodi.store_tracker:
class: stdClass
factory: [@elcodi.manager.configuration, get]
arguments: ['store.tracker']

#
# Store address
#
elcodi.store_address:
class: %elcodi.entity.address.class%
factory_service: elcodi.service.store_address_manager
factory_method: getStoreAddress
- [@elcodi.store_template]
5 changes: 0 additions & 5 deletions app/config/common/translations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,3 @@ elcodi_entity_translator:
metaTitle: ~
metaDescription: ~
metaKeywords: ~
Elcodi\Component\Shipping\Entity\Interfaces\CarrierInterface:
alias: carrier
fields:
name: ~
description: ~
22 changes: 15 additions & 7 deletions app/config/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ imports:
# Common Elcodi configuration
- { resource: common/translations.yml }
- { resource: common/filesystem.yml }
- { resource: common/configuration.yml }
- { resource: common/cache.yml }
- { resource: common/twig.yml }
- { resource: common/metrics.yml }
Expand Down Expand Up @@ -46,8 +45,7 @@ twig:
globals:
elcodi_context: []
currency_wrapper: @elcodi.wrapper.currency
store_tracker: @elcodi.store_tracker
store_address: @elcodi.store_address
store: @elcodi.store

# Doctrine Configuration
doctrine:
Expand All @@ -63,6 +61,8 @@ doctrine:
charset: UTF8

orm:
resolve_target_entities:
Elcodi\Component\Cart\Entity\Interfaces\CartInterface2: Elcodi\Component\Cart\Entity\Cart2
auto_generate_proxy_classes: "%kernel.debug%"
entity_managers:
default:
Expand All @@ -76,6 +76,7 @@ assetic:
- StoreCoreBundle
- StoreTemplateBundle
- AdminGeoBundle
- AdminStoreBundle
debug: "%kernel.debug%"
use_controller: false
filters:
Expand Down Expand Up @@ -125,10 +126,6 @@ jms_i18n_routing:
#
# Elcodi related configuration
#

elcodi_bamboo:
store_tracker: 7s89da7s8d9a

elcodi_media:
images:
resize:
Expand All @@ -143,11 +140,22 @@ elcodi_media:
# mapping:
# location:
# manager: default
#
# For retrieving location data through the API instead of a simple service, you
# can use the API adapter and configure the host your API is located.
#
# elcodi_geo:
# location_provider: elcodi.location_provider.api
# location_api_host: http://my.server:9090
#

elcodi_page:
renderers:
- bamboo.page.renderer.template_renderer

#
# Overwrite your Error templates
#
store_core:
error_templates:
fallback: true
Expand Down
7 changes: 0 additions & 7 deletions app/config/config_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,3 @@ doctrine:
web_profiler:
toolbar: false
intercept_redirects: false

elcodi_bamboo:
cache_prefix: ''
store_name: 'Elcodi Store'
store_tracker: '101010101010'
store_enabled: true
store_under_construction: false
1 change: 1 addition & 0 deletions app/config/routing/routing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ admin_routes:
#
api_routes:
resource: "routing_api.yml"
prefix: /%bamboo_api_prefix%
options:
i18n: false

Expand Down
10 changes: 2 additions & 8 deletions app/config/routing/routing_admin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ admin_attribute:
admin_product:
resource: "@AdminProductBundle/Resources/config/routing.yml"

admin_shipping:
resource: "@AdminShippingBundle/Resources/config/routing.yml"

admin_media:
resource: "@AdminMediaBundle/Resources/config/routing.yml"

Expand All @@ -37,9 +34,6 @@ admin_newsletter:
admin_page:
resource: "@AdminPageBundle/Resources/config/routing.yml"

admin_configuration:
resource: "@AdminConfigurationBundle/Resources/config/routing.yml"

admin_templates:
resource: "@AdminTemplateBundle/Resources/config/routing.yml"

Expand All @@ -55,8 +49,8 @@ admin_geo:
admin_languages:
resource: "@AdminLanguageBundle/Resources/config/routing.yml"

admin_payments:
resource: "@AdminPaymentBundle/Resources/config/routing.yml"
admin_store:
resource: "@AdminStoreBundle/Resources/config/routing.yml"

admin_login_check:
path: /login_check
Expand Down
4 changes: 2 additions & 2 deletions app/config/routing/routing_store.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ store_hwi_oauth_login:
prefix: /login

store_github_login:
pattern: /login/check-github
path: /login/check-github

store_paypal_login:
pattern: /login/check-paypal
path: /login/check-paypal
8 changes: 0 additions & 8 deletions app/config/security/accessControl.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,6 @@ security:
roles: ROLE_ADMIN

# store
login_area:
path: ^/login.*
roles: IS_AUTHENTICATED_ANONYMOUSLY

password_area:
path: ^/password.*
roles: IS_AUTHENTICATED_ANONYMOUSLY

public_area:
path: ^/.*
roles: IS_AUTHENTICATED_ANONYMOUSLY
Loading

0 comments on commit 8905b3e

Please sign in to comment.