以下是我的schema.yml
CmsFooter:
actAs:
I18n:
fields: [title,description]
Timestampable:
columns:
id:
type: integer(4)
fixed: false
unsigned: false
primary: true
autoincrement: true
is_default:
type: enum(1)
values: [Y, N]
default: N
notnull: true
autoincrement: false
title:
type: string(255)
fixed: false
unsigned: false
primary: false
notnull: true
autoincrement: false
description:
type: string()
fixed: false
unsigned: false
primary: false
notnull: true
autoincrement: false
LanguageMaster:
actAs:
Timestampable:
columns:
id:
type: integer(11)
fixed: false
unsigned: false
primary: true
autoincrement: true
name:
type: string(50)
fixed: false
unsigned: false
primary: false
notnull: true
autoincrement: false
culture:
type: string(4)
fixed: false
unsigned: false
primary: false
notnull: true
autoincrement: false
is_active:
type: enum(1)
fixed: false
unsigned: false
values:
- Y
- N
primary: false
default: N
notnull: true
autoincrement: false
is_default:
type: enum(1)
fixed: false
unsigned: false
values:
- Y
- N
primary: false
default: N
notnull: true
autoincrement: false
file_name:
type: string(50)
fixed: false
unsigned: false
primary: false
notnull: true
autoincrement: false
relations:
CmsFooterTranslation:
local: culture
foreign: lang
type: many
onDelete: CASCADE
onUpdate: CASCADE
我正在生成架构 - > DB。
当我运行此架构时,它不提供数据库表中的关系
表名: - cms_footer_translation字段: - lang
在我需要它的关系中应该显示language_master.culture ondelete cascade& onupdate cascade
任何帮助??
答案 0 :(得分:0)
我定义的工作关系的一个例子是:
relations:
Testimony:
class: Testimony
local: testimony_id
foreign: id
foreignAlias: HomePage
onDelete: cascade
onUpdate: cascade
foreignType: one
owningSide: true
indexes:
fk_home_page_testimony1:
fields: [testimony_id]
我会再读一遍documentation并比较你对他们的看法。