Displaying 20 results from an estimated 800 matches similar to: "Rails, respond_to? over anonymous module (extend has_many)."
2011 Nov 24
5
ActiveRecord::AssociationTypeMismatch
Hi to all,
I have this error and I don''t understand why. I have three model,
Image and Playlist and PlaylistItem. Everything works fine. The app
should work also a XML REST service. When I made this call I obtain
this XML because the playlist don''t contains images:
GET http://0.0.0.0:3000/playlists/7.xml
<playlist>
<id>7</id>
2009 Aug 28
2
Association extension method
In my application a user working at a dropzone can manipulate
transactions against customer accounts. Here''s my models:
class Transaction < ActiveRecord::Base
belongs_to :account
end
class Account < ActiveRecord::Base
belongs_to :dropzone
has_many :transactions
end
class Dropzone < ActiveRecord::Base
has_many :transactions, :through => :accounts do
def
2006 May 26
4
shouldn''t this work? - session[:array_of_objects].delete_if {|x| x.id == params[:id]}
I am saving an array of active record objects (college courses) in the
session as session[:course_list]. This is the cart for a registration
controller.
If a student chooses to delete the course from the list I get the :id
as params[:id].
However if I do
session[:course_list].delete_if {|x| x.id ==params[:id]}
does not work.
session[:course_list].delete_at(idx)
works. Ocourse to do this I have
2008 Nov 19
3
Overwriting / Decorating ActiveRecord association accessor
Hi,
I am trying to overwrite the accessor of a has_many association.
Basically my class looks like this:
class Person
has_many :emails
has_one :link, :class_name => ''PersonProxy''
def emails_with_link
link.emails + emails_without_link
end
alias_method_chain :emails, :link
end
Now that works fine if I only access the collection like
>>
2013 Nov 05
0
[LLVMdev] Compiling issues: undefined reference to `.Lline_table_start1'
Hi,
What version of clang are you using? I think r174785 is the fix.
Manman
On Tue, Nov 5, 2013 at 11:04 AM, lipengcheng <pli at cs.rochester.edu> wrote:
> What do you mean by test case please ? Using the following commands to
> compile mcf program
> can reproduce such issue all the time.
>
> Probably it is my version's problem. Because I checked out 3.3version from
2013 Nov 05
2
[LLVMdev] Compiling issues: undefined reference to `.Lline_table_start1'
What do you mean by test case please ? Using the following commands to compile mcf program
can reproduce such issue all the time.
Probably it is my version's problem. Because I checked out 3.3version from SVN before published.
Could you tell me where Manman modified ? I cannot port to new version very quickly after changing
it a lot already.
Thanks,
- Pengcheng
On Nov 5, 2013, at
2013 Nov 05
1
[LLVMdev] Compiling issues: undefined reference to `.Lline_table_start1'
Also r174479.
Manman
On Tue, Nov 5, 2013 at 11:11 AM, Manman Ren <manman.ren at gmail.com> wrote:
> Hi,
>
> What version of clang are you using? I think r174785 is the fix.
>
> Manman
>
>
> On Tue, Nov 5, 2013 at 11:04 AM, lipengcheng <pli at cs.rochester.edu> wrote:
>
>> What do you mean by test case please ? Using the following commands to
2007 Jan 31
1
help with extensions
I am working with extensions to has_many associations, and I want to create
a finder method that is conditional on the attributes of the object whose
association I''m working with.
So, to use the example from the Agile Web Development: the authors show on
pg 340 in the second edition how to pass an argument to a finder method. But
I want to know if it''s possible to instead have
2019 May 10
4
Asterisk 13.26.0 webRTC: Asterisk not passing along video
Hello
I am trying to set up webRTC video calls from my Chrome webbrowser
(Fedora) to my Chrome webbrowser (Windows 10).
There is local video input (I can see myself), but never video on the
receiving side.
This is the case in both directions (so it makes no difference which
peer is calling which peer).
Both webRTC SIP peers have opus and H264 codec in their peer definition :
Video
2013 Nov 06
1
[LLVMdev] "-relocation-model=static" does not work in llc compiler ?
Another finding is when I use both -code-model=large and -relocation-model=pic (!!!!!note changed),
it still generate the static relocation. So does it mean -relocation-model=pic does not like to work
with -code-model=large ?
Thanks,
-Pengcheng
On Nov 6, 2013, at 1:52 PM, lipengcheng <pli at cs.rochester.edu> wrote:
> Yep. I tried it. It used a movabsq instruction instead and a
2017 May 01
2
SSH1 deleted
--
jim knoble | jmknoble at pobox.com
> On Apr 30, 2017, at 19:40, Darren Tucker <dtucker at zip.com.au> wrote:
>
>> On Mon, May 1, 2017 at 12:09 PM, Damien Miller <djm at mindrot.org> wrote:
>>
>> Hi,
>>
>> I just deleted SSHv1 support in OpenBSD and portable OpenSSH. There's
>> probably a little dead code still to be expunged, but
2011 Jun 21
1
[LLVMdev] atomic (memory ordered) operations
Hi,
what's the current status of the memory-ordered operations described in
https://docs.google.com/Doc?docid=0AYWBeVVqyP7dZGRiNG1oeHpfMjJkejVnOThkZA&hl=en.&pli=1
i.e. the ones for "load acquire", "store release" etc. for C++0x atomics,
not the older ones for the __sync intrinsics? The specification looks good -
is it just waiting to be implemented?
Al
--
2008 Dec 31
3
custom package provider troubles
I have written a custom package provider for the pkgutil utility on
Solaris 10. Pkgutil replaces pkg-get which is not deprecated. All I
did was modify the Blastwave provider to use pkgutil instead of pkg-
get. I''ve tried two approaches to get the provider on to the client.
First, I created a plugin. I created a module called package to
contain the plugin. The only file in
2012 Jan 11
1
How many "rollback" TXGs in a ring for 4k drives?
Hello all, I found this dialog on the zfs-devel at zfsonlinux.org list,
and I''d like someone to confirm-or-reject the discussed statement.
Paraphrasing in my words and understanding:
"Labels, including Uberblock rings, are fixed 256KB in size each,
of which 128KB is the UB ring. Normally there is 1KB of data in
one UB, which gives 128 TXGs to rollback to. When ashift=12 is
2013 Nov 05
0
[LLVMdev] Compiling issues: undefined reference to `.Lline_table_start1'
This is from work that Manman did. I thought she'd fixed this particular
issue though. Can you file a bug with a test case please?
On Nov 5, 2013 10:10 AM, "lipengcheng" <pli at cs.rochester.edu> wrote:
> Hello LLVM,
>
> I encountered the following bugs when I compiled my program in debug
> version.
> Could someone help me with that ? Really appreciate that.
2007 Aug 03
0
acts_as_paranoid and Association Extensions (has_one troubles)
Hi... Isn''t there a proper way or hack/workaround for the following?
* For the example with unfortunate disabilities.. look below,,,
Usage of has_* (associationmethods) do {def with_deleted
AccociatedModel#with_scope} {Paranoid''s#find_with_deleted}...
The has_one associations give me a nil object when invoking it with
Model.association_OBJECT.with_deleted. Has_many does like
2006 Nov 04
0
arrayfields-3.6.0
URLS:
- http://raa.ruby-lang.org/project/arrayfields/
- http://www.codeforpeople.com/lib/ruby/arrayfields/
- http://rubyforge.org/projects/arrayfields/
SYNOPSIS:
allow keyword access to arrays:
require ''arrayfields''
fields = ''name'', ''age''
row = [ ''bob'', 30 ]
row.fields = fields
row[
2008 Oct 29
0
RJS problem after upgrading to Rails 2.0.2
I just updated an old app from 1.2.6 to 2.0.2 and I''m having an rjs problem.
I have one page that has 2 submit to remote buttons, one to do a price
override and the other to remove the lineitem. Everything is working
perfectly before the update but now the price override doesn''t update the
page. I''ve verified that the price_override method still gets called
because
2006 Jan 08
3
Family Connection 1.1.2
== What is Family Connection? ==
Family Connection is an easy-to-setup online hub for your family that
includes a Family News section with Photos, and an Address Book.
For more information, visit http://familyconnect.rubyforge.org/
== Downloads ==
Latest:
svn checkout svn://rubyforge.org/var/svn/familyconnect/trunk
Version 1.1.2:
svn checkout
2010 Nov 20
3
Global text search (and replace) on MacVim?
Been trying out Macvim and I think I have covered most of what I used in
other editors except for how to handle global searches and replaces for text
in files (i.e. not looking for file names, but search and replace text
within all files below a specific directory). Can anyone who uses MacVim
tell me what they use for such tasks? I have been poking around and see
:grep as the main method, although