0
我已经从自定义资源(简报)创建了一个网格,并且我想在每行上添加一个“发送”按钮,旁边是默认的“编辑”和“删除“ 纽扣。 但我不知道如何定义网格定义自定义操作,我不觉得在Sylius文档的信息...在Sylius资源网格中添加自定义操作
这里是我的网高清:
sylius_grid:
grids:
admin_newsletter:
driver:
name: doctrine/orm
options:
class: NewsletterBundle\Entity\Newsletter
sorting:
date: desc
fields:
titre:
type: string
label: sylius.ui.title
sortable: ~
date:
type: datetime
label: sylius.ui.date
sortable: ~
options:
format: d/m/Y
envoye:
type: twig
label: admin.ui.newsletter_envoye
sortable: ~
options:
template: NewsletterBundle:Helper:_sent.html.twig
filters:
search:
type: string
label: sylius.ui.search
options:
fields: [titre]
actions:
main:
create:
type: create
item:
update:
type: update
delete:
type: delete
# This is what I want:
send:
type: send
任何如何做到这一点的想法?
谢谢!
就是这样! Tks CoderMaggie :) – wyllyjon