Tag: 协会条款

使用Stripe的订阅表单未正确传递参数

我在我的Rails 4.2应用程序上收到以下错误。 我正在尝试使用Stripe设置订阅。 订阅属于业务和has_one计划。 在我看来,我在URL中传递了参数: http:// localhost:3000 / subscriptions / new?plan_id = 2&business_id = 1001 提交表单后,我收到以下错误,我的代码如下。 如果这是一个初学者问题,请原谅我。 订阅控制器 class SubscriptionsController e flash[:error] = e.message render :new end private def stripe_params params.permit :stripeEmail, :stripeToken end # Use callbacks to share common setup or constraints between actions. def set_subscription @subscription = Subscription.find(params[:id]) end # Never trust parameters […]