我的contenttype.yml文件定义了以下内容类型:
#Testimonials
testimonials:
name: Testimonials
singular_name: Testimonial
fields:
name:
type: text
class: large
position:
type: text
body:
type: textarea
height: 150px
listing_template: testimonials.twig
record_template: testimonial.twig
现在,在我的浏览器中,如果我导航到http://localhost:8080/boltCMS/testimonials
,我会看到我的record_template,但如果我导航至http://localhost:8080/boltCMS/testimonials/1
,我会收到一个错误。
找不到页面testimonials/1
。
那么我该如何导航到我的listing_template
?这是我可以在contenttypes.yml
中设置和修改的内容吗?
如果我将以下内容添加到我的感言.titch文件,
{{ dump(records) }}
我在浏览器中看到一个空数组。
谢谢。
您是否在数据库中检查过"1"是否是您的某个推荐信的正确段塞?