kit

Inline consequence

Built revision v17.10.0

Phoenix
Topics

Human support

Bring a missing role, layout, or state, or a rendering against the standard, to the session working on kit. Name the package and the entry.

On Record, Form, Stepped flow, Settings

Inline consequence

Oakmere Primary School invoice

Cancelling this invoice removes the £240.00 amount due.

Takes effect as soon as you confirm.

You can issue a replacement invoice from Oakmere Primary School’s record.

A consequence whose action cannot be taken yet.

Oakmere Primary School invoice

Cancelling this invoice removes the £240.00 amount due.

Takes effect as soon as you confirm.

You can issue a replacement invoice from Oakmere Primary School’s record.

Wait for the invoice to be checked before cancelling.

Oakmere Primary School invoice

Cancelling this invoice removes the £240.00 amount due.

Takes effect as soon as you confirm.

A consequence that sends an email shows it as its recipient will get it.

Oakmere Primary School choir rehearsal

Moving the rehearsal to Thursday 6 February emails Aisha Khan the new time.

Channel
Email to aisha@oakmereprimary.org
Subject
Your rehearsal moves to Thursday 6 February

Aisha is emailed as soon as you confirm.

To change it after that, move it again. Aisha is emailed about that move too.

A consequence that sends a text shows it as a phone shows it.

St Anne’s Scout Group deposit

Refunding the £50.00 deposit texts Priya Shah that it is on its way.

Channel
Text to 07700 900123

Oakmere Village Hall: your £50.00 deposit for St Anne’s Scout Group is on its way back to you. It reaches your account within 5 working days.

Takes effect as soon as you confirm.

A refund cannot be taken back. You can charge a new deposit from St Anne’s Scout Group’s record.

A consequence that changes amounts holds each, before and after.

Autumn programme hire charge

Splitting the £180.00 charge across three payers changes what each one owes.

What each payer owes
Payer BeforeAfter
Oakmere Primary School
£180.00
£90.00
Oakmere WI
£0.00
£50.00
St Anne’s Scout Group
£0.00
£40.00

Takes effect as soon as you confirm.

To change the split later, split the charge again from its record.

A consequence that changes amounts and sends a text holds the amounts, then the text.

St Anne’s Scout Group deposit

Refunding the £50.00 deposit texts Priya Shah that it is on its way.

The deposit before and after
Deposit BeforeAfter
Held
£50.00
£0.00
Refunded
£0.00
£50.00
Channel
Text to 07700 900123

Oakmere Village Hall: your £50.00 deposit for St Anne’s Scout Group is on its way back to you. It reaches your account within 5 working days.

Takes effect as soon as you confirm.

A refund cannot be taken back. You can charge a new deposit from St Anne’s Scout Group’s record.

Source
<Kit.Phoenix.Roles.InlineConsequence.inline_consequence aria-label="Cancel Oakmere Primary School invoice">
  <:subject>Oakmere Primary School invoice</:subject>
  <:consequence>Cancelling this invoice removes the £240.00 amount due.</:consequence>
  <:effective_time>Takes effect as soon as you confirm.</:effective_time>
  <:correction_path>
    You can issue a replacement invoice from <a href="#role-inline-consequence">Oakmere Primary School’s record</a>.
  </:correction_path>
  <:action>
    <Kit.Phoenix.Roles.PrimaryAction.primary_action>
      Cancel invoice
    </Kit.Phoenix.Roles.PrimaryAction.primary_action>
  </:action>
</Kit.Phoenix.Roles.InlineConsequence.inline_consequence>
<p class="specimen-case-line">A consequence whose action cannot be taken yet.</p>
<Kit.Phoenix.Roles.InlineConsequence.inline_consequence aria-label="Cancel Oakmere Primary School invoice">
  <:subject>Oakmere Primary School invoice</:subject>
  <:consequence>Cancelling this invoice removes the £240.00 amount due.</:consequence>
  <:effective_time>Takes effect as soon as you confirm.</:effective_time>
  <:correction_path>You can issue a replacement invoice from <a href="#role-inline-consequence">Oakmere Primary School’s record</a>.</:correction_path>
  <:action><Kit.Phoenix.Roles.InertControl.inert_control action="primary-action" id="role-inline-consequence-cancel" words="Wait for the invoice to be checked before cancelling.">Cancel invoice</Kit.Phoenix.Roles.InertControl.inert_control></:action>
</Kit.Phoenix.Roles.InlineConsequence.inline_consequence>
<Kit.Phoenix.Roles.InlineConsequence.inline_consequence id="role-inline-consequence-empty-region" aria-label="Cancel Oakmere Primary School invoice">
  <:subject>Oakmere Primary School invoice</:subject>
  <:consequence>Cancelling this invoice removes the £240.00 amount due.</:consequence>
  <:effective_time>Takes effect as soon as you confirm.</:effective_time>
  <:correction_path><a :if={false} href="#role-inline-consequence">Oakmere Primary School’s record</a></:correction_path>
  <:action>
    <Kit.Phoenix.Roles.PrimaryAction.primary_action>Cancel invoice</Kit.Phoenix.Roles.PrimaryAction.primary_action>
  </:action>
</Kit.Phoenix.Roles.InlineConsequence.inline_consequence>
<p class="specimen-case-line">A consequence that sends an email shows it as its recipient will get it.</p>
<Kit.Phoenix.Roles.InlineConsequence.inline_consequence aria-label="Move Oakmere Primary School choir rehearsal">
  <:subject>Oakmere Primary School choir rehearsal</:subject>
  <:consequence>Moving the rehearsal to Thursday 6 February emails Aisha Khan the new time.</:consequence>
  <:outbound_preview>
    <Kit.Phoenix.Roles.OutboundPreview.outbound_preview>
      <:facts>
        <Kit.Phoenix.Roles.FactGroup.fact_group>
          <Kit.Phoenix.Roles.LabelledFact.labelled_fact>
            <:name>Channel</:name><:value>Email to <Kit.Phoenix.Email.email address="aisha@oakmereprimary.org" /></:value>
          </Kit.Phoenix.Roles.LabelledFact.labelled_fact>
          <Kit.Phoenix.Roles.LabelledFact.labelled_fact>
            <:name>Subject</:name><:value>Your rehearsal moves to Thursday 6 February</:value>
          </Kit.Phoenix.Roles.LabelledFact.labelled_fact>
        </Kit.Phoenix.Roles.FactGroup.fact_group>
      </:facts>
      <:email title="Your rehearsal moves to Thursday 6 February" document="<!doctype html><html lang=en><head><style>body{margin:0;padding:24px;font-family:Georgia,serif;color:#222222;background:#ffffff}h1{margin:0 0 16px;font-size:22px}p{margin:0 0 12px;font-size:15px;line-height:1.5}</style></head><body><h1>Your rehearsal has moved</h1><p>Hello Aisha,</p><p>The choir rehearsal on Tuesday 4 February now takes place on Thursday 6 February, 16:00 to 17:30, in the Garden room.</p><p>Oakmere Village Hall</p></body></html>" />
    </Kit.Phoenix.Roles.OutboundPreview.outbound_preview>
  </:outbound_preview>
  <:effective_time>Aisha is emailed as soon as you confirm.</:effective_time>
  <:correction_path>To change it after that, move it again. Aisha is emailed about that move too.</:correction_path>
  <:action>
    <Kit.Phoenix.Roles.PrimaryAction.primary_action>Move rehearsal</Kit.Phoenix.Roles.PrimaryAction.primary_action>
  </:action>
</Kit.Phoenix.Roles.InlineConsequence.inline_consequence>
<p class="specimen-case-line">A consequence that sends a text shows it as a phone shows it.</p>
<Kit.Phoenix.Roles.InlineConsequence.inline_consequence aria-label="Refund St Anne’s Scout Group deposit">
  <:subject>St Anne’s Scout Group deposit</:subject>
  <:consequence>Refunding the £50.00 deposit texts Priya Shah that it is on its way.</:consequence>
  <:outbound_preview>
    <Kit.Phoenix.Roles.OutboundPreview.outbound_preview>
      <:facts>
        <Kit.Phoenix.Roles.FactGroup.fact_group>
          <Kit.Phoenix.Roles.LabelledFact.labelled_fact>
            <:name>Channel</:name><:value>Text to 07700 900123</:value>
          </Kit.Phoenix.Roles.LabelledFact.labelled_fact>
        </Kit.Phoenix.Roles.FactGroup.fact_group>
      </:facts>
      <:text>Oakmere Village Hall: your £50.00 deposit for St Anne’s Scout Group is on its way back to you.
It reaches your account within 5 working days.</:text>
    </Kit.Phoenix.Roles.OutboundPreview.outbound_preview>
  </:outbound_preview>
  <:effective_time>Takes effect as soon as you confirm.</:effective_time>
  <:correction_path>
    A refund cannot be taken back. You can charge a new deposit from <a href="#role-inline-consequence">St Anne’s Scout Group’s record</a>.
  </:correction_path>
  <:action>
    <Kit.Phoenix.Roles.PrimaryAction.primary_action>Refund deposit</Kit.Phoenix.Roles.PrimaryAction.primary_action>
  </:action>
</Kit.Phoenix.Roles.InlineConsequence.inline_consequence>
<p class="specimen-case-line">A consequence that changes amounts holds each, before and after.</p>
<Kit.Phoenix.Roles.InlineConsequence.inline_consequence aria-label="Split the Autumn programme hire charge">
  <:subject>Autumn programme hire charge</:subject>
  <:consequence>Splitting the £180.00 charge across three payers changes what each one owes.</:consequence>
  <:amounts>
    <Kit.Phoenix.Table.comparison_table>
      <:caption>What each payer owes</:caption>
      <:subject_heading label="Payer" />
      <:column_headings label="Before" kind="amount">Before</:column_headings>
      <:column_headings label="After" kind="amount">After</:column_headings>
      <:row facts={[%Kit.Phoenix.Table.ComparisonCell{content: Kit.Phoenix.Table.Fact.words([Kit.Phoenix.Words.amount(Kit.Phoenix.Amount.money(reader(), Money.new(:GBP, "180.00")))])}, %Kit.Phoenix.Table.ComparisonCell{content: Kit.Phoenix.Table.Fact.words([Kit.Phoenix.Words.amount(Kit.Phoenix.Amount.money(reader(), Money.new(:GBP, "90.00")))])}]}>Oakmere Primary School</:row>
      <:row facts={[%Kit.Phoenix.Table.ComparisonCell{content: Kit.Phoenix.Table.Fact.words([Kit.Phoenix.Words.amount(Kit.Phoenix.Amount.money(reader(), Money.new(:GBP, "0.00")))])}, %Kit.Phoenix.Table.ComparisonCell{content: Kit.Phoenix.Table.Fact.words([Kit.Phoenix.Words.amount(Kit.Phoenix.Amount.money(reader(), Money.new(:GBP, "50.00")))])}]}>Oakmere WI</:row>
      <:row facts={[%Kit.Phoenix.Table.ComparisonCell{content: Kit.Phoenix.Table.Fact.words([Kit.Phoenix.Words.amount(Kit.Phoenix.Amount.money(reader(), Money.new(:GBP, "0.00")))])}, %Kit.Phoenix.Table.ComparisonCell{content: Kit.Phoenix.Table.Fact.words([Kit.Phoenix.Words.amount(Kit.Phoenix.Amount.money(reader(), Money.new(:GBP, "40.00")))])}]}>St Anne’s Scout Group</:row>
    </Kit.Phoenix.Table.comparison_table>
  </:amounts>
  <:effective_time>Takes effect as soon as you confirm.</:effective_time>
  <:correction_path>To change the split later, split the charge again from its record.</:correction_path>
  <:action>
    <Kit.Phoenix.Roles.PrimaryAction.primary_action>Split charge</Kit.Phoenix.Roles.PrimaryAction.primary_action>
  </:action>
</Kit.Phoenix.Roles.InlineConsequence.inline_consequence>
<p class="specimen-case-line">A consequence that changes amounts and sends a text holds the amounts, then the text.</p>
<Kit.Phoenix.Roles.InlineConsequence.inline_consequence aria-label="Refund St Anne’s Scout Group deposit">
  <:subject>St Anne’s Scout Group deposit</:subject>
  <:consequence>Refunding the £50.00 deposit texts Priya Shah that it is on its way.</:consequence>
  <:amounts>
    <Kit.Phoenix.Table.comparison_table>
      <:caption>The deposit before and after</:caption>
      <:subject_heading label="Deposit" />
      <:column_headings label="Before" kind="amount">Before</:column_headings>
      <:column_headings label="After" kind="amount">After</:column_headings>
      <:row facts={[%Kit.Phoenix.Table.ComparisonCell{content: Kit.Phoenix.Table.Fact.words([Kit.Phoenix.Words.amount(Kit.Phoenix.Amount.money(reader(), Money.new(:GBP, "50.00")))])}, %Kit.Phoenix.Table.ComparisonCell{content: Kit.Phoenix.Table.Fact.words([Kit.Phoenix.Words.amount(Kit.Phoenix.Amount.money(reader(), Money.new(:GBP, "0.00")))])}]}>Held</:row>
      <:row facts={[%Kit.Phoenix.Table.ComparisonCell{content: Kit.Phoenix.Table.Fact.words([Kit.Phoenix.Words.amount(Kit.Phoenix.Amount.money(reader(), Money.new(:GBP, "0.00")))])}, %Kit.Phoenix.Table.ComparisonCell{content: Kit.Phoenix.Table.Fact.words([Kit.Phoenix.Words.amount(Kit.Phoenix.Amount.money(reader(), Money.new(:GBP, "50.00")))])}]}>Refunded</:row>
    </Kit.Phoenix.Table.comparison_table>
  </:amounts>
  <:outbound_preview>
    <Kit.Phoenix.Roles.OutboundPreview.outbound_preview>
      <:facts>
        <Kit.Phoenix.Roles.FactGroup.fact_group>
          <Kit.Phoenix.Roles.LabelledFact.labelled_fact>
            <:name>Channel</:name><:value>Text to 07700 900123</:value>
          </Kit.Phoenix.Roles.LabelledFact.labelled_fact>
        </Kit.Phoenix.Roles.FactGroup.fact_group>
      </:facts>
      <:text>Oakmere Village Hall: your £50.00 deposit for St Anne’s Scout Group is on its way back to you.
It reaches your account within 5 working days.</:text>
    </Kit.Phoenix.Roles.OutboundPreview.outbound_preview>
  </:outbound_preview>
  <:effective_time>Takes effect as soon as you confirm.</:effective_time>
  <:correction_path>
    A refund cannot be taken back. You can charge a new deposit from <a href="#role-inline-consequence">St Anne’s Scout Group’s record</a>.
  </:correction_path>
  <:action>
    <Kit.Phoenix.Roles.PrimaryAction.primary_action>Refund deposit</Kit.Phoenix.Roles.PrimaryAction.primary_action>
  </:action>
</Kit.Phoenix.Roles.InlineConsequence.inline_consequence>