-
Notifications
You must be signed in to change notification settings - Fork 2
Hdpi 3764 income expenditure frontend #989
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
4388591
d6866fd
9ba67c9
34c61f8
e1e2c62
3b08446
42e5d57
ae01f5f
9fa0a5a
e30d7ed
292ff60
69693e4
96bcf8a
493dbca
28f2fd5
77e39b9
6df27ab
71be550
8cce697
c08adaf
b27c92c
5d07c1c
aeefb8e
39cc693
f401783
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| { | ||
| "caption": "cyResponding to the possession claim", | ||
| "pageTitle": "cyIncome and expenses", | ||
| "infoParagraph1": "cyDetails about your income and expenses can be used by a judge to reach a decision on your case, and also to decide how much you could afford to repay if you have rent arrears.", | ||
| "infoParagraph2": "cyOn the day of the hearing, there may be a duty adviser at the court who can give you advice and represent you for free. They can also use this information to see if there's any additional benefits or support you might be entitled to.", | ||
| "infoParagraph3": "cyThe claimant will be able to see your answers.", | ||
| "question": "cyDo you want to provide details of your income and expenses?", | ||
| "options": { | ||
| "yes": "cyYes", | ||
| "no": "cyNo" | ||
| }, | ||
| "errors": { | ||
| "provideFinanceDetails": "cySelect if you want to provide details of your income and expenses" | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,60 @@ | ||
| { | ||
| "caption": "cyRespond to a property possession claim", | ||
| "pageTitle": "cyWhat regular income do you receive? (Optional)", | ||
| "hintText": "cySelect all that apply. Enter total amount in pounds and pence, for example £148.00 or £148.50. The information you provide must be truthful and accurate.", | ||
| "options": { | ||
| "incomeFromJobs": "cyIncome from all jobs you do", | ||
| "pension": "cyPension – state and private", | ||
| "universalCredit": "cyUniversal Credit", | ||
| "otherBenefits": "cyOther benefits and credits", | ||
| "moneyFromElsewhere": "cyMoney from somewhere else (for example, child maintenance payments or someone in your household gives you money)" | ||
| }, | ||
| "subFields": { | ||
| "amount": "cyTotal amount received", | ||
| "frequency": "cyReceived every:", | ||
| "moneyFromElsewhereDetailsLabel": "cyGive details", | ||
| "moneyFromElsewhereDetailsHint": "cyGive details about the other sources of income and how much you usually receive" | ||
| }, | ||
| "frequency": { | ||
| "week": "cyWeek", | ||
| "month": "cyMonth" | ||
| }, | ||
| "errors": { | ||
| "incomeFromJobsAmount": { | ||
| "required": "cyEnter the total amount you receive from all jobs you do", | ||
| "largeAmount": "cyThe total amount you receive from all jobs you do each week or month must be less than £1 billion" | ||
| }, | ||
| "incomeFromJobsFrequency": { | ||
| "required": "cySelect how frequently you receive income from all jobs you do" | ||
| }, | ||
| "pensionAmount": { | ||
| "required": "cyEnter the total amount you receive from a state or private pension", | ||
| "largeAmount": "cyThe total amount you receive from pension (state and private) each week or month must be less than £1 billion" | ||
| }, | ||
| "pensionFrequency": { | ||
| "required": "cySelect how frequently you receive income from a state or private pension" | ||
| }, | ||
| "universalCreditAmount": { | ||
| "required": "cyEnter the total amount you receive from Universal Credit", | ||
| "largeAmount": "cyThe total amount you receive from Universal Credit each week or month must be less than £1 billion" | ||
| }, | ||
| "universalCreditFrequency": { | ||
| "required": "cySelect how frequently you receive Universal Credit" | ||
| }, | ||
| "otherBenefitsAmount": { | ||
| "required": "cyEnter the total amount you receive from other benefits and credits", | ||
| "largeAmount": "cyThe total amount you receive from other benefits and credit each week or month must be less than £1 billion" | ||
| }, | ||
| "otherBenefitsFrequency": { | ||
| "required": "cySelect how frequently you receive income from other benefits and credits" | ||
| }, | ||
| "moneyFromElsewhereDetails": { | ||
| "required": "cyGive details about the other sources of income and how much you usually receive" | ||
| }, | ||
| "amount": { | ||
| "negative": "cyAmount cannot be negative", | ||
| "tooLarge": "cyAmount is too large", | ||
| "invalidFormat": "cyEnter amount in pounds and pence, for example 148.00 or 148.50" | ||
| } | ||
| } | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| { | ||
| "caption": "Responding to the possession claim", | ||
| "pageTitle": "Income and expenses", | ||
| "infoParagraph1": "Details about your income and expenses can be used by a judge to reach a decision on your case, and also to decide how much you could afford to repay if you have rent arrears.", | ||
| "infoParagraph2": "On the day of the hearing, there may be a duty adviser at the court who can give you advice and represent you for free. They can also use this information to see if there's any additional benefits or support you might be entitled to.", | ||
| "infoParagraph3": "The claimant will be able to see your answers.", | ||
| "question": "Do you want to provide details of your income and expenses?", | ||
| "options": { | ||
| "yes": "Yes", | ||
| "no": "No" | ||
| }, | ||
| "errors": { | ||
| "provideFinanceDetails": "Select if you want to provide details of your income and expenses" | ||
| } | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,60 @@ | ||
| { | ||
| "caption": "Respond to a property possession claim", | ||
| "pageTitle": "What regular income do you receive? (Optional)", | ||
| "hintText": "Select all that apply. Enter total amount in pounds and pence, for example £148.00 or £148.50. The information you provide must be truthful and accurate.", | ||
| "options": { | ||
| "incomeFromJobs": "Income from all jobs you do", | ||
| "pension": "Pension – state and private", | ||
| "universalCredit": "Universal Credit", | ||
| "otherBenefits": "Other benefits and credits", | ||
| "moneyFromElsewhere": "Money from somewhere else (for example, child maintenance payments or someone in your household gives you money)" | ||
| }, | ||
| "subFields": { | ||
| "amount": "Total amount received", | ||
| "frequency": "Received every:", | ||
| "moneyFromElsewhereDetailsLabel": "Give details", | ||
| "moneyFromElsewhereDetailsHint": "Give details about the other sources of income and how much you usually receive" | ||
| }, | ||
| "frequency": { | ||
| "week": "Week", | ||
| "month": "Month" | ||
| }, | ||
| "errors": { | ||
| "incomeFromJobsAmount": { | ||
| "required": "Enter the total amount you receive from all jobs you do", | ||
| "largeAmount": "The total amount you receive from all jobs you do each week or month must be less than £1 billion" | ||
| }, | ||
| "incomeFromJobsFrequency": { | ||
| "required": "Select how frequently you receive income from all jobs you do" | ||
| }, | ||
| "pensionAmount": { | ||
| "required": "Enter the total amount you receive from a state or private pension", | ||
| "largeAmount": "The total amount you receive from pension (state and private) each week or month must be less than £1 billion" | ||
| }, | ||
| "pensionFrequency": { | ||
| "required": "Select how frequently you receive income from a state or private pension" | ||
| }, | ||
| "universalCreditAmount": { | ||
| "required": "Enter the total amount you receive from Universal Credit", | ||
| "largeAmount": "The total amount you receive from Universal Credit each week or month must be less than £1 billion" | ||
| }, | ||
| "universalCreditFrequency": { | ||
| "required": "Select how frequently you receive Universal Credit" | ||
| }, | ||
| "otherBenefitsAmount": { | ||
| "required": "Enter the total amount you receive from other benefits and credits", | ||
| "largeAmount": "The total amount you receive from other benefits and credit each week or month must be less than £1 billion" | ||
| }, | ||
| "otherBenefitsFrequency": { | ||
| "required": "Select how frequently you receive income from other benefits and credits" | ||
| }, | ||
| "moneyFromElsewhereDetails": { | ||
| "required": "Give details about the other sources of income and how much you usually receive" | ||
| }, | ||
| "amount": { | ||
| "negative": "Amount cannot be negative", | ||
| "tooLarge": "Amount is too large", | ||
| "invalidFormat": "Enter amount in pounds and pence, for example 148.00 or 148.50" | ||
| } | ||
| } | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| /** | ||
| * Validation constants for income and expenditure forms. | ||
| * Shared across all income/expense related steps. | ||
| */ | ||
|
|
||
| /** Maximum income/expense amount: £1 billion in pence */ | ||
| export const MAX_INCOME_AMOUNT = 1_000_000_000; | ||
|
|
||
| /** Amount format: up to 10 digits, exactly 2 decimal places */ | ||
| export const AMOUNT_FORMAT_REGEX = /^\d{1,10}\.\d{2}$/; |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,12 +3,15 @@ export enum CaseState { | |
| SUBMITTED = 'Submitted', | ||
| } | ||
|
|
||
| export type YesNoValue = 'YES' | 'NO' | null; | ||
| export type YesNoValue = 'Yes' | 'No' | null; | ||
| export type TenancyTypeCorrectValue = YesNoValue | 'NOT_SURE'; | ||
| export type ContactPreference = 'EMAIL' | 'POST' | null; | ||
|
|
||
| export type YesNoNotSureValue = 'YES' | 'NO' | 'NOT_SURE'; | ||
|
|
||
| export type FrequencyValue = 'WEEKLY' | 'MONTHLY'; | ||
| export type PenceAmount = string; | ||
|
|
||
| export interface CcdUserCase { | ||
| id: string; | ||
| state: CaseState; | ||
|
|
@@ -37,6 +40,25 @@ export interface Address { | |
| Country?: string; | ||
| } | ||
|
|
||
| export interface HouseholdCircumstances { | ||
| shareIncomeExpenseDetails?: YesNoValue; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. These HouseHoldCirumstances fields should match the backend entity/domain and match the "Yes"/"No" values. I've changed this on my PR already here
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. resolved now |
||
| incomeFromJobs?: YesNoValue; | ||
| incomeFromJobsAmount?: PenceAmount; | ||
| incomeFromJobsFrequency?: FrequencyValue; | ||
| pension?: YesNoValue; | ||
| pensionAmount?: PenceAmount; | ||
| pensionFrequency?: FrequencyValue; | ||
| universalCredit?: YesNoValue; | ||
| universalCreditAmount?: PenceAmount; | ||
| universalCreditFrequency?: FrequencyValue; | ||
| ucApplicationDate?: string; | ||
| otherBenefits?: YesNoValue; | ||
| otherBenefitsAmount?: PenceAmount; | ||
| otherBenefitsFrequency?: FrequencyValue; | ||
| moneyFromElsewhere?: YesNoValue; | ||
| moneyFromElsewhereDetails?: string; | ||
| } | ||
|
|
||
| export interface PossessionClaimResponse { | ||
| defendantContactDetails?: { | ||
| party?: { | ||
|
|
@@ -61,6 +83,7 @@ export interface PossessionClaimResponse { | |
| dateOfBirth?: string; | ||
| landlordRegistered?: YesNoNotSureValue; | ||
| landlordLicensed?: YesNoNotSureValue; | ||
| householdCircumstances?: HouseholdCircumstances; | ||
| }; | ||
| } | ||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.