Editing Backup Files

Please note: this only applies to Clear Thinking extensions that support the "Backup Settings" feature.

To manually edit settings, you should first change and edit some settings directly through the admin panel, then download the backup file to view how the settings are stored in the database. The data is in the following format:

Column 1: SETTING         = the setting key
Column 2: NUMBER          = the setting number (if applicable)
Column 3: SUB-SETTING     = the sub-setting key (if applicable)
Column 4: SUB-NUMBER      = the sub-setting number (if applicable)
Column 5: SUB-SUB-SETTING = the sub-sub-setting key (if applicable)
Column 6: VALUE           = the value for the setting

Settings that are contained within tables (such as Charges, Rules, or Modules) use the NUMBER column to store data associated with the same setting, and use SUB-SETTINGs and SUB-SUB-SETTINGs to set further individual settings. For example, a charge setting might use this data:

SETTING NUMBER SUB-SETTING SUB-NUMBER SUB-SUB-SETTING VALUE
charge 2 charges 5.00
charge 2 group A
charge 2 rule 1 comparison any
charge 2 rule 1 type product_group
charge 2 rule 1 value 2
charge 2 title_admin regular charge
charge 2 title_en Flat Rate Charge
charge 2 type flat

Since the SETTING for each row is "charge" and the NUMBER for each row is "2", that means that all these settings apply to charge #2. The SUB-SETTING values show the various settings associated with charge #2. For example, the "group" for charge #2 is "A", and the "type" of the charge is "flat".

One of these is a "rule" setting, which has its own sub-settings (comparison, type, and value) associated with it. Rules always have these three sub-settings, so when creating your own, you'll want to add three new rows. For example, to add a Customer Group rule, you'd add rows like this:

SETTING NUMBER SUB-SETTING SUB-NUMBER SUB-SUB-SETTING VALUE
charge 2 rule 2 type customer_group
charge 2 rule 2 comparison is
charge 2 rule 2 value 1

That rule would mean the charge is enabled when the customer is part of the group with the customer_group_id of 1. To view all the valid setting values for a particular rule type, first add rules in the admin panel using each comparison value, then download the backup file of the settings to view the various options.