Skip to content

Commit 90152f8

Browse files
committed
ブログコンテンツ削除時にブログ記事とカテゴリの関連データが削除されない
1 parent 3cda043 commit 90152f8

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

plugins/bc-blog/src/Model/Table/BlogContentsTable.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,15 +122,15 @@ public function initialize(array $config): void
122122
'order' => 'posted DESC',
123123
'foreignKey' => 'blog_content_id',
124124
'dependent' => true,
125-
'exclusive' => false,
125+
'cascadeCallbacks' => true,
126126
]);
127127
$this->hasMany('BlogCategories', [
128128
'className' => 'BcBlog.BlogCategories',
129129
'order' => 'id',
130130
'limit' => 10,
131131
'foreignKey' => 'blog_content_id',
132132
'dependent' => true,
133-
'exclusive' => false,
133+
'cascadeCallbacks' => true,
134134
]);
135135
}
136136

0 commit comments

Comments
 (0)