【发布时间】:2011-05-06 09:17:15
【问题描述】:
我已经为我的 Symfony+doctrine 应用程序的数据库编写了我的 yaml 架构,我正试图让它来制作模型等,但它在 doctrine:build-model 上出错
$> ./symfony 学说:构建模型
>> 学说生成模型类>> 文件+ /tmp/doctrine_schema_89653.yml
No yml schema found in /tmp/doctrine_schema_89653.yml
我将我的架构放在config/doctrine/schema.yml 中,根据我经历过的所有教程,它应该在哪里。经过一番谷歌搜索后,我认为我的 yaml 中可能存在语法错误,但我不确定。以防万一:
Coder:
actAs: [Timestampable]
tableName: dormcode_coder
columns:
id:
type: integer
primary: true
autoincrement: true
username: string(60)
password: string(60)
email: string(255)
firstname: string(60)
lastname: string(60)
Client:
actAs: [Timestampable]
tableName: dormcode_client
columns:
id:
type: integer
primary: true
autoincrement: true
username: string(60)
password: string(60)
email: string(255)
firstname: string(60)
lastname: string(60)
Project:
actAs: [Timestampable]
tableName: dormcode_project
columns:
id:
type: integer
primary: true
autoincrement: true
client_id: integer
title: string(255)
briefdesc: clob
spec: clob
coder_id:
type: integer
notnull: false
default: null
paytype: string(30)
negotiable:
type: bool
default: false
complete:
type: bool
default: false
relations:
Coder:
foreignType: one
Client:
foreignType: one
Iteration:
actAs: [Timestampable]
tableName: dormcode_iteration
columns:
id:
type: integer
primary: true
autoincrement: true
ordernum: integer
description: clob
project_id: integer
relations:
Project:
foreignAlias: Iterations
我不确定还会有什么,有谁知道其他类型的事情可能会导致该错误吗?这真的没有意义......
编辑:我刚刚在 /tmp 中查找了该文件,它就在那里。它继续{ } 就是这样。
【问题讨论】:
标签: database symfony1 doctrine yaml