No change.  My function is still unavailable.  Here's me adding to the 
permissions functions and attr_accessible.

class Blacklist < ActiveRecord::Base

  hobo_model # Don't put anything above this

  fields do
    identifier :string
    timestamps
  end
  attr_accessible :identifier, :bulk_add_list

...

  def bulk_add_permitted?
    true
  end

end


On Sunday, January 6, 2013 6:13:37 AM UTC-8, Bryan Larsen wrote:
>
> I forgot to mention that you'll have to add the new field to both your 
> permission functions and your attr_accessible. 
>
> cheers, 
> Bryan 
>
>
> On Sat, Jan 5, 2013 at 11:39 PM, Dan Lamet <[email protected]<javascript:>> 
> wrote: 
> > It looks like this code is supposed to go in the application.dryml. 
>  With 
> > some massaging, it does recognize it. 
> > 
> > <extend tag="form" for="Blacklist"> 
> >    <field-list: fields="identifier, bulk_add"> 
> >       <batch-entries-view:> 
> >         <textarea name="&bulk_add_list" value=""/> 
> >       </batch-entries-view:> 
> >    </field-list:> 
> > </extend> 
> > 
> > I added an empty method in my blacklist.rb model called bulk_add.  This 
> > seems to invoke in the "New Blacklist" page.  (Is there any reason I 
> should 
> > have expected that?)  And there is a label that reads, "Bulk add (Not 
> > Available)".  Was there possibly something really obvious that I might 
> have 
> > missed?  (read newbie here) 
> > 
> > Thanks again, 
> > 
> > Dan 
> > 
> > On Saturday, January 5, 2013 12:12:45 PM UTC-8, Dan Lamet wrote: 
> >> 
> >> Bryan: 
> >> 
> >> The "def batch_entries=" you suggest looks like what I want to do.  Can 
> >> you tell me where the DRMYL you wrote would go? 
> >> 
> >> Thanks, 
> >> 
> >> Dan 
> >> 
> >> On Friday, January 4, 2013 9:47:28 PM UTC-8, Bryan Larsen wrote: 
> >>> 
> >>> The standard way of adding a bunch of entries at once in Hobo is via 
> >>> the input-many tag. 
> >>> 
> >>> But that doesn't sound like what you want, since you want to use a 
> >>> textarea.   It may not be the best way, but how I'd probably do it 
> >>> would be through a virtual attribute on your model.   if you have a 
> >>> BlackList that has_many :entries, you could do a "def batch_entries=" 
> >>> in your model that processes the textarea. 
> >>> then: 
> >>> 
> >>> <extend form for="BlackList"> 
> >>>    <field-list: fields="foo, bar, batch_entries"> 
> >>>       <batch-entries-view:> 
> >>>         <textarea name="&param_name_for_this" value=""/> 
> >>> 
> >>> Bryan 
> >>> 
> >>> On Fri, Jan 4, 2013 at 10:38 AM, Dan Lamet <[email protected]> wrote: 
> >>> > I'm a RoR/ActiveScaffold veteran.  I'm new to Hobo, however.  I've 
> just 
> >>> > gone 
> >>> > through the two-minute and Agility tutorials, and I've read through 
> >>> > some of 
> >>> > the other chapters, but I can't seem to figure out how to hook into 
> the 
> >>> > GUI 
> >>> > properly. 
> >>> > 
> >>> > I have an app for which I'm keeping a black list.  I'd like to 
> retain 
> >>> > the 
> >>> > default Hobo ability to create a single record one at a time.  But I 
> >>> > also 
> >>> > want to create a new page with a text area where I could paste 
> dozens 
> >>> > of 
> >>> > lines of new black list entries for a batch add.  I have the page 
> built 
> >>> > via 
> >>> > an old style RoR action, but can't figure out how to create link on 
> the 
> >>> > Hobo 
> >>> > page.  I'd also be happy to inline the new functionality via Ajax. 
>  Any 
> >>> > suggestions are welcomed. 
> >>> > 
> >>> > Thanks, Dan 
> >>> > 
> >>> > -- 
> >>> > You received this message because you are subscribed to the Google 
> >>> > Groups 
> >>> > "Hobo Users" group. 
> >>> > To view this discussion on the web visit 
> >>> > https://groups.google.com/d/msg/hobousers/-/3pbCigKiPCkJ. 
> >>> > To post to this group, send email to [email protected]. 
> >>> > To unsubscribe from this group, send email to 
> >>> > [email protected]. 
> >>> > For more options, visit this group at 
> >>> > http://groups.google.com/group/hobousers?hl=en. 
> > 
> > -- 
> > You received this message because you are subscribed to the Google 
> Groups 
> > "Hobo Users" group. 
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msg/hobousers/-/wQOk6bV2Ng0J. 
> > 
> > To post to this group, send email to [email protected]<javascript:>. 
>
> > To unsubscribe from this group, send email to 
> > [email protected] <javascript:>. 
> > For more options, visit this group at 
> > http://groups.google.com/group/hobousers?hl=en. 
>

-- 
You received this message because you are subscribed to the Google Groups "Hobo 
Users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/hobousers/-/8GPdspc7bxgJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/hobousers?hl=en.

Reply via email to