- {{ adv.price.currency }}
+ {{ adv.price.currency(null,'currency',false) }}
{% if setting_value('visiosoft.module.location::list_page_location') %}
diff --git a/addons/default/visiosoft/advs-module/resources/views/list/table.twig b/addons/default/visiosoft/advs-module/resources/views/list/table.twig
index d969f529c..e90cb7f34 100644
--- a/addons/default/visiosoft/advs-module/resources/views/list/table.twig
+++ b/addons/default/visiosoft/advs-module/resources/views/list/table.twig
@@ -36,7 +36,7 @@
- {{ adv.price.currency }}
+ {{ adv.price.currency(null,'currency',false) }}
|
{{ adv.created_at|date("d/m/Y") }}
diff --git a/addons/default/visiosoft/advs-module/src/Adv/AdvRepository.php b/addons/default/visiosoft/advs-module/src/Adv/AdvRepository.php
index f3ef4674e..a54f6a251 100644
--- a/addons/default/visiosoft/advs-module/src/Adv/AdvRepository.php
+++ b/addons/default/visiosoft/advs-module/src/Adv/AdvRepository.php
@@ -190,15 +190,7 @@ class AdvRepository extends EntryRepository implements AdvRepositoryInterface
if ($isActiveDopings) {
- if ($param == null) {
- $DopingModel = new DopingModel();
- $doping_advs_ids = $DopingModel->getFeaturedAds(3);
- $query = $query->whereIn('advs_advs.id', $doping_advs_ids);
- }
- $query = $query->leftJoin('dopings_dopings', function ($join) {
- $join->on('advs_advs.id', '=', 'dopings_dopings.adv_name_id');
- $join->where('dopings_dopings.doping_type_id', '=', 4);
- });
+ $query = app('Visiosoft\DopingsModule\Http\Controller\DopingsController')->search($query, $param);
}
if (!empty($param['sort_by'])) {
switch ($param['sort_by']) {
@@ -215,8 +207,7 @@ class AdvRepository extends EntryRepository implements AdvRepositoryInterface
} else {
$query = $query->orderBy('advs_advs.created_at', 'desc');
if ($isActiveDopings) {
- $query = $query->select('advs_advs.*', 'advs_advs_translations.name as name',
- 'advs_advs_translations.advs_desc as advs_desc', 'dopings_dopings.id as doping');
+ $query = app('Visiosoft\DopingsModule\Http\Controller\DopingsController')->querySelect($query);
} else {
$query = $query->select('advs_advs.*', 'advs_advs_translations.name as name',
'advs_advs_translations.advs_desc as advs_desc');
diff --git a/addons/default/visiosoft/advs-module/src/Http/Controller/advsController.php b/addons/default/visiosoft/advs-module/src/Http/Controller/advsController.php
index c92588e45..1e7337400 100644
--- a/addons/default/visiosoft/advs-module/src/Http/Controller/advsController.php
+++ b/addons/default/visiosoft/advs-module/src/Http/Controller/advsController.php
@@ -163,6 +163,7 @@ class AdvsController extends PublicController
foreach ($featured_advs as $index => $ad) {
$featured_advs[$index]->detail_url = $this->adv_model->getAdvDetailLinkByModel($ad, 'list');
+ $featured_advs[$index]->price = number_format($ad->price);
$featured_advs[$index] = $this->adv_model->AddAdsDefaultCoverImage($ad);
}
diff --git a/addons/default/visiosoft/location-module/resources/js/filterLocation.js b/addons/default/visiosoft/location-module/resources/js/filterLocation.js
index 589909e7b..a012e7a83 100644
--- a/addons/default/visiosoft/location-module/resources/js/filterLocation.js
+++ b/addons/default/visiosoft/location-module/resources/js/filterLocation.js
@@ -198,7 +198,7 @@ function SelectOnClick() {
var id = $(this).attr('data-id');
if ($(this).attr('data-field') == "country") {
- input.val(id)
+ $('input[name="country"]').val(id)
text_html.html(input_text)
$(".filter-location-body input[type='checkbox']").prop('checked', false);
$(".filter-location-body li[data-id='" + id + "'] input[type='checkbox']").prop('checked', true);
diff --git a/addons/default/visiosoft/location-module/resources/views/ads-list/partials/location-fields.twig b/addons/default/visiosoft/location-module/resources/views/ads-list/partials/location-fields.twig
index 60561af34..7156b88a7 100644
--- a/addons/default/visiosoft/location-module/resources/views/ads-list/partials/location-fields.twig
+++ b/addons/default/visiosoft/location-module/resources/views/ads-list/partials/location-fields.twig
@@ -3,13 +3,13 @@
{{ trans('visiosoft.module.location::field.address.name') }}
-
- {{ getCountry(setting_value('visiosoft.module.location::default_country')).name }}
-
{% set country = setting_value('visiosoft.module.location::default_country') %}
{% if app.request.get('country') %}
{% set country = app.request.get('country') %}
{% endif %}
+
+ {{ getCountry(country).name }}
+
diff --git a/composer.json b/composer.json
index 509c5675a..2f0d114b4 100644
--- a/composer.json
+++ b/composer.json
@@ -67,6 +67,8 @@
"anomaly/html_block-extension": "~1.0.0",
"anomaly/wysiwyg_block-extension": "~1.0.0",
"ammadeuss/laravel-html-dom-parser": "^1.1",
+ "visiosoft/decimal-field_type": "~2.1.0",
+ "visiosoft/integer-field_type": "~2.1.0",
"guzzlehttp/guzzle": "~6.3.3"
},
"require-dev": {
|