Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Table-Plus with Select Option
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  15 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
jhstephenson  
View profile  
 More options May 1 2012, 12:22 pm
From: jhstephenson <jstep...@scc-i.com>
Date: Tue, 1 May 2012 09:22:30 -0700 (PDT)
Local: Tues, May 1 2012 12:22 pm
Subject: Table-Plus with Select Option

In another development tool I use, when I have a selection list that
exceeds 20 or 30 items I usually create a button on the data entry form
that takes me to a screen similar in form to Hobo's Index page. From there
I can search for the record I am looking for and then click a button or
link to select the record I want. The ID of the selected record is returned
to the calling form and the link to the child is established.

It looks to me like that should be possible with something like a
Table-Plus based form, but I have no clue how to set that up.

Can someone point me to an example of how something like this might be done?

Thanks,
Jim


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
kevinpfromnm  
View profile  
 More options May 1 2012, 2:45 pm
From: kevinpfromnm <kevinpfro...@gmail.com>
Date: Tue, 1 May 2012 11:45:06 -0700 (PDT)
Local: Tues, May 1 2012 2:45 pm
Subject: Re: Table-Plus with Select Option

You're talking about a form input that instead of a plain select, you can
filter by name.  You're probably looking for the <name-one /> tag.  You'll
need to setup an autocompleter to go along with it.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jhstephenson  
View profile  
 More options May 1 2012, 4:17 pm
From: jhstephenson <jstep...@scc-i.com>
Date: Tue, 1 May 2012 13:17:31 -0700 (PDT)
Local: Tues, May 1 2012 4:17 pm
Subject: Re: Table-Plus with Select Option

What I am looking for is something like this:

I have am creating a new part purchased for a customer. It has the
following fields:

Name (part description):
Date:
Customer:
Quantity:
etc....

When I get to the customer field, right now it is a drop down box listing
all of my customers (or at least as many as are allowed to be displayed). I
actually have over 200 possible customers to chose from, which I believe is
too many for a drop down box, even if it was allowed.

I am not sure if this can be accomplished by what you are describing or not.

What I would like is the following:

Name (part description):
Date:
Customer: _______________ |Select| (Button or Link)
Quantity:
etc....

When the Select button is clicked I want to bring up a Table view with the
folllowing on it:

Search ____________________________

Customer                     Address                       Contact

ABC Customer              Any Address                 Some Contact    
|Select| (Button or Link)
.                                                                                                
|Select| (Button or Link)
.                                                                                                
|Select| (Button or Link)
.                                                                                                
|Select| (Button or Link)
XYZ Customer               Their Address               Their Contact      
|Select| (Button or Link)

When selected it would return the Customer ID just like it had been chosen
from a Drop down list.

I am not sure if that is what you are describing or not.

Does that make sense?

Jim


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
kevinpfromnm  
View profile  
 More options May 1 2012, 4:48 pm
From: kevinpfromnm <kevinpfro...@gmail.com>
Date: Tue, 1 May 2012 13:48:51 -0700 (PDT)
Local: Tues, May 1 2012 4:48 pm
Subject: Re: Table-Plus with Select Option

You're not going to get something like that out of the box.  Something like
a lightbox or other modal dialog to hold the table.  The table will need to
be ajax updated based on filters.  Then you'll need a custom javascript to
pass the selection back to the form.

Otherwise you'd need to store/pass along the form information for a
standard page load somehow, then repopulate the form when you get back.

Seriously though, give the name-one a try.  It's probably 80-90% towards
what you're after functionality wise.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jhstephenson  
View profile  
 More options May 2 2012, 6:31 pm
From: jhstephenson <jstep...@scc-i.com>
Date: Wed, 2 May 2012 15:31:51 -0700 (PDT)
Local: Wed, May 2 2012 6:31 pm
Subject: Re: Table-Plus with Select Option

I  think I must be missing something on how name-one works.

Below is what I have from my application.dryml for my product form:

<extend tag="form" for="Product">
    <old-form merge>
        <field-list: fields="category, customer, department, vendor, name,
serial_number, date_ordered, date_received, date_invoiced,
        vendor_invoice, scc_invoice, quantity, dollar_amount,
warranty_years, warranty_days, item, comments">

            <name-label:>Part Description</name-label:>

            <category-tag:><name-one/></category-tag:>
            <customer-tag:><name-one/></customer-tag:>
            <vendor-tag:><name-one/></vendor-tag:>

        </field-list:>
    </old-form>
</extend>

When I run it, I don't get anything different. I must have missed something
on how to use name-one.

Jim


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
kevinpfromnm  
View profile  
 More options May 2 2012, 6:42 pm
From: kevinpfromnm <kevinpfro...@gmail.com>
Date: Wed, 2 May 2012 15:42:52 -0700 (PDT)
Local: Wed, May 2 2012 6:42 pm
Subject: Re: Table-Plus with Select Option

The parameter is field-name-view: not -tag.  I usually put in some plain
text before adding a tag just to make sure I got the parameter right.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jhstephenson  
View profile  
 More options May 2 2012, 6:46 pm
From: jhstephenson <jstep...@scc-i.com>
Date: Wed, 2 May 2012 15:46:52 -0700 (PDT)
Local: Wed, May 2 2012 6:46 pm
Subject: Re: Table-Plus with Select Option

I must really be missing something because all that does is bring up an
edit field. There is no link to the table at all.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ignacio Huerta  
View profile  
 More options May 3 2012, 10:13 am
From: Ignacio Huerta <igna...@ihuerta.net>
Date: Thu, 03 May 2012 16:13:10 +0200
Local: Thurs, May 3 2012 10:13 am
Subject: Re: [Hobo Users] Re: Table-Plus with Select Option
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

It looks like an "edit field", because name-one is indeed an input
field where you can type. The trick is: you start typing the name of a
client, and then you are given a list to select from, just like when
you are start typing in Google and Google suggests some possible words.

If it doesn't work you can monitor the Ajax calls in several ways. For
example, you can look at the log or use Firebug's network tab.

Regards,
Ignacio

El 03/05/12 00:46, jhstephenson escribi :

- --
Ignacio Huerta Arteche
http://www.ihuerta.net
Tel fono: 0034 645 70 77 35
Email realizado con software libre
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk+iknYACgkQBPlUJ6RHaOQpIACfYISIdMZlsBCe6aeC2sf1WBo7
DmEAoNBAphAG2VlXq/1U69DfDeb3fKkY
=F8to
-----END PGP SIGNATURE-----


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jhstephenson  
View profile  
 More options May 3 2012, 9:22 pm
From: jhstephenson <jstep...@scc-i.com>
Date: Thu, 3 May 2012 18:22:08 -0700 (PDT)
Local: Thurs, May 3 2012 9:22 pm
Subject: Re: Table-Plus with Select Option

Ok. Here is what the log shows when I try do it on just my Category field:

Started GET "/categories/complete_name?query=Computer" for 127.0.0.1 at
2012-05-03 19:18:24 -0600
   [1m [36mSQL (2.0ms) [0m   [1mSHOW TABLES [0m
   [1m [35mSQL (1.0ms) [0m  SHOW TABLES
   [1m [36mSQL (2.0ms) [0m   [1mSHOW TABLES [0m
   [1m [35mSQL (1.0ms) [0m  SHOW TABLES
   [1m [36mSQL (1.0ms) [0m   [1mSHOW TABLES [0m
   [1m [35mSQL (2.0ms) [0m  SHOW TABLES
   [1m [36mSQL (2.0ms) [0m   [1mSHOW TABLES [0m
  Processing by CategoriesController#show as JS
  Parameters: {"query"=>"Computer", "id"=>"complete_name"}
   [1m [35mSQL (1.0ms) [0m  SELECT COUNT(*) AS count_id FROM `users`
   [1m [36mUser Load (1.0ms) [0m   [1mSELECT `users`.* FROM `users` WHERE
(`users`.`id` = 1) LIMIT 1 [0m
   [1m [35mCategory Load (0.0ms) [0m  SELECT `categories`.* FROM
`categories` WHERE (`categories`.`id` = 0) LIMIT 1
Completed   in 20ms

ActiveRecord::RecordNotFound (Couldn't find Category with ID=complete_name):

Rendered
C:/Ruby193/lib/ruby/gems/1.9.1/gems/actionpack-3.0.1/lib/action_dispatch/mi ddleware/templates/rescues/_trace.erb
(1.0ms)
Rendered
C:/Ruby193/lib/ruby/gems/1.9.1/gems/actionpack-3.0.1/lib/action_dispatch/mi ddleware/templates/rescues/_request_and_response.erb
(3.0ms)
Rendered
C:/Ruby193/lib/ruby/gems/1.9.1/gems/actionpack-3.0.1/lib/action_dispatch/mi ddleware/templates/rescues/diagnostics.erb
within rescues/layout (16.0ms)

I assume the key entry here is the one indicating that ActiveRecord could
not fine the Category with ID=complete_name.
Should there be a method in the Category controller called complete_name?

Jim


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Matt Jones  
View profile  
 More options May 4 2012, 7:56 am
From: Matt Jones <al2o...@gmail.com>
Date: Fri, 4 May 2012 07:56:46 -0400
Local: Fri, May 4 2012 7:56 am
Subject: Re: [Hobo Users] Re: Table-Plus with Select Option

On May 3, 2012, at 9:22 PM, jhstephenson wrote:

Yep. The quickest way to get one is with the autocomplete method:

http://cookbook.hobocentral.net/manual/controllers#autocompleters

--Matt Jones


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jhstephenson  
View profile  
 More options May 4 2012, 3:23 pm
From: jhstephenson <jstep...@scc-i.com>
Date: Fri, 4 May 2012 12:23:30 -0700 (PDT)
Local: Fri, May 4 2012 3:23 pm
Subject: Re: [Hobo Users] Re: Table-Plus with Select Option

Thanks,

That will give me what I want. On thing I notice is that the search result
brings up anything found with the matching characters, not just something
that starts with what I type. I actually like that better than what I
planned, but if I wanted to limit it to just the starting characters of a
name field, is there a way to filter it that way?

Jim


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
kevinpfromnm  
View profile  
 More options May 4 2012, 4:30 pm
From: kevinpfromnm <kevinpfro...@gmail.com>
Date: Fri, 4 May 2012 13:30:31 -0700 (PDT)
Local: Fri, May 4 2012 4:30 pm
Subject: Re: [Hobo Users] Re: Table-Plus with Select Option

The autocompleter provides a default finder which you could override to
only return results starting with your match.  You might want to do that
for performance reasons as matching text anywhere in a string is much more
expensive than matching the beginning (of an indexed column).


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
kevinpfromnm  
View profile  
 More options May 4 2012, 4:33 pm
From: kevinpfromnm <kevinpfro...@gmail.com>
Date: Fri, 4 May 2012 13:33:21 -0700 (PDT)
Local: Fri, May 4 2012 4:33 pm
Subject: Re: [Hobo Users] Re: Table-Plus with Select Option

Oh, there's a parameter in autocompleter to specify a different query_scope
from default now (as opposed to using a finder).


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jhstephenson  
View profile  
 More options May 4 2012, 5:47 pm
From: jhstephenson <jstep...@scc-i.com>
Date: Fri, 4 May 2012 14:47:21 -0700 (PDT)
Local: Fri, May 4 2012 5:47 pm
Subject: Re: [Hobo Users] Re: Table-Plus with Select Option

Thanks,

I just have to learn more about scopes now. I wish there were more examples
for things like this.

Jim


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
kevinpfromnm  
View profile  
 More options May 4 2012, 10:05 pm
From: kevinpfromnm <kevinpfro...@gmail.com>
Date: Fri, 4 May 2012 19:05:46 -0700 (PDT)
Local: Fri, May 4 2012 10:05 pm
Subject: Re: [Hobo Users] Re: Table-Plus with Select Option

Scopes are a rails thing so there's more than just hobo's docs.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »