Skip to content

Conversation

@wakes
Copy link

@wakes wakes commented Sep 9, 2015

Added configuration settings:

FileAttachmentField:
  module_scripts_dir: 'javascript/'
  dropzone_script_file: 'javascript/dropzone.js'
  dropzone_config_file: 'javascript/default_config.json'

to specify where javascript and front-end config is loaded from more succinctly. If they start with a '/' then they will load relative to web root so you can place them outside the module.

Thanks for the awesome upload field!

wakes and others added 5 commits September 9, 2015 11:34
How do you do this properly? Composer should work it out apparently, never works for me though.
Again with the composer
@unclecheese
Copy link
Owner

Thanks, guys.

@shoaibali The Config API offers Before and After settings that allow you to specify with some precision when the file should load and what it should override. You can see in the dropzone config.yml file:

---
Name: dropzone
After: 'framework/*','cms/*'
---

It specifies to load after framework and cms. Because the snippet is also named, in your config, you can just specify After: ['#dropzone'].

@wakes In general, I have no objections to the changes. Because the module is most useful on the frontend, I think the ability to override the scripts is warranted.

Since I didn't see this until now (email issue wasn't sending me Github notifications), would you mind rebasing your changes? We'll aim to put this in a 1.2 release.

@shoaibali
Copy link

Thank you @unclecheese for the explanation :)

I forgot about the before/after functions in yaml file.

@unclecheese
Copy link
Owner

Would you be able to rebase this against the master so we can merge it in?

@wakes
Copy link
Author

wakes commented Jan 14, 2016

Hi unclecheese,

Yup, I'll do it this afternoon and submit pull request.

Cheers,

Steve Wake
Developer

DigitalHod Limited

E: wakes@digitalhod.net
P: 021 026 30019

On 15/1/2016, at 10:01, unclecheese notifications@github.com wrote:

Would you be able to rebase this against the master so we can merge it in?


Reply to this email directly or view it on GitHub #24 (comment).

@silbinarywolf
Copy link
Contributor

@wakes Bumping this from the past. Still able to rebase this to get it in?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants