diff --git a/addons/default/visiosoft/advs-module/resources/config/settings/sections.php b/addons/default/visiosoft/advs-module/resources/config/settings/sections.php index 75de1d0be..7c83e2392 100644 --- a/addons/default/visiosoft/advs-module/resources/config/settings/sections.php +++ b/addons/default/visiosoft/advs-module/resources/config/settings/sections.php @@ -30,6 +30,7 @@ return [ 'default_published_time', 'default_GET', 'listing_page_image', + 'show_ads_count', ], ], 'create_ad' => [ @@ -41,6 +42,7 @@ return [ 'hide_configurations', 'make_map_required', 'show_breadcrumb_when_creating_ad', + 'show_post_ad_agreement', ], ], 'ads_image' => [ diff --git a/addons/default/visiosoft/advs-module/resources/config/settings/settings.php b/addons/default/visiosoft/advs-module/resources/config/settings/settings.php index 7ef868ffe..df69de9c2 100644 --- a/addons/default/visiosoft/advs-module/resources/config/settings/settings.php +++ b/addons/default/visiosoft/advs-module/resources/config/settings/settings.php @@ -325,4 +325,18 @@ return [ 'mode' => 'checkbox' ], ], + 'show_ads_count' => [ + 'type' => 'anomaly.field_type.boolean', + 'config' => [ + 'default_value' => true, + 'mode' => 'checkbox' + ], + ], + 'show_post_ad_agreement' => [ + 'type' => 'anomaly.field_type.boolean', + 'config' => [ + 'default_value' => false, + 'mode' => 'checkbox' + ], + ], ]; diff --git a/addons/default/visiosoft/advs-module/resources/lang/en/button.php b/addons/default/visiosoft/advs-module/resources/lang/en/button.php index 48657e31a..c09c7bc27 100644 --- a/addons/default/visiosoft/advs-module/resources/lang/en/button.php +++ b/addons/default/visiosoft/advs-module/resources/lang/en/button.php @@ -41,4 +41,5 @@ return [ 'create_configurations' => 'Create Configurations', 'replicate' => 'Replicate', 'fast_create' => 'Fast create', + 'publish' => 'Publish', ]; diff --git a/addons/default/visiosoft/advs-module/resources/lang/en/field.php b/addons/default/visiosoft/advs-module/resources/lang/en/field.php index 43aa321a6..e813d5ec7 100644 --- a/addons/default/visiosoft/advs-module/resources/lang/en/field.php +++ b/addons/default/visiosoft/advs-module/resources/lang/en/field.php @@ -314,6 +314,10 @@ return [ 'listing_details' => 'Listing Details', 'preview' => 'Preview', 'congratulations' => 'Congratulations', + 'ad_desc' => 'Ad Description', + 'upload_photos' => 'Upload Photos', + 'additional_fields' => 'Additional Fields', + 'ad_location' => 'Ad Location', 'free' => 'Free', 'ad_date' => 'Ad Date', diff --git a/addons/default/visiosoft/advs-module/resources/lang/en/message.php b/addons/default/visiosoft/advs-module/resources/lang/en/message.php index f99494a88..3d41352db 100644 --- a/addons/default/visiosoft/advs-module/resources/lang/en/message.php +++ b/addons/default/visiosoft/advs-module/resources/lang/en/message.php @@ -4,7 +4,7 @@ return [ 'error_added_cart' => 'Requested product is currently missing or inactive', 'please_payment' => 'Please Pay', 'bank_account_info' => 'Bank account information', - 'agreement' => 'By clicking Post, you agree to our Terms of Use and Privacy Policy acknowledge that you are the rightful owner of this item.', + 'agreement' => 'By clicking Publish, you agree to our Terms of Use and Privacy Policy acknowledge that you are the rightful owner of this item.', 'update_category_msg' => 'The classified category will be updated.', 'updated_category_msg' => 'Category successfully edited.', 'create_ad_with_post_cat' => [ diff --git a/addons/default/visiosoft/advs-module/resources/lang/en/setting.php b/addons/default/visiosoft/advs-module/resources/lang/en/setting.php index 56e9cf779..660e90150 100644 --- a/addons/default/visiosoft/advs-module/resources/lang/en/setting.php +++ b/addons/default/visiosoft/advs-module/resources/lang/en/setting.php @@ -197,4 +197,12 @@ return [ 'show_breadcrumb_when_creating_ad' => [ 'name' => 'Show Breadcrumb When Creating an Ad', ], + 'show_ads_count' => [ + 'name' => 'Show Ads Count', + 'instructions' => 'Show ads count on the left categories list', + ], + 'show_post_ad_agreement' => [ + 'name' => 'Show Post Ad Agreement', + 'instructions' => 'Turn this on if you want to display a privacy policy agreement on the ad creation page', + ], ]; diff --git a/addons/default/visiosoft/advs-module/resources/views/new-ad/new-create.twig b/addons/default/visiosoft/advs-module/resources/views/new-ad/new-create.twig index 81a40ec4a..dfc591859 100644 --- a/addons/default/visiosoft/advs-module/resources/views/new-ad/new-create.twig +++ b/addons/default/visiosoft/advs-module/resources/views/new-ad/new-create.twig @@ -20,7 +20,9 @@
- {% set form = form('advs', 'advs').entry(id).actions(['update']).get() %} + {% set form = form('advs', 'advs').entry(id).actions({'update': { + 'text': trans('visiosoft.module.advs::button.publish') + }}).get() %} {{ form_open({ 'id': 'createEditAdvForm', 'class': 'form ' ~ form.options.class , @@ -45,7 +47,7 @@ {% include 'visiosoft.module.advs::new-ad/partials/contact-info' %}
{{ trans('visiosoft.module.advs::field.ad_info') }}
-
+
{% set fields = form.fields.base().pluck('field_name').all() %}
@@ -99,7 +101,7 @@ }).input|raw }}
{% set PriceValue = form.fields.price.value|split('.') %} -
+
{% if setting_value('visiosoft.field_type.decimal::showDecimal') %} @@ -108,7 +110,7 @@ value="{{ PriceValue[1] }}">
{% endif %} -
+
+ {% if setting_value('visiosoft.module.advs::show_post_ad_agreement') %} +
{{ form.actions|raw }}
diff --git a/addons/default/visiosoft/advs-module/resources/views/new-ad/partials/contact-info.twig b/addons/default/visiosoft/advs-module/resources/views/new-ad/partials/contact-info.twig index 7975a456f..f0f40442e 100644 --- a/addons/default/visiosoft/advs-module/resources/views/new-ad/partials/contact-info.twig +++ b/addons/default/visiosoft/advs-module/resources/views/new-ad/partials/contact-info.twig @@ -1,6 +1,6 @@
{{ trans('visiosoft.module.advs::field.contact_info') }}
-
-
+
+