Skip to main content

Module batch

Module batch 

Source
Expand description

后台文章的批量操作:发布、转为草稿、移到回收站。

逐篇走文章写入业务(各自事务与缓存失效),返回成功与失败篇数;某一篇失败不影响其余。 Leptos server function,注册在 /api 路径下。

Structs§

BatchPosts
Serialized arguments for the batch_posts server function.

Constants§

MAX_BATCH 🔒
单次批量操作的篇数上限。

Functions§

batch_posts
对多篇文章执行同一操作。需要 admin 权限。