Create type discount_usage (#476)
* Create type discount_usage * Add discount_codes.discount_usage_type * Fix SQL * Make query idempotent * Bump revision
This commit is contained in:
@@ -0,0 +1,14 @@
|
|||||||
|
ALTER TABLE discount_codes
|
||||||
|
DROP COLUMN IF EXISTS discount_usage_type;
|
||||||
|
|
||||||
|
DROP TYPE IF EXISTS discount_usage;
|
||||||
|
|
||||||
|
CREATE TYPE discount_usage AS ENUM (
|
||||||
|
'default',
|
||||||
|
'influencer',
|
||||||
|
'customer service',
|
||||||
|
'internal'
|
||||||
|
);
|
||||||
|
|
||||||
|
ALTER TABLE discount_codes
|
||||||
|
ADD COLUMN discount_usage_type discount_usage NOT NULL DEFAULT 'default';
|
||||||
Reference in New Issue
Block a user