features初始化流程的更新
This commit is contained in:
parent
d9eebd7b1e
commit
79821cb8ec
|
|
@ -15,9 +15,9 @@ function packageJsonContent({ name, version, description, cliVersion, cliName, c
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
oakDependencyStr = `"oak-common-aspect": "^1.0.2",
|
oakDependencyStr = `"oak-common-aspect": "^1.0.2",
|
||||||
"oak-domain": "^1.1.4",
|
"oak-domain": "^1.1.7",
|
||||||
"oak-frontend-base": "^1.0.7",
|
"oak-frontend-base": "^1.0.7",
|
||||||
"oak-general-business": "^1.0.7",
|
"oak-general-business": "^1.0.8",
|
||||||
"oak-external-sdk": "^1.0.2",
|
"oak-external-sdk": "^1.0.2",
|
||||||
"oak-memory-tree-store": "^1.0.4",`;
|
"oak-memory-tree-store": "^1.0.4",`;
|
||||||
oakDevDependencyStr = `"${cliName}": "^${cliVersion}",`;
|
oakDevDependencyStr = `"${cliName}": "^${cliVersion}",`;
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
import { EntityDict } from 'oak-app-domain';
|
import { EntityDict } from 'oak-app-domain';
|
||||||
import { BasicFeatures } from 'oak-frontend-base/lib/features';
|
import { BasicFeatures } from 'oak-frontend-base/lib/features';
|
||||||
|
import { GeneralFeatures } from 'oak-general-business/lib/features';
|
||||||
import { CommonAspectDict } from 'oak-common-aspect';
|
import { CommonAspectDict } from 'oak-common-aspect';
|
||||||
import * as Sample from './Sample';
|
import * as Sample from './Sample';
|
||||||
import { AspectDict } from '../aspects/AspectDict';
|
import { AspectDict } from '../aspects/AspectDict';
|
||||||
|
|
@ -16,6 +17,11 @@ export function initialize(
|
||||||
EntityDict,
|
EntityDict,
|
||||||
RuntimeContext,
|
RuntimeContext,
|
||||||
AspectDict & CommonAspectDict<EntityDict, RuntimeContext>
|
AspectDict & CommonAspectDict<EntityDict, RuntimeContext>
|
||||||
|
>,
|
||||||
|
generalFeatures: GeneralFeatures<
|
||||||
|
EntityDict,
|
||||||
|
RuntimeContext,
|
||||||
|
AspectDict & CommonAspectDict<EntityDict, RuntimeContext>
|
||||||
>
|
>
|
||||||
) {
|
) {
|
||||||
const { cache } = basicFeatures;
|
const { cache } = basicFeatures;
|
||||||
|
|
|
||||||
|
|
@ -41,19 +41,19 @@ export default function initialize(
|
||||||
>,
|
>,
|
||||||
context: RuntimeContext
|
context: RuntimeContext
|
||||||
) => {
|
) => {
|
||||||
const { token, extraFile, application } = initializeGeneralFeatures<
|
const generalFeatures = initializeGeneralFeatures<
|
||||||
EntityDict,
|
EntityDict,
|
||||||
RuntimeContext,
|
RuntimeContext,
|
||||||
AspectDict
|
AspectDict
|
||||||
>(aspectWrapper, basicFeatures, type, context);
|
>(aspectWrapper, basicFeatures, type, context);
|
||||||
|
|
||||||
const features = initializeFeatures(aspectWrapper, basicFeatures);
|
const features = initializeFeatures(
|
||||||
|
aspectWrapper,
|
||||||
|
basicFeatures,
|
||||||
|
generalFeatures
|
||||||
|
);
|
||||||
const features2 = Object.assign(
|
const features2 = Object.assign(
|
||||||
{
|
generalFeatures,
|
||||||
token,
|
|
||||||
extraFile,
|
|
||||||
application,
|
|
||||||
},
|
|
||||||
features
|
features
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -37,19 +37,19 @@ export default function initialize(
|
||||||
>,
|
>,
|
||||||
context: RuntimeContext
|
context: RuntimeContext
|
||||||
) => {
|
) => {
|
||||||
const { token, extraFile, application } = initializeGeneralFeatures<
|
const generalFeatures = initializeGeneralFeatures<
|
||||||
EntityDict,
|
EntityDict,
|
||||||
RuntimeContext,
|
RuntimeContext,
|
||||||
AspectDict
|
AspectDict
|
||||||
>(aspectWrapper, basicFeatures, type, context);
|
>(aspectWrapper, basicFeatures, type, context);
|
||||||
|
|
||||||
const features = initializeFeatures(aspectWrapper, basicFeatures);
|
const features = initializeFeatures(
|
||||||
|
aspectWrapper,
|
||||||
|
basicFeatures,
|
||||||
|
generalFeatures
|
||||||
|
);
|
||||||
const features2 = Object.assign(
|
const features2 = Object.assign(
|
||||||
{
|
generalFeatures,
|
||||||
token,
|
|
||||||
extraFile,
|
|
||||||
application,
|
|
||||||
},
|
|
||||||
features
|
features
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue