trusty-cms 7.0.0 → 7.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/app/assets/javascripts/admin/custom_file_upload.js +5 -5
- data/app/controllers/admin/assets_controller.rb +2 -2
- data/app/helpers/admin/references_helper.rb +3 -3
- data/app/views/admin/assets/new.html.haml +0 -1
- data/lib/trusty_cms/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 757c811a343c2e361cba40efbb19e65643d9685ec8e361dab2ed97c6876c1261
|
4
|
+
data.tar.gz: d6ac859204a5f6f92708ddf194666c52a5b4b536c0d22099cd072f52e9196f0e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ee0cd37d1046d1a9b657912619af9b831bba79dad31556db8b15158a5611280c74d33ee43bf0752ffa34538af0609e664f0542688ccb0177044f7a0d28392a47
|
7
|
+
data.tar.gz: 4e59b6c26564c3fda61dc9dea53ac8b4fd883f64520ab3595c9c7b77b5812128f0e061cd7711f613203e9c8323db1d14f2af9b8249cbb57bf6c666fb3e39c273
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
$(function () {
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
2
|
+
const fileUpload = $('#asset_asset');
|
3
|
+
const fileChosen = $('#file-chosen');
|
4
|
+
fileUpload.on('change', function () {
|
5
|
+
fileChosen.text(this.files[0].name)
|
6
|
+
})
|
7
7
|
});
|
@@ -35,7 +35,7 @@ class Admin::AssetsController < Admin::ResourceController
|
|
35
35
|
@assets = []
|
36
36
|
@page_attachments = []
|
37
37
|
compress = current_site.try(:compress).nil? ? true : current_site.compress
|
38
|
-
asset_params[:asset][:asset].
|
38
|
+
asset_params[:asset][:asset].reject(&:blank?).each do |uploaded_asset|
|
39
39
|
if uploaded_asset.content_type == 'application/octet-stream'
|
40
40
|
flash[:notice] = 'Please only upload assets that have a valid extension in the name.'
|
41
41
|
else
|
@@ -90,6 +90,6 @@ class Admin::AssetsController < Admin::ResourceController
|
|
90
90
|
end
|
91
91
|
|
92
92
|
def asset_params
|
93
|
-
params.permit(:id, :for_attachment, asset: [:
|
93
|
+
params.permit(:id, :for_attachment, asset: [:for_attachment, { asset: [] }])
|
94
94
|
end
|
95
95
|
end
|
@@ -5,7 +5,7 @@ module Admin::ReferencesHelper
|
|
5
5
|
String.new.tap do |output|
|
6
6
|
class_of_page.tag_descriptions.sort.each do |tag_name, description|
|
7
7
|
value = t("desc.#{tag_name.gsub(':', '-')}").match('desc') ? description : t("desc.#{tag_name.gsub(':', '-')}")
|
8
|
-
output << render(partial: 'admin/references/tag_reference
|
8
|
+
output << render(partial: 'admin/references/tag_reference',
|
9
9
|
locals: { tag_name: tag_name,
|
10
10
|
description: RedCloth.new(TrustyCms::Taggable::Util.strip_leading_whitespace(value)).to_html })
|
11
11
|
end
|
@@ -35,8 +35,8 @@ module Admin::ReferencesHelper
|
|
35
35
|
|
36
36
|
def filter
|
37
37
|
@filter ||= begin
|
38
|
-
|
39
|
-
|
38
|
+
TextFilter.find_descendant(params[:filter_name])
|
39
|
+
end
|
40
40
|
end
|
41
41
|
|
42
42
|
def class_of_page
|
@@ -8,7 +8,6 @@
|
|
8
8
|
|
9
9
|
- main.edit_form do
|
10
10
|
- form_for :asset, :url => admin_assets_path, :html => { :method => "post", :multipart => true } do |f|
|
11
|
-
= render :partial => "form", :locals => { :f => f }
|
12
11
|
%fieldset
|
13
12
|
%label.custom-file-upload
|
14
13
|
= t("clipped_extension.choose_file")
|
data/lib/trusty_cms/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: trusty-cms
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.0.
|
4
|
+
version: 7.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- TrustyCms CMS dev team
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-10-
|
11
|
+
date: 2024-10-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activestorage-validator
|