mirror of
https://github.com/openclassify/openclassify.git
synced 2026-01-11 18:01:10 -06:00
Merge branch 'master' of https://github.com/openclassify/openclassify into muammer
This commit is contained in:
commit
8405702412
@ -40,7 +40,7 @@ return [
|
||||
'ads_detail' => [
|
||||
'title' => 'visiosoft.module.advs::section.ads_detail',
|
||||
'fields' => [
|
||||
'ads_id_date_hidden',
|
||||
'ads_date_hidden',
|
||||
'hide_seller_info',
|
||||
]
|
||||
],
|
||||
|
||||
@ -384,7 +384,7 @@ return [
|
||||
'favicon' => [
|
||||
'type' => 'anomaly.field_type.file',
|
||||
],
|
||||
'ads_id_date_hidden' => [
|
||||
'ads_date_hidden' => [
|
||||
'type' => 'anomaly.field_type.boolean',
|
||||
'config' => [
|
||||
'default_value' => false,
|
||||
|
||||
@ -203,9 +203,9 @@ return [
|
||||
'name' => 'Show Ads Count',
|
||||
'instructions' => 'Show ads count on the left categories list',
|
||||
],
|
||||
'ads_id_date_hidden' => [
|
||||
'name' => 'Hide ID and Created Date',
|
||||
'instructions' => 'Hide ID and created date in ads detail page',
|
||||
'ads_date_hidden' => [
|
||||
'name' => 'Hide Created Date',
|
||||
'instructions' => 'Hide created date in ads detail page',
|
||||
],
|
||||
'hide_listing_header' => [
|
||||
'name' => 'Hide Listing Header',
|
||||
|
||||
@ -89,7 +89,6 @@
|
||||
|
||||
{{ addBlock('ads-list/row-bottom')|raw }}
|
||||
|
||||
{# <div class="category-tabs"></div>#}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -67,7 +67,7 @@ class AdvRepository extends EntryRepository implements AdvRepositoryInterface
|
||||
});
|
||||
}
|
||||
}
|
||||
if (!setting_value('visiosoft.module.location::hide_location_filter') and isset($param['country'])) {
|
||||
if (!setting_value('visiosoft.module.location::hide_location_filter')) {
|
||||
$country = !empty($param['country']) ? $param['country'] : setting_value('visiosoft.module.location::default_country');
|
||||
if ($country) {
|
||||
$query = $query->where('country_id', $country);
|
||||
|
||||
@ -489,9 +489,9 @@ class AdvsController extends PublicController
|
||||
$adv = $this->adv_repository->getListItemAdv($id);
|
||||
}
|
||||
|
||||
if ($adv && ((!$adv->expired() && $adv->getStatus() === 'approved') || $adv->created_by_id === \auth()->id())) {
|
||||
if ((auth()->user() and auth()->user()->hasRole('admin')) or ($adv && ((!$adv->expired() && $adv->getStatus() === 'approved') || $adv->created_by_id === \auth()->id()))) {
|
||||
// Check if created by exists
|
||||
if (!$adv->created_by) {
|
||||
if ((auth()->user() and !auth()->user()->hasRole('admin')) and !$adv->created_by) {
|
||||
$this->messages->error('visiosoft.module.advs::message.this_ad_is_not_valid_anymore');
|
||||
return $this->redirect->route('visiosoft.module.advs::list');
|
||||
}
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
<?php namespace Visiosoft\DefaultadminTheme\Listener;
|
||||
|
||||
use Anomaly\Streams\Platform\Entry\EntryModel;
|
||||
use Anomaly\Streams\Platform\Ui\Table\Component\Header\Header;
|
||||
use Illuminate\Support\Collection;
|
||||
use Anomaly\Streams\Platform\Ui\Table\Component\Filter\Type\SearchFilter;
|
||||
@ -53,7 +54,11 @@ class AddGsmFilter
|
||||
$builder->setColumns([
|
||||
'first_name',
|
||||
'last_name',
|
||||
'email',
|
||||
'email' => [
|
||||
'value' => function (EntryModel $entry) {
|
||||
return str_ends_with($entry->email, '@example.com') ? '' : $entry->email;
|
||||
}
|
||||
],
|
||||
'gsm_phone',
|
||||
'created_at' => [
|
||||
'value' => 'entry.created_at'
|
||||
|
||||
@ -18,9 +18,10 @@ class UsersController extends AdminController
|
||||
$term = request()->term;
|
||||
if ($term) {
|
||||
return $userRepository->newQuery()
|
||||
->select(DB::raw("CONCAT_WS('', first_name, ' ', last_name, ' (', gsm_phone, ' || ', email, ')') AS name"), 'id')
|
||||
->select(DB::raw("CONCAT_WS('', first_name, ' ', last_name, ' (', gsm_phone, ' || ', display_name, ' || ', email, ')') AS name"), 'id')
|
||||
->where('first_name', 'LIKE', "%$term%")
|
||||
->orWhere('last_name', 'LIKE', "%$term%")
|
||||
->orWhere('display_name', 'LIKE', "%$term%")
|
||||
->orWhere('gsm_phone', 'LIKE', "%$term%")
|
||||
->limit(setting_value('visiosoft.module.advs::user_filter_limit'))
|
||||
->pluck('name', 'id');
|
||||
|
||||
@ -68,6 +68,7 @@ class ProfileModuleServiceProvider extends AddonServiceProvider
|
||||
'profile/class/extendTime/{id},{type}' => 'Visiosoft\ProfileModule\Http\Controller\MyProfileController@extendAds',
|
||||
'profile/message/show/{id}' => 'Visiosoft\ProfileModule\Http\Controller\MyProfileController@showMessage',
|
||||
'profile/close-account' => [
|
||||
'middleware' => 'auth',
|
||||
'as' => 'visiosoft.module.profile::profile_close_account',
|
||||
'uses' => 'Visiosoft\ProfileModule\Http\Controller\MyProfileController@disableAccount'
|
||||
],
|
||||
|
||||
@ -9,12 +9,14 @@ SET time_zone = "+00:00";
|
||||
/*!40101 SET NAMES utf8mb4 */;
|
||||
|
||||
|
||||
INSERT INTO `default_settings_settings` (`id`, `sort_order`, `created_at`, `created_by_id`, `updated_at`, `updated_by_id`, `key`, `value`) VALUES
|
||||
(7, 7, '2019-07-15 06:48:46', 1, '2019-07-15 06:53:05', 1, 'streams::date_format', 'j F, Y'),
|
||||
(8, 8, '2019-07-15 06:48:46', 1, '2019-07-15 06:53:05', 1, 'streams::time_format', 'H:i'),
|
||||
(11, 11, '2019-07-15 06:48:46', 1, '2019-07-15 06:53:05', 1, 'streams::standard_theme', 'visiosoft.theme.base'),
|
||||
(12, 12, '2019-07-15 06:48:46', 1, '2019-07-15 06:53:05', 1, 'streams::admin_theme', 'visiosoft.theme.defaultadmin'),
|
||||
(15, 15, '2019-07-15 06:48:46', 1, '2019-07-15 06:53:05', 1, 'streams::enabled_locales', 'a:11:{i:0;s:2:\"en\";i:1;s:2:\"fa\";i:2;s:2:\"ar\";i:3;s:2:\"el\";i:4;s:2:\"es\";i:5;s:2:\"fr\";i:6;s:2:\"it\";i:7;s:2:\"nl\";i:8;s:2:\"pt\";i:9;s:2:\"ru\";i:10;s:2:\"tr\";}');
|
||||
INSERT INTO `default_settings_settings` (`created_at`,`key`, `value`) VALUES
|
||||
('2019-07-15 06:48:46', 'streams::date_format', 'j F, Y'),
|
||||
('2019-07-15 06:48:46', 'streams::time_format', 'H:i'),
|
||||
('2019-07-15 06:48:46', 'streams::name', 'PHP Classifieds software'),
|
||||
('2019-07-15 06:48:46', 'streams::description', 'OpenClassify is modular and most advanced open source classified platform build with Laravel.Use it in real estate classifieds, auto, e-commerce and other ...'),
|
||||
('2019-07-15 06:48:46', 'streams::standard_theme', 'visiosoft.theme.base'),
|
||||
('2019-07-15 06:48:46', 'streams::admin_theme', 'visiosoft.theme.defaultadmin'),
|
||||
('2019-07-15 06:48:46', 'streams::enabled_locales', 'a:11:{i:0;s:2:\"en\";i:1;s:2:\"fa\";i:2;s:2:\"ar\";i:3;s:2:\"el\";i:4;s:2:\"es\";i:5;s:2:\"fr\";i:6;s:2:\"it\";i:7;s:2:\"nl\";i:8;s:2:\"pt\";i:9;s:2:\"ru\";i:10;s:2:\"tr\";}');
|
||||
COMMIT;
|
||||
|
||||
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user