@memberjunction/codegen-lib 1.7.1 → 1.8.1
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/dist/Angular/angular-codegen.d.ts +63 -0
- package/dist/Angular/angular-codegen.d.ts.map +1 -0
- package/dist/{angular_client_codegen.js → Angular/angular-codegen.js} +153 -46
- package/dist/Angular/angular-codegen.js.map +1 -0
- package/dist/Angular/join-grid-related-entity-component.d.ts +24 -0
- package/dist/Angular/join-grid-related-entity-component.d.ts.map +1 -0
- package/dist/Angular/join-grid-related-entity-component.js +86 -0
- package/dist/Angular/join-grid-related-entity-component.js.map +1 -0
- package/dist/Angular/related-entity-components.d.ts +111 -0
- package/dist/Angular/related-entity-components.d.ts.map +1 -0
- package/dist/Angular/related-entity-components.js +82 -0
- package/dist/Angular/related-entity-components.js.map +1 -0
- package/dist/Angular/user-view-grid-related-entity-component.d.ts +11 -0
- package/dist/Angular/user-view-grid-related-entity-component.d.ts.map +1 -0
- package/dist/Angular/user-view-grid-related-entity-component.js +51 -0
- package/dist/Angular/user-view-grid-related-entity-component.js.map +1 -0
- package/dist/Config/config.d.ts.map +1 -0
- package/dist/{config.js → Config/config.js} +1 -1
- package/dist/Config/config.js.map +1 -0
- package/dist/{db.d.ts → Config/db-connection.d.ts} +1 -1
- package/dist/Config/db-connection.d.ts.map +1 -0
- package/dist/{db.js → Config/db-connection.js} +1 -1
- package/dist/Config/db-connection.js.map +1 -0
- package/dist/Database/dbSchema.d.ts.map +1 -0
- package/dist/{dbSchema.js → Database/dbSchema.js} +2 -2
- package/dist/Database/dbSchema.js.map +1 -0
- package/dist/{manageMetadata.d.ts → Database/manage-metadata.d.ts} +36 -3
- package/dist/Database/manage-metadata.d.ts.map +1 -0
- package/dist/{manageMetadata.js → Database/manage-metadata.js} +171 -18
- package/dist/Database/manage-metadata.js.map +1 -0
- package/dist/Database/sql.d.ts.map +1 -0
- package/dist/{sql.js → Database/sql.js} +5 -5
- package/dist/Database/sql.js.map +1 -0
- package/dist/Database/sql_codegen.d.ts.map +1 -0
- package/dist/{sql_codegen.js → Database/sql_codegen.js} +20 -30
- package/dist/Database/sql_codegen.js.map +1 -0
- package/dist/{advanced_generation.d.ts → Misc/advanced_generation.d.ts} +1 -1
- package/dist/Misc/advanced_generation.d.ts.map +1 -0
- package/dist/{advanced_generation.js → Misc/advanced_generation.js} +1 -1
- package/dist/Misc/advanced_generation.js.map +1 -0
- package/dist/Misc/createNewUser.d.ts +12 -0
- package/dist/Misc/createNewUser.d.ts.map +1 -0
- package/dist/Misc/createNewUser.js +113 -0
- package/dist/Misc/createNewUser.js.map +1 -0
- package/dist/Misc/logging.d.ts.map +1 -0
- package/dist/{logging.js → Misc/logging.js} +1 -1
- package/dist/Misc/logging.js.map +1 -0
- package/dist/{runCommand.d.ts → Misc/runCommand.d.ts} +1 -1
- package/dist/Misc/runCommand.d.ts.map +1 -0
- package/dist/Misc/runCommand.js.map +1 -0
- package/dist/Misc/util.d.ts.map +1 -0
- package/dist/Misc/util.js.map +1 -0
- package/dist/action_subclasses_codegen.js +1 -1
- package/dist/action_subclasses_codegen.js.map +1 -1
- package/dist/createNewUser.d.ts +1 -1
- package/dist/createNewUser.d.ts.map +1 -1
- package/dist/createNewUser.js +2 -2
- package/dist/createNewUser.js.map +1 -1
- package/dist/entity_subclasses_codegen.js +1 -1
- package/dist/entity_subclasses_codegen.js.map +1 -1
- package/dist/graphql_server_codegen.d.ts.map +1 -1
- package/dist/graphql_server_codegen.js +10 -6
- package/dist/graphql_server_codegen.js.map +1 -1
- package/dist/index.d.ts +14 -11
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +14 -11
- package/dist/index.js.map +1 -1
- package/dist/runCodeGen.js +21 -21
- package/dist/runCodeGen.js.map +1 -1
- package/package.json +7 -7
- package/dist/advanced_generation.d.ts.map +0 -1
- package/dist/advanced_generation.js.map +0 -1
- package/dist/angular_client_codegen.d.ts +0 -43
- package/dist/angular_client_codegen.d.ts.map +0 -1
- package/dist/angular_client_codegen.js.map +0 -1
- package/dist/config.d.ts.map +0 -1
- package/dist/config.js.map +0 -1
- package/dist/db.d.ts.map +0 -1
- package/dist/db.js.map +0 -1
- package/dist/dbSchema.d.ts.map +0 -1
- package/dist/dbSchema.js.map +0 -1
- package/dist/logging.d.ts.map +0 -1
- package/dist/logging.js.map +0 -1
- package/dist/manageMetadata.d.ts.map +0 -1
- package/dist/manageMetadata.js.map +0 -1
- package/dist/runCommand.d.ts.map +0 -1
- package/dist/runCommand.js.map +0 -1
- package/dist/sql.d.ts.map +0 -1
- package/dist/sql.js.map +0 -1
- package/dist/sql_codegen.d.ts.map +0 -1
- package/dist/sql_codegen.js.map +0 -1
- package/dist/util.d.ts.map +0 -1
- package/dist/util.js.map +0 -1
- /package/dist/{config.d.ts → Config/config.d.ts} +0 -0
- /package/dist/{dbSchema.d.ts → Database/dbSchema.d.ts} +0 -0
- /package/dist/{sql.d.ts → Database/sql.d.ts} +0 -0
- /package/dist/{sql_codegen.d.ts → Database/sql_codegen.d.ts} +0 -0
- /package/dist/{logging.d.ts → Misc/logging.d.ts} +0 -0
- /package/dist/{runCommand.js → Misc/runCommand.js} +0 -0
- /package/dist/{util.d.ts → Misc/util.d.ts} +0 -0
- /package/dist/{util.js → Misc/util.js} +0 -0
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import { EntityInfo, EntityRelationshipInfo, UserInfo } from "@memberjunction/core";
|
|
2
|
+
/**
|
|
3
|
+
* Represents info on an Angular class that is used in the generated code
|
|
4
|
+
*/
|
|
5
|
+
export declare class AngularComponentInfo {
|
|
6
|
+
/**
|
|
7
|
+
* The typescript class name for the component
|
|
8
|
+
*/
|
|
9
|
+
ClassName: string;
|
|
10
|
+
/**
|
|
11
|
+
* The name of the module so it can be properly imported by the generated module
|
|
12
|
+
*/
|
|
13
|
+
ModuleName: string;
|
|
14
|
+
/**
|
|
15
|
+
* The Angular selector name for the component
|
|
16
|
+
*/
|
|
17
|
+
AngularSelectorName: string;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Classes that generate Angular code must return this type
|
|
21
|
+
*/
|
|
22
|
+
export declare class GenerationResult {
|
|
23
|
+
/**
|
|
24
|
+
* Was the generation successful?
|
|
25
|
+
*/
|
|
26
|
+
Success: boolean;
|
|
27
|
+
/**
|
|
28
|
+
* If generation was not successful, this will contain the error message
|
|
29
|
+
*/
|
|
30
|
+
ErrorMessage?: string;
|
|
31
|
+
/**
|
|
32
|
+
* This is the HTML/Angular template code that will be used by the caller in generating the final Angular component
|
|
33
|
+
*/
|
|
34
|
+
TemplateOutput: string;
|
|
35
|
+
/**
|
|
36
|
+
* Optional, TypeScript code that will be injected into the class definition for the Angular component. This is useful for adding additional methods or properties to the component
|
|
37
|
+
*/
|
|
38
|
+
CodeOutput?: string;
|
|
39
|
+
/**
|
|
40
|
+
* A reference to the component that generated the output. Useful for accessing the properties of the component later on for imports/etc
|
|
41
|
+
*/
|
|
42
|
+
Component: RelatedEntityDisplayComponentGeneratorBase;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Properties needed for the Generate() method to execute
|
|
46
|
+
*/
|
|
47
|
+
export declare class GenerationInput {
|
|
48
|
+
/**
|
|
49
|
+
* The entity that is the primary entity
|
|
50
|
+
*/
|
|
51
|
+
Entity: EntityInfo;
|
|
52
|
+
/**
|
|
53
|
+
* Relationship Information for this component
|
|
54
|
+
*/
|
|
55
|
+
RelationshipInfo: EntityRelationshipInfo;
|
|
56
|
+
/**
|
|
57
|
+
* The name of the tab on a multi-tabbed interface, this is often provided but not mandatory. Use it if it makes sense for your component and
|
|
58
|
+
* it is most commonly used to defer loading by using the IsCurrentTab() method from the BaseFormComponent that all of the generated components inherit from
|
|
59
|
+
*/
|
|
60
|
+
TabName: string;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Base class that all sub-classes of RelatedEntityDisplayComponentConfigBase use to define a derived class that will defined the shape
|
|
64
|
+
* of their configuration object.
|
|
65
|
+
*/
|
|
66
|
+
export declare class ComponentConfigBase {
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Base Class that is responsible for generating the Angular template code for the related entity display component.
|
|
70
|
+
*
|
|
71
|
+
* The built-in functionality within the {@link BaseFormComponent} can be used in the Angular template without any changes since the generated code will be injected
|
|
72
|
+
* into the Angular template of a sub-class of {@link BaseFormComponent}. If you need additional code to be added to the sub-class on the TypeScript side, you can
|
|
73
|
+
* provide that in the optional `CodeOutput` property of the `GenerationResult` object that is returned by the `Generate` method.
|
|
74
|
+
*
|
|
75
|
+
* Some of the commonly used methods/properties of the {@link BaseFormComponent} that can be used in the Angular template are below. Check out the documentation in the `@memberjunction/ng-base-forms` package and the
|
|
76
|
+
* {@link BaseFormComponent} class for more details.
|
|
77
|
+
*
|
|
78
|
+
* * {@link BaseFormComponent#BuildRelationshipViewParamsByEntityName BuildRelationshipViewParamsByEntityName}
|
|
79
|
+
* * {@link BaseFormComponent#NewRecordValues NewRecordValues}
|
|
80
|
+
* * {@link BaseFormComponent#IsCurrentTab IsCurrentTab}
|
|
81
|
+
* * {@link BaseFormComponent#GridEditMode GridEditMode}
|
|
82
|
+
* * {@link BaseFormComponent#GridBottomMargin GridBottomMargin}
|
|
83
|
+
*
|
|
84
|
+
* @see {@link BaseFormComponent}
|
|
85
|
+
*/
|
|
86
|
+
export declare abstract class RelatedEntityDisplayComponentGeneratorBase {
|
|
87
|
+
/**
|
|
88
|
+
* The subclass provides the package import path which can be local or from a repository such as @memberjunction/ng-user-view-grid as an example
|
|
89
|
+
*/
|
|
90
|
+
abstract get ImportPath(): string;
|
|
91
|
+
/**
|
|
92
|
+
* The subclass must define 1 or more AngularClassInfo objects that represent the Angular classes that are being used in the generated code
|
|
93
|
+
*/
|
|
94
|
+
abstract get ImportItems(): AngularComponentInfo[];
|
|
95
|
+
/**
|
|
96
|
+
* The subclass must implement this method to generate the Angular template code for the related entity display component
|
|
97
|
+
* @param entity The entity that is the primary entity
|
|
98
|
+
* @param relatedEntity The entity that is the related entity
|
|
99
|
+
*/
|
|
100
|
+
abstract Generate(input: GenerationInput): Promise<GenerationResult>;
|
|
101
|
+
/**
|
|
102
|
+
* Use this method to dynamically instantiate the correct RelatedEntityDisplayComponentGeneratorBase subclass based on the relationshipInfo provided
|
|
103
|
+
* @param relationshipInfo The relationship info that contains the info needed to get the right component
|
|
104
|
+
* @param contextUser Context user for any needed database interaction
|
|
105
|
+
* @param params Provide any number of additional parameters that should be passed along to the constructor of the component
|
|
106
|
+
*/
|
|
107
|
+
static GetComponent(relationshipInfo: EntityRelationshipInfo, contextUser: UserInfo, ...params: any[]): Promise<RelatedEntityDisplayComponentGeneratorBase>;
|
|
108
|
+
private static _componentInstanceMap;
|
|
109
|
+
abstract get ConfigType(): ComponentConfigBase;
|
|
110
|
+
}
|
|
111
|
+
//# sourceMappingURL=related-entity-components.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"related-entity-components.d.ts","sourceRoot":"","sources":["../../src/Angular/related-entity-components.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,sBAAsB,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAIpF;;GAEG;AACH,qBAAa,oBAAoB;IAC7B;;OAEG;IACI,SAAS,EAAE,MAAM,CAAC;IACzB;;OAEG;IACI,UAAU,EAAE,MAAM,CAAC;IAC1B;;OAEG;IACI,mBAAmB,EAAE,MAAM,CAAC;CACtC;AAED;;GAEG;AACH,qBAAa,gBAAgB;IACzB;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;IACvB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,SAAS,EAAE,0CAA0C,CAAC;CACzD;AAED;;GAEG;AACH,qBAAa,eAAe;IACxB;;OAEG;IACH,MAAM,EAAE,UAAU,CAAC;IACnB;;OAEG;IACH,gBAAgB,EAAE,sBAAsB,CAAC;IACzC;;;OAGG;IACH,OAAO,EAAE,MAAM,CAAC;CACnB;AAGD;;;GAGG;AACH,qBAAa,mBAAmB;CAE/B;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,8BAAsB,0CAA0C;IAC5D;;OAEG;IACH,aAAoB,UAAU,IAAI,MAAM,CAAC;IACzC;;OAEG;IACH,aAAoB,WAAW,IAAI,oBAAoB,EAAE,CAAC;IAE1D;;;;OAIG;aACa,QAAQ,CAAC,KAAK,EAAE,eAAe,GAAG,OAAO,CAAC,gBAAgB,CAAC;IAE3E;;;;;OAKG;WACiB,YAAY,CAAC,gBAAgB,EAAE,sBAAsB,EAAE,WAAW,EAAE,QAAQ,EAAE,GAAG,MAAM,EAAE,GAAG,EAAE,GAAG,OAAO,CAAC,0CAA0C,CAAC;IAyBxK,OAAO,CAAC,MAAM,CAAC,qBAAqB,CAA0H;IAE9J,aAAoB,UAAU,IAAI,mBAAmB,CAAC;CACzD"}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.RelatedEntityDisplayComponentGeneratorBase = exports.ComponentConfigBase = exports.GenerationInput = exports.GenerationResult = exports.AngularComponentInfo = void 0;
|
|
4
|
+
const core_entities_1 = require("@memberjunction/core-entities");
|
|
5
|
+
const global_1 = require("@memberjunction/global");
|
|
6
|
+
/**
|
|
7
|
+
* Represents info on an Angular class that is used in the generated code
|
|
8
|
+
*/
|
|
9
|
+
class AngularComponentInfo {
|
|
10
|
+
}
|
|
11
|
+
exports.AngularComponentInfo = AngularComponentInfo;
|
|
12
|
+
/**
|
|
13
|
+
* Classes that generate Angular code must return this type
|
|
14
|
+
*/
|
|
15
|
+
class GenerationResult {
|
|
16
|
+
}
|
|
17
|
+
exports.GenerationResult = GenerationResult;
|
|
18
|
+
/**
|
|
19
|
+
* Properties needed for the Generate() method to execute
|
|
20
|
+
*/
|
|
21
|
+
class GenerationInput {
|
|
22
|
+
}
|
|
23
|
+
exports.GenerationInput = GenerationInput;
|
|
24
|
+
/**
|
|
25
|
+
* Base class that all sub-classes of RelatedEntityDisplayComponentConfigBase use to define a derived class that will defined the shape
|
|
26
|
+
* of their configuration object.
|
|
27
|
+
*/
|
|
28
|
+
class ComponentConfigBase {
|
|
29
|
+
}
|
|
30
|
+
exports.ComponentConfigBase = ComponentConfigBase;
|
|
31
|
+
/**
|
|
32
|
+
* Base Class that is responsible for generating the Angular template code for the related entity display component.
|
|
33
|
+
*
|
|
34
|
+
* The built-in functionality within the {@link BaseFormComponent} can be used in the Angular template without any changes since the generated code will be injected
|
|
35
|
+
* into the Angular template of a sub-class of {@link BaseFormComponent}. If you need additional code to be added to the sub-class on the TypeScript side, you can
|
|
36
|
+
* provide that in the optional `CodeOutput` property of the `GenerationResult` object that is returned by the `Generate` method.
|
|
37
|
+
*
|
|
38
|
+
* Some of the commonly used methods/properties of the {@link BaseFormComponent} that can be used in the Angular template are below. Check out the documentation in the `@memberjunction/ng-base-forms` package and the
|
|
39
|
+
* {@link BaseFormComponent} class for more details.
|
|
40
|
+
*
|
|
41
|
+
* * {@link BaseFormComponent#BuildRelationshipViewParamsByEntityName BuildRelationshipViewParamsByEntityName}
|
|
42
|
+
* * {@link BaseFormComponent#NewRecordValues NewRecordValues}
|
|
43
|
+
* * {@link BaseFormComponent#IsCurrentTab IsCurrentTab}
|
|
44
|
+
* * {@link BaseFormComponent#GridEditMode GridEditMode}
|
|
45
|
+
* * {@link BaseFormComponent#GridBottomMargin GridBottomMargin}
|
|
46
|
+
*
|
|
47
|
+
* @see {@link BaseFormComponent}
|
|
48
|
+
*/
|
|
49
|
+
class RelatedEntityDisplayComponentGeneratorBase {
|
|
50
|
+
/**
|
|
51
|
+
* Use this method to dynamically instantiate the correct RelatedEntityDisplayComponentGeneratorBase subclass based on the relationshipInfo provided
|
|
52
|
+
* @param relationshipInfo The relationship info that contains the info needed to get the right component
|
|
53
|
+
* @param contextUser Context user for any needed database interaction
|
|
54
|
+
* @param params Provide any number of additional parameters that should be passed along to the constructor of the component
|
|
55
|
+
*/
|
|
56
|
+
static async GetComponent(relationshipInfo, contextUser, ...params) {
|
|
57
|
+
let key = "UserViewGrid"; // default key/name of component
|
|
58
|
+
if (relationshipInfo.DisplayComponentID && relationshipInfo.DisplayComponentID > 0) {
|
|
59
|
+
// get the component from the component info provided
|
|
60
|
+
await core_entities_1.TypeTablesCache.Instance.Config(false, contextUser);
|
|
61
|
+
const component = core_entities_1.TypeTablesCache.Instance.EntityRelationshipDisplayComponents.find(x => x.ID === relationshipInfo.DisplayComponentID);
|
|
62
|
+
if (component) {
|
|
63
|
+
key = component.Name;
|
|
64
|
+
}
|
|
65
|
+
else
|
|
66
|
+
throw new Error(`Could not find the DisplayComponent with ID ${relationshipInfo.DisplayComponentID}`);
|
|
67
|
+
}
|
|
68
|
+
// check to see if we have an existing entry in our component instance map, if so use that, otherwise create a new component, add to map, and return
|
|
69
|
+
if (RelatedEntityDisplayComponentGeneratorBase._componentInstanceMap.has(key)) {
|
|
70
|
+
return RelatedEntityDisplayComponentGeneratorBase._componentInstanceMap.get(key);
|
|
71
|
+
}
|
|
72
|
+
else {
|
|
73
|
+
// if we get here that means we have the key we need to use so get the component built
|
|
74
|
+
const component = global_1.MJGlobal.Instance.ClassFactory.CreateInstance(RelatedEntityDisplayComponentGeneratorBase, key, params);
|
|
75
|
+
RelatedEntityDisplayComponentGeneratorBase._componentInstanceMap.set(key, component);
|
|
76
|
+
return component;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
exports.RelatedEntityDisplayComponentGeneratorBase = RelatedEntityDisplayComponentGeneratorBase;
|
|
81
|
+
RelatedEntityDisplayComponentGeneratorBase._componentInstanceMap = new Map();
|
|
82
|
+
//# sourceMappingURL=related-entity-components.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":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FAAsF;YACtF,MAAM,SAAS,GAAG,iBAAQ,CAAC,QAAQ,CAAC,YAAY,CAAC,cAAc,CAA6C,0CAA0C,EAAE,GAAG,EAAE,MAAM,CAAC,CAAC;YACrK,0CAA0C,CAAC,qBAAqB,CAAC,GAAG,CAAC,GAAG,EAAE,SAAS,CAAC,CAAC;YACrF,OAAO,SAAS,CAAC;QACrB,CAAC;IACL,CAAC;;AA9CL,gGAmDC;AAHkB,gEAAqB,GAA4D,IAAI,GAAG,EAAsD,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { AngularComponentInfo, ComponentConfigBase, GenerationInput, GenerationResult, RelatedEntityDisplayComponentGeneratorBase } from "./related-entity-components";
|
|
2
|
+
/**
|
|
3
|
+
* Implementation of the UserViewGridRelatedEntityGenerator class that generates the Angular component for a related entity in a UserViewGrid display component
|
|
4
|
+
*/
|
|
5
|
+
export declare class UserViewGridRelatedEntityGenerator extends RelatedEntityDisplayComponentGeneratorBase {
|
|
6
|
+
get ImportPath(): string;
|
|
7
|
+
get ImportItems(): AngularComponentInfo[];
|
|
8
|
+
Generate(input: GenerationInput): Promise<GenerationResult>;
|
|
9
|
+
get ConfigType(): typeof ComponentConfigBase;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=user-view-grid-related-entity-component.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"user-view-grid-related-entity-component.d.ts","sourceRoot":"","sources":["../../src/Angular/user-view-grid-related-entity-component.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,eAAe,EAAE,gBAAgB,EAAE,0CAA0C,EAAE,MAAM,6BAA6B,CAAC;AAEvK;;GAEG;AACH,qBACa,kCAAmC,SAAQ,0CAA0C;IAC9F,IAAW,UAAU,IAAI,MAAM,CAE9B;IACD,IAAW,WAAW,IAAI,oBAAoB,EAAE,CAQ/C;IACY,QAAQ,CAAC,KAAK,EAAE,eAAe,GAAG,OAAO,CAAC,gBAAgB,CAAC;IAgBxE,IAAW,UAAU,IAAI,OAAO,mBAAmB,CAElD;CACJ"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.UserViewGridRelatedEntityGenerator = void 0;
|
|
10
|
+
const global_1 = require("@memberjunction/global");
|
|
11
|
+
const related_entity_components_1 = require("./related-entity-components");
|
|
12
|
+
/**
|
|
13
|
+
* Implementation of the UserViewGridRelatedEntityGenerator class that generates the Angular component for a related entity in a UserViewGrid display component
|
|
14
|
+
*/
|
|
15
|
+
let UserViewGridRelatedEntityGenerator = class UserViewGridRelatedEntityGenerator extends related_entity_components_1.RelatedEntityDisplayComponentGeneratorBase {
|
|
16
|
+
get ImportPath() {
|
|
17
|
+
return "@memberjunction/ng-user-view-grid";
|
|
18
|
+
}
|
|
19
|
+
get ImportItems() {
|
|
20
|
+
return [
|
|
21
|
+
{
|
|
22
|
+
ClassName: "UserViewGridComponent",
|
|
23
|
+
AngularSelectorName: "mj-user-view-grid",
|
|
24
|
+
ModuleName: "UserViewGridModule"
|
|
25
|
+
}
|
|
26
|
+
];
|
|
27
|
+
}
|
|
28
|
+
async Generate(input) {
|
|
29
|
+
const template = `<mj-user-view-grid
|
|
30
|
+
[Params]="BuildRelationshipViewParamsByEntityName('${input.RelationshipInfo.RelatedEntity}')"
|
|
31
|
+
[NewRecordValues]="NewRecordValues('${input.RelationshipInfo.RelatedEntity}')"
|
|
32
|
+
[AllowLoad]="IsCurrentTab('${input.TabName}')"
|
|
33
|
+
[EditMode]="GridEditMode()"
|
|
34
|
+
[BottomMargin]="GridBottomMargin">
|
|
35
|
+
</mj-user-view-grid>`;
|
|
36
|
+
return {
|
|
37
|
+
Success: true,
|
|
38
|
+
TemplateOutput: template,
|
|
39
|
+
CodeOutput: null,
|
|
40
|
+
Component: this
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
get ConfigType() {
|
|
44
|
+
return null;
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
exports.UserViewGridRelatedEntityGenerator = UserViewGridRelatedEntityGenerator;
|
|
48
|
+
exports.UserViewGridRelatedEntityGenerator = UserViewGridRelatedEntityGenerator = __decorate([
|
|
49
|
+
(0, global_1.RegisterClass)(related_entity_components_1.RelatedEntityDisplayComponentGeneratorBase, "UserViewGrid")
|
|
50
|
+
], UserViewGridRelatedEntityGenerator);
|
|
51
|
+
//# sourceMappingURL=user-view-grid-related-entity-component.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"user-view-grid-related-entity-component.js","sourceRoot":"","sources":["../../src/Angular/user-view-grid-related-entity-component.ts"],"names":[],"mappings":";;;;;;;;;AAAA,mDAAuD;AACvD,2EAAuK;AAEvK;;GAEG;AAEI,IAAM,kCAAkC,GAAxC,MAAM,kCAAmC,SAAQ,sEAA0C;IAC9F,IAAW,UAAU;QACjB,OAAO,mCAAmC,CAAC;IAC/C,CAAC;IACD,IAAW,WAAW;QAClB,OAAO;YACH;gBACI,SAAS,EAAE,uBAAuB;gBAClC,mBAAmB,EAAE,mBAAmB;gBACxC,UAAU,EAAE,oBAAoB;aACnC;SACJ,CAAC;IACN,CAAC;IACM,KAAK,CAAC,QAAQ,CAAC,KAAsB;QACxC,MAAM,QAAQ,GAAG;yDACgC,KAAK,CAA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MAAM,GAAG,WAAW,EAAE,CAEpD;AACD,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,eAAe,EAAE,CAEhE;AAED,wBAAgB,UAAU,CAAC,WAAW,EAAE,MAAM,GAAG,WAAW,CAE3D;AAED,wBAAgB,eAAe,CAAC,WAAW,EAAE,MAAM,EAAE,YAAY,CAAC,EAAE,GAAG,GAAG,GAAG,CAM5E;AAED,wBAAgB,cAAc,IAAI,MAAM,CAEvC"}
|
|
@@ -7,7 +7,7 @@ exports.mj_core_schema = exports.getSettingValue = exports.getSetting = exports.
|
|
|
7
7
|
const env_var_1 = __importDefault(require("env-var"));
|
|
8
8
|
const fs_1 = __importDefault(require("fs"));
|
|
9
9
|
const path_1 = __importDefault(require("path"));
|
|
10
|
-
const logging_1 = require("
|
|
10
|
+
const logging_1 = require("../Misc/logging");
|
|
11
11
|
exports.dbHost = env_var_1.default.get('DB_HOST').required().asString();
|
|
12
12
|
exports.dbPort = env_var_1.default.get('DB_PORT').default('1433').asPortNumber();
|
|
13
13
|
exports.dbUsername = env_var_1.default.get('DB_USERNAME').required().asString();
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../src/Config/config.ts"],"names":[],"mappings":";;;;;;AAAA,sDAA0B;AAC1B,4CAAoB;AACpB,gDAAwB;AACxB,6CAA4C;AAE/B,QAAA,MAAM,GAAG,iBAAG,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,CAAC;AAClD,QAAA,MAAM,GAAG,iBAAG,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,YAAY,EAAE,CAAC;AAC3D,QAAA,UAAU,GAAG,iBAAG,CAAC,GAAG,CAAC,aAAa,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,CAAC;AAC1D,QAAA,UAAU,GAAG,iBAAG,CAAC,GAAG,CAAC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["../../src/Config/db-connection.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAA;AAqBpC,QAAA,MAAM,aAAa,YAA4B,CAAA;AAE/C,eAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"db-connection.js","sourceRoot":"","sources":["../../src/Config/db-connection.ts"],"names":[],"mappings":";;AAAA,iCAAiC;AACjC,qCAAwH;AACxH,qCAAoC;AAIpC,MAAM,SAAS,GAA+B;IAC1C,IAAI,EAAE,OAAO;IACb,OAAO,EAAE,KAAK;IACd,IAAI,EAAE,eAAM;IACZ,IAAI,EAAE,eAAM;IACZ,QAAQ,EAAE,mBAAU;IACpB,QAAQ,EAAE,mBAAU;IACpB,QAAQ,EAAE,mBAAU;IACpB,WAAW,EAAE,KAAK;IAClB,cAAc,EAAE,MAAM,EAAE,+DAA+D;IACvF,OAAO,EAAE;QACP,YAAY,EAAE,uBAAc,IAAI,uBAAc,CAAC,IAAI,EAAE,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,uBAAc,CAAC,CAAC,CAAC,SAAS;QAC7F,sBAAsB,EAAE,iCAAwB,KAAK,IAAI,IAAI,iCAAwB,KAAK,SAAS,CAAC,CAAC,CAAC,iCAAwB,CAAC,CAAC,CAAC,SAAS;KAC3I;CACF,CAAC;AAGJ,MAAM,aAAa,GAAG,IAAI,oBAAU,CAAC,SAAS,CAAC,CAAA;AAE/C,kBAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dbSchema.d.ts","sourceRoot":"","sources":["../../src/Database/dbSchema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAQnE;;GAEG;AACH,qBACa,qBAAqB;IACvB,0BAA0B,CAAC,QAAQ,EAAE,UAAU,EAAE,EAAE,SAAS,EAAE,MAAM,GAAG,OAAO;IAoF9E,oBAAoB,CAAC,QAAQ,EAAE,UAAU,EAAE,EAAE,eAAe,EAAE,MAAM,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,aAAa,EAAE,OAAO,GAAG,MAAM;IAuBlI,SAAS,CAAC,kBAAkB,CAAC,MAAM,EAAE,UAAU,EAAE,aAAa,EAAE,OAAO,GAAI,MAAM;IA4BjF,SAAS,CAAC,iBAAiB,CAAC,KAAK,EAAE,eAAe,EAAE,aAAa,EAAE,OAAO,GAAI,MAAM;CAavF"}
|
|
@@ -10,10 +10,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.DBSchemaGeneratorBase = void 0;
|
|
13
|
-
const logging_1 = require("
|
|
13
|
+
const logging_1 = require("../Misc/logging");
|
|
14
14
|
const fs_1 = __importDefault(require("fs"));
|
|
15
15
|
const path_1 = __importDefault(require("path"));
|
|
16
|
-
const config_1 = require("
|
|
16
|
+
const config_1 = require("../Config/config");
|
|
17
17
|
const global_1 = require("@memberjunction/global");
|
|
18
18
|
/**
|
|
19
19
|
* Base class for generating a database schema JSON output, you can sub-class this class to create your own schema generator logic
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dbSchema.js","sourceRoot":"","sources":["../../src/Database/dbSchema.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,6CAA4C;AAC5C,4CAAoB;AACpB,gDAAwB;AACxB,6CAA8C;AAC9C,mDAAuD;AAGvD;;GAEG;AAEI,IAAM,qBAAqB,GAA3B,MAAM,qBAAqB;IACvB,0BAA0B,CAAC,QAAsB,EAAE,SAAiB;QACvE,IAAI,CAAC,YAAE,CAAC,UAAU,CAAC,SAAS,CAAC;YACzB,YAAE,CAAC,SAAS,CAAC,SAAS,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,2CAA2C;QAE7F,MAAM,cAAc,GAAa,mBAAU,C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AC,IAAI;sCACH,sBAAsB;+BAC7B,KAAK,CAAC,IAAI,KAAK,SAAS,GAAG,QAAQ;oCAC9B,KAAK,CAAC,UAAU;kBAClC,CAAA;QACV,OAAO,OAAO,CAAC;IACnB,CAAC;CACJ,CAAA;AArJY,sDAAqB;gCAArB,qBAAqB;IADjC,IAAA,sBAAa,EAAC,qBAAqB,CAAC;GACxB,qBAAqB,CAqJjC"}
|
|
@@ -47,7 +47,40 @@ export declare class ManageMetadataBase {
|
|
|
47
47
|
* @param excludeSchemas
|
|
48
48
|
* @returns
|
|
49
49
|
*/
|
|
50
|
-
manageEntityFields(ds: DataSource, excludeSchemas: string[]): Promise<boolean>;
|
|
50
|
+
manageEntityFields(ds: DataSource, excludeSchemas: string[], skipCreatedAtUpdatedAtFieldValidation: boolean): Promise<boolean>;
|
|
51
|
+
/**
|
|
52
|
+
* This method ensures that the __mj_CreatedAt and __mj_UpdatedAt fields exist in each entity that has TrackRecordChanges set to true. If the fields do not exist, they are created.
|
|
53
|
+
* If the fields exist but have incorrect default values, the default values are updated. The default value that is to be used for these special fields is GETUTCDATE() which is the
|
|
54
|
+
* UTC date and time. This method is called as part of the manageEntityFields method and is not intended to be called directly.
|
|
55
|
+
* @param ds
|
|
56
|
+
*/
|
|
57
|
+
protected ensureCreatedAtUpdatedAtFieldsExist(ds: DataSource, excludeSchemas: string[]): Promise<boolean>;
|
|
58
|
+
/**
|
|
59
|
+
* This method handles the validation of the existence of the specified special date field and if it does exist it makes sure the default value is set correctly, if it doesn't exist
|
|
60
|
+
* it makes sure that it is created. This method is called as part of the ensureCreatedAtUpdatedAtFieldsExist method and is not intended to be called directly.
|
|
61
|
+
* @param entity
|
|
62
|
+
* @param fieldName
|
|
63
|
+
* @param currentFieldData
|
|
64
|
+
*/
|
|
65
|
+
protected ensureSpecialDateFieldExistsAndHasCorrectDefaultValue(ds: DataSource, entity: any, fieldName: string, currentFieldData: any): Promise<boolean>;
|
|
66
|
+
/**
|
|
67
|
+
* Creates the default constraint for a special date field. This method is called as part of the ensureSpecialDateFieldExistsAndHasCorrectDefaultValue method and is not intended to be called directly.
|
|
68
|
+
*/
|
|
69
|
+
protected createDefaultConstraintForSpecialDateField(ds: DataSource, entity: any, fieldName: string): Promise<void>;
|
|
70
|
+
/**
|
|
71
|
+
* Drops and recreates the default constraint for a special date field. This method is called as part of the ensureSpecialDateFieldExistsAndHasCorrectDefaultValue method and is not intended to be called directly.
|
|
72
|
+
* @param ds
|
|
73
|
+
* @param entity
|
|
74
|
+
* @param fieldName
|
|
75
|
+
*/
|
|
76
|
+
protected dropAndCreateDefaultConstraintForSpecialDateField(ds: DataSource, entity: any, fieldName: string): Promise<void>;
|
|
77
|
+
/**
|
|
78
|
+
* Drops an existing default constraint from a given column within a given entity, if it exists
|
|
79
|
+
* @param ds
|
|
80
|
+
* @param entity
|
|
81
|
+
* @param fieldName
|
|
82
|
+
*/
|
|
83
|
+
protected dropExistingDefaultConstraint(ds: DataSource, entity: any, fieldName: string): Promise<void>;
|
|
51
84
|
/**
|
|
52
85
|
* This method generates descriptions for entities in teh system where there is no existing description. This is an experimental feature and is done using AI. In order for it
|
|
53
86
|
* to be invoked, the EntityDescriptions feature must be enabled in the Advanced Generation configuration.
|
|
@@ -108,7 +141,7 @@ export declare class ManageMetadataBase {
|
|
|
108
141
|
protected deleteUnneededEntityFields(ds: DataSource, excludeSchemas: string[]): Promise<boolean>;
|
|
109
142
|
protected manageEntityFieldValues(ds: DataSource, excludeSchemas: string[]): Promise<boolean>;
|
|
110
143
|
protected syncEntityFieldValues(ds: DataSource, entityID: number, entityFieldName: string, possibleValues: string[]): Promise<boolean>;
|
|
111
|
-
protected parseCheckConstraintValues(constraintDefinition: string, fieldName: string): string[] | null;
|
|
144
|
+
protected parseCheckConstraintValues(constraintDefinition: string, fieldName: string, entityName: string): string[] | null;
|
|
112
145
|
protected createExcludeTablesAndSchemasFilter(fieldPrefix: string): string;
|
|
113
146
|
protected createNewEntities(ds: DataSource): Promise<boolean>;
|
|
114
147
|
protected shouldCreateNewEntity(ds: DataSource, newEntity: any): Promise<{
|
|
@@ -128,4 +161,4 @@ export declare class ManageMetadataBase {
|
|
|
128
161
|
protected stripWhitespace(s: string): string;
|
|
129
162
|
protected generatePluralName(singularName: string): string;
|
|
130
163
|
}
|
|
131
|
-
//# sourceMappingURL=
|
|
164
|
+
//# sourceMappingURL=manage-metadata.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"manage-metadata.d.ts","sourceRoot":"","sources":["../../src/Database/manage-metadata.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAErC,OAAO,EAAkF,QAAQ,EAAgB,MAAM,sBAAsB,CAAC;AAO9I;;;GAGG;AACH,qBACa,kBAAkB;IAC5B,OAAO,CAAC,MAAM,CAAC,cAAc,CAAgB;IAC7C,WAAkB,aAAa,IAAI,MAAM,EAAE,CAE1C;IAED;;;;OAIG;IACU,cAAc,CAAC,EAAE,EAAE,UAAU,GAAG,OAAO,CAAC,OAAO,CAAC;cA8C7C,qBAAqB,CAAC,EAAE,EAAE,UAAU,GAAG,OAAO,CAAC,OAAO,CAAC;cAoBvD,yBAAyB,CAAC,EAAE,EAAE,UAAU,EAAE,EAAE,EAAE,GAAG,GAAG,OAAO,CAAC,OAAO,CAAC;cA4CpE,8BAA8B,CAAC,EAAE,EAAE,UAAU,EAAE,EAAE,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,GAAG,OAAO,CAAC,OAAO,CAAC;IAuBvG;;;;;;OAMG;cACa,yBAAyB,CAAC,EAAE,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,EAAE,EAAE,EAAE,EAAE,QAAQ,GAAG,OAAO,CAAC,OAAO,CAAC;IAOnH;;;;;;OAMG;cACa,kCAAkC,CAAC,EAAE,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,EAAE,EAAG,EAAE,EAAE,QAAQ,GAAG,OAAO,CAAC,OAAO,CAA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