gpt4 book ai didi

grails - 如何使用后请求方法将一个操作重定向到另一个操作

转载 作者:行者123 更新时间:2023-12-02 13:51:19 24 4
gpt4 key购买 nike

注意:第二个操作仅允许POST方法。我们无法由用户执行该操作。

static allowedMethods = [save: "POST",booked:"POST"]

def save()
{
// did save operation here
redirect action:'booked'
}

def booked()
{
//did the operation related with this
render view :'payment'
}

最佳答案

继续尝试

def save()
{// did save operation here
forward action:'booked'
}

def booked()
{
//did the operation related with this
render view :'payment'
}

传递给 的所有参数都将直接传递给 预订的方法。这是您需要的吗?

关于grails - 如何使用后请求方法将一个操作重定向到另一个操作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32029468/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com