Custom Popup Dialogue Box (ability to choose sets)

Permalink
I would like to be able to Choose a set without having to use a select box and choose from 300 and growing sets.

Can anyone help point me in the right Direction, or how to call a custom dialogue window that I can then populate with the set choose/search funtion found on the side of the file manager.

Ideally I would like to be able to have a Set Dialogue like the file/images/users dialogue windows.

Can anyone point me in the right direction?

Thanks Sean

TheRealSean
 
ScottC replied on at Permalink Reply
ScottC
jeez, I'd think you'd want to get a huge dropdown of all your sets and then run a liveQuery(updating as you type) sort of filter that narrows down a selectbox, or a list of check boxes(depends if you only need one or multiple).
TheRealSean replied on at Permalink Reply
TheRealSean
Thanks for your reply Scott,

I have managed to get the instant search from the file manager working, but the problem I am finding is I am embedding the form within a form, thus if I type, it filters my results, but then the form has been submitted via ajax and of course wont allow me to submit the wrapping form.

Not to mention forms are not allowed within forms, something I did not realise I had done until inspecting the page elements, but if you could point me to an alternative method for running that live query on a div rather then form, whilst it is embedded within another form.

Then I could use that to filter them down.
TheRealSean replied on at Permalink Reply
TheRealSean
Update: So I did manage to get the Display within a pop up box but don't know enough to load up the box and then pass the selected value out of the dialogue box.

If anyone else could help, but Ill post what I have now it may help someone.

I used the code from here but tweaked it as my input is already within a form
http://kilianvalkhof.com/2010/javascript/how-to-build-a-fast-simple...
<?php 
//im using this within a package
$th = Loader::helper('concrete/urls'); 
$get_files_url= $th->getToolsURL('files/search_form_sets_custom','package');
?>
<?php 
//but if you want to load as an element
Loader::element('files/search_form_sets_custom', array('searchInstance' => $searchInstance, 'searchRequest' => $searchRequest));
//I dont think the search request is needed, its part of the core file, I think from a saved filter?
?>
//This is from the search_form_sets_custom
//This displays the actual file set and search box
<?php 
$s1 = FileSet::getMySets();
$form = Loader::helper('form');


This is not the cleanest code and if anyone would like to do so please do and then share the results.

Thanks,
ps I would still like to get this to work within a dialogue
I was using this
<script>
function openSetManager() {
   $.fn.dialog.open({
      width: '50%',
      height: '50%',
      modal: false,
      href: SG_GET_FILES_URL,
      title: 'Set Selector',
      onClose: function () {
      }
   });
}</script>
TheRealSean replied on at Permalink Reply
TheRealSean
I have an adjusted version of the set selector found in the file manager working now. This makes it easier to select sets but I would still like to be able to move this to a pop up box within a dialogue model

I can then move it to a page attribute. Similar to the multiple file attribute, but I would like to store (multiple) set(s) against the page.

Has no one done anything like this? before Or can someone point me to a good tutorial about using the dialogue/pop up windows so I can attempt to create my own version.
adavis replied on at Permalink Reply
adavis
Have you had any response to your post re: assistance finding a good tutorial for this? I feel like documentation is really lacking when trying to develop anything beyond the basics =/
TheRealSean replied on at Permalink Reply
TheRealSean
No sorry, and I have not really looked into it further, I have played with the dialogue window but nothing that ever seems to work.

It always seems that I can create something easier with a jQuery dialogue window.

I would like to be able to do this though it would it much easier for creating galleries