mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-08-09 07:25:19 +02:00
Separate exclude and one-time transaction handling (#2400)
* Separate exclude and one-time transaction handling - Split transaction "exclude" and "one-time" toggles into separate controls in transaction detail view - Updated Transaction::Search to show excluded transactions with grayed-out styling instead of filtering them out - Modified IncomeStatement calculations to exclude both excluded and one_time transactions from totals - Added migration to convert existing excluded transactions to also be one_time for backward compatibility - Updated transaction list view to show asterisk for one_time transactions and gray out excluded ones - Added controller support for kind parameter in transaction updates 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com> * Fix linting issues - Remove trailing whitespace from migration - Fix ERB formatting throughout templates 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com> --------- Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
parent
c003e8c6ed
commit
63d8114b05
28 changed files with 147 additions and 115 deletions
|
@ -3,7 +3,7 @@
|
|||
<div class="mx-auto w-12 h-12 rounded-full bg-destructive-surface flex items-center justify-center mb-4">
|
||||
<%= icon("alert-circle", class: "w-6 h-6 text-destructive") %>
|
||||
</div>
|
||||
<h1 class="text-2xl font-medium text-primary"><%= t('doorkeeper.authorizations.error.title') %></h1>
|
||||
<h1 class="text-2xl font-medium text-primary"><%= t("doorkeeper.authorizations.error.title") %></h1>
|
||||
</div>
|
||||
|
||||
<div class="bg-surface-inset rounded-lg p-4">
|
||||
|
|
|
@ -3,12 +3,12 @@
|
|||
<div class="mx-auto w-12 h-12 rounded-full bg-surface-inset flex items-center justify-center mb-4">
|
||||
<%= icon("loader-circle", class: "w-6 h-6 text-primary animate-spin") %>
|
||||
</div>
|
||||
<h1 class="text-2xl font-medium text-primary"><%= t('.title') %></h1>
|
||||
<h1 class="text-2xl font-medium text-primary"><%= t(".title") %></h1>
|
||||
<p class="text-sm text-secondary">Redirecting you back to the application...</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<% turbo_disabled = @pre_auth.redirect_uri&.start_with?('maybeapp://') || params[:display] == 'mobile' %>
|
||||
<% turbo_disabled = @pre_auth.redirect_uri&.start_with?("maybeapp://") || params[:display] == "mobile" %>
|
||||
<%= form_tag @pre_auth.redirect_uri, method: :post, name: :redirect_form, authenticity_token: false, data: { turbo: !turbo_disabled } do %>
|
||||
<% auth.body.compact.each do |key, value| %>
|
||||
<%= hidden_field_tag key, value %>
|
||||
|
|
|
@ -5,13 +5,13 @@
|
|||
<div class="bg-container rounded-xl p-6 space-y-6">
|
||||
<div class="space-y-2 text-center">
|
||||
<p class="text-sm text-secondary">
|
||||
<%= raw t('.prompt', client_name: content_tag(:span, @pre_auth.client.name, class: 'font-medium text-primary')) %>
|
||||
<%= raw t(".prompt", client_name: content_tag(:span, @pre_auth.client.name, class: "font-medium text-primary")) %>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<% if @pre_auth.scopes.count > 0 %>
|
||||
<div class="bg-surface-inset rounded-lg p-4 space-y-3">
|
||||
<p class="text-sm font-medium text-primary"><%= t('.able_to') %>:</p>
|
||||
<p class="text-sm font-medium text-primary"><%= t(".able_to") %>:</p>
|
||||
<ul class="space-y-2">
|
||||
<% @pre_auth.scopes.each do |scope| %>
|
||||
<li class="flex items-start gap-2 text-sm text-secondary">
|
||||
|
@ -24,7 +24,7 @@
|
|||
<% end %>
|
||||
|
||||
<div class="space-y-3">
|
||||
<% turbo_disabled = params[:redirect_uri]&.start_with?('maybeapp://') || params[:display] == 'mobile' %>
|
||||
<% turbo_disabled = params[:redirect_uri]&.start_with?("maybeapp://") || params[:display] == "mobile" %>
|
||||
<%= form_tag oauth_authorization_path, method: :post, class: "w-full", data: { turbo: !turbo_disabled } do %>
|
||||
<%= hidden_field_tag :client_id, @pre_auth.client.uid, id: nil %>
|
||||
<%= hidden_field_tag :redirect_uri, @pre_auth.redirect_uri, id: nil %>
|
||||
|
@ -38,7 +38,7 @@
|
|||
<%= hidden_field_tag :display, params[:display], id: nil %>
|
||||
<% end %>
|
||||
<%= render ButtonComponent.new(
|
||||
text: t('doorkeeper.authorizations.buttons.authorize'),
|
||||
text: t("doorkeeper.authorizations.buttons.authorize"),
|
||||
variant: :primary,
|
||||
size: :lg,
|
||||
full_width: true,
|
||||
|
@ -46,7 +46,7 @@
|
|||
data: { disable_with: "Authorizing..." }
|
||||
) %>
|
||||
<% end %>
|
||||
|
||||
|
||||
<%= form_tag oauth_authorization_path, method: :delete, class: "w-full", data: { turbo: !turbo_disabled } do %>
|
||||
<%= hidden_field_tag :client_id, @pre_auth.client.uid, id: nil %>
|
||||
<%= hidden_field_tag :redirect_uri, @pre_auth.redirect_uri, id: nil %>
|
||||
|
@ -60,7 +60,7 @@
|
|||
<%= hidden_field_tag :display, params[:display], id: nil %>
|
||||
<% end %>
|
||||
<%= render ButtonComponent.new(
|
||||
text: t('doorkeeper.authorizations.buttons.deny'),
|
||||
text: t("doorkeeper.authorizations.buttons.deny"),
|
||||
variant: :outline,
|
||||
size: :lg,
|
||||
full_width: true,
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<div class="mx-auto w-12 h-12 rounded-full bg-success-surface flex items-center justify-center mb-4">
|
||||
<%= icon("check", class: "w-6 h-6 text-success") %>
|
||||
</div>
|
||||
<h1 class="text-2xl font-medium text-primary"><%= t('.title') %></h1>
|
||||
<h1 class="text-2xl font-medium text-primary"><%= t(".title") %></h1>
|
||||
</div>
|
||||
|
||||
<div class="bg-surface-inset rounded-lg p-4">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue