Put the user's role and branch on GET /profile, upsert role_user and branch_user on POST, and drop their list endpoints.
Also accept flexible card-order form values, move mock seed under db/mock, and regenerate Swagger. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
7225dc0399
commit
8795ae2195
47 files changed
+1308
-1785
No files matched your search
@@ -47,6 +47,10 @@ CREATE TABLE IF NOT EXISTS roles (
|
||||
updated_at TIMESTAMP DEFAULT (CURRENT_TIMESTAMP AT TIME ZONE 'UTC') NOT NULL
|
||||
);
|
||||
|
||||
INSERT INTO roles (code, name, guard_name)
|
||||
SELECT 'user', 'User', 'web'
|
||||
WHERE NOT EXISTS (SELECT 1 FROM roles WHERE code = 'user');
|
||||
|
||||
CREATE TABLE IF NOT EXISTS permissions (
|
||||
id bigserial PRIMARY KEY,
|
||||
code character varying(255) NOT NULL DEFAULT '',
|
||||
@@ -174,7 +178,7 @@ CREATE TABLE IF NOT EXISTS card_orders (
|
||||
unique_id character varying(255),
|
||||
card_state_id bigint NOT NULL,
|
||||
card_type_id 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,
|
||||
|
||||
Reference in new issue
Block a user