From 82d34bc4e9ff6e1d5c18a05dd03f4ada6d9c2115 Mon Sep 17 00:00:00 2001 From: Andrii Semenets Date: Sat, 19 Oct 2024 20:18:45 +0300 Subject: [PATCH] remove 'samecostcenter' and 'samecostcenterforcredits' form settings and strings (#86) --- lang/de/local_shopping_cart.php | 5 ----- lang/en/local_shopping_cart.php | 5 ----- settings.php | 14 -------------- 3 files changed, 24 deletions(-) diff --git a/lang/de/local_shopping_cart.php b/lang/de/local_shopping_cart.php index 4f59cf8..c88eb54 100644 --- a/lang/de/local_shopping_cart.php +++ b/lang/de/local_shopping_cart.php @@ -512,11 +512,6 @@ $string['ro'] = "Rumänien"; $string['rounddiscounts'] = 'Rabatte runden'; $string['rounddiscounts_desc'] = 'Rabatte auf ganze Zahlen runden (mathematisch, ohne Nachkommastellen)'; -$string['samecostcenter'] = 'Nur eine Kostenstelle pro Zahlungsvorgang'; -$string['samecostcenter_desc'] = 'Alle Items im Warenkorb müssen die selbe Kostenstelle haben. -Items mit unterschiedlichen Kostenstellen müssen separat gebucht werden.'; -$string['samecostcenterforcredits'] = 'Guthaben nur für selbe Kostenstellen verwenden'; -$string['samecostcenterforcredits_desc'] = 'Wenn diese Einstellung aktiviert ist und einE NutzerIn Guthaben erhält, so kann dieses Guthaben nur für Artikel der selben Kostenstelle verwendet werden.'; $string['saveinvoicenumber'] = 'Nur Rechnungsnummer speichern'; $string['sch_paymentaccountid'] = "Wechsle das Zahlungsanbieter-Konto"; $string['se'] = "Schweden"; diff --git a/lang/en/local_shopping_cart.php b/lang/en/local_shopping_cart.php index 973b632..8385c0e 100644 --- a/lang/en/local_shopping_cart.php +++ b/lang/en/local_shopping_cart.php @@ -581,11 +581,6 @@ $string['ro'] = "Romania"; $string['rounddiscounts'] = 'Round discounts'; $string['rounddiscounts_desc'] = 'Round discounts to full numbers (no decimals)'; -$string['samecostcenter'] = 'Only one cost center per payment'; -$string['samecostcenter_desc'] = 'All payment items in shopping cart need to have the same cost center. -Items with different cost centers need to be booked separately.'; -$string['samecostcenterforcredits'] = 'Use credits only for the same costcenter'; -$string['samecostcenterforcredits_desc'] = 'If this setting is turned on and a user receives credits, these credits can only be used for items with the same costcenter.'; $string['saveinvoicenumber'] = 'Just save invoice number'; $string['sch_paymentaccountid'] = "Change the payment account"; $string['se'] = "Sweden"; diff --git a/settings.php b/settings.php index 296f799..0ff837e 100644 --- a/settings.php +++ b/settings.php @@ -177,20 +177,7 @@ 'shipping' => ucfirst(new lang_string('addresses:shipping', 'local_shopping_cart')), ] )); - // If this setting is turned on, all payment items in shopping cart need to have the same cost center. - $settings->add( - new admin_setting_configcheckbox($componentname . '/samecostcenter', - get_string('samecostcenter', 'local_shopping_cart'), - get_string('samecostcenter_desc', 'local_shopping_cart'), 0)); - - // If this setting is turned on and a user receives credits, they can later only be used for items with the same costcenter. - $settings->add( - new admin_setting_configcheckbox($componentname . '/samecostcenterforcredits', - get_string('samecostcenterforcredits', 'local_shopping_cart'), - get_string('samecostcenterforcredits_desc', 'local_shopping_cart'), 0)); - $samecostcenterforcredits = get_config('local_shopping_cart', 'samecostcenterforcredits'); - if ($samecostcenterforcredits) { // If no costcenter is specified in credits, they can be redeemed for items from this costcenter. $settings->add( new admin_setting_configtext( @@ -211,7 +198,6 @@ PARAM_RAW ) ); - } // Setting to activate manual rebooking for cashier. $settings->add(