first commit
This commit is contained in:
27
plugins/stGroupPricePlugin/config/config.php
Normal file
27
plugins/stGroupPricePlugin/config/config.php
Normal file
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
/**
|
||||
* SOTESHOP/stGroupPricePlugin
|
||||
*
|
||||
*
|
||||
* @package stGroupPricePlugin
|
||||
* @author Bartosz Alejski <bartosz.alejski@sote.pl>
|
||||
*/
|
||||
|
||||
/**
|
||||
* Włączanie modułów
|
||||
*/
|
||||
stPluginHelper::addEnableModule('stGroupPriceBackend', 'backend');
|
||||
|
||||
/**
|
||||
* Routingi
|
||||
*/
|
||||
if (SF_APP == 'backend')
|
||||
{
|
||||
stPluginHelper::addRouting('stGroupPricePlugin', '/group-price/:action/*', 'stGroupPriceBackend', 'list', 'backend');
|
||||
|
||||
$dispatcher->connect('stAdminGenerator.generateStProduct', array('stGroupPricePluginListener', 'generateStProduct'));
|
||||
|
||||
stSocketView::addComponent('stGroupPriceBackend.configCustom.Content','stGroupPriceBackend','configContent');
|
||||
|
||||
stLicenseTypeHelper::addCommercialModule('stGroupPricePlugin');
|
||||
}
|
||||
17
plugins/stGroupPricePlugin/config/generator/stProduct.yml
Normal file
17
plugins/stGroupPricePlugin/config/generator/stProduct.yml
Normal file
@@ -0,0 +1,17 @@
|
||||
edit:
|
||||
display:
|
||||
"Ceny": [_group_price_id]
|
||||
fields:
|
||||
group_price_id: {name: Grupa cenowa, params: include_custom="---" include_blank=false, i18n: stGroupPriceBackend}
|
||||
list:
|
||||
additional_filters: [group_price_id]
|
||||
fields:
|
||||
group_price_id: {name: Grupa cenowa, i18n: stGroupPriceBackend}
|
||||
|
||||
export:
|
||||
fields:
|
||||
group_price: {name: Grupa cenowa, class: stGroupPriceExport, method: getProduct}
|
||||
|
||||
import:
|
||||
fields:
|
||||
group_price: {class: stGroupPriceExport, method: setProduct}
|
||||
84
plugins/stGroupPricePlugin/config/schema.yml
Normal file
84
plugins/stGroupPricePlugin/config/schema.yml
Normal file
@@ -0,0 +1,84 @@
|
||||
---
|
||||
propel:
|
||||
_attributes:
|
||||
defaultIdMethod: native
|
||||
package: plugins.stGroupPricePlugin.lib.model
|
||||
st_group_price:
|
||||
_attributes:
|
||||
phpName: GroupPrice
|
||||
created_at:
|
||||
type: timestamp
|
||||
updated_at:
|
||||
type: timestamp
|
||||
id:
|
||||
type: INTEGER
|
||||
primaryKey: true
|
||||
required: true
|
||||
autoIncrement: true
|
||||
name:
|
||||
type: VARCHAR
|
||||
size: 255
|
||||
description:
|
||||
type: VARCHAR
|
||||
size: 255
|
||||
tax_id:
|
||||
type: INTEGER
|
||||
required: false
|
||||
foreignTable: st_tax
|
||||
foreignReference: id
|
||||
onDelete: setnull
|
||||
opt_vat:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
currency_id:
|
||||
type: INTEGER
|
||||
foreignTable: st_currency
|
||||
foreignReference: id
|
||||
onDelete: setnull
|
||||
price_type:
|
||||
type: VARCHAR
|
||||
size: 24
|
||||
price_modifier:
|
||||
type: VARCHAR
|
||||
size: 10
|
||||
price_netto:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
price_brutto:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
old_price_netto:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
old_price_brutto:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
wholesale_a_netto:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
wholesale_a_brutto:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
wholesale_b_netto:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
wholesale_b_brutto:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
wholesale_c_netto:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
wholesale_c_brutto:
|
||||
type: DECIMAL
|
||||
size: 10
|
||||
scale: 2
|
||||
@@ -0,0 +1,13 @@
|
||||
propel:
|
||||
st_product:
|
||||
_attributes:
|
||||
phpName: Product
|
||||
isI18N: true
|
||||
i18nTable: st_product_i18n
|
||||
group_price_id:
|
||||
type: INTEGER
|
||||
foreignTable: st_group_price
|
||||
foreignReference: id
|
||||
onDelete: setnull
|
||||
_indexes:
|
||||
group_price_idx: [group_price_id]
|
||||
Reference in New Issue
Block a user