Skip to content
This repository has been archived by the owner on Jun 4, 2024. It is now read-only.

Commit

Permalink
Merge pull request #5 from SOHELAHMED7/115-default-in-openapi-schema-…
Browse files Browse the repository at this point in the history
…does-not-generate-migration-with-default-in-mariadb

Fix #115
  • Loading branch information
SOHELAHMED7 authored Dec 30, 2022
2 parents 86ae33d + 8c074a9 commit 512a11e
Show file tree
Hide file tree
Showing 11 changed files with 19 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function up()
7 => 'col_9 varchar(9) NULL DEFAULT NULL',
8 => 'col_10 varchar(10) NULL DEFAULT NULL',
9 => 'col_11 text NULL DEFAULT NULL',
10 => 'price decimal(10,2) NULL DEFAULT 0',
]);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function up()
7 => 'col_9 varchar(9) NULL DEFAULT NULL',
8 => 'col_10 varchar(10) NULL DEFAULT NULL',
9 => 'col_11 text NULL',
10 => 'price decimal(10,2) NULL DEFAULT 0',
]);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function safeUp()
7 => 'col_9 varchar NULL DEFAULT NULL',
8 => 'col_10 varchar NULL DEFAULT NULL',
9 => 'col_11 text NULL DEFAULT NULL',
10 => 'price decimal(10,2) NULL DEFAULT 0',
]);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function up()
7 => 'col_9 varchar(9) NULL DEFAULT NULL',
8 => 'col_10 varchar(10) NULL DEFAULT NULL',
9 => 'col_11 text NULL DEFAULT NULL',
10 => 'price decimal(10,2) NULL DEFAULT 0',
]);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function up()
7 => 'col_9 varchar(9) NULL DEFAULT NULL',
8 => 'col_10 varchar(10) NULL DEFAULT NULL',
9 => 'col_11 text NULL',
10 => 'price decimal(10,2) NULL DEFAULT 0',
]);
}

Expand Down
5 changes: 5 additions & 0 deletions tests/specs/x_db_type/fresh/mysql/x_db_type_mysql.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,11 @@ components:
col_11:
type: string
x-db-type: TEXT
price:
description: price in EUR
type: number
x-db-type: decimal(10,2)
default: 0


Alldbdatatype: # All DB data type
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function safeUp()
7 => 'col_9 varchar NULL DEFAULT NULL',
8 => 'col_10 varchar NULL DEFAULT NULL',
9 => 'col_11 text NULL DEFAULT NULL',
10 => 'price decimal(10,2) NULL DEFAULT 0',
]);
}

Expand Down
5 changes: 5 additions & 0 deletions tests/specs/x_db_type/fresh/pgsql/x_db_type_pgsql.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,11 @@ components:
col_11:
type: string
x-db-type: TEXT
price:
description: price in EUR
type: number
x-db-type: decimal(10,2)
default: 0


Alldbdatatype: # All DB data type
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function up()
7 => 'col_9 varchar(9) NULL DEFAULT NULL',
8 => 'col_10 varchar(10) NULL DEFAULT NULL',
9 => 'col_11 text NULL DEFAULT NULL',
10 => 'price decimal(10,2) NULL DEFAULT 0',
]);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function up()
7 => 'col_9 varchar(9) NULL DEFAULT NULL',
8 => 'col_10 varchar(10) NULL DEFAULT NULL',
9 => 'col_11 text NULL',
10 => 'price decimal(10,2) NULL DEFAULT 0',
]);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function safeUp()
7 => 'col_9 varchar NULL DEFAULT NULL',
8 => 'col_10 varchar NULL DEFAULT NULL',
9 => 'col_11 text NULL DEFAULT NULL',
10 => 'price decimal(10,2) NULL DEFAULT 0',
]);
}

Expand Down

0 comments on commit 512a11e

Please sign in to comment.