Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
public
/
sequelize
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
不要怂,就是干,撸起袖子干!
Commit bda00ef6
authored
Feb 26, 2013
by
Chia-liang Kao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
DataTypes.ARRAY helper
1 parent
d7bca298
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
2 deletions
lib/data-types.js
spec/postgres/dao.spec.js
lib/data-types.js
View file @
bda00ef
...
@@ -7,5 +7,6 @@ module.exports = {
...
@@ -7,5 +7,6 @@ module.exports = {
BOOLEAN
:
'TINYINT(1)'
,
BOOLEAN
:
'TINYINT(1)'
,
FLOAT
:
'FLOAT'
,
FLOAT
:
'FLOAT'
,
NOW
:
'NOW'
,
NOW
:
'NOW'
,
ENUM
:
'ENUM'
ENUM
:
'ENUM'
,
ARRAY
:
function
(
type
)
{
return
type
+
'[]'
}
}
}
spec/postgres/dao.spec.js
View file @
bda00ef
...
@@ -18,7 +18,7 @@ if (dialect.match(/^postgres/)) {
...
@@ -18,7 +18,7 @@ if (dialect.match(/^postgres/)) {
self
.
User
=
sequelize
.
define
(
'User'
,
{
self
.
User
=
sequelize
.
define
(
'User'
,
{
username
:
DataTypes
.
STRING
,
username
:
DataTypes
.
STRING
,
email
:
{
type
:
'text[]'
}
email
:
{
type
:
DataTypes
.
ARRAY
(
DataTypes
.
TEXT
)
}
})
})
},
},
onComplete
:
function
()
{
onComplete
:
function
()
{
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment