public
Fork of rails/rails
Description: Ruby on Rails
Homepage: http://rubyonrails.org
Clone URL: git://github.com/josh/rails.git

The rails Network Feed   feed

NZKoz commented on rails/rails about 3 hours ago
Comment in 5556db2:

I was just merging rick’s attachment_fu differences, it’s minor garbage enhancements but no huge deal, don’t overthink it guys :)

ptzn started watching rails about 7 hours ago
rails is at rails/rails
acook8103 commented on rails/rails about 7 hours ago
Comment in 1b4b1aa:

Textile Reference I followed said to do pre and code.
Let’s try just code so you can see the html. I also took out lt and gt.
<code>
form action="/inventory/requests/350903690" class="edit_request" id="edit_request_350903690" method="post">
input id="request_existing_line_item_attributes_51161156_equipment_type_id" name="requestexisting_line_item_attributes[equipment_type_id]" size="30" type="text" value="691081111" /
input id="request_existing_line_item_attributes___existing_equipment_line_item_attributes_860256615_equipment_id" name="request[existing_line_item_attributes[]]existing_equipment_line_item_attributes[equipment_id]" size="30" type="text" value="1029003634" /
/form
</code>

acook8103 commented on rails/rails about 7 hours ago
Comment in 1b4b1aa:

Generation of HTML element id and form field name are inconsistent after 2nd level of nesting.
<pre>
<code>
<% form_for([: inventory, @request]) do |f| >
<
line_item = @request.line_items.first >
<
f.fields_for "existing_line_item_attributes[]", line_item do |li| >
<
= li.text_field :equipment_type_id >
<
equipment_li = line_item.equipment_line_items.first >
<
li.fields_for "existing_equipment_line_item_attributes[]", equipment_li do |eli| >
<
= eli.text_field :equipment_id >
<
end >
<
end >
<
end %>
</code>
</pre>
Generates this:
<pre>
<code>
<form action="/inventory/requests/350903690" class="edit_request" id="edit_request_350903690" method="post">
<input id="request_existing_line_item_attributes_51161156_equipment_type_id" name="requestexisting_line_item_attributes[equipment_type_id]" size="30" type="text" value="691081111" />
<input id="request_existing_line_item_attributes___existing_equipment_line_item_attributes_860256615_equipment_id" name="request[existing_line_item_attributes[]]existing_equipment_line_item_attributes[equipment_id]" size="30" type="text" value="1029003634" />
</form>
</code>
</pre>
You notice that the in the 3rd level that the 2nd level ID is missing and that the "[]" are enclosed within the first field.
I was able to get the the above form to work as expected by removing the brackets and explicitly setting the id.Generation of HTML element id and form field name are inconsistent after 2nd level of nesting.
<pre>
<code>
<% form_for([:inventory, @request]) do |f| >
<
line_item = @request.line_items.first >
<
f.fields_for "existing_line_item_attributes", line_item, :index => line_item.id do |li| >
<
= li.text_field :equipment_type_id >
<
equipment_li = line_item.equipment_line_items.first >
<
li.fields_for "existing_equipment_line_item_attributes", equipment_li, :index => equipment_li.id do |eli| >
<
= eli.text_field :equipment_id >
<
end >
<
end >
<
end %>
</code>
</pre>
I perused the code, but am not familiar enough with things to spot anything.
Thanks for the original patch. Made my code less ugly.

zdennis commented on rails/rails about 8 hours ago
Comment in 2bf58aa:

I think this has broken how gems and plugins load. The commit before this does not show the problem. Basically, gems which are loaded by plugins and installed in vendor/gems/ no longer works. It worked prior to this commit.

mmonteleone started watching rails about 9 hours ago
rails is at rails/rails
djd commented on rails/rails about 10 hours ago
Comment on activesupport/lib/active_support/memoizable.rb L4 in 8603813:

What about using __query and __bang?

methodmissing committed to methodmissing/rails about 10 hours ago

ff21c478201d207ebe4e27118a820570afe33ded

Merge branch 'master' of git://github.com/rails/rails

dasch commented on rails/rails about 11 hours ago
Comment on activesupport/lib/active_support/inflector.rb L269 in 5556db2:

Needs a dot at the end.

dasch commented on rails/rails about 11 hours ago
Comment on activesupport/lib/active_support/inflector.rb L267 in 5556db2:

Should have read # Replace accented chars with their ASCII equivalents.

mjankowski committed to mjankowski/rails about 12 hours ago

4066de309aa41b54ddc775eb0fc757fb8a2faff9

Merge branch 'master' of git://github.com/rails/rails

mjankowski committed to mjankowski/rails about 12 hours ago

b901190c2b0c77ad2734205d6545e54d83000d86

Merge branch 'master' of git://github.com/rails/rails

mjankowski committed to mjankowski/rails about 12 hours ago

0dffaac972f7f25faef01b8087ad829b12f0e269

Merge branch 'master' of git://github.com/rails/rails

mjankowski committed to mjankowski/rails about 12 hours ago

62a8425eec3367c029b170080a4aa23121b939ab

Merge branch 'master' of git://github.com/rails/rails

mjankowski committed to mjankowski/rails about 12 hours ago

758e5a8d189f54e8017e010f90f6388acf314303

Merge branch 'master' of git://github.com/rails/rails

mjankowski committed to mjankowski/rails about 12 hours ago

a173a4306fd41c2b28cd55b9cd8cfc25f7f2864f

Merge branch 'master' of git://github.com/rails/rails

toldroyd started watching rails about 13 hours ago
rails is at rails/rails
marczal started watching rails about 13 hours ago
rails is at rails/rails
eschulte started watching rails about 14 hours ago
rails is at rails/rails
xaviershay commented on rails/rails about 14 hours ago
Comment in 5556db2:

oh fair point
<pre><code>
parameterized_string.downcase!
parameterized_string
</code></pre>

ripta commented on rails/rails about 14 hours ago

The comment has since been removed.

ripta commented on rails/rails about 14 hours ago
Comment in 5556db2:

Ah, man, I really wish I had a preview button.

ripta commented on rails/rails about 14 hours ago
Comment in 5556db2:

downcase! returns nil if the method doesn’t change the string.
<pre>
<code>
>> a = "hello"
=> "hello"
>> a.downcase
=> "hello"
>> a.downcase!
=> nil
</code>
</pre>
Nonetheless, it does create one less object every time.

xaviershay commented on rails/rails about 14 hours ago
Comment in 5556db2:

you know, if you’re really trying to get it down. downcase! returns the value, too:
&gt;&gt; &quot;A&quot;.downcase! =&gt; &quot;a&quot;

xaviershay commented on rails/rails about 14 hours ago
Comment in 5556db2:

<pre><code>
GC.disable
def count_string_objects_created
start = ObjectSpace.each_object(String) {}
yield
(ObjectSpace.each_object(String) {} – start).to_s
end
puts ’#downcase: ’ + count_string_objects_created {
a = "hello"
a.downcase
}
puts ’#downcase!: ’ + count_string_objects_created {
a = "hello"
a.downcase!
}
</code></pre>

NZKoz committed to rails/rails about 15 hours ago

aec391621b6af7af1e0ba61c993bbdd88624eac3

Make sure last_modified! works with <= rather than just equality.

NZKoz committed to rails/rails about 15 hours ago

5556db22c57294a9f4e2ee4e633834ec6a200242

Reduce memory usage slightly in String#parameterize

NZKoz committed to rails/rails about 15 hours ago

a4629e707d80a5769f7a71ca6ed9471015e14dc9

Extract transliteration code to a seperate method.

codyfauser committed to rails/rails about 17 hours ago

f2c10f27565318b5efbdc57fb608b2afe9ae445d

Add ActiveResource::Base#to_xml and ActiveResource::Base#to_json methods. [#1011 state:resolved]

akaspick committed to rails/rails about 20 hours ago

dce6ade4cdc2833b53bd600ef10f9bce83c7102d

Ensure select_tag#name attribute uses [] when :multiple is true. [#1146 state:resolved]