Merge pull request #337 from openclassify/vedat

add topfields parameters
This commit is contained in:
Fatih Alp 2020-02-19 09:33:04 +03:00 committed by GitHub
commit 1ea374159c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 311 additions and 307 deletions

View File

@ -1,200 +1,204 @@
{% set formHtml %} {% set formHtml %}
<form action="{{ url_route('visiosoft.module.advs::list') }}" method="get"> <form action="{{ url_route('visiosoft.module.advs::list') }}" method="get">
{% endset %} {% endset %}
{% if 'cat' in param|keys %} {% if 'cat' in param|keys %}
{% if not param['cat'] is empty %} {% if not param['cat'] is empty %}
{% set catId = entries('cats', 'category').find(param['cat']) %} {% set catId = entries('cats', 'category').find(param['cat']) %}
{% set cityId = null %} {% set cityId = null %}
{% if 'city' in param|keys %} {% if 'city' in param|keys %}
{% set citiesArray = param['city'][0]|split(',') %} {% set citiesArray = param['city'][0]|split(',') %}
{% if count(citiesArray) is same as(1) %} {% if count(citiesArray) is same as(1) %}
{% set cityId = entries('location', 'cities').find(param['city'][0]) %} {% set cityId = entries('location', 'cities').find(param['city'][0]) %}
{% endif %}
{% endif %} {% endif %}
{% set formHtml %}
<form action="{{ url_route('adv_list_seo', [catId.slug, cityId.slug]) }}" method="get">
{% endset %}
{% endif %} {% endif %}
{% endif %} {% set formHtml %}
{{ formHtml }} <form action="{{ url_route('adv_list_seo', [catId.slug, cityId.slug]) }}" method="get">
<div class="row"> {% endset %}
<input type="hidden" name="cat" value="{{ app.request.get('cat') }}"> {% endif %}
<input type="hidden" name="user" value="{{ app.request.get('user') }}"> {% endif %}
<div class="col-md-12 px-4"> {{ formHtml }}
<div class="row"> <div class="row">
<div id="filter" class="w-100 mb-3"> <input type="hidden" name="cat" value="{{ app.request.get('cat') }}">
<input type="hidden" name="user" value="{{ app.request.get('user') }}">
<div class="col-md-12 px-4">
<div class="row">
<div id="filter" class="w-100 mb-3">
{{ addBlock('ads-list/partials/list-filter',{ {{ addBlock('ads-list/partials/list-filter',{
'mainCats':mainCats, 'mainCats':mainCats,
'subCats':subCats, 'subCats':subCats,
'ranges':ranges, 'ranges':ranges,
'checkboxes':checkboxes, 'checkboxes':checkboxes,
'radio':radio, 'topfields' : topfields,
'countries':countries, 'radio':radio,
'cities':cities, 'countries':countries,
'districts':districts, 'cities':cities,
'neighborhoods':neighborhoods, 'districts':districts,
'villages':villages, 'neighborhoods':neighborhoods,
'param':param 'villages':villages,
})|raw }} 'param':param
})|raw }}
<!-- Date Filter Start --> <!-- Date Filter Start -->
<div class="card mb-3"> <div class="card mb-3">
<div class="card-header breadcrumb mb-0" id="dateHeading"> <div class="card-header breadcrumb mb-0" id="dateHeading">
<h5 class="mb-0"> <h5 class="mb-0">
<button class="btn btn-link text-dark" data-toggle="collapse" data-target="#date" <button class="btn btn-link text-dark" data-toggle="collapse" data-target="#date"
aria-expanded="true" aria-controls="date"> aria-expanded="true" aria-controls="date">
<i class="fa fa-calendar"></i> <i class="fa fa-calendar"></i>
{{ trans("visiosoft.module.advs::field.date.name") }} {{ trans("visiosoft.module.advs::field.date.name") }}
</button> </button>
</h5> </h5>
</div> </div>
<div id="dateContainer" class="collapse show overflow-auto" aria-labelledby="dateHeading" <div id="dateContainer" class="collapse show overflow-auto" aria-labelledby="dateHeading"
data-parent="#filter" data-parent="#filter"
style="max-height: 300px;"> style="max-height: 300px;">
<div class="d-flex flex-column p-3 m-0"> <div class="d-flex flex-column p-3 m-0">
<div class="form-check py-1"> <div class="form-check py-1">
<input class="form-check-input" type="radio" name="date" id="dateDay" value="day"> <input class="form-check-input" type="radio" name="date" id="dateDay"
<label class="form-check-label" for="dateDay"> value="day">
{{ trans("visiosoft.module.advs::field.in_the_last_24_hours.name") }} <label class="form-check-label" for="dateDay">
</label> {{ trans("visiosoft.module.advs::field.in_the_last_24_hours.name") }}
</div> </label>
<div class="form-check py-1"> </div>
<input class="form-check-input" type="radio" name="date" id="dateWeek" value="week"> <div class="form-check py-1">
<label class="form-check-label" for="dateWeek"> <input class="form-check-input" type="radio" name="date" id="dateWeek"
{{ trans("visiosoft.module.advs::field.in_the_last_week.name") }} value="week">
</label> <label class="form-check-label" for="dateWeek">
</div> {{ trans("visiosoft.module.advs::field.in_the_last_week.name") }}
<div class="form-check py-1"> </label>
<input class="form-check-input" type="radio" name="date" id="dateMonth" </div>
value="month"> <div class="form-check py-1">
<label class="form-check-label" for="dateMonth"> <input class="form-check-input" type="radio" name="date" id="dateMonth"
{{ trans("visiosoft.module.advs::field.in_the_last_month.name") }} value="month">
</label> <label class="form-check-label" for="dateMonth">
{{ trans("visiosoft.module.advs::field.in_the_last_month.name") }}
</label>
</div>
</div> </div>
</div> </div>
</div> </div>
</div> <!-- Date Filter End -->
<!-- Date Filter End -->
<!-- Media Filter Start --> <!-- Media Filter Start -->
<div class="card mb-3"> <div class="card mb-3">
<div class="card-header breadcrumb mb-0" id="mediaHeading"> <div class="card-header breadcrumb mb-0" id="mediaHeading">
<h5 class="mb-0"> <h5 class="mb-0">
<button class="btn btn-link text-dark" data-toggle="collapse" data-target="#media" <button class="btn btn-link text-dark" data-toggle="collapse" data-target="#media"
aria-expanded="true" aria-controls="media"> aria-expanded="true" aria-controls="media">
<i class="fa fa-camera"></i> <i class="fa fa-camera"></i>
{{ trans("visiosoft.module.advs::field.photo.name") }} {{ trans("visiosoft.module.advs::field.photo.name") }}
, {{ trans("visiosoft.module.advs::field.video.name") }} , {{ trans("visiosoft.module.advs::field.video.name") }}
</button> </button>
</h5> </h5>
</div> </div>
<div id="mediaContainer" class="collapse show overflow-auto" aria-labelledby="mediaHeading" <div id="mediaContainer" class="collapse show overflow-auto" aria-labelledby="mediaHeading"
data-parent="#filter" data-parent="#filter"
style="max-height: 300px;"> style="max-height: 300px;">
<div class="row p-3 m-0"> <div class="row p-3 m-0">
<div class="form-check py-1"> <div class="form-check py-1">
<input class="form-check-input" type="checkbox" value="true" name="photo" <input class="form-check-input" type="checkbox" value="true" name="photo"
id="photo"> id="photo">
<label class="form-check-label" for="photo"> <label class="form-check-label" for="photo">
{{ trans("visiosoft.module.advs::field.ads_with_photo.name") }} {{ trans("visiosoft.module.advs::field.ads_with_photo.name") }}
</label> </label>
</div> </div>
<div class="form-check py-1"> <div class="form-check py-1">
<input class="form-check-input" type="checkbox" value="true" name="video" <input class="form-check-input" type="checkbox" value="true" name="video"
id="video"> id="video">
<label class="form-check-label" for="video"> <label class="form-check-label" for="video">
{{ trans("visiosoft.module.advs::field.ads_with_video.name") }} {{ trans("visiosoft.module.advs::field.ads_with_video.name") }}
</label> </label>
</div>
</div> </div>
</div> </div>
</div> </div>
</div> <!-- Media Filter End -->
<!-- Media Filter End -->
<!-- Map Filter Start --> <!-- Map Filter Start -->
<div class="card mb-3"> <div class="card mb-3">
<div class="card-header breadcrumb mb-0" id="mapHeading"> <div class="card-header breadcrumb mb-0" id="mapHeading">
<h5 class="mb-0"> <h5 class="mb-0">
<button class="btn btn-link text-dark" data-toggle="collapse" data-target="#mapFilter" <button class="btn btn-link text-dark" data-toggle="collapse"
aria-expanded="true" aria-controls="mapFilter"> data-target="#mapFilter"
<i class="fa fa-map"></i> aria-expanded="true" aria-controls="mapFilter">
{{ trans("visiosoft.module.advs::field.map.name") }} <i class="fa fa-map"></i>
</button> {{ trans("visiosoft.module.advs::field.map.name") }}
</h5> </button>
</div> </h5>
<div id="mapContainer" class="collapse show overflow-auto" aria-labelledby="mapHeading" </div>
data-parent="#filter" <div id="mapContainer" class="collapse show overflow-auto" aria-labelledby="mapHeading"
style="max-height: 300px;"> data-parent="#filter"
<div class="row p-3 m-0"> style="max-height: 300px;">
<div class="form-check py-1"> <div class="row p-3 m-0">
<input class="form-check-input" type="checkbox" value="true" name="map" <div class="form-check py-1">
id="mapFilter"> <input class="form-check-input" type="checkbox" value="true" name="map"
<label class="form-check-label" for="mapFilter"> id="mapFilter">
{{ trans("visiosoft.module.advs::field.yes.name") }} <label class="form-check-label" for="mapFilter">
</label> {{ trans("visiosoft.module.advs::field.yes.name") }}
</label>
</div>
</div> </div>
</div> </div>
</div> </div>
</div> <!-- Map Filter End -->
<!-- Map Filter End -->
<!-- Price Filter Start --> <!-- Price Filter Start -->
<div class="card mb-3"> <div class="card mb-3">
<div class="card-header breadcrumb mb-0" id="priceHeading"> <div class="card-header breadcrumb mb-0" id="priceHeading">
<h5 class="mb-0"> <h5 class="mb-0">
<button class="btn btn-link text-dark" data-toggle="collapse" data-target="#price" <button class="btn btn-link text-dark" data-toggle="collapse" data-target="#price"
aria-expanded="true" aria-controls="price"> aria-expanded="true" aria-controls="price">
<i class="fas fa-money-bill"></i> <i class="fas fa-money-bill"></i>
{{ trans("visiosoft.module.advs::field.price.name") }} {{ trans("visiosoft.module.advs::field.price.name") }}
</button> </button>
</h5> </h5>
</div> </div>
<div id="price" class="collapse show overflow-auto" aria-labelledby="priceHeading" <div id="price" class="collapse show overflow-auto" aria-labelledby="priceHeading"
data-parent="#filter" data-parent="#filter"
style="max-height: 300px;"> style="max-height: 300px;">
<div class="row p-0 m-0"> <div class="row p-0 m-0">
{% set active_currencies = setting_value('visiosoft.module.advs::enabled_currencies') %} {% set active_currencies = setting_value('visiosoft.module.advs::enabled_currencies') %}
<div class="col-md-4 p-1 m-0"> <div class="col-md-4 p-1 m-0">
<input type="number" class="price-input form-control w-100" <input type="number" class="price-input form-control w-100"
value="{{ app.request.get('min_price') }}" value="{{ app.request.get('min_price') }}"
name="min_price" min="0" name="min_price" min="0"
placeholder="{{ trans('visiosoft.module.advs::field.min.name') }}"> placeholder="{{ trans('visiosoft.module.advs::field.min.name') }}">
</div> </div>
<div class="col-md-4 p-1 pr-0 m-0"> <div class="col-md-4 p-1 pr-0 m-0">
<input class="price-input form-control w-100" type="number" <input class="price-input form-control w-100" type="number"
value="{{ app.request.get('max_price') }}" value="{{ app.request.get('max_price') }}"
name="max_price" name="max_price"
placeholder="{{ trans('visiosoft.module.advs::field.max.name') }}"> placeholder="{{ trans('visiosoft.module.advs::field.max.name') }}">
</div>
<div class="col-md-4 py-1 px-0">
<select name="currency" id="currency" class="form-control">
{% for currency in active_currencies %}
<option {% if app.request.get('currency') == currency %}
selected
{% endif %}value="{{ currency }}">{{ currency }}</option>
{% endfor %}
</select>
</div>
</div> </div>
<div class="col-md-4 py-1 px-0">
<select name="currency" id="currency" class="form-control">
{% for currency in active_currencies %}
<option {% if app.request.get('currency') == currency %}
selected
{% endif %}value="{{ currency }}">{{ currency }}</option>
{% endfor %}
</select>
</div>
</div> </div>
</div> </div>
</div> <!-- Price Filter End -->
<!-- Price Filter End -->
<div class="card"> <div class="card">
<div class="card-header bg-primary text-center" id="submitHeading"> <div class="card-header bg-primary text-center" id="submitHeading">
<h5 class="mb-0"> <h5 class="mb-0">
<button class="btn btn-link text-white w-100"> <button class="btn btn-link text-white w-100">
<i class="fas fa-search"></i> <i class="fas fa-search"></i>
{{ trans("visiosoft.module.advs::field.search") }} {{ trans("visiosoft.module.advs::field.search") }}
</button> </button>
</h5> </h5>
</div>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</div> </form>
</form>

View File

@ -1,138 +1,138 @@
{ {
"name": "openclassify/openclassify", "name": "openclassify/openclassify",
"description": "OpenClassify is the extensible and most advanced open source classified app build with Laravel.", "description": "OpenClassify is the extensible and most advanced open source classified app build with Laravel.",
"type": "project", "type": "project",
"keywords": [ "keywords": [
"OpenClassify", "OpenClassify",
"classified", "classified",
"open Classify" "open Classify"
], ],
"license": "MIT", "license": "MIT",
"authors": [ "authors": [
{ {
"name": "Visiosoft, Inc.", "name": "Visiosoft, Inc.",
"email": "support@visiosoft.com.tr" "email": "support@visiosoft.com.tr"
}
],
"require": {
"wikimedia/composer-merge-plugin": "~1.4.0",
"anomaly/streams-composer-plugin": "~1.1.0",
"visiosoft/streams-platform": "^1.7",
"anomaly/default_authenticator-extension": "~2.1.0",
"anomaly/throttle_security_check-extension": "~2.1.0",
"anomaly/private_storage_adapter-extension": "~1.0.0",
"anomaly/default_page_handler-extension": "~2.1.0",
"anomaly/user_security_check-extension": "~2.1.0",
"anomaly/xml_feed_widget-extension": "~2.1.0",
"anomaly/page_link_type-extension": "~2.1.0",
"anomaly/url_link_type-extension": "~2.1.0",
"anomaly/relationship-field_type": "~2.2.0",
"anomaly/colorpicker-field_type": "~2.3.0",
"anomaly/polymorphic-field_type": "~2.1.0",
"anomaly/checkboxes-field_type": "~2.4.0",
"anomaly/encrypted-field_type": "~2.1.0",
"anomaly/datetime-field_type": "~3.0.0",
"anomaly/repeater-field_type": "~1.3.0",
"anomaly/language-field_type": "~2.2.0",
"anomaly/multiple-field_type": "~2.3.0",
"anomaly/textarea-field_type": "~2.1.0",
"anomaly/markdown-field_type": "~3.1.0",
"anomaly/wysiwyg-field_type": "~3.1.0",
"anomaly/boolean-field_type": "~2.3.0",
"anomaly/country-field_type": "~2.3.0",
"anomaly/decimal-field_type": "~2.1.0",
"anomaly/integer-field_type": "~2.1.0",
"anomaly/editor-field_type": "~3.1.0",
"anomaly/select-field_type": "~2.3.0",
"anomaly/slider-field_type": "~3.0.0",
"anomaly/addon-field_type": "~2.2.0",
"anomaly/email-field_type": "~2.1.0",
"anomaly/state-field_type": "~2.3.0",
"anomaly/files-field_type": "~2.3.0",
"anomaly/tags-field_type": "~2.4.0",
"anomaly/slug-field_type": "~2.1.0",
"anomaly/text-field_type": "~2.2.0",
"anomaly/file-field_type": "~2.2.0",
"anomaly/url-field_type": "~2.2.0",
"anomaly/configuration-module": "~2.1.0",
"anomaly/preferences-module": "~2.2.0",
"anomaly/navigation-module": "~2.4.0",
"anomaly/dashboard-module": "~2.2.0",
"anomaly/redirects-module": "~2.3.0",
"anomaly/variables-module": "~2.4.0",
"anomaly/settings-module": "~2.4.0",
"anomaly/addons-module": "~2.3.0",
"anomaly/blocks-module": "~1.3.0",
"anomaly/search-module": "~3.0.0",
"anomaly/system-module": "~1.0.0",
"anomaly/users-module": "~2.5.0",
"anomaly/pages-module": "~2.6.0",
"anomaly/posts-module": "~2.6.0",
"anomaly/files-module": "~2.6.0",
"anomaly/contact-plugin": "~1.2.0",
"anomaly/helper-plugin": "~2.1.0",
"anomaly/robots-extension": "~2.1.0",
"anomaly/sitemap-extension": "~2.2.0",
"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"
},
"replace" : {
"anomaly/streams-platform": "*"
},
"require-dev": {
"filp/whoops": "~2.0",
"phpunit/phpunit": "^7.0",
"fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*",
"symfony/css-selector": "3.1.*",
"symfony/dom-crawler": "3.1.*",
"anomaly/installer-module": "~2.3.0"
},
"repositories": [
{
"type": "composer",
"url": "https://packages.pyrocms.com"
},
{
"type": "composer",
"url": "https://community.pyrocms.com"
}
],
"autoload": {
"classmap": [
"database"
],
"psr-4": {
"App\\": "app/"
}
},
"autoload-dev": {
"classmap": [
"tests/TestCase.php"
]
},
"extra": {
"merge-plugin": {
"include": [
"addons/*/*/*/composer.json",
"core/*/*/composer.json"
],
"recurse": true,
"replace": false
},
"laravel": {
"dont-discover": [
"*"
]
}
},
"config": {
"bin-dir": "bin",
"preferred-install": "dist",
"optimize-autoloader": true
} }
],
"require": {
"wikimedia/composer-merge-plugin": "~1.4.0",
"anomaly/streams-composer-plugin": "~1.1.0",
"visiosoft/streams-platform": "^1.7",
"anomaly/default_authenticator-extension": "~2.1.0",
"anomaly/throttle_security_check-extension": "~2.1.0",
"anomaly/private_storage_adapter-extension": "~1.0.0",
"anomaly/default_page_handler-extension": "~2.1.0",
"anomaly/user_security_check-extension": "~2.1.0",
"anomaly/xml_feed_widget-extension": "~2.1.0",
"anomaly/page_link_type-extension": "~2.1.0",
"anomaly/url_link_type-extension": "~2.1.0",
"anomaly/relationship-field_type": "~2.2.0",
"anomaly/colorpicker-field_type": "~2.3.0",
"anomaly/polymorphic-field_type": "~2.1.0",
"anomaly/checkboxes-field_type": "~2.4.0",
"anomaly/encrypted-field_type": "~2.1.0",
"anomaly/datetime-field_type": "~3.0.0",
"anomaly/repeater-field_type": "~1.3.0",
"anomaly/language-field_type": "~2.2.0",
"anomaly/multiple-field_type": "~2.3.0",
"anomaly/textarea-field_type": "~2.1.0",
"anomaly/markdown-field_type": "~3.1.0",
"anomaly/wysiwyg-field_type": "~3.1.0",
"anomaly/boolean-field_type": "~2.3.0",
"anomaly/country-field_type": "~2.3.0",
"anomaly/decimal-field_type": "~2.1.0",
"anomaly/integer-field_type": "~2.1.0",
"anomaly/editor-field_type": "~3.1.0",
"anomaly/select-field_type": "~2.3.0",
"anomaly/slider-field_type": "~3.0.0",
"anomaly/addon-field_type": "~2.2.0",
"anomaly/email-field_type": "~2.1.0",
"anomaly/state-field_type": "~2.3.0",
"anomaly/files-field_type": "~2.3.0",
"anomaly/tags-field_type": "~2.4.0",
"anomaly/slug-field_type": "~2.1.0",
"anomaly/text-field_type": "~2.2.0",
"anomaly/file-field_type": "~2.2.0",
"anomaly/url-field_type": "~2.2.0",
"anomaly/configuration-module": "~2.1.0",
"anomaly/preferences-module": "~2.2.0",
"anomaly/navigation-module": "~2.4.0",
"anomaly/dashboard-module": "~2.2.0",
"anomaly/redirects-module": "~2.3.0",
"anomaly/variables-module": "~2.4.0",
"anomaly/settings-module": "~2.4.0",
"anomaly/addons-module": "~2.3.0",
"anomaly/blocks-module": "~1.3.0",
"anomaly/search-module": "~3.0.0",
"anomaly/system-module": "~1.0.0",
"anomaly/users-module": "~2.5.0",
"anomaly/pages-module": "~2.6.0",
"anomaly/posts-module": "~2.6.0",
"anomaly/files-module": "~2.6.0",
"anomaly/contact-plugin": "~1.2.0",
"anomaly/helper-plugin": "~2.1.0",
"anomaly/robots-extension": "~2.1.0",
"anomaly/sitemap-extension": "~2.2.0",
"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"
},
"replace": {
"anomaly/streams-platform": "*"
},
"require-dev": {
"filp/whoops": "~2.0",
"phpunit/phpunit": "^7.0",
"fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*",
"symfony/css-selector": "3.1.*",
"symfony/dom-crawler": "3.1.*",
"anomaly/installer-module": "~2.3.0"
},
"repositories": [
{
"type": "composer",
"url": "https://packages.pyrocms.com"
},
{
"type": "composer",
"url": "https://community.pyrocms.com"
}
],
"autoload": {
"classmap": [
"database"
],
"psr-4": {
"App\\": "app/"
}
},
"autoload-dev": {
"classmap": [
"tests/TestCase.php"
]
},
"extra": {
"merge-plugin": {
"include": [
"addons/*/*/*/composer.json",
"core/*/*/composer.json"
],
"recurse": true,
"replace": false
},
"laravel": {
"dont-discover": [
"*"
]
}
},
"config": {
"bin-dir": "bin",
"preferred-install": "dist",
"optimize-autoloader": true
}
} }