【发布时间】:2015-03-21 22:21:39
【问题描述】:
我有一个这样的模型 -
{
"name": "MakeCallTestConfiguration",
"base": "PersistedModel",
"idInjection": true,
"properties": {
"id": {
"type": "number",
"id": true,
"generated": true
},
"destination": {
"type": "string",
"required": true
},
"clientId": {
"type": "number",
"required": true
},
"logTime":{
"type" : "date",
}
},
"validations": [],
"relations": {},
"acls": [],
"methods": []
}
对于“logTime”,如何自动生成时间戳?我的意思是像
“TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP”
【问题讨论】:
标签: loopbackjs strongloop