similar to: polymorphism with created_at and modified_at

Displaying 20 results from an estimated 5000 matches similar to: "polymorphism with created_at and modified_at"

2005 Sep 02
7
Form to update two tables
Hello there, this is probably a very simple problem but I''m stuck. I''m following the Login generator tutorial from rubyonrails. It''s all worked fine so far. But I want to add a bit more functionality so that when a user signs up in addition to chosing a login name and password they type in a company name which is added to a seperate table called COMPANIES. The id
2006 May 27
0
Typo 1055 created_at Vs. published_at
[Couldn''t post this to the Typo forum, hope it''s Ok here :-)] Before I go off and create a Typo ticket, I''d like to know if anyone else is experiencing this and what there thoughts might be on the subject? In Typo 1055, if you use the admin interface and change the published date for an article, you will get "post not found", when you click on the article
2010 Jul 19
1
How to write your own created_at/updated_at?
I''m using Pfeed(http://github.com/parolkar/pfeed) plugin for User Activity Feeds. It creates PfeedItem model records and uses created_at field for a lot of stuff inside. Now I need to export/import those user logs. I do exporting to YAML. When I reconstruct PfeedItem AR object from YAML, it have real(old) creation time in created_at attribute. When I save this PfeedItem - there is new
2009 Feb 19
0
[LLVMdev] Parametric polymorphism
On Wednesday 18 February 2009 23:36:27 DeLesley Hutchins wrote: > > Why do you say that people who compile, e.g., functional languages > > would benefit from type variables in LLVM? > > I like the level the LLVM is at, and would prefer to deal with > > instantiating parametric polymorphism at a higher level. > > I'm surprised you're happy with a
2010 May 25
2
Site Navigation With Polymorphic Has Many Through
Hi, seem to keep running into a wall here. I can''t find any resources on site navigation that can deal with any model being in the nav, allow nesting, and can dynamically update. So I thought about it for a while, and decided on a MenuItems class, which contained the position of the child in relation to it''s siblings, where the parent and the child were polymorphic. Then a given
2009 Feb 18
2
[LLVMdev] Parametric polymorphism
> Why do you say that people who compile, e.g., functional languages > would benefit from type variables in LLVM? > I like the level the LLVM is at, and would prefer to deal with > instantiating parametric polymorphism at a higher level. I'm surprised you're happy with a non-polymorphic llvm. Does Cayenne target llvm? Dependent types take polymorphism to new heights -- but
2007 Jun 27
0
ActiveRecord Type issue -- What am I missing?
Hey everyone, First, apologies for the crosspost, I meant to post this to this group, my previous post was a mistake. I''m having a frustrating ActiveRecord issue. Maybe what I''m trying to do will not work, but if that''s the case, I''d like to know why. Otherwise I''d love to know what I''m doing wrong. My goal is to store prices (numbers with
2007 Aug 16
0
created_at Column and strftime
I am trying to format the created_at value of an object for display in the view. Just for testing purposes, right now I''m doing - puts @the_object.created_at.strftime(''%B %e, %G'') puts @the_object.created_at.to_date.strftime(''%B %e, %G'') The first line doesn''t output anything, while the second one outputs the date in the correct format. Why
2006 Sep 22
2
possible to create polymorphic relationship with STI models?
I would like to associate a ‘product’ model with 3 models inherited from ‘image’: part, action and accessory. I have it working with Has_many :through relating products to images through attachments, I then have to determine the ‘type’ of the STI extension. This means i have to go product.images. While this is ok, i can see it getting tricky when i want to go products.images <<
2015 Jan 27
2
[LLVMdev] RFC: Introduce a section to the programmers manual about type hierarchies, polymorphism, and virtual dispatch.
The proposed addition to ProgrammersManuel.rst is below the break... This is essentially trying to explain the emerging design techniques being used in LLVM these days somewhere more accessible than the comments on a particular piece of infrastructure. It covers the "concepts-based polymorphism" that caused some confusion during initial reviews of the new pass manager as well as the
2006 Mar 17
3
RoR problems with Created_At and PostgreSQL
So, I wrote some pages which essentially created some articles which are saved to a database, which also include both the "magic" rows ''created_at'' and ''updated_at''. Now, on my development machine I''m running the MySQL-database and everything worked as I wanted it to. On the live server I''ve had to switch to PostgreSQL 8.1 due to
2009 Feb 18
0
[LLVMdev] Parametric polymorphism
On Wed, Feb 18, 2009 at 12:32, DeLesley SpamBox <delesley.spambox at googlemail.com> wrote: >> I think the problem is deeper than that, in that LLVM has no official >> concept of a subtype, so I don't see how the idea of polymorphism >> could be defined in it. > > Parametric polymorphism is different from subtype polymorphism; you > can have one without the
2009 Jan 17
0
Created_at date/time if off by UTC-5 hours ?
Hello - My model has created_at and updated_at which get set automatically, as expected, but the time is 5 hours off. For example, if I create a new record at 7:15:25 AM the created_at time shows 12:15:25. I suspect this has to do with my time zone (Eastern Time, United States). But if I do a Time.now, it shows the correct time. Does the Timestamp class use a different zone than the Time
2012 Oct 23
0
multidimensional Array or Hash with group_by 'created_at'
Hello, i want to create a multidimensional Array or Hash with group_by ''created_at''. 3 dimensions needed: myArray[week][day][data] currently i only created it with 2 dimesions: #model def self.group_per_day all.group_by{|t| t.created_at.strftime("%d. %B, %Y")}.sort #"%U" for Weeks end #controller @pdf_activities = Activity.group_per_day #view
2005 Dec 19
3
created_on, created_at defaulting to 2000/01/01 00:00:00
Hello all, Rails 1.0.0 created_on is being set to 2000/01/01 00:00:00 Any ideas on this ? Thanks! Schema is create table user_login_history ( id int identity(1,1) not null, user_id int not null, created_on datetime default(getdate()) not null, created_at datetime default(getdate()) not null, updated_on datetime default(getdate()) not null, constraint pk_user_login_history primary key clustered
2012 Mar 22
1
why doesn't .where() honor polymorphism?
I love the query interface (ActiveMethod::QueryMethods), but one thing has bugged me: why doesn''t it generate calls for polymorphic associations? For example: class MyModel < ActiveRecord::Base belongs_to :parent, :polymorphic => true end I would expect: MyModel.where(:parent => a) to be equivalent to: MyModel.where("my_models.parent_id = ? AND
2009 Feb 18
2
[LLVMdev] Parametric polymorphism
> I think the problem is deeper than that, in that LLVM has no official > concept of a subtype, so I don't see how the idea of polymorphism > could be defined in it. Parametric polymorphism is different from subtype polymorphism; you can have one without the other. Parametric polymorphism just means that you can use type variables (like T) in the IR, which are later instantiated to
2006 Mar 08
0
combining STI + polymorphism + rich self HABTM : how to ?
Hi all, I need to model simple typed polymorphic relations: ''John'' [''works_for''] ''Bill'' ''John'' [''speaks_for''] ''Microsoft'' ''Microsoft'' [''hold_shares_of''] ''Apple'' I''m having a hard time combining : - S.T.I.
2009 Feb 11
6
Sessions do not update created_at column?
Hi All, I added a column to the sessions table called "created_at" in order to allow the created time to be recorded. However, different from other Models, the column does not update automatically. Therefore, what codes should I add to update the sessions."created_at" value? It is important for avoiding hacker keeping the sessions alive. Thanks much! Arthur -- Posted via
2006 Jun 10
0
Ordering Based on created_at in HABTM relationship
I have the following line in my controller: @tag = Tag.find_by_name @params[:id] Now, how do I order the rows based on the HABTM relationship problems_tags i.e. problems_tags.created_at DESC Thanks :-) John Kopanas http://www.kopanas.com ============================================================ http://www.soen.info - Index of online software engineering knowledge http://www.cusec.net -