Skip to the content
Documentation
Help Start
Reading in:
  • German: 9,059 of 9,059 pages
About the help in other languages
All help pages

exp:expbackfillordersiteaccess

Infer the siteaccess of orders placed before ezorder.siteaccess was recorded (dry run unless --apply).

Download as PDF

Address: https://doc.exponential.earth/exphelp/viewer/examples/commands/expbackfillordersiteaccess.md

On this page

exp:expbackfillordersiteaccess

Infer the siteaccess of orders placed before ezorder.siteaccess was recorded (dry run unless --apply).

Script bin/php/expbackfillordersiteaccess.php, code in kernel/private/classes/commands/expbackfillordersiteaccess.php. Run it from the installation root, as the user the web server runs as:

./console exp:expbackfillordersiteaccess --help
php bin/php/expbackfillordersiteaccess.php --help

Help text

Infer the siteaccess of orders that have none (placed before Exponential 6.0.15 recorded it)
from the content tree each site siteaccess serves: an order whose products all lie in the tree of
exactly one site (its PathPrefix node, else its RootNode) gets that siteaccess; orders matching none
or several stay unknown. Administrations (admin, editor ...) never take orders and are left out,
decided as the siteaccess menu decides them ([AdminSiteAccessMenu] AdminSiteAccessList[], else the
design). Siteaccesses named with --exclude are never chosen either: the next candidate can win, and an
order only excluded siteaccesses serve stays unknown. An order that has a siteaccess is never changed.
Without --apply nothing is written: the siteaccesses considered, excluded and left out are listed,
then each order with the siteaccess it would get, or why it stays unknown.

Example: php bin/php/expbackfillordersiteaccess.php
         php bin/php/expbackfillordersiteaccess.php --prefer-deepest-root
         php bin/php/expbackfillordersiteaccess.php --exclude=site_mobile,site_preview
         php bin/php/expbackfillordersiteaccess.php --exclude=site_mobile --exclude=site_preview --prefer-deepest-root
         php bin/php/expbackfillordersiteaccess.php --apply

Options

OptionValueHelp
--applyWrite the inferred siteaccesses (the default is a dry run that changes nothing)
--prefer-deepest-rootOff by default. Only for public sites with nested roots (a shop inside another site's tree): of several sites that serve every product, take the one whose root is deepest when it is the only one that deep
--excluderequiredNever choose these siteaccesses: a comma list, and the option may be repeated (--exclude=a,b --exclude=c). A name not in AvailableSiteAccessList is a warning, not an error

Read from the option definitions in the code (startup(), getOptions(), options() or ezcConsoleOption). Every script also takes the standard options of the script framework (--help, --siteaccess, --debug, --quiet, --allow-root-user ...).


Generated by ./console exp:help:examples from bin/php/expbackfillordersiteaccess.php, kernel/private/classes/commands/expbackfillordersiteaccess.php. Do not edit this page: change the source and generate again (how). Free documentation: GFDL 1.3 or later.

Something wrong on this page? Report an error

Documentation license

This documentation is free documentation, licensed under the GNU Free Documentation License 1.3 or later.

Exponential Copyright © 1998-2026 Exponential Foundation and 7x