chore: perauset customer project

This commit is contained in:
e2e
2026-07-11 08:35:17 +02:00
commit 37eea09bf0
293 changed files with 28412 additions and 0 deletions

View File

@@ -0,0 +1,38 @@
import { When } from '@cucumber/cucumber'
import type { PerausetWorld } from '../support/world.js'
When('I create a finance record {string} with amount {int} and type {string}', async function (this: PerausetWorld, name: string, amount: number, recordType: string) {
await this.post('/finance', {
name,
amount,
recordType,
category: 'operations',
})
})
When('I list finance records', async function (this: PerausetWorld) {
await this.get('/finance')
})
When('I update the finance record with name {string}', async function (this: PerausetWorld, name: string) {
const financeId = (this as any).financeId
await this.put(`/finance/${financeId}`, {
financeId,
name,
})
})
When('I link the finance record to entity type {string}', async function (this: PerausetWorld, entityType: string) {
const financeId = (this as any).financeId
const entityId = (this as any).itemId
await this.post('/finance/links', {
financeId,
entityType,
entityId,
})
})
When('I list finance links for the current finance record', async function (this: PerausetWorld) {
const financeId = (this as any).financeId
await this.get(`/finance/links?financeId=${financeId}`)
})