@admc-go-th/admc-library 1.0.42 → 1.0.43
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/databases/schema/mdEbook.ts +6 -1
- package/databases/schema/mdEbookGroup.ts +7 -1
- package/databases/tables/index.d.ts +1 -2
- package/databases/tables/index.js +116 -105
- package/databases/tables/mdEbook.d.ts +2 -54
- package/databases/tables/mdEbook.js +138 -44
- package/databases/tables/mdEbookGroup.d.ts +2 -30
- package/databases/tables/mdEbookGroup.js +187 -14
- package/mdEbook-C-qae2zR.d.ts +83 -0
- package/package.json +1 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
|
-
Model, Table, Column, DataType, Index, Sequelize, ForeignKey
|
|
2
|
+
Model, Table, Column, DataType, Index, Sequelize, ForeignKey, BelongsTo
|
|
3
3
|
} from "sequelize-typescript";
|
|
4
|
+
import { mdEbookGroup } from "./mdEbookGroup";
|
|
4
5
|
|
|
5
6
|
export interface mdEbookAttributes {
|
|
6
7
|
id?: number;
|
|
@@ -53,6 +54,7 @@ export class mdEbook extends Model<mdEbookAttributes, mdEbookAttributes> impleme
|
|
|
53
54
|
})
|
|
54
55
|
declare keyName?: string;
|
|
55
56
|
|
|
57
|
+
@ForeignKey(() => mdEbookGroup)
|
|
56
58
|
@Column({
|
|
57
59
|
field: "group_id",
|
|
58
60
|
allowNull: true,
|
|
@@ -185,4 +187,7 @@ export class mdEbook extends Model<mdEbookAttributes, mdEbookAttributes> impleme
|
|
|
185
187
|
})
|
|
186
188
|
declare updatedDate?: Date;
|
|
187
189
|
|
|
190
|
+
@BelongsTo(() => mdEbookGroup)
|
|
191
|
+
declare mdEbookGroup?: mdEbookGroup;
|
|
192
|
+
|
|
188
193
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
|
-
Model, Table, Column, DataType, Index, Sequelize, ForeignKey
|
|
2
|
+
Model, Table, Column, DataType, Index, Sequelize, ForeignKey, HasMany
|
|
3
3
|
} from "sequelize-typescript";
|
|
4
|
+
import { mdEbook } from "./mdEbook";
|
|
4
5
|
|
|
5
6
|
export interface mdEbookGroupAttributes {
|
|
6
7
|
id?: number;
|
|
@@ -94,4 +95,9 @@ export class mdEbookGroup extends Model<mdEbookGroupAttributes, mdEbookGroupAttr
|
|
|
94
95
|
})
|
|
95
96
|
declare updatedDate?: Date;
|
|
96
97
|
|
|
98
|
+
@HasMany(() => mdEbook, {
|
|
99
|
+
sourceKey: "id"
|
|
100
|
+
})
|
|
101
|
+
declare mdEbooks?: mdEbook[];
|
|
102
|
+
|
|
97
103
|
}
|
|
@@ -4,8 +4,7 @@ export { a as files, f as filesAttributes, b as mdBanner, m as mdBannerAttribute
|
|
|
4
4
|
export { mdCmsSingle, mdCmsSingleAttributes } from './mdCmsSingle.js';
|
|
5
5
|
export { mdDocumentPdf, mdDocumentPdfAttributes } from './mdDocumentPdf.js';
|
|
6
6
|
export { mdDownload, mdDownloadAttributes } from './mdDownload.js';
|
|
7
|
-
export { mdEbook, mdEbookAttributes } from '
|
|
8
|
-
export { mdEbookGroup, mdEbookGroupAttributes } from './mdEbookGroup.js';
|
|
7
|
+
export { a as mdEbook, m as mdEbookAttributes, c as mdEbookGroup, b as mdEbookGroupAttributes } from '../../mdEbook-C-qae2zR.js';
|
|
9
8
|
export { a as mdFaq, m as mdFaqAttributes, c as mdFaqGroup, b as mdFaqGroupAttributes } from '../../mdFaq-1c4X_DI2.js';
|
|
10
9
|
export { mdLink, mdLinkAttributes } from './mdLink.js';
|
|
11
10
|
export { a as mdNews, m as mdNewsAttributes, c as mdNewsGroup, b as mdNewsGroupAttributes } from '../../mdNews-CYzk8W_D.js';
|
|
@@ -1821,8 +1821,11 @@ mdDownload = __decorateClass([
|
|
|
1821
1821
|
], mdDownload);
|
|
1822
1822
|
|
|
1823
1823
|
// src/databases/tables/mdEbook.ts
|
|
1824
|
+
var import_sequelize_typescript19 = require("sequelize-typescript");
|
|
1825
|
+
|
|
1826
|
+
// src/databases/tables/mdEbookGroup.ts
|
|
1824
1827
|
var import_sequelize_typescript18 = require("sequelize-typescript");
|
|
1825
|
-
var
|
|
1828
|
+
var mdEbookGroup = class extends import_sequelize_typescript18.Model {
|
|
1826
1829
|
};
|
|
1827
1830
|
__decorateClass([
|
|
1828
1831
|
(0, import_sequelize_typescript18.Column)({
|
|
@@ -1830,240 +1833,248 @@ __decorateClass([
|
|
|
1830
1833
|
autoIncrement: true,
|
|
1831
1834
|
type: import_sequelize_typescript18.DataType.INTEGER
|
|
1832
1835
|
})
|
|
1833
|
-
],
|
|
1836
|
+
], mdEbookGroup.prototype, "id", 2);
|
|
1834
1837
|
__decorateClass([
|
|
1835
1838
|
(0, import_sequelize_typescript18.Column)({
|
|
1839
|
+
allowNull: true,
|
|
1836
1840
|
type: import_sequelize_typescript18.DataType.STRING(60)
|
|
1837
1841
|
})
|
|
1838
|
-
],
|
|
1842
|
+
], mdEbookGroup.prototype, "uuid", 2);
|
|
1839
1843
|
__decorateClass([
|
|
1840
1844
|
(0, import_sequelize_typescript18.Column)({
|
|
1841
1845
|
field: "key_name",
|
|
1842
1846
|
allowNull: true,
|
|
1843
1847
|
type: import_sequelize_typescript18.DataType.STRING(100)
|
|
1844
1848
|
})
|
|
1845
|
-
],
|
|
1849
|
+
], mdEbookGroup.prototype, "keyName", 2);
|
|
1846
1850
|
__decorateClass([
|
|
1847
1851
|
(0, import_sequelize_typescript18.Column)({
|
|
1848
|
-
field: "
|
|
1852
|
+
field: "user_id",
|
|
1849
1853
|
allowNull: true,
|
|
1850
1854
|
type: import_sequelize_typescript18.DataType.INTEGER
|
|
1851
1855
|
})
|
|
1852
|
-
],
|
|
1856
|
+
], mdEbookGroup.prototype, "userId", 2);
|
|
1853
1857
|
__decorateClass([
|
|
1854
1858
|
(0, import_sequelize_typescript18.Column)({
|
|
1855
|
-
|
|
1856
|
-
type: import_sequelize_typescript18.DataType.INTEGER
|
|
1859
|
+
type: import_sequelize_typescript18.DataType.STRING(255)
|
|
1857
1860
|
})
|
|
1858
|
-
],
|
|
1861
|
+
], mdEbookGroup.prototype, "name", 2);
|
|
1859
1862
|
__decorateClass([
|
|
1860
1863
|
(0, import_sequelize_typescript18.Column)({
|
|
1861
1864
|
allowNull: true,
|
|
1862
1865
|
type: import_sequelize_typescript18.DataType.STRING(255)
|
|
1863
1866
|
})
|
|
1864
|
-
],
|
|
1867
|
+
], mdEbookGroup.prototype, "description", 2);
|
|
1865
1868
|
__decorateClass([
|
|
1866
1869
|
(0, import_sequelize_typescript18.Column)({
|
|
1867
1870
|
allowNull: true,
|
|
1868
|
-
type: import_sequelize_typescript18.DataType.
|
|
1871
|
+
type: import_sequelize_typescript18.DataType.INTEGER
|
|
1869
1872
|
})
|
|
1870
|
-
],
|
|
1873
|
+
], mdEbookGroup.prototype, "status", 2);
|
|
1871
1874
|
__decorateClass([
|
|
1872
1875
|
(0, import_sequelize_typescript18.Column)({
|
|
1876
|
+
field: "created_by",
|
|
1873
1877
|
allowNull: true,
|
|
1874
|
-
type: import_sequelize_typescript18.DataType.STRING
|
|
1878
|
+
type: import_sequelize_typescript18.DataType.STRING(60)
|
|
1875
1879
|
})
|
|
1876
|
-
],
|
|
1880
|
+
], mdEbookGroup.prototype, "createdBy", 2);
|
|
1877
1881
|
__decorateClass([
|
|
1878
1882
|
(0, import_sequelize_typescript18.Column)({
|
|
1879
|
-
field: "
|
|
1883
|
+
field: "created_date",
|
|
1880
1884
|
allowNull: true,
|
|
1881
|
-
type: import_sequelize_typescript18.DataType.
|
|
1885
|
+
type: import_sequelize_typescript18.DataType.DATE
|
|
1882
1886
|
})
|
|
1883
|
-
],
|
|
1887
|
+
], mdEbookGroup.prototype, "createdDate", 2);
|
|
1884
1888
|
__decorateClass([
|
|
1885
1889
|
(0, import_sequelize_typescript18.Column)({
|
|
1886
|
-
field: "
|
|
1890
|
+
field: "updated_by",
|
|
1887
1891
|
allowNull: true,
|
|
1888
|
-
type: import_sequelize_typescript18.DataType.STRING(
|
|
1892
|
+
type: import_sequelize_typescript18.DataType.STRING(60)
|
|
1889
1893
|
})
|
|
1890
|
-
],
|
|
1894
|
+
], mdEbookGroup.prototype, "updatedBy", 2);
|
|
1891
1895
|
__decorateClass([
|
|
1892
1896
|
(0, import_sequelize_typescript18.Column)({
|
|
1893
|
-
field: "
|
|
1897
|
+
field: "updated_date",
|
|
1894
1898
|
allowNull: true,
|
|
1895
|
-
type: import_sequelize_typescript18.DataType.
|
|
1899
|
+
type: import_sequelize_typescript18.DataType.DATE
|
|
1896
1900
|
})
|
|
1897
|
-
],
|
|
1901
|
+
], mdEbookGroup.prototype, "updatedDate", 2);
|
|
1898
1902
|
__decorateClass([
|
|
1899
|
-
(0, import_sequelize_typescript18.
|
|
1900
|
-
|
|
1901
|
-
allowNull: true,
|
|
1902
|
-
type: import_sequelize_typescript18.DataType.STRING(60)
|
|
1903
|
+
(0, import_sequelize_typescript18.HasMany)(() => mdEbook, {
|
|
1904
|
+
sourceKey: "id"
|
|
1903
1905
|
})
|
|
1904
|
-
],
|
|
1906
|
+
], mdEbookGroup.prototype, "mdEbooks", 2);
|
|
1907
|
+
mdEbookGroup = __decorateClass([
|
|
1908
|
+
(0, import_sequelize_typescript18.Table)({
|
|
1909
|
+
tableName: "md_ebook_group",
|
|
1910
|
+
timestamps: false
|
|
1911
|
+
})
|
|
1912
|
+
], mdEbookGroup);
|
|
1913
|
+
|
|
1914
|
+
// src/databases/tables/mdEbook.ts
|
|
1915
|
+
var mdEbook = class extends import_sequelize_typescript19.Model {
|
|
1916
|
+
};
|
|
1905
1917
|
__decorateClass([
|
|
1906
|
-
(0,
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
type:
|
|
1918
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1919
|
+
primaryKey: true,
|
|
1920
|
+
autoIncrement: true,
|
|
1921
|
+
type: import_sequelize_typescript19.DataType.INTEGER
|
|
1910
1922
|
})
|
|
1911
|
-
], mdEbook.prototype, "
|
|
1923
|
+
], mdEbook.prototype, "id", 2);
|
|
1912
1924
|
__decorateClass([
|
|
1913
|
-
(0,
|
|
1914
|
-
|
|
1915
|
-
type: import_sequelize_typescript18.DataType.JSON
|
|
1925
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1926
|
+
type: import_sequelize_typescript19.DataType.STRING(60)
|
|
1916
1927
|
})
|
|
1917
|
-
], mdEbook.prototype, "
|
|
1928
|
+
], mdEbook.prototype, "uuid", 2);
|
|
1918
1929
|
__decorateClass([
|
|
1919
|
-
(0,
|
|
1930
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1931
|
+
field: "key_name",
|
|
1920
1932
|
allowNull: true,
|
|
1921
|
-
type:
|
|
1933
|
+
type: import_sequelize_typescript19.DataType.STRING(100)
|
|
1922
1934
|
})
|
|
1923
|
-
], mdEbook.prototype, "
|
|
1935
|
+
], mdEbook.prototype, "keyName", 2);
|
|
1924
1936
|
__decorateClass([
|
|
1925
|
-
(0,
|
|
1937
|
+
(0, import_sequelize_typescript19.ForeignKey)(() => mdEbookGroup),
|
|
1938
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1939
|
+
field: "group_id",
|
|
1926
1940
|
allowNull: true,
|
|
1927
|
-
type:
|
|
1941
|
+
type: import_sequelize_typescript19.DataType.INTEGER
|
|
1928
1942
|
})
|
|
1929
|
-
], mdEbook.prototype, "
|
|
1943
|
+
], mdEbook.prototype, "groupId", 2);
|
|
1930
1944
|
__decorateClass([
|
|
1931
|
-
(0,
|
|
1932
|
-
field: "
|
|
1933
|
-
type:
|
|
1945
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1946
|
+
field: "user_id",
|
|
1947
|
+
type: import_sequelize_typescript19.DataType.INTEGER
|
|
1934
1948
|
})
|
|
1935
|
-
], mdEbook.prototype, "
|
|
1949
|
+
], mdEbook.prototype, "userId", 2);
|
|
1936
1950
|
__decorateClass([
|
|
1937
|
-
(0,
|
|
1938
|
-
field: "start_date",
|
|
1951
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1939
1952
|
allowNull: true,
|
|
1940
|
-
type:
|
|
1953
|
+
type: import_sequelize_typescript19.DataType.STRING(255)
|
|
1941
1954
|
})
|
|
1942
|
-
], mdEbook.prototype, "
|
|
1955
|
+
], mdEbook.prototype, "title", 2);
|
|
1943
1956
|
__decorateClass([
|
|
1944
|
-
(0,
|
|
1945
|
-
field: "expire_date",
|
|
1957
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1946
1958
|
allowNull: true,
|
|
1947
|
-
type:
|
|
1959
|
+
type: import_sequelize_typescript19.DataType.STRING
|
|
1948
1960
|
})
|
|
1949
|
-
], mdEbook.prototype, "
|
|
1961
|
+
], mdEbook.prototype, "description", 2);
|
|
1950
1962
|
__decorateClass([
|
|
1951
|
-
(0,
|
|
1952
|
-
field: "created_by",
|
|
1963
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1953
1964
|
allowNull: true,
|
|
1954
|
-
type:
|
|
1965
|
+
type: import_sequelize_typescript19.DataType.STRING
|
|
1955
1966
|
})
|
|
1956
|
-
], mdEbook.prototype, "
|
|
1967
|
+
], mdEbook.prototype, "detail", 2);
|
|
1957
1968
|
__decorateClass([
|
|
1958
|
-
(0,
|
|
1959
|
-
field: "
|
|
1969
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1970
|
+
field: "meta_title",
|
|
1960
1971
|
allowNull: true,
|
|
1961
|
-
type:
|
|
1972
|
+
type: import_sequelize_typescript19.DataType.STRING(255)
|
|
1962
1973
|
})
|
|
1963
|
-
], mdEbook.prototype, "
|
|
1974
|
+
], mdEbook.prototype, "metaTitle", 2);
|
|
1964
1975
|
__decorateClass([
|
|
1965
|
-
(0,
|
|
1966
|
-
field: "
|
|
1976
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1977
|
+
field: "meta_keyword",
|
|
1967
1978
|
allowNull: true,
|
|
1968
|
-
type:
|
|
1979
|
+
type: import_sequelize_typescript19.DataType.STRING(255)
|
|
1969
1980
|
})
|
|
1970
|
-
], mdEbook.prototype, "
|
|
1981
|
+
], mdEbook.prototype, "metaKeyword", 2);
|
|
1971
1982
|
__decorateClass([
|
|
1972
|
-
(0,
|
|
1973
|
-
field: "
|
|
1983
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1984
|
+
field: "meta_description",
|
|
1974
1985
|
allowNull: true,
|
|
1975
|
-
type:
|
|
1986
|
+
type: import_sequelize_typescript19.DataType.STRING(255)
|
|
1976
1987
|
})
|
|
1977
|
-
], mdEbook.prototype, "
|
|
1978
|
-
|
|
1979
|
-
(0,
|
|
1980
|
-
|
|
1981
|
-
|
|
1988
|
+
], mdEbook.prototype, "metaDescription", 2);
|
|
1989
|
+
__decorateClass([
|
|
1990
|
+
(0, import_sequelize_typescript19.Column)({
|
|
1991
|
+
field: "image_cover",
|
|
1992
|
+
allowNull: true,
|
|
1993
|
+
type: import_sequelize_typescript19.DataType.STRING(60)
|
|
1982
1994
|
})
|
|
1983
|
-
], mdEbook);
|
|
1984
|
-
|
|
1985
|
-
// src/databases/tables/mdEbookGroup.ts
|
|
1986
|
-
var import_sequelize_typescript19 = require("sequelize-typescript");
|
|
1987
|
-
var mdEbookGroup = class extends import_sequelize_typescript19.Model {
|
|
1988
|
-
};
|
|
1995
|
+
], mdEbook.prototype, "imageCover", 2);
|
|
1989
1996
|
__decorateClass([
|
|
1990
1997
|
(0, import_sequelize_typescript19.Column)({
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
type: import_sequelize_typescript19.DataType.
|
|
1998
|
+
field: "image_gallery",
|
|
1999
|
+
allowNull: true,
|
|
2000
|
+
type: import_sequelize_typescript19.DataType.JSON
|
|
1994
2001
|
})
|
|
1995
|
-
],
|
|
2002
|
+
], mdEbook.prototype, "imageGallery", 2);
|
|
1996
2003
|
__decorateClass([
|
|
1997
2004
|
(0, import_sequelize_typescript19.Column)({
|
|
1998
2005
|
allowNull: true,
|
|
1999
|
-
type: import_sequelize_typescript19.DataType.
|
|
2006
|
+
type: import_sequelize_typescript19.DataType.JSON
|
|
2000
2007
|
})
|
|
2001
|
-
],
|
|
2008
|
+
], mdEbook.prototype, "attachments", 2);
|
|
2002
2009
|
__decorateClass([
|
|
2003
2010
|
(0, import_sequelize_typescript19.Column)({
|
|
2004
|
-
field: "key_name",
|
|
2005
2011
|
allowNull: true,
|
|
2006
|
-
type: import_sequelize_typescript19.DataType.
|
|
2012
|
+
type: import_sequelize_typescript19.DataType.INTEGER
|
|
2007
2013
|
})
|
|
2008
|
-
],
|
|
2014
|
+
], mdEbook.prototype, "sort", 2);
|
|
2009
2015
|
__decorateClass([
|
|
2010
2016
|
(0, import_sequelize_typescript19.Column)({
|
|
2011
|
-
field: "user_id",
|
|
2012
2017
|
allowNull: true,
|
|
2013
2018
|
type: import_sequelize_typescript19.DataType.INTEGER
|
|
2014
2019
|
})
|
|
2015
|
-
],
|
|
2020
|
+
], mdEbook.prototype, "status", 2);
|
|
2016
2021
|
__decorateClass([
|
|
2017
2022
|
(0, import_sequelize_typescript19.Column)({
|
|
2018
|
-
|
|
2023
|
+
field: "has_expire",
|
|
2024
|
+
type: import_sequelize_typescript19.DataType.INTEGER
|
|
2019
2025
|
})
|
|
2020
|
-
],
|
|
2026
|
+
], mdEbook.prototype, "hasExpire", 2);
|
|
2021
2027
|
__decorateClass([
|
|
2022
2028
|
(0, import_sequelize_typescript19.Column)({
|
|
2029
|
+
field: "start_date",
|
|
2023
2030
|
allowNull: true,
|
|
2024
|
-
type: import_sequelize_typescript19.DataType.
|
|
2031
|
+
type: import_sequelize_typescript19.DataType.DATE
|
|
2025
2032
|
})
|
|
2026
|
-
],
|
|
2033
|
+
], mdEbook.prototype, "startDate", 2);
|
|
2027
2034
|
__decorateClass([
|
|
2028
2035
|
(0, import_sequelize_typescript19.Column)({
|
|
2036
|
+
field: "expire_date",
|
|
2029
2037
|
allowNull: true,
|
|
2030
|
-
type: import_sequelize_typescript19.DataType.
|
|
2038
|
+
type: import_sequelize_typescript19.DataType.DATE
|
|
2031
2039
|
})
|
|
2032
|
-
],
|
|
2040
|
+
], mdEbook.prototype, "expireDate", 2);
|
|
2033
2041
|
__decorateClass([
|
|
2034
2042
|
(0, import_sequelize_typescript19.Column)({
|
|
2035
2043
|
field: "created_by",
|
|
2036
2044
|
allowNull: true,
|
|
2037
2045
|
type: import_sequelize_typescript19.DataType.STRING(60)
|
|
2038
2046
|
})
|
|
2039
|
-
],
|
|
2047
|
+
], mdEbook.prototype, "createdBy", 2);
|
|
2040
2048
|
__decorateClass([
|
|
2041
2049
|
(0, import_sequelize_typescript19.Column)({
|
|
2042
2050
|
field: "created_date",
|
|
2043
2051
|
allowNull: true,
|
|
2044
2052
|
type: import_sequelize_typescript19.DataType.DATE
|
|
2045
2053
|
})
|
|
2046
|
-
],
|
|
2054
|
+
], mdEbook.prototype, "createdDate", 2);
|
|
2047
2055
|
__decorateClass([
|
|
2048
2056
|
(0, import_sequelize_typescript19.Column)({
|
|
2049
2057
|
field: "updated_by",
|
|
2050
2058
|
allowNull: true,
|
|
2051
2059
|
type: import_sequelize_typescript19.DataType.STRING(60)
|
|
2052
2060
|
})
|
|
2053
|
-
],
|
|
2061
|
+
], mdEbook.prototype, "updatedBy", 2);
|
|
2054
2062
|
__decorateClass([
|
|
2055
2063
|
(0, import_sequelize_typescript19.Column)({
|
|
2056
2064
|
field: "updated_date",
|
|
2057
2065
|
allowNull: true,
|
|
2058
2066
|
type: import_sequelize_typescript19.DataType.DATE
|
|
2059
2067
|
})
|
|
2060
|
-
],
|
|
2061
|
-
|
|
2068
|
+
], mdEbook.prototype, "updatedDate", 2);
|
|
2069
|
+
__decorateClass([
|
|
2070
|
+
(0, import_sequelize_typescript19.BelongsTo)(() => mdEbookGroup)
|
|
2071
|
+
], mdEbook.prototype, "mdEbookGroup", 2);
|
|
2072
|
+
mdEbook = __decorateClass([
|
|
2062
2073
|
(0, import_sequelize_typescript19.Table)({
|
|
2063
|
-
tableName: "
|
|
2074
|
+
tableName: "md_ebook",
|
|
2064
2075
|
timestamps: false
|
|
2065
2076
|
})
|
|
2066
|
-
],
|
|
2077
|
+
], mdEbook);
|
|
2067
2078
|
|
|
2068
2079
|
// src/databases/tables/mdFaq.ts
|
|
2069
2080
|
var import_sequelize_typescript21 = require("sequelize-typescript");
|
|
@@ -1,54 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
interface mdEbookAttributes {
|
|
4
|
-
id?: number;
|
|
5
|
-
uuid: string;
|
|
6
|
-
keyName?: string;
|
|
7
|
-
groupId?: number;
|
|
8
|
-
userId: number;
|
|
9
|
-
title?: string;
|
|
10
|
-
description?: string;
|
|
11
|
-
detail?: string;
|
|
12
|
-
metaTitle?: string;
|
|
13
|
-
metaKeyword?: string;
|
|
14
|
-
metaDescription?: string;
|
|
15
|
-
imageCover?: string;
|
|
16
|
-
imageGallery?: object;
|
|
17
|
-
attachments?: object;
|
|
18
|
-
sort?: number;
|
|
19
|
-
status?: number;
|
|
20
|
-
hasExpire: number;
|
|
21
|
-
startDate?: Date;
|
|
22
|
-
expireDate?: Date;
|
|
23
|
-
createdBy?: string;
|
|
24
|
-
createdDate?: Date;
|
|
25
|
-
updatedBy?: string;
|
|
26
|
-
updatedDate?: Date;
|
|
27
|
-
}
|
|
28
|
-
declare class mdEbook extends Model<mdEbookAttributes, mdEbookAttributes> implements mdEbookAttributes {
|
|
29
|
-
id?: number;
|
|
30
|
-
uuid: string;
|
|
31
|
-
keyName?: string;
|
|
32
|
-
groupId?: number;
|
|
33
|
-
userId: number;
|
|
34
|
-
title?: string;
|
|
35
|
-
description?: string;
|
|
36
|
-
detail?: string;
|
|
37
|
-
metaTitle?: string;
|
|
38
|
-
metaKeyword?: string;
|
|
39
|
-
metaDescription?: string;
|
|
40
|
-
imageCover?: string;
|
|
41
|
-
imageGallery?: object;
|
|
42
|
-
attachments?: object;
|
|
43
|
-
sort?: number;
|
|
44
|
-
status?: number;
|
|
45
|
-
hasExpire: number;
|
|
46
|
-
startDate?: Date;
|
|
47
|
-
expireDate?: Date;
|
|
48
|
-
createdBy?: string;
|
|
49
|
-
createdDate?: Date;
|
|
50
|
-
updatedBy?: string;
|
|
51
|
-
updatedDate?: Date;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
export { mdEbook, type mdEbookAttributes };
|
|
1
|
+
import 'sequelize-typescript';
|
|
2
|
+
export { a as mdEbook, m as mdEbookAttributes } from '../../mdEbook-C-qae2zR.js';
|
|
@@ -31,8 +31,11 @@ __export(mdEbook_exports, {
|
|
|
31
31
|
mdEbook: () => mdEbook
|
|
32
32
|
});
|
|
33
33
|
module.exports = __toCommonJS(mdEbook_exports);
|
|
34
|
+
var import_sequelize_typescript2 = require("sequelize-typescript");
|
|
35
|
+
|
|
36
|
+
// src/databases/tables/mdEbookGroup.ts
|
|
34
37
|
var import_sequelize_typescript = require("sequelize-typescript");
|
|
35
|
-
var
|
|
38
|
+
var mdEbookGroup = class extends import_sequelize_typescript.Model {
|
|
36
39
|
};
|
|
37
40
|
__decorateClass([
|
|
38
41
|
(0, import_sequelize_typescript.Column)({
|
|
@@ -40,153 +43,244 @@ __decorateClass([
|
|
|
40
43
|
autoIncrement: true,
|
|
41
44
|
type: import_sequelize_typescript.DataType.INTEGER
|
|
42
45
|
})
|
|
43
|
-
],
|
|
46
|
+
], mdEbookGroup.prototype, "id", 2);
|
|
44
47
|
__decorateClass([
|
|
45
48
|
(0, import_sequelize_typescript.Column)({
|
|
49
|
+
allowNull: true,
|
|
46
50
|
type: import_sequelize_typescript.DataType.STRING(60)
|
|
47
51
|
})
|
|
48
|
-
],
|
|
52
|
+
], mdEbookGroup.prototype, "uuid", 2);
|
|
49
53
|
__decorateClass([
|
|
50
54
|
(0, import_sequelize_typescript.Column)({
|
|
51
55
|
field: "key_name",
|
|
52
56
|
allowNull: true,
|
|
53
57
|
type: import_sequelize_typescript.DataType.STRING(100)
|
|
54
58
|
})
|
|
55
|
-
],
|
|
59
|
+
], mdEbookGroup.prototype, "keyName", 2);
|
|
56
60
|
__decorateClass([
|
|
57
61
|
(0, import_sequelize_typescript.Column)({
|
|
58
|
-
field: "
|
|
62
|
+
field: "user_id",
|
|
59
63
|
allowNull: true,
|
|
60
64
|
type: import_sequelize_typescript.DataType.INTEGER
|
|
61
65
|
})
|
|
62
|
-
],
|
|
66
|
+
], mdEbookGroup.prototype, "userId", 2);
|
|
63
67
|
__decorateClass([
|
|
64
68
|
(0, import_sequelize_typescript.Column)({
|
|
65
|
-
|
|
66
|
-
type: import_sequelize_typescript.DataType.INTEGER
|
|
69
|
+
type: import_sequelize_typescript.DataType.STRING(255)
|
|
67
70
|
})
|
|
68
|
-
],
|
|
71
|
+
], mdEbookGroup.prototype, "name", 2);
|
|
69
72
|
__decorateClass([
|
|
70
73
|
(0, import_sequelize_typescript.Column)({
|
|
71
74
|
allowNull: true,
|
|
72
75
|
type: import_sequelize_typescript.DataType.STRING(255)
|
|
73
76
|
})
|
|
74
|
-
],
|
|
77
|
+
], mdEbookGroup.prototype, "description", 2);
|
|
75
78
|
__decorateClass([
|
|
76
79
|
(0, import_sequelize_typescript.Column)({
|
|
77
80
|
allowNull: true,
|
|
78
|
-
type: import_sequelize_typescript.DataType.
|
|
81
|
+
type: import_sequelize_typescript.DataType.INTEGER
|
|
79
82
|
})
|
|
80
|
-
],
|
|
83
|
+
], mdEbookGroup.prototype, "status", 2);
|
|
81
84
|
__decorateClass([
|
|
82
85
|
(0, import_sequelize_typescript.Column)({
|
|
86
|
+
field: "created_by",
|
|
83
87
|
allowNull: true,
|
|
84
|
-
type: import_sequelize_typescript.DataType.STRING
|
|
88
|
+
type: import_sequelize_typescript.DataType.STRING(60)
|
|
85
89
|
})
|
|
86
|
-
],
|
|
90
|
+
], mdEbookGroup.prototype, "createdBy", 2);
|
|
87
91
|
__decorateClass([
|
|
88
92
|
(0, import_sequelize_typescript.Column)({
|
|
93
|
+
field: "created_date",
|
|
94
|
+
allowNull: true,
|
|
95
|
+
type: import_sequelize_typescript.DataType.DATE
|
|
96
|
+
})
|
|
97
|
+
], mdEbookGroup.prototype, "createdDate", 2);
|
|
98
|
+
__decorateClass([
|
|
99
|
+
(0, import_sequelize_typescript.Column)({
|
|
100
|
+
field: "updated_by",
|
|
101
|
+
allowNull: true,
|
|
102
|
+
type: import_sequelize_typescript.DataType.STRING(60)
|
|
103
|
+
})
|
|
104
|
+
], mdEbookGroup.prototype, "updatedBy", 2);
|
|
105
|
+
__decorateClass([
|
|
106
|
+
(0, import_sequelize_typescript.Column)({
|
|
107
|
+
field: "updated_date",
|
|
108
|
+
allowNull: true,
|
|
109
|
+
type: import_sequelize_typescript.DataType.DATE
|
|
110
|
+
})
|
|
111
|
+
], mdEbookGroup.prototype, "updatedDate", 2);
|
|
112
|
+
__decorateClass([
|
|
113
|
+
(0, import_sequelize_typescript.HasMany)(() => mdEbook, {
|
|
114
|
+
sourceKey: "id"
|
|
115
|
+
})
|
|
116
|
+
], mdEbookGroup.prototype, "mdEbooks", 2);
|
|
117
|
+
mdEbookGroup = __decorateClass([
|
|
118
|
+
(0, import_sequelize_typescript.Table)({
|
|
119
|
+
tableName: "md_ebook_group",
|
|
120
|
+
timestamps: false
|
|
121
|
+
})
|
|
122
|
+
], mdEbookGroup);
|
|
123
|
+
|
|
124
|
+
// src/databases/tables/mdEbook.ts
|
|
125
|
+
var mdEbook = class extends import_sequelize_typescript2.Model {
|
|
126
|
+
};
|
|
127
|
+
__decorateClass([
|
|
128
|
+
(0, import_sequelize_typescript2.Column)({
|
|
129
|
+
primaryKey: true,
|
|
130
|
+
autoIncrement: true,
|
|
131
|
+
type: import_sequelize_typescript2.DataType.INTEGER
|
|
132
|
+
})
|
|
133
|
+
], mdEbook.prototype, "id", 2);
|
|
134
|
+
__decorateClass([
|
|
135
|
+
(0, import_sequelize_typescript2.Column)({
|
|
136
|
+
type: import_sequelize_typescript2.DataType.STRING(60)
|
|
137
|
+
})
|
|
138
|
+
], mdEbook.prototype, "uuid", 2);
|
|
139
|
+
__decorateClass([
|
|
140
|
+
(0, import_sequelize_typescript2.Column)({
|
|
141
|
+
field: "key_name",
|
|
142
|
+
allowNull: true,
|
|
143
|
+
type: import_sequelize_typescript2.DataType.STRING(100)
|
|
144
|
+
})
|
|
145
|
+
], mdEbook.prototype, "keyName", 2);
|
|
146
|
+
__decorateClass([
|
|
147
|
+
(0, import_sequelize_typescript2.ForeignKey)(() => mdEbookGroup),
|
|
148
|
+
(0, import_sequelize_typescript2.Column)({
|
|
149
|
+
field: "group_id",
|
|
150
|
+
allowNull: true,
|
|
151
|
+
type: import_sequelize_typescript2.DataType.INTEGER
|
|
152
|
+
})
|
|
153
|
+
], mdEbook.prototype, "groupId", 2);
|
|
154
|
+
__decorateClass([
|
|
155
|
+
(0, import_sequelize_typescript2.Column)({
|
|
156
|
+
field: "user_id",
|
|
157
|
+
type: import_sequelize_typescript2.DataType.INTEGER
|
|
158
|
+
})
|
|
159
|
+
], mdEbook.prototype, "userId", 2);
|
|
160
|
+
__decorateClass([
|
|
161
|
+
(0, import_sequelize_typescript2.Column)({
|
|
162
|
+
allowNull: true,
|
|
163
|
+
type: import_sequelize_typescript2.DataType.STRING(255)
|
|
164
|
+
})
|
|
165
|
+
], mdEbook.prototype, "title", 2);
|
|
166
|
+
__decorateClass([
|
|
167
|
+
(0, import_sequelize_typescript2.Column)({
|
|
168
|
+
allowNull: true,
|
|
169
|
+
type: import_sequelize_typescript2.DataType.STRING
|
|
170
|
+
})
|
|
171
|
+
], mdEbook.prototype, "description", 2);
|
|
172
|
+
__decorateClass([
|
|
173
|
+
(0, import_sequelize_typescript2.Column)({
|
|
174
|
+
allowNull: true,
|
|
175
|
+
type: import_sequelize_typescript2.DataType.STRING
|
|
176
|
+
})
|
|
177
|
+
], mdEbook.prototype, "detail", 2);
|
|
178
|
+
__decorateClass([
|
|
179
|
+
(0, import_sequelize_typescript2.Column)({
|
|
89
180
|
field: "meta_title",
|
|
90
181
|
allowNull: true,
|
|
91
|
-
type:
|
|
182
|
+
type: import_sequelize_typescript2.DataType.STRING(255)
|
|
92
183
|
})
|
|
93
184
|
], mdEbook.prototype, "metaTitle", 2);
|
|
94
185
|
__decorateClass([
|
|
95
|
-
(0,
|
|
186
|
+
(0, import_sequelize_typescript2.Column)({
|
|
96
187
|
field: "meta_keyword",
|
|
97
188
|
allowNull: true,
|
|
98
|
-
type:
|
|
189
|
+
type: import_sequelize_typescript2.DataType.STRING(255)
|
|
99
190
|
})
|
|
100
191
|
], mdEbook.prototype, "metaKeyword", 2);
|
|
101
192
|
__decorateClass([
|
|
102
|
-
(0,
|
|
193
|
+
(0, import_sequelize_typescript2.Column)({
|
|
103
194
|
field: "meta_description",
|
|
104
195
|
allowNull: true,
|
|
105
|
-
type:
|
|
196
|
+
type: import_sequelize_typescript2.DataType.STRING(255)
|
|
106
197
|
})
|
|
107
198
|
], mdEbook.prototype, "metaDescription", 2);
|
|
108
199
|
__decorateClass([
|
|
109
|
-
(0,
|
|
200
|
+
(0, import_sequelize_typescript2.Column)({
|
|
110
201
|
field: "image_cover",
|
|
111
202
|
allowNull: true,
|
|
112
|
-
type:
|
|
203
|
+
type: import_sequelize_typescript2.DataType.STRING(60)
|
|
113
204
|
})
|
|
114
205
|
], mdEbook.prototype, "imageCover", 2);
|
|
115
206
|
__decorateClass([
|
|
116
|
-
(0,
|
|
207
|
+
(0, import_sequelize_typescript2.Column)({
|
|
117
208
|
field: "image_gallery",
|
|
118
209
|
allowNull: true,
|
|
119
|
-
type:
|
|
210
|
+
type: import_sequelize_typescript2.DataType.JSON
|
|
120
211
|
})
|
|
121
212
|
], mdEbook.prototype, "imageGallery", 2);
|
|
122
213
|
__decorateClass([
|
|
123
|
-
(0,
|
|
214
|
+
(0, import_sequelize_typescript2.Column)({
|
|
124
215
|
allowNull: true,
|
|
125
|
-
type:
|
|
216
|
+
type: import_sequelize_typescript2.DataType.JSON
|
|
126
217
|
})
|
|
127
218
|
], mdEbook.prototype, "attachments", 2);
|
|
128
219
|
__decorateClass([
|
|
129
|
-
(0,
|
|
220
|
+
(0, import_sequelize_typescript2.Column)({
|
|
130
221
|
allowNull: true,
|
|
131
|
-
type:
|
|
222
|
+
type: import_sequelize_typescript2.DataType.INTEGER
|
|
132
223
|
})
|
|
133
224
|
], mdEbook.prototype, "sort", 2);
|
|
134
225
|
__decorateClass([
|
|
135
|
-
(0,
|
|
226
|
+
(0, import_sequelize_typescript2.Column)({
|
|
136
227
|
allowNull: true,
|
|
137
|
-
type:
|
|
228
|
+
type: import_sequelize_typescript2.DataType.INTEGER
|
|
138
229
|
})
|
|
139
230
|
], mdEbook.prototype, "status", 2);
|
|
140
231
|
__decorateClass([
|
|
141
|
-
(0,
|
|
232
|
+
(0, import_sequelize_typescript2.Column)({
|
|
142
233
|
field: "has_expire",
|
|
143
|
-
type:
|
|
234
|
+
type: import_sequelize_typescript2.DataType.INTEGER
|
|
144
235
|
})
|
|
145
236
|
], mdEbook.prototype, "hasExpire", 2);
|
|
146
237
|
__decorateClass([
|
|
147
|
-
(0,
|
|
238
|
+
(0, import_sequelize_typescript2.Column)({
|
|
148
239
|
field: "start_date",
|
|
149
240
|
allowNull: true,
|
|
150
|
-
type:
|
|
241
|
+
type: import_sequelize_typescript2.DataType.DATE
|
|
151
242
|
})
|
|
152
243
|
], mdEbook.prototype, "startDate", 2);
|
|
153
244
|
__decorateClass([
|
|
154
|
-
(0,
|
|
245
|
+
(0, import_sequelize_typescript2.Column)({
|
|
155
246
|
field: "expire_date",
|
|
156
247
|
allowNull: true,
|
|
157
|
-
type:
|
|
248
|
+
type: import_sequelize_typescript2.DataType.DATE
|
|
158
249
|
})
|
|
159
250
|
], mdEbook.prototype, "expireDate", 2);
|
|
160
251
|
__decorateClass([
|
|
161
|
-
(0,
|
|
252
|
+
(0, import_sequelize_typescript2.Column)({
|
|
162
253
|
field: "created_by",
|
|
163
254
|
allowNull: true,
|
|
164
|
-
type:
|
|
255
|
+
type: import_sequelize_typescript2.DataType.STRING(60)
|
|
165
256
|
})
|
|
166
257
|
], mdEbook.prototype, "createdBy", 2);
|
|
167
258
|
__decorateClass([
|
|
168
|
-
(0,
|
|
259
|
+
(0, import_sequelize_typescript2.Column)({
|
|
169
260
|
field: "created_date",
|
|
170
261
|
allowNull: true,
|
|
171
|
-
type:
|
|
262
|
+
type: import_sequelize_typescript2.DataType.DATE
|
|
172
263
|
})
|
|
173
264
|
], mdEbook.prototype, "createdDate", 2);
|
|
174
265
|
__decorateClass([
|
|
175
|
-
(0,
|
|
266
|
+
(0, import_sequelize_typescript2.Column)({
|
|
176
267
|
field: "updated_by",
|
|
177
268
|
allowNull: true,
|
|
178
|
-
type:
|
|
269
|
+
type: import_sequelize_typescript2.DataType.STRING(60)
|
|
179
270
|
})
|
|
180
271
|
], mdEbook.prototype, "updatedBy", 2);
|
|
181
272
|
__decorateClass([
|
|
182
|
-
(0,
|
|
273
|
+
(0, import_sequelize_typescript2.Column)({
|
|
183
274
|
field: "updated_date",
|
|
184
275
|
allowNull: true,
|
|
185
|
-
type:
|
|
276
|
+
type: import_sequelize_typescript2.DataType.DATE
|
|
186
277
|
})
|
|
187
278
|
], mdEbook.prototype, "updatedDate", 2);
|
|
279
|
+
__decorateClass([
|
|
280
|
+
(0, import_sequelize_typescript2.BelongsTo)(() => mdEbookGroup)
|
|
281
|
+
], mdEbook.prototype, "mdEbookGroup", 2);
|
|
188
282
|
mdEbook = __decorateClass([
|
|
189
|
-
(0,
|
|
283
|
+
(0, import_sequelize_typescript2.Table)({
|
|
190
284
|
tableName: "md_ebook",
|
|
191
285
|
timestamps: false
|
|
192
286
|
})
|
|
@@ -1,30 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
interface mdEbookGroupAttributes {
|
|
4
|
-
id?: number;
|
|
5
|
-
uuid?: string;
|
|
6
|
-
keyName?: string;
|
|
7
|
-
userId?: number;
|
|
8
|
-
name: string;
|
|
9
|
-
description?: string;
|
|
10
|
-
status?: number;
|
|
11
|
-
createdBy?: string;
|
|
12
|
-
createdDate?: Date;
|
|
13
|
-
updatedBy?: string;
|
|
14
|
-
updatedDate?: Date;
|
|
15
|
-
}
|
|
16
|
-
declare class mdEbookGroup extends Model<mdEbookGroupAttributes, mdEbookGroupAttributes> implements mdEbookGroupAttributes {
|
|
17
|
-
id?: number;
|
|
18
|
-
uuid?: string;
|
|
19
|
-
keyName?: string;
|
|
20
|
-
userId?: number;
|
|
21
|
-
name: string;
|
|
22
|
-
description?: string;
|
|
23
|
-
status?: number;
|
|
24
|
-
createdBy?: string;
|
|
25
|
-
createdDate?: Date;
|
|
26
|
-
updatedBy?: string;
|
|
27
|
-
updatedDate?: Date;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
export { mdEbookGroup, type mdEbookGroupAttributes };
|
|
1
|
+
import 'sequelize-typescript';
|
|
2
|
+
export { c as mdEbookGroup, b as mdEbookGroupAttributes } from '../../mdEbook-C-qae2zR.js';
|
|
@@ -31,8 +31,11 @@ __export(mdEbookGroup_exports, {
|
|
|
31
31
|
mdEbookGroup: () => mdEbookGroup
|
|
32
32
|
});
|
|
33
33
|
module.exports = __toCommonJS(mdEbookGroup_exports);
|
|
34
|
+
var import_sequelize_typescript2 = require("sequelize-typescript");
|
|
35
|
+
|
|
36
|
+
// src/databases/tables/mdEbook.ts
|
|
34
37
|
var import_sequelize_typescript = require("sequelize-typescript");
|
|
35
|
-
var
|
|
38
|
+
var mdEbook = class extends import_sequelize_typescript.Model {
|
|
36
39
|
};
|
|
37
40
|
__decorateClass([
|
|
38
41
|
(0, import_sequelize_typescript.Column)({
|
|
@@ -40,74 +43,244 @@ __decorateClass([
|
|
|
40
43
|
autoIncrement: true,
|
|
41
44
|
type: import_sequelize_typescript.DataType.INTEGER
|
|
42
45
|
})
|
|
43
|
-
],
|
|
46
|
+
], mdEbook.prototype, "id", 2);
|
|
44
47
|
__decorateClass([
|
|
45
48
|
(0, import_sequelize_typescript.Column)({
|
|
46
|
-
allowNull: true,
|
|
47
49
|
type: import_sequelize_typescript.DataType.STRING(60)
|
|
48
50
|
})
|
|
49
|
-
],
|
|
51
|
+
], mdEbook.prototype, "uuid", 2);
|
|
50
52
|
__decorateClass([
|
|
51
53
|
(0, import_sequelize_typescript.Column)({
|
|
52
54
|
field: "key_name",
|
|
53
55
|
allowNull: true,
|
|
54
56
|
type: import_sequelize_typescript.DataType.STRING(100)
|
|
55
57
|
})
|
|
56
|
-
],
|
|
58
|
+
], mdEbook.prototype, "keyName", 2);
|
|
57
59
|
__decorateClass([
|
|
60
|
+
(0, import_sequelize_typescript.ForeignKey)(() => mdEbookGroup),
|
|
58
61
|
(0, import_sequelize_typescript.Column)({
|
|
59
|
-
field: "
|
|
62
|
+
field: "group_id",
|
|
60
63
|
allowNull: true,
|
|
61
64
|
type: import_sequelize_typescript.DataType.INTEGER
|
|
62
65
|
})
|
|
63
|
-
],
|
|
66
|
+
], mdEbook.prototype, "groupId", 2);
|
|
67
|
+
__decorateClass([
|
|
68
|
+
(0, import_sequelize_typescript.Column)({
|
|
69
|
+
field: "user_id",
|
|
70
|
+
type: import_sequelize_typescript.DataType.INTEGER
|
|
71
|
+
})
|
|
72
|
+
], mdEbook.prototype, "userId", 2);
|
|
64
73
|
__decorateClass([
|
|
65
74
|
(0, import_sequelize_typescript.Column)({
|
|
75
|
+
allowNull: true,
|
|
66
76
|
type: import_sequelize_typescript.DataType.STRING(255)
|
|
67
77
|
})
|
|
68
|
-
],
|
|
78
|
+
], mdEbook.prototype, "title", 2);
|
|
79
|
+
__decorateClass([
|
|
80
|
+
(0, import_sequelize_typescript.Column)({
|
|
81
|
+
allowNull: true,
|
|
82
|
+
type: import_sequelize_typescript.DataType.STRING
|
|
83
|
+
})
|
|
84
|
+
], mdEbook.prototype, "description", 2);
|
|
85
|
+
__decorateClass([
|
|
86
|
+
(0, import_sequelize_typescript.Column)({
|
|
87
|
+
allowNull: true,
|
|
88
|
+
type: import_sequelize_typescript.DataType.STRING
|
|
89
|
+
})
|
|
90
|
+
], mdEbook.prototype, "detail", 2);
|
|
69
91
|
__decorateClass([
|
|
70
92
|
(0, import_sequelize_typescript.Column)({
|
|
93
|
+
field: "meta_title",
|
|
71
94
|
allowNull: true,
|
|
72
95
|
type: import_sequelize_typescript.DataType.STRING(255)
|
|
73
96
|
})
|
|
74
|
-
],
|
|
97
|
+
], mdEbook.prototype, "metaTitle", 2);
|
|
98
|
+
__decorateClass([
|
|
99
|
+
(0, import_sequelize_typescript.Column)({
|
|
100
|
+
field: "meta_keyword",
|
|
101
|
+
allowNull: true,
|
|
102
|
+
type: import_sequelize_typescript.DataType.STRING(255)
|
|
103
|
+
})
|
|
104
|
+
], mdEbook.prototype, "metaKeyword", 2);
|
|
105
|
+
__decorateClass([
|
|
106
|
+
(0, import_sequelize_typescript.Column)({
|
|
107
|
+
field: "meta_description",
|
|
108
|
+
allowNull: true,
|
|
109
|
+
type: import_sequelize_typescript.DataType.STRING(255)
|
|
110
|
+
})
|
|
111
|
+
], mdEbook.prototype, "metaDescription", 2);
|
|
112
|
+
__decorateClass([
|
|
113
|
+
(0, import_sequelize_typescript.Column)({
|
|
114
|
+
field: "image_cover",
|
|
115
|
+
allowNull: true,
|
|
116
|
+
type: import_sequelize_typescript.DataType.STRING(60)
|
|
117
|
+
})
|
|
118
|
+
], mdEbook.prototype, "imageCover", 2);
|
|
119
|
+
__decorateClass([
|
|
120
|
+
(0, import_sequelize_typescript.Column)({
|
|
121
|
+
field: "image_gallery",
|
|
122
|
+
allowNull: true,
|
|
123
|
+
type: import_sequelize_typescript.DataType.JSON
|
|
124
|
+
})
|
|
125
|
+
], mdEbook.prototype, "imageGallery", 2);
|
|
126
|
+
__decorateClass([
|
|
127
|
+
(0, import_sequelize_typescript.Column)({
|
|
128
|
+
allowNull: true,
|
|
129
|
+
type: import_sequelize_typescript.DataType.JSON
|
|
130
|
+
})
|
|
131
|
+
], mdEbook.prototype, "attachments", 2);
|
|
75
132
|
__decorateClass([
|
|
76
133
|
(0, import_sequelize_typescript.Column)({
|
|
77
134
|
allowNull: true,
|
|
78
135
|
type: import_sequelize_typescript.DataType.INTEGER
|
|
79
136
|
})
|
|
80
|
-
],
|
|
137
|
+
], mdEbook.prototype, "sort", 2);
|
|
138
|
+
__decorateClass([
|
|
139
|
+
(0, import_sequelize_typescript.Column)({
|
|
140
|
+
allowNull: true,
|
|
141
|
+
type: import_sequelize_typescript.DataType.INTEGER
|
|
142
|
+
})
|
|
143
|
+
], mdEbook.prototype, "status", 2);
|
|
144
|
+
__decorateClass([
|
|
145
|
+
(0, import_sequelize_typescript.Column)({
|
|
146
|
+
field: "has_expire",
|
|
147
|
+
type: import_sequelize_typescript.DataType.INTEGER
|
|
148
|
+
})
|
|
149
|
+
], mdEbook.prototype, "hasExpire", 2);
|
|
150
|
+
__decorateClass([
|
|
151
|
+
(0, import_sequelize_typescript.Column)({
|
|
152
|
+
field: "start_date",
|
|
153
|
+
allowNull: true,
|
|
154
|
+
type: import_sequelize_typescript.DataType.DATE
|
|
155
|
+
})
|
|
156
|
+
], mdEbook.prototype, "startDate", 2);
|
|
157
|
+
__decorateClass([
|
|
158
|
+
(0, import_sequelize_typescript.Column)({
|
|
159
|
+
field: "expire_date",
|
|
160
|
+
allowNull: true,
|
|
161
|
+
type: import_sequelize_typescript.DataType.DATE
|
|
162
|
+
})
|
|
163
|
+
], mdEbook.prototype, "expireDate", 2);
|
|
81
164
|
__decorateClass([
|
|
82
165
|
(0, import_sequelize_typescript.Column)({
|
|
83
166
|
field: "created_by",
|
|
84
167
|
allowNull: true,
|
|
85
168
|
type: import_sequelize_typescript.DataType.STRING(60)
|
|
86
169
|
})
|
|
87
|
-
],
|
|
170
|
+
], mdEbook.prototype, "createdBy", 2);
|
|
88
171
|
__decorateClass([
|
|
89
172
|
(0, import_sequelize_typescript.Column)({
|
|
90
173
|
field: "created_date",
|
|
91
174
|
allowNull: true,
|
|
92
175
|
type: import_sequelize_typescript.DataType.DATE
|
|
93
176
|
})
|
|
94
|
-
],
|
|
177
|
+
], mdEbook.prototype, "createdDate", 2);
|
|
95
178
|
__decorateClass([
|
|
96
179
|
(0, import_sequelize_typescript.Column)({
|
|
97
180
|
field: "updated_by",
|
|
98
181
|
allowNull: true,
|
|
99
182
|
type: import_sequelize_typescript.DataType.STRING(60)
|
|
100
183
|
})
|
|
101
|
-
],
|
|
184
|
+
], mdEbook.prototype, "updatedBy", 2);
|
|
102
185
|
__decorateClass([
|
|
103
186
|
(0, import_sequelize_typescript.Column)({
|
|
104
187
|
field: "updated_date",
|
|
105
188
|
allowNull: true,
|
|
106
189
|
type: import_sequelize_typescript.DataType.DATE
|
|
107
190
|
})
|
|
191
|
+
], mdEbook.prototype, "updatedDate", 2);
|
|
192
|
+
__decorateClass([
|
|
193
|
+
(0, import_sequelize_typescript.BelongsTo)(() => mdEbookGroup)
|
|
194
|
+
], mdEbook.prototype, "mdEbookGroup", 2);
|
|
195
|
+
mdEbook = __decorateClass([
|
|
196
|
+
(0, import_sequelize_typescript.Table)({
|
|
197
|
+
tableName: "md_ebook",
|
|
198
|
+
timestamps: false
|
|
199
|
+
})
|
|
200
|
+
], mdEbook);
|
|
201
|
+
|
|
202
|
+
// src/databases/tables/mdEbookGroup.ts
|
|
203
|
+
var mdEbookGroup = class extends import_sequelize_typescript2.Model {
|
|
204
|
+
};
|
|
205
|
+
__decorateClass([
|
|
206
|
+
(0, import_sequelize_typescript2.Column)({
|
|
207
|
+
primaryKey: true,
|
|
208
|
+
autoIncrement: true,
|
|
209
|
+
type: import_sequelize_typescript2.DataType.INTEGER
|
|
210
|
+
})
|
|
211
|
+
], mdEbookGroup.prototype, "id", 2);
|
|
212
|
+
__decorateClass([
|
|
213
|
+
(0, import_sequelize_typescript2.Column)({
|
|
214
|
+
allowNull: true,
|
|
215
|
+
type: import_sequelize_typescript2.DataType.STRING(60)
|
|
216
|
+
})
|
|
217
|
+
], mdEbookGroup.prototype, "uuid", 2);
|
|
218
|
+
__decorateClass([
|
|
219
|
+
(0, import_sequelize_typescript2.Column)({
|
|
220
|
+
field: "key_name",
|
|
221
|
+
allowNull: true,
|
|
222
|
+
type: import_sequelize_typescript2.DataType.STRING(100)
|
|
223
|
+
})
|
|
224
|
+
], mdEbookGroup.prototype, "keyName", 2);
|
|
225
|
+
__decorateClass([
|
|
226
|
+
(0, import_sequelize_typescript2.Column)({
|
|
227
|
+
field: "user_id",
|
|
228
|
+
allowNull: true,
|
|
229
|
+
type: import_sequelize_typescript2.DataType.INTEGER
|
|
230
|
+
})
|
|
231
|
+
], mdEbookGroup.prototype, "userId", 2);
|
|
232
|
+
__decorateClass([
|
|
233
|
+
(0, import_sequelize_typescript2.Column)({
|
|
234
|
+
type: import_sequelize_typescript2.DataType.STRING(255)
|
|
235
|
+
})
|
|
236
|
+
], mdEbookGroup.prototype, "name", 2);
|
|
237
|
+
__decorateClass([
|
|
238
|
+
(0, import_sequelize_typescript2.Column)({
|
|
239
|
+
allowNull: true,
|
|
240
|
+
type: import_sequelize_typescript2.DataType.STRING(255)
|
|
241
|
+
})
|
|
242
|
+
], mdEbookGroup.prototype, "description", 2);
|
|
243
|
+
__decorateClass([
|
|
244
|
+
(0, import_sequelize_typescript2.Column)({
|
|
245
|
+
allowNull: true,
|
|
246
|
+
type: import_sequelize_typescript2.DataType.INTEGER
|
|
247
|
+
})
|
|
248
|
+
], mdEbookGroup.prototype, "status", 2);
|
|
249
|
+
__decorateClass([
|
|
250
|
+
(0, import_sequelize_typescript2.Column)({
|
|
251
|
+
field: "created_by",
|
|
252
|
+
allowNull: true,
|
|
253
|
+
type: import_sequelize_typescript2.DataType.STRING(60)
|
|
254
|
+
})
|
|
255
|
+
], mdEbookGroup.prototype, "createdBy", 2);
|
|
256
|
+
__decorateClass([
|
|
257
|
+
(0, import_sequelize_typescript2.Column)({
|
|
258
|
+
field: "created_date",
|
|
259
|
+
allowNull: true,
|
|
260
|
+
type: import_sequelize_typescript2.DataType.DATE
|
|
261
|
+
})
|
|
262
|
+
], mdEbookGroup.prototype, "createdDate", 2);
|
|
263
|
+
__decorateClass([
|
|
264
|
+
(0, import_sequelize_typescript2.Column)({
|
|
265
|
+
field: "updated_by",
|
|
266
|
+
allowNull: true,
|
|
267
|
+
type: import_sequelize_typescript2.DataType.STRING(60)
|
|
268
|
+
})
|
|
269
|
+
], mdEbookGroup.prototype, "updatedBy", 2);
|
|
270
|
+
__decorateClass([
|
|
271
|
+
(0, import_sequelize_typescript2.Column)({
|
|
272
|
+
field: "updated_date",
|
|
273
|
+
allowNull: true,
|
|
274
|
+
type: import_sequelize_typescript2.DataType.DATE
|
|
275
|
+
})
|
|
108
276
|
], mdEbookGroup.prototype, "updatedDate", 2);
|
|
277
|
+
__decorateClass([
|
|
278
|
+
(0, import_sequelize_typescript2.HasMany)(() => mdEbook, {
|
|
279
|
+
sourceKey: "id"
|
|
280
|
+
})
|
|
281
|
+
], mdEbookGroup.prototype, "mdEbooks", 2);
|
|
109
282
|
mdEbookGroup = __decorateClass([
|
|
110
|
-
(0,
|
|
283
|
+
(0, import_sequelize_typescript2.Table)({
|
|
111
284
|
tableName: "md_ebook_group",
|
|
112
285
|
timestamps: false
|
|
113
286
|
})
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { Model } from 'sequelize-typescript';
|
|
2
|
+
|
|
3
|
+
interface mdEbookGroupAttributes {
|
|
4
|
+
id?: number;
|
|
5
|
+
uuid?: string;
|
|
6
|
+
keyName?: string;
|
|
7
|
+
userId?: number;
|
|
8
|
+
name: string;
|
|
9
|
+
description?: string;
|
|
10
|
+
status?: number;
|
|
11
|
+
createdBy?: string;
|
|
12
|
+
createdDate?: Date;
|
|
13
|
+
updatedBy?: string;
|
|
14
|
+
updatedDate?: Date;
|
|
15
|
+
}
|
|
16
|
+
declare class mdEbookGroup extends Model<mdEbookGroupAttributes, mdEbookGroupAttributes> implements mdEbookGroupAttributes {
|
|
17
|
+
id?: number;
|
|
18
|
+
uuid?: string;
|
|
19
|
+
keyName?: string;
|
|
20
|
+
userId?: number;
|
|
21
|
+
name: string;
|
|
22
|
+
description?: string;
|
|
23
|
+
status?: number;
|
|
24
|
+
createdBy?: string;
|
|
25
|
+
createdDate?: Date;
|
|
26
|
+
updatedBy?: string;
|
|
27
|
+
updatedDate?: Date;
|
|
28
|
+
mdEbooks?: mdEbook[];
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
interface mdEbookAttributes {
|
|
32
|
+
id?: number;
|
|
33
|
+
uuid: string;
|
|
34
|
+
keyName?: string;
|
|
35
|
+
groupId?: number;
|
|
36
|
+
userId: number;
|
|
37
|
+
title?: string;
|
|
38
|
+
description?: string;
|
|
39
|
+
detail?: string;
|
|
40
|
+
metaTitle?: string;
|
|
41
|
+
metaKeyword?: string;
|
|
42
|
+
metaDescription?: string;
|
|
43
|
+
imageCover?: string;
|
|
44
|
+
imageGallery?: object;
|
|
45
|
+
attachments?: object;
|
|
46
|
+
sort?: number;
|
|
47
|
+
status?: number;
|
|
48
|
+
hasExpire: number;
|
|
49
|
+
startDate?: Date;
|
|
50
|
+
expireDate?: Date;
|
|
51
|
+
createdBy?: string;
|
|
52
|
+
createdDate?: Date;
|
|
53
|
+
updatedBy?: string;
|
|
54
|
+
updatedDate?: Date;
|
|
55
|
+
}
|
|
56
|
+
declare class mdEbook extends Model<mdEbookAttributes, mdEbookAttributes> implements mdEbookAttributes {
|
|
57
|
+
id?: number;
|
|
58
|
+
uuid: string;
|
|
59
|
+
keyName?: string;
|
|
60
|
+
groupId?: number;
|
|
61
|
+
userId: number;
|
|
62
|
+
title?: string;
|
|
63
|
+
description?: string;
|
|
64
|
+
detail?: string;
|
|
65
|
+
metaTitle?: string;
|
|
66
|
+
metaKeyword?: string;
|
|
67
|
+
metaDescription?: string;
|
|
68
|
+
imageCover?: string;
|
|
69
|
+
imageGallery?: object;
|
|
70
|
+
attachments?: object;
|
|
71
|
+
sort?: number;
|
|
72
|
+
status?: number;
|
|
73
|
+
hasExpire: number;
|
|
74
|
+
startDate?: Date;
|
|
75
|
+
expireDate?: Date;
|
|
76
|
+
createdBy?: string;
|
|
77
|
+
createdDate?: Date;
|
|
78
|
+
updatedBy?: string;
|
|
79
|
+
updatedDate?: Date;
|
|
80
|
+
mdEbookGroup?: mdEbookGroup;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export { mdEbook as a, type mdEbookGroupAttributes as b, mdEbookGroup as c, type mdEbookAttributes as m };
|