Accept flexible loan payloads and nest related info on lending responses.
Some checks failed
CI/CD / Vet, test, build (push) Has been cancelled
CI/CD / Docker image (push) Has been cancelled

Widen loan_orders.region in the init migration and share common relation helpers across loan APIs.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-08-26 13:06:06 +05:00
parent 0098422798
commit 6683826662
13 changed files with 591 additions and 346 deletions

View File

@@ -250,7 +250,7 @@ CREATE TABLE IF NOT EXISTS loan_orders (
source character varying(255) DEFAULT 'web'::character varying,
user_id bigint,
loan_type bigint NOT NULL,
region character varying(2) NOT NULL,
region character varying(255) NOT NULL,
branch_id bigint NOT NULL,
customer_name character varying(255) NOT NULL,
customer_surname character varying(255) NOT NULL,

View File

@@ -1,3 +0,0 @@
ALTER TABLE card_pin_orders
ALTER COLUMN region TYPE character varying(2)
USING LEFT(region, 2);

View File

@@ -1,2 +0,0 @@
ALTER TABLE card_pin_orders
ALTER COLUMN region TYPE character varying(255);