keystonejs 表单处理文档位置
keystonejs form processing documentation location
有没有人有关于 keystone js 模型方法 "getUpdateHandler" 和处理程序方法 "process" 的 source/documentation "form post"[=11 下 https://gist.github.com/wuhaixing/e90b8497f925ff9c7bfc =]
不幸的是,这部分代码库目前根本没有真正的文档记录。有一个小讨论 here,您可能会觉得有帮助,但我将在下面总结要点:
更新处理程序背后的想法是让您可以轻松地从站点的前端更新您的字段。你告诉它你想更新哪些字段,并给它相关的数据。然后它会检查您的模型,使其能够自行处理任何验证错误等,如果一切正常,它将执行必要的操作来更新您的字段。
你可以看到进程函数本身here, and there are a few comments which may be helpful, but this is by no means documentation. Further, there is a good example on the SydJS site (links to the backend code (route) and the frontend code (template))。希望这足以让您入门。
有没有人有关于 keystone js 模型方法 "getUpdateHandler" 和处理程序方法 "process" 的 source/documentation "form post"[=11 下 https://gist.github.com/wuhaixing/e90b8497f925ff9c7bfc =]
不幸的是,这部分代码库目前根本没有真正的文档记录。有一个小讨论 here,您可能会觉得有帮助,但我将在下面总结要点:
更新处理程序背后的想法是让您可以轻松地从站点的前端更新您的字段。你告诉它你想更新哪些字段,并给它相关的数据。然后它会检查您的模型,使其能够自行处理任何验证错误等,如果一切正常,它将执行必要的操作来更新您的字段。
你可以看到进程函数本身here, and there are a few comments which may be helpful, but this is by no means documentation. Further, there is a good example on the SydJS site (links to the backend code (route) and the frontend code (template))。希望这足以让您入门。