虽然使saveEventArgs.Cancel = true并且从内容服务的保存事件返回时正被重定向到#/ content / content / edit / 0,这在umbraco UI中抛出请求错误,因为没有id为0的节点。
请帮助理解,如何避免umbraco在保存取消时编辑0 id。
答案 0 :(得分:0)
如果有人在寻找具体的答案。您可以在Saving Event Handler中调用IContentService上的save方法,并将raise事件设置为false。 例如。
server {
listen 80;
listen [::]:80;
server_name backend.domaine.na.me www.backend.domaine.na.me;
return 301 https://$server_name$request_uri;
}
server {
# SSL configuration
listen 443 ssl http2;
listen [::]:443 ssl http2;
include snippets/ssl-backend.domaine.na.me.conf;
include snippets/ssl-params.conf;
location = /favicon.ico { access_log off; log_not_found off; }
location /static/ {
root /projects/my_django_app;
}
location /media/ {
root /projects/my_django_app;
}
location ~ /.well-known {
allow all;
}
location / {
proxy_pass http://unix:/projects/my_django_app.sock;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto https;
proxy_set_header Host $http_host;
proxy_redirect off;
}
}