mirror of
https://github.com/openclassify/openclassify.git
synced 2026-01-11 18:01:10 -06:00
Merge pull request #374 from openclassify/vedat
currency && admin advs link
This commit is contained in:
commit
91c57efaec
@ -1,7 +1,7 @@
|
||||
<div class="slider-text">
|
||||
<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 offered-field offered-row">
|
||||
<h3 class="ad-price">
|
||||
<b>{{ adv.price.currency(null,'currency',false) }}</b>
|
||||
<b>{{ adv.price.currency(null,'currency') }}</b>
|
||||
<!-- priceField with Block -->
|
||||
{{ addBlock('ad-detail/priceField',{'adv':adv})|raw }}
|
||||
<!-- priceField with Block -->
|
||||
|
||||
@ -20,7 +20,7 @@
|
||||
<div class="col-md-3 text-left justify-content-center align-self-center">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<b>{{ adv.price.currency(null,'currency',false) }}</b>
|
||||
<b>{{ adv.price.currency(null,'currency') }}</b>
|
||||
</div>
|
||||
{% if setting_value('visiosoft.module.location::list_page_location') %}
|
||||
<div class="col-md-12 justify-content-center align-self-center text-truncate">
|
||||
|
||||
@ -36,7 +36,7 @@
|
||||
</div>
|
||||
</td>
|
||||
<td class="justify-content-center align-middle td-price">
|
||||
<b>{{ adv.price.currency(null,'currency',false) }}</b>
|
||||
<b>{{ adv.price.currency(null,'currency') }}</b>
|
||||
</td>
|
||||
<td class="justify-content-center align-middle td-date">
|
||||
<small>{{ adv.created_at|date("d/m/Y") }}</small>
|
||||
|
||||
@ -27,6 +27,7 @@ use Illuminate\Contracts\Events\Dispatcher;
|
||||
class AdvsController extends AdminController
|
||||
{
|
||||
private $model;
|
||||
|
||||
public function __construct(AdvModel $model)
|
||||
{
|
||||
$this->model = $model;
|
||||
@ -84,20 +85,16 @@ class AdvsController extends AdminController
|
||||
|
||||
$table->setColumns([
|
||||
'cover_photo' => [
|
||||
'wrapper' => function (EntryInterface $entry, Request $request) {
|
||||
if (strpos($entry->cover_photo, 'http') === 0) {
|
||||
$wrapper = '<img width="64" src="'.$entry->cover_photo.'">';
|
||||
} else if (is_null($entry->cover_photo)) {
|
||||
$wrapper = '<img width="64" src="{{ img(\'visiosoft.theme.base::images/no-image.png\').url }}">';
|
||||
} else {
|
||||
$wrapper = '<img width="64" src="'.$request->root().'/'.$entry->cover_photo.'">';
|
||||
}
|
||||
return $wrapper;
|
||||
'value' => function (EntryInterface $entry) {
|
||||
return "<img width='80px' src='" . $this->model->AddAdsDefaultCoverImage($entry)->cover_photo . "' >";
|
||||
},
|
||||
],
|
||||
'entry.id',
|
||||
'name' => [
|
||||
'class' => 'advs-name',
|
||||
'value' => function (EntryInterface $entry) {
|
||||
return "<a href='" . $this->model->getAdvDetailLinkByModel($entry, 'list') . "' > " . $entry->name . "</a > ";
|
||||
},
|
||||
],
|
||||
'price' => [
|
||||
'class' => 'advs-price',
|
||||
@ -154,11 +151,11 @@ class AdvsController extends AdminController
|
||||
'options' => $users,
|
||||
],
|
||||
'status' => [
|
||||
'filter' => 'select',
|
||||
'query' => StatusFilterQuery::class,
|
||||
'filter' => 'select',
|
||||
'query' => StatusFilterQuery::class,
|
||||
'options' => [
|
||||
'approved' => 'visiosoft.module.advs::field.status.option.approved',
|
||||
'expired' => 'visiosoft.module.advs::field.status.option.expired',
|
||||
'approved' => 'visiosoft.module.advs::field.status.option.approved',
|
||||
'expired' => 'visiosoft.module.advs::field.status.option.expired',
|
||||
'unpublished' => 'visiosoft.module.advs::field.status.option.unpublished',
|
||||
'pending_admin' => 'visiosoft.module.advs::field.status.option.pending_admin',
|
||||
'pending_user' => 'visiosoft.module.advs::field.status.option.pending_user',
|
||||
@ -221,7 +218,7 @@ class AdvsController extends AdminController
|
||||
{
|
||||
$directory = 'assets';
|
||||
$files->deleteDirectory($directory = $application->getAssetsPath($directory), true);
|
||||
echo "<div class=\"bar\"></div>" . "<br>";
|
||||
echo " < div class=\"bar\"></div>" . "<br>";
|
||||
echo "<style>
|
||||
.bar {
|
||||
width: 30%;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user