Files
grzanieplus.pl/plugins/stAllegroPlugin/modules/stAllegroBackend/config/generator.yml
2025-03-12 17:06:23 +01:00

151 lines
9.0 KiB
YAML

generator:
class: stAdminGenerator
param:
model_class: AllegroApiOffer
theme: simple
head:
package: stAllegroPlugin
documentation:
pl: "https://www.sote.pl/docs/allegro-integracja"
en: "https://www.soteshop.com/docs/allegro"
custom_actions:
edit: [assign_product, choose_product]
list:
forward_parameters: [product_id, category_id]
use_helper: [stAsset]
build_options:
related_id: forward_parameters.product_id
related_class: Product
parent_module: stProduct
title: "Lista ofert"
menu:
display: [list, delivery_price_list]
fields:
list: {name: "Lista ofert", action: stAllegroBackend/list}
delivery_price_list: {name: "Cenniki dostaw", action: stAllegroDeliveryBackend/list, i18n: stAllegroDeliveryBackend}
display: [=_primary_image, =name, shop_product_code, stock_available, shop_product_stock, _price, stock_sold, id, status_label]
fields:
primary_image: {name: "", width: 1%}
name: {name: "Tytuł"}
id: {name: Numer, width: 1%}
shop_product_code: {name: "Powiązany produkt", width: 1%}
status_label: {name: "Status", width: 1%}
stock_sold: {name: "Sprzedano", width: 1%}
stock_available: {name: "Sztuk", width: 1%}
shop_product_stock: {name: "W magazynie", width: 1%}
price: {name: "Cena", width: 1%}
filters:
price: {partial: filter_offer_price}
status_label: {partial: filter_offer_status}
select_actions:
display:
"Aukcje:": [create, duplicate]
actions:
_delete: -
object_actions:
_edit: -
_delete: -
duplicate: {name: "Wystaw podobną", icon: "duplicate", action: "duplicate"}
preview: {name: "Podgląd", icon: "preview", action: "%%offer_url%%", params: "target=_blank"}
actions:
_create: {name: Dodaj}
edit:
use_helper: [stAllegro, stAllegroParameter]
use_stylesheet: [backend/stAllegroPlugin.css?v11]
forward_parameters: [product_id, category_id]
build_options:
related_id: forward_parameters.product_id
related_class: Product
related_field: shop_product
parent_module: stProduct
title: "Edycja oferty"
display:
"NONE": [allow_sync, name, _category, _product]
"Powiązany produkt": [_assigned_product, _shop_product_options]
fields:
name: {name: "Tytuł"}
category: {name: "Kategoria", required: true}
product: {name: Produkt Allegro}
assigned_product: {name: "Produkt", type: "custom"}
shop_product_options: {name: "Opcje produktu", type: "custom", required: true}
allow_sync: {name: "Synchronizuj ofertę", type: "checkbox_tag", help: "Jeśli zaznaczone oferta będzie synchronizowana z produktem na sklepie. W przypadku ręcznego zakończenia oferty opcja jest automatycznie odznaczana w celu zablokowania automatycznego wznowienia oferty."}
actions: []
assign_product_edit:
use_helper: [stAllegro]
use_stylesheet: [backend/stAllegroPlugin.css?v11]
forward_parameters: [product_id, category_id]
title: "Przypisz produkt"
display:
"NONE": [_shop_product_id, _shop_product_options]
fields:
shop_product_id: {name: "Produkt", required: true}
shop_product_options: {name: "Opcje produktu", type: "custom", required: true}
actions:
_save: {name: "Zapisz"}
choose_product_edit:
use_helper: [stAllegro]
use_stylesheet: [backend/stAllegroPlugin.css?v11]
forward_parameters: [product_id, category_id]
title: "Dodaj"
display:
"NONE": [_shop_product_id, _shop_product_options]
fields:
shop_product_id: {name: "Produkt", required: true}
shop_product_options: {name: "Opcje produktu", type: "custom", required: true}
actions:
_save: {name: "Dalej"}
config:
use_helper: [stAllegro, stAllegroDelivery]
title: "Konfiguracja"
description: "Zarządzanie systemami aukcyjnymi, wystawianie produktów na aukcje, konfiguracja ustawień."
menu:
display: [config, delivery]
fields:
config: {name: "Konfiguracja", action: stAllegroBackend/config}
delivery: {name: "Cenniki dostawy", action: stAllegroDeliveryBackend/list}
display:
"Ustawienia konta Allegro.pl": [enable, sandbox, client_id, _client_secret]
"Lokalizacja": [~allegro_pl_state, allegro_pl_city, allegro_pl_post_code]
"Dostawa i płatność": [delivery_shipping_rates_id, delivery_handling_time, payments_invoice]
"Warunki reklamacji / gwarancji / zwrotów": [warranty, implied_warranty, return_policy]
"Import zamówień": [import_product_name]
"Oferty": [_offer_product_commission, offer_sync_product_price]
fields:
enable: {name: Włącz, type: checkbox }
sandbox: {name: Sandbox, type: checkbox }
offer_sync_product_price: {name: Synchronizuj cenę produktu, type: checkbox}
offer_product_commission: {name: "Prowizja [%]", help: Jeśli ustawiona prowizja doliczana jest do ceny produktu podczas wystawiania lub aktualizacji oferty}
client_id: {name: Client ID, required: true, params: size=40}
client_secret: {name: Client Secret, required: true}
allegro_pl_state: {name: "Region", required: true}
allegro_pl_city: {name: "Miasto", required: true}
allegro_pl_post_code: {name: "Kod pocztowy", params: size=6, required: true}
bank_account1: {name: "Numer konta bankowego", params: size=28}
bank_account2: {name: "Dodatkowy numer konta bankowego", params: size=28}
warranty: {name: Informacja o gwarancji, callback: st_allegro_warranty_select_tag}
implied_warranty: {name: Warunki reklamacji, callback: st_allegro_implied_warranty_select_tag}
return_policy: {name: Warunki zwrotów, callback: st_allegro_return_policy_select_tag}
delivery_shipping_rates_id: {name: Domyślny cennik dostawy, callback: st_allegro_shippin_rates_select_tag}
delivery_handling_time: {name: Domyślny czas wysyłki, callback: st_allegro_delivery_times_select_tag}
payments_invoice: {name: Domyślne opcje faktury, callback: st_allegro_payments_invoice_select_tag}
import_product_name:
name: Nazwy produktów
type: select
display: [offer, product]
help: Określa czy produkty zachowają swoją oryginalną nazwę czy nazwę jaka jest wyśietlana po stronie oferty Allegro
options:
product: {name: Oryginalna nazwa produktu}
offer: {name: Tytuł oferty Allegro}
actions:
_save: {name: Zapisz}