Skip to content
This repository has been archived by the owner on Jun 11, 2022. It is now read-only.

FirstName and LastName property types #3

Open
maeve opened this issue Apr 6, 2011 · 0 comments
Open

FirstName and LastName property types #3

maeve opened this issue Apr 6, 2011 · 0 comments

Comments

@maeve
Copy link
Contributor

maeve commented Apr 6, 2011

We commonly have to translate between data structures that store a person's name as a single string and structures that split the name into first name and last name.

It would be nice if modelish could abstract away the boilerplate by doing something like this:

    property :customer_first_name, :type => FirstName, :from => :input_name
    property :customer_last_name, :type => LastName, :from => :input_name

The format for the input string should default to "first last", with some kind of configuration option to override that.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant