mirror of
https://github.com/ubicloud/ubicloud.git
synced 2025-10-04 22:02:18 +08:00
This switches Clover to use the form method for forms, which automatically handles adding the appropriate csrf tag, so you don't need to duplicate the path in a separate csrf_tag call. The form method comes from the forme_route_csrf plugin, which is what CloverAdmin already uses. While here, change some rodauth forms to use *_path instead of "/" + *_route. Also, change some "#{@project.path}#{@pg.path}" to path(@pg).
23 lines
805 B
Text
23 lines
805 B
Text
<% @page_title = "GitHub Runners Integration" %>
|
|
|
|
<% if !@project.has_valid_payment_method? %>
|
|
<% form(action: billing_path, method: :post) do %>
|
|
<%== part(
|
|
"components/empty_state",
|
|
icon: "hero-banknotes",
|
|
title: "No billing information",
|
|
description:
|
|
"Project doesn't have valid billing information. First, you need to update the project's billing details to use GitHub Runners.",
|
|
button_title: "New Billing Information"
|
|
) %>
|
|
<% end %>
|
|
<% else %>
|
|
<%== part(
|
|
"components/empty_state",
|
|
icon: "github",
|
|
title: "No Connected Accounts",
|
|
description: "Get started by installing our GitHub app to your user or organization account.",
|
|
button_link: "#{@project.path}/github/create",
|
|
button_title: "Connect New Account"
|
|
) %>
|
|
<% end %>
|