@axiosleo/orm-mysql 0.14.1 → 0.14.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/orm-mysql.js +1 -1
- package/package.json +1 -1
- package/src/builder.js +2 -2
- package/docker-compose.yml +0 -18
- package/pnpm-workspace.yaml +0 -5
package/bin/orm-mysql.js
CHANGED
package/package.json
CHANGED
package/src/builder.js
CHANGED
|
@@ -749,7 +749,7 @@ class ManageSQLBuilder extends Builder {
|
|
|
749
749
|
let str = `\`${options.name}\` ${type}`;
|
|
750
750
|
if (typeof options.length !== 'undefined') {
|
|
751
751
|
if (type === 'DECIMAL') {
|
|
752
|
-
str += `(${options.precision || 10}, ${options.length || 6})`;
|
|
752
|
+
str += `(${options.precision || 10}, ${options.scale || options.length || 6})`;
|
|
753
753
|
} else {
|
|
754
754
|
str += `(${options.length})`;
|
|
755
755
|
}
|
|
@@ -760,7 +760,7 @@ class ManageSQLBuilder extends Builder {
|
|
|
760
760
|
} else if (type === 'TINYINT') {
|
|
761
761
|
str += '(4)';
|
|
762
762
|
} else if (type === 'DECIMAL') {
|
|
763
|
-
str += `(${options.precision || 10}, ${options.length || 6})`;
|
|
763
|
+
str += `(${options.precision || 10}, ${options.scale || options.length || 6})`;
|
|
764
764
|
}
|
|
765
765
|
if (options.allowNull === false || options.primaryKey === true) {
|
|
766
766
|
str += ' NOT NULL';
|
package/docker-compose.yml
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
version: '3'
|
|
2
|
-
# Settings and configurations that are common for all containers
|
|
3
|
-
services:
|
|
4
|
-
mysql:
|
|
5
|
-
image: 'mysql:8.0'
|
|
6
|
-
container_name: "orm-feature-tests-mysql"
|
|
7
|
-
command: mysqld --default-authentication-plugin=mysql_native_password --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci
|
|
8
|
-
environment:
|
|
9
|
-
MYSQL_ROOT_PASSWORD: '3AQqZTfmww=Ftj'
|
|
10
|
-
MYSQL_DATABASE: 'feature_tests'
|
|
11
|
-
restart: 'always'
|
|
12
|
-
ports:
|
|
13
|
-
- "3306:3306"
|
|
14
|
-
healthcheck:
|
|
15
|
-
test: ["CMD", "mysqladmin", "ping", "-h", "localhost", "-uroot", "-p3AQqZTfmww=Ftj"]
|
|
16
|
-
interval: 5s
|
|
17
|
-
timeout: 3s
|
|
18
|
-
retries: 10
|