Displaying 20 results from an estimated 200 matches similar to: "workweek_select"
2006 Mar 14
21
Changing default date format in Rails
I''ve spent all day digging through the rails api and postgres-pr on
this, I think it''s time to ask the list.
Postgres stores a Date in YYYY-MM-DD format. My users want the dates
in MM/DD/YYYY format.
Sure, I could explicitly convert it on the app level every place where
a date is displayed, but that seemed like a DRY violation.
I thought I''d be clever and simply
2006 Jun 12
5
railish icons?
This is a little off topic but someone here knows, I''m sure... Does
anyone have a good site to find freely available standard icons for
things like add/edit/delete/save?
I''m looking for a set of clean and simple matching icons that capture
that Railsy-Web 2.0 feel...
Maybe icons aren''t Railsy...
Steven
--
Posted via http://www.ruby-forum.com/.
2007 Jan 25
6
NOT FOUND error
I''ve been hunting the web and reading the mailing lists all day but
I''m not finding any guidance on this problem. When I try to talk to my
mongrel it simply responds with NOT FOUND and nothing else. I can''t
find anything on google because this has to be the second most commond
phrase in existence.
Any help or guidance would be greatly appreciated.
Sincerely,
Chuck Vose
2006 Aug 28
8
Railsy way to Export Database Schema?
Is there a nice way in rails to automatically extract an exising
database schema from an existing app and then in a new app automatically
create a database based on this schema?
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post
2012 Feb 21
8
should_receive_chain
Do you often find yourself doing this:
active = double(''active'')
active.should_receive(:first)
users = double(''users'', active: active)
account.should_receive(:users).and_return(users)
for this:
account.users.active.first
?
Of course, we could use stub_chain, but that doesn''t let us know
*where* the chain broke.
Would you like to do this?
2006 Jul 18
3
Navigation techniques, everyone?
I''m rewriting the code to my first app. I want to reuse a lot of it,
but tidy it up a lot. The first thing I will tackle is my nav-bar.
Throughout a user''s experience on my app, I want it to reload as little
as possible (I''ll have about 7 or 8 controllers with about 70 actions).
So, I''ve thought of a few ways of doing it, and was wondering if you
guys
2006 Jul 06
6
Problem with gettext and functional tests
Hi,
I am using gettext to let my web application know several languages. All
works fine, but since I integrated it, my functional tests don''t work any
more.
I keep getting the error message:
NoMethodError: undefined method `cgi'' for
#<ActionController::TestRequest:0xb77f7f88>.
All right, TestRequest doesn''t have a cgi method. Therefore I just included
this into
2006 Jul 06
9
Where to put code - controller or model
I have a Rails app that is a directory indexer. It passes the desired
directory path in the url.
There is a user table, and a permissions table (which contains the
volumes each user has permission to see). There is also a volume table,
which contains the available volumes, and a path table, which contains
the paths to every file available on the machine. [There are other
tables, but these
2006 Jun 30
14
Saving boolean attributes
Hi,
I''m just learning Ruby on Rails and ran into something where I know I''m
either doing something very stupid or I''m missing something.
My model as a boolean attribute called active_flag. In my Sql Server
database this is stored as a bit value. I then setup a method in my
controller called "deactivate". This is very simple, it does:
def deactivate
2006 Aug 12
1
has and belongs to many different?
Is there such a thing? I am thinking of an application that has
something like this:
1. person has many things - there is a ''persons'' table
2. the things he has are stored in a table that is something like this
person_id, thing_table_name, thing_id
For example, it may map to
person1, books, 23 #Person 1 owns book 23
person1, books, 25 #Person 1 owns book 25
2006 Jul 17
5
Functional Tests misbehaving with Globalize
Howdy all
Apologies to the folks subscribed to the globalize list for dual
posting this message...
I''ve got a project running globalize and rails 1.1.4, and I''ve only
recently adopted a strong love for testing. Now my models are 100%
tested (I must note that I do not make use of any translations in the
database yet), and I''ve now started with functional tests before
2006 Jul 06
6
Functional tsts
Hi all,
I have created projects module in my application using scaffold,
and it created me everything, and all the modules are working except the
functional test. This is the error
1) Failure:
test_create(ProjectsControllerTest)
[test/functional/projects_controller_test.rb
:55]:
Expected response to be a <:redirect>, but was <200>
8 tests, 25 assertions, 1 failures, 0
2006 Jul 06
3
Accessing form field contents
I have an HTML form on the screen, that is connected to a database
(standard Ruby way). I found that there are people that would rather not
fill in this information, but would rather search Amazon for the info.
Therefore, I added a link to the right of one of the fields that, when
pressed, will search Amazon for what ever you typed into that field.
So, how can I do that? At first I tried
2008 Apr 15
2
environment.rb uninitialized constant when starting console
I have the following code in environment.rb:
require File.join(File.dirname(__FILE__), ''boot'')
raw_config = File.read(RAILS_ROOT + "/config/config.yml")
APP_CONFIG = YAML.load(raw_config)[RAILS_ENV]
This works fine when running the server, but if I try and start a
console I get:
Loading development environment.
2006 Jul 18
9
Simple Array Issue - HELP
Ok, I am interfacing with the del.icio.us API and I want to collect the
links in an @instance variable for my view. But I''m having trouble with
that part. Here''s what I have:
def get_authenticated(path, http)
request = Net::HTTP::Get.new(path)
request.basic_auth ''user'', ''pass''
response = http.request(request)
response.value
response.body
end
2006 Jul 07
8
Going to production soon, need server advice
I''ve got a RoR app that will be going to production soon (in the next
month or so) and would like to get some feedback on what kind of web
server setup people have had good luck with. I''m looking for something
that is:
1. Stable
2. Easy to setup
3. Secure (sorry but Windows is ruled out here)
My deployment will either be on Fedora Core 5 or possible Mac OS X
Server.
2006 Jul 06
2
Validation Error
Hi all,
I''m trying to validate a data field.
I''ve added ''validate_presence_of :name'' to the record model, but when I
try to create a record i get an error complaining that it can''t find
data from another table that also is updated on that page.
Let me explain further,
On my ''record'' update page, I have data from another table
2006 Jul 18
3
DB Migrations & Column Order
Hello,
I created a table and about 10 migrations down the line I decided that
I needed to add an ID column (this was actually a table for a has_many
:through and I recently realized that it needs an ID column, unlike
HABTM tables). I am a big perfectionist and I frequently run "SHOW
COLUMNS IN table;", so I naturally expect to see the "id" column the
first one listed. However,
2006 May 24
8
Where to recruit Ruby on Rails developers?
Anyone have suggestions on where to recruit Ruby on Rails developers?
My startup''s in Berkeley, CA and I''m looking for a talented technical
lead. I''ve tried LinkedIn and Craigslist but the pickings are slim. This
project provides an opportunity to use OpenLaszlo.
rocky at_sign teampatent dot com
--
Posted via http://www.ruby-forum.com/.
2006 Jun 20
8
Integrating multiple applications
I''ve got a couple apps that I use (billing app, support ticket app,
some other custom apps) that I want to integrate into one site. They
will all use the same layout for the most part, and will link between
each other.
When I initially thought of doing this, I figured if I put the apps at
different roots - /billing /support etc - then the links wouldn''t work
at all, because