mirror of
https://github.com/openclassify/openclassify.git
synced 2026-01-11 18:01:10 -06:00
Merge pull request #879 from openclassify/muammertop
ads image upload limit
This commit is contained in:
commit
0c470597bb
@ -22,7 +22,8 @@ return [
|
||||
'fields' => [
|
||||
'latest-limit',
|
||||
'popular_ads_limit',
|
||||
'default_view_type',
|
||||
'ads_image_limit',
|
||||
'default_view_type',
|
||||
'price_area_hidden',
|
||||
'hide_listing_standard_price',
|
||||
'hide_zero_price',
|
||||
|
||||
@ -362,4 +362,10 @@ return [
|
||||
"default_value" => '#00a651',
|
||||
]
|
||||
],
|
||||
'ads_image_limit' => [
|
||||
"type" => "anomaly.field_type.integer",
|
||||
"config" => [
|
||||
"default_value" => 25
|
||||
]
|
||||
]
|
||||
];
|
||||
|
||||
@ -16,6 +16,7 @@ $(function () {
|
||||
var dropzone = new Dropzone('.dropzone:not(data-initialized)',
|
||||
{
|
||||
paramName: 'upload',
|
||||
maxFiles: imageCount,
|
||||
resizeWidth: settings_image['resize_width'],
|
||||
resizeHeight: settings_image['resize_height'],
|
||||
autoProcessQueue: true,
|
||||
|
||||
@ -15,6 +15,11 @@
|
||||
|
||||
</div>
|
||||
<script>
|
||||
|
||||
var imageCount = {{ field_type.value|length < setting_value('visiosoft.module.advs::ads_image_limit')
|
||||
? setting_value('visiosoft.module.advs::ads_image_limit') - field_type.value|length
|
||||
: 0 }}
|
||||
|
||||
var settings_image = {
|
||||
'resize_width':"{{ setting_value('visiosoft.module.advs::full_image_width') }}",
|
||||
'resize_height':"{{ setting_value('visiosoft.module.advs::full_image_height') }}"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user