similar to: formtastic / activeadmin

Displaying 20 results from an estimated 1000 matches similar to: "formtastic / activeadmin"

2009 Aug 07
2
paperclip model fails while when updating with no attachment
Hi all, I have paperclip running in my rails environment. I setup a new model just for paperclip called Assets so that I could upload multiple files per item (even though I''m only using 1 attachment per item at the moment). Everything works except for the following: Updating an item record with no attachment in the form but having PREVIOUSLY attached an asset while creating or updating.
2011 Feb 21
1
Multiple custom CSS for Formtastic
Inside stylesheets I have formtastic.css and formtastic_changes.css. In formtastic_changes.css I have a custom with: form.formtastic { width: 700px; etc.. It is working ok but now in only one page only, need a narrower form, say 530. So I need to have two width set up. What is the best way to do this? I mean I do not want to change the other forms in the project, I just want to change the
2012 Oct 16
0
How to avoid an attribute without passing it to post in formtastic
I am developing rails application. I have a check box in the form like: <td><%= b.check_box :chkbx, label: false, checked: false %></td> While submitting the form. I need to avoid passing checkbox name argument in the post. How to avoid checkbox attribute from passing it to post in formtastic? -- Posted via http://www.ruby-forum.com/. -- You received this message because
2012 Sep 22
1
formtastic does not save at all
Rails 3.1.3 I am using Formtastic gem in order to deal with multi-select dependencies. <%= semantic_form_for(@give) do |f| %> <%= f.inputs do %> <%= f.input :departure, :collection => Departure.find(:all, :order=>:city).collect{ |c| [c.city,c.id]}, :required=>true %> <div id="destinationCity"> <%= render :partial =>
2012 Oct 31
2
What is Formtastic and SimpleForm gem ? Is any one of this is by default included in Rails ?
Hi all, I read Formtastic and SimpleForm gem. I am using 3.4 Q 1 Is any one of this is by default included in Rails ? Q2 Any advantage of this gems over simple form tags ? As per my knowledge we are using form helper , but still i raised the qustion ? Thanks Regards Fahim Babar Patel -- You received this message because you are subscribed to the Google Groups "Ruby
2006 Mar 29
1
Posting multiple files - how to set up params correctly
All, I have a page where I am allowing the user to specify multiple image files that are related to one HTML document. I want to end up with an array of image files that I can then assign into an array within the controller. I''m trying to set up my file_field correctly but am having trouble. I''m not clear on how "the multiple input tags with the same name turning into
2009 Oct 20
5
Annoying problem with file_field and paperclip
Hi all, I have a really really annoying problem that''s driving me nuts with file_field and paperclip and having to upload images everytime a form is edited even though the user is quite happy with the currently uploaded image or loose the previously uploaded image. This seems to be caused by the rails file_field helper not storing the data that has been read in from the db in the same
2004 Aug 18
1
Not a User Yet - but have some questions
I've been tasked with fitting out an appartment building with a phone system. The entire appartment is getting broadband, with Cat6 Cables into each appartment and fibre down the trunk. I was hoping to have PSTN in the basement connecting to the IP system. Today I found out however that one of the services will be paid TV - and it will need a PSTN backchannel - ie a modem. The set top
2006 Apr 05
6
How to Upload Image through RoR??
Hi, I have one form , in which I am using file_field teg for input image file as follows. ===== <%= file_field("store", "picture") %> ======= Tha Actual fileld name of my Image field in Database is "store_photo" with datatype LargeBLOB. & Inside my Store Model I have specified "def picture" as follows:- ========================= def
2006 Jan 22
1
file_field questions
A couple questions about file_field elements. First, with code such as this: <%= file_field ''attachments'', ''filename'' %> Would the filename of the file I select be the value that''s stored within the database under the "filename" column, and then I would just add in code in my "create" controller to upload the actual file?
2006 Jan 15
4
file_field vs. file_field_tag
Hi, The documentation doesn''t make it clear why both file_field and file_field_tag are both useful. What is the reason for having two instead of just one of these? Thanks, Peter
2007 Sep 30
2
Outputing to the browser, how?
Hello, I''m writting some helper methods to write forms, so I have this working code: class TableFormBuilder < ActionView::Helpers::FormBuilder ["file_field", "password_field", "text_field"].each do |name| define_method(name) do |label, *args| @template.content_tag(:tr, @template.content_tag(:td, @template.content_tag(:label,
2008 Jul 14
1
about string error for upload file in rails 2.1
hello: I have code for upload image file to server file system.This works in rails 1.2.3.But in rails 2.1,it gets an error. The following is the important code: In a view: <%form_for :user,:url=>{:action=>"register"},:html=>{:multipart=>true} do |f|-%> <p> <label>照片</label> <%=f.file_field "file"-%> </p>
2006 Feb 05
0
validating presence of file uploads
not sure whats going on here, but I''m using some pretty standard code to manage file uploads in to a db, but having trouble detecting if the file upload field has been filled or not. in my Asset Model, I have: def asset=(asset_field) self.name = base_part_of(asset_field.original_filename) self.content_type = asset_field.content_type.chomp self.data = asset_field.read end def
2006 Jul 26
5
code for uploading files to the filesystem instead of db
Does anyone have any standard code for uploading files to the filesystem? I''ve got code already for uploading images to the database but I''d prefer to store the files on the filesystem. In particular I need to know how to (a) ensure a file has been selected in the file_field (b) how to extract the filename from the file_field (c) how to actually move the file from client to
2012 Jan 29
0
ActiveAdmin: Nested attributes not working for STI
HI All, I am having Model "Customer" using STI for sender and receiver, and i am unable to save the both sender and receiver by nested attribute. Below are my model and active admin resource codes, correct me if i am wrong nested attribute on concept. CUSTOMER MODEL: class Customer < ActiveRecord::Base belongs_to :sender, :class_name => "Customer" has_many
2011 Aug 07
2
PROBLEM WITH PAPERCLIP
hello, i am trying to upload a image file ...using paperclip in rails 3 i did as follows 1. In gemfile => included gem paperclip 2.In config/environments /development.rb => Paperclip.options[:command_path] = "/usr/bin/" (convert path) 3.created a controller *picusers *and defined => def create @picuser = Picuser.create(params[:picuser]) end 4.created a model *picuser
2013 May 02
0
nested forms in activeadmin is mass assigning
Here is my question<http://stackoverflow.com/questions/16325137/yet-another-cant-mass-assign-protected-attributes-address-post> . -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to
2012 Sep 08
4
dash symbol
In the example below, what is the dash doing between the class attribute and array: (field_helpers - [:label, :check_box, :radio_button, :fields_for, :hidden_field, :file_field]).each do |selector| -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to
2010 Jan 16
3
Formtastic and Access to Variables of Nested Model
So I''m not even sure if I''ll be able to properly explain what I''m trying to do, but I''ll do my best. Let''s say that I have two models: Document and Option. A Document has many Options (and, by extension, an Option belongs to a Document). Each document may have a different number of options, hence why I made it a separate model. Each document has the