public
Description: DataMapper Adapters
Homepage: http://www.yehudakatz.com
Clone URL: git://github.com/wycats/dm-adapters.git
Search Repo:
Stop changing the API Sam
wycats (author)
Tue May 13 21:37:13 -0700 2008
commit  4051dd9388c55c480e7a5368896d4353dbaaefb6
tree    882b88934cd5e3d2be479922619f8920a9dea2e9
parent  4adb2e64fb049b4e13ded3fae3bbbe0658438314
...
116
117
118
119
 
120
121
122
...
116
117
118
 
119
120
121
122
0
@@ -116,7 +116,7 @@
0
         
0
         conditions = query.conditions.map {|c| SQL.from_condition(c, repository)}.compact.join(") AND (")
0
         
0
- query_string = "SELECT #{query.fields.map {|f| f.field}.join(", ")} from #{query.model_name}"
0
+ query_string = "SELECT #{query.fields.map {|f| f.field}.join(", ")} from #{query.model.storage_name(repository.name)}"
0
         query_string << " WHERE (#{conditions})" unless conditions.empty?
0
         query_string << " ORDER BY #{SQL.order(query.order[0])}" unless query.order.empty?
0
         query_string << " LIMIT #{query.limit}" if query.limit

Comments

  • sam Wed May 14 09:43:39 -0700 2008

    Don’t blame me! It’s all Dan I tell ya! :-D

  • dkubb Mon May 19 14:17:15 -0700 2008

    This one was me, but there was a good reason for this change. If this was in dm-more we would’ve kept it in sync with dm-core’s still-in-development API.