Skip to content

Commit

Permalink
refactor: merge main
Browse files Browse the repository at this point in the history
  • Loading branch information
henrikbossart committed Oct 13, 2023
2 parents be0d5cb + 0cedd33 commit 8fd333a
Show file tree
Hide file tree
Showing 26 changed files with 201 additions and 178 deletions.
16 changes: 14 additions & 2 deletions .github/workflows/on-main-push.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,24 @@ jobs:
run: yarn build:packages

- name: Publish dm-core package
run: yarn workspace @development-framework/dm-core publish --access public
run: |
PACKAGE_VERSION=$(cat packages/dm-core/package.json | jq '.["version"]' | tr -d '"')
PACKAGE_NAME=$(cat packages/dm-core/package.json | jq '.["name"]' | tr -d '"')
VERSION_EXISTS=$(curl --HEAD --output /dev/null --silent -w "%{http_code}" https://registry.npmjs.org/$PACKAGE_NAME/$PACKAGE_VERSION)
if [[ $VERSION_EXISTS == 404 ]]; then
yarn workspace @development-framework/dm-core publish --access public
fi
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Publish dm-core-plugins package
run: yarn workspace @development-framework/dm-core-plugins publish --access public
run: |
PACKAGE_VERSION=$(cat packages/dm-core-plugins/package.json | jq '.["version"]' | tr -d '"')
PACKAGE_NAME=$(cat packages/dm-core-plugins/package.json | jq '.["name"]' | tr -d '"')
VERSION_EXISTS=$(curl --HEAD --output /dev/null --silent -w "%{http_code}" https://registry.npmjs.org/$PACKAGE_NAME/$PACKAGE_VERSION)
if [[ $VERSION_EXISTS == 404 ]]; then
yarn workspace @development-framework/dm-core-plugins publish --access public
fi
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

Expand Down
4 changes: 2 additions & 2 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"packages/dm-core": "1.6.2",
"packages/dm-core-plugins": "1.7.2"
"packages/dm-core": "1.6.4",
"packages/dm-core-plugins": "1.8.1"
}
14 changes: 11 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,21 @@ See under `packages/` for list of available plugins or [NPM](https://www.npmjs.c
<a id="quickstart"></a>
## :zap: Quickstart

First, install the plugin:
First, install the plugins:

```
yarn install @development-framework/<plugin>
yarn install @development-framework/dm-core-plugins
```

Add the installed plugin to the `src/plugins.js` file.
Add the installed plugins to the `src/plugins.js` file.

```
import dmCorePlugins from '@development-framework/dm-core-plugins'
export default {
...dmCorePlugins
}
```

<a id="development"></a>
## :dizzy: Development
Expand Down
3 changes: 2 additions & 1 deletion example/.env.dev
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
VITE_REDIRECT_URI=https://application-dm-demos-dev.radix.equinor.com
VITE_DMSS_URL=https://dmss-dm-demos-dev.radix.equinor.com
VITE_DMSS_URL=https://dmss-dm-demos-dev.radix.equinor.com
VITE_DM_JOB_URL=https://job-dm-demos-dev.radix.equinor.com
3 changes: 2 additions & 1 deletion example/.env.prod
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
# Use this as a template when creating new .env.[mode] file

VITE_REDIRECT_URI=https://application-dm-demos-prod.radix.equinor.com
VITE_DMSS_URL=https://dmss-dm-demos-prod.radix.equinor.com
VITE_DMSS_URL=https://dmss-dm-demos-prod.radix.equinor.com
VITE_DM_JOB_URL=https://job-dm-demos-prod.radix.equinor.com
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"name": "fetch_omniaTS_signal_jobs",
"type": "dmss://DemoDataSource/apps/MySignalApp/models/JobList",
"jobs": []
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"name": "JobList",
"type": "CORE:Blueprint",
"attributes": [
{
"name": "name",
"type": "CORE:BlueprintAttribute",
"attributeType": "string"
},
{
"name": "type",
"type": "CORE:BlueprintAttribute",
"attributeType": "string"
},
{
"name": "jobs",
"type": "CORE:BlueprintAttribute",
"label": "Jobs",
"attributeType": "JOBCORE:Job",
"optional": false,
"dimensions": "*"
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -104,21 +104,18 @@
"config": {
"type": "PLUGINS:dm-core-plugins/job/JobConfig",
"jobTargetAddress": {
"type": "PLUGINS:dm-core-plugins/job/JobTargetAddress",
"jobAddress": ".job",
"jobAddressScope": "local"
"type": "PLUGINS:dm-core-plugins/job/TargetAddress",
"targetAddress": ".job",
"addressScope": "local"
},
"label": "signal job",
"runner": {
"type": "dmss://DemoDataSource/apps/MySignalApp/models/SignalGeneratorJob"
},
"outputTarget": ".signal",
"jobInput": {
"type": "PLUGINS:dm-core-plugins/job/JobInput",
"_type": "dmss://system/SIMOS/Reference",
"referenceType": "link",
"jobInputAddress": ".study.cases[0]",
"jobInputAddressScope": "local"
"type": "PLUGINS:dm-core-plugins/job/TargetAddress",
"targetAddress": "."
}
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,42 +2,22 @@
"type": "CORE:RecipeLink",
"_blueprintPath_": "/plugins/form/read_only_primitives/blueprints/ReadOnlyPrimitives",
"initialUiRecipe": {
"name": "ViewSelector",
"name": "ReadOnly",
"type": "CORE:UiRecipe",
"plugin": "@development-framework/dm-core-plugins/view_selector/tabs",
"plugin": "@development-framework/dm-core-plugins/form",
"category": "edit",
"config": {
"type": "PLUGINS:dm-core-plugins/view_selector/ViewSelectorConfig",
"childTabsOnRender": true,
"items": [
{
"type": "PLUGINS:dm-core-plugins/view_selector/ViewSelectorItem",
"viewConfig": {
"type": "CORE:ReferenceViewConfig",
"recipe": "ReadOnly"
}
}
]
"type": "PLUGINS:dm-core-plugins/form/FormInput",
"fields": [
"stringRequired",
"stringOptional",
"numberRequired",
"numberOptional",
"integer",
"checkboxOptional",
"checkboxRequired"
],
"readOnly": true
}
},
"uiRecipes": [
{
"name": "ReadOnly",
"type": "CORE:UiRecipe",
"plugin": "@development-framework/dm-core-plugins/form",
"category": "edit",
"config": {
"type": "PLUGINS:dm-core-plugins/form/FormInput",
"fields": [
"stringRequired",
"stringOptional",
"numberRequired",
"numberOptional",
"integer",
"checkboxOptional",
"checkboxRequired"
],
"readOnly": true
}
}
]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,9 @@
"type": "CORE:RecipeLink",
"_blueprintPath_": "/plugins/form/simple/blueprints/Simple",
"initialUiRecipe": {
"name": "ViewSelector",
"name": "Edit",
"type": "CORE:UiRecipe",
"plugin": "@development-framework/dm-core-plugins/view_selector/tabs",
"config": {
"type": "PLUGINS:dm-core-plugins/view_selector/ViewSelectorConfig",
"childTabsOnRender": true,
"items": [
{
"type": "PLUGINS:dm-core-plugins/view_selector/ViewSelectorItem",
"viewConfig": {
"type": "CORE:InlineRecipeViewConfig",
"recipe": {
"name": "Edit",
"type": "CORE:UiRecipe",
"description": "Default edit",
"plugin": "@development-framework/dm-core-plugins/form"
},
"scope": "self"
}
}
]
}
"description": "Default edit",
"plugin": "@development-framework/dm-core-plugins/form"
}
}
22 changes: 11 additions & 11 deletions example/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ services:
MONGO_INITDB_ROOT_PASSWORD: xd7wCEhEx4kszsecYFfC

job-api:
image: datamodelingtool.azurecr.io/dm-job:v1.2.1
image: datamodelingtool.azurecr.io/dm-job:v1.2.2
platform: linux/amd64
restart: unless-stopped
environment:
Expand All @@ -55,16 +55,16 @@ services:
ports:
- '5001:5000'

# db-ui:
# image: mongo-express:1.0.0-alpha
# restart: unless-stopped
# ports:
# - "8082:8081"
# environment:
# ME_CONFIG_MONGODB_SERVER: db
# ME_CONFIG_MONGODB_ADMINUSERNAME: maf
# ME_CONFIG_MONGODB_ADMINPASSWORD: maf
# ME_CONFIG_MONGODB_ENABLE_ADMIN: "true"
# db-ui:
# image: mongo-express:1.0.0-alpha
# restart: unless-stopped
# ports:
# - "8082:8081"
# environment:
# ME_CONFIG_MONGODB_SERVER: db
# ME_CONFIG_MONGODB_ADMINUSERNAME: root
# ME_CONFIG_MONGODB_ADMINPASSWORD: xd7wCEhEx4kszsecYFfC
# ME_CONFIG_MONGODB_ENABLE_ADMIN: "true"

job-store:
image: redis:6.2.5-alpine
Expand Down
2 changes: 1 addition & 1 deletion example/reset-app.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,6 @@ fi
echo "Upload plugins blueprints to DMSS"
dm --token "$TOKEN" --url $VITE_DMSS_URL import-plugin-blueprints ../node_modules/@development-framework/dm-core-plugins
echo "Upload app/ to DMSS"
dm --token "$TOKEN" --url $VITE_DMSS_URL reset app
dm --force --token "$TOKEN" --url $VITE_DMSS_URL reset app
echo "Creating lookup table"
dm --token "$TOKEN" --url $VITE_DMSS_URL create-lookup example DemoDataSource/recipes
25 changes: 25 additions & 0 deletions packages/dm-core-plugins/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,31 @@
* dependencies
* @development-framework/dm-core bumped from ^1.6.0 to ^1.6.1

### Dependencies

* The following workspace dependencies were updated
* dependencies
* @development-framework/dm-core bumped from ^1.6.3 to ^1.6.4

## [1.8.0](https://github.com/equinor/dm-core-packages/compare/dm-core-plugins-v1.7.2...dm-core-plugins-v1.8.0) (2023-10-10)


### Features

* storage uncontained ([e8f3c13](https://github.com/equinor/dm-core-packages/commit/e8f3c13e99e29570d5c25a0abc3d230a0a7044e9))


### Bug Fixes

* make it possible to append to lists in explorer plugin ([4ce8bd2](https://github.com/equinor/dm-core-packages/commit/4ce8bd2bf1073b68b3ed940be42520228510a1fe))


### Dependencies

* The following workspace dependencies were updated
* dependencies
* @development-framework/dm-core bumped from ^1.6.2 to ^1.6.3

## [1.7.2](https://github.com/equinor/dm-core-packages/compare/dm-core-plugins-v1.7.1...dm-core-plugins-v1.7.2) (2023-10-10)


Expand Down
7 changes: 4 additions & 3 deletions packages/dm-core-plugins/blueprints/job/JobConfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
{
"name": "outputTarget",
"type": "CORE:BlueprintAttribute",
"attributeType": "string"
"attributeType": "string",
"optional": true
},
{
"name": "label",
Expand All @@ -26,12 +27,12 @@
{
"name": "jobTargetAddress",
"type": "CORE:BlueprintAttribute",
"attributeType": "PLUGINS:dm-core-plugins/job/JobTargetAddress"
"attributeType": "PLUGINS:dm-core-plugins/job/TargetAddress"
},
{
"name": "jobInput",
"type": "CORE:BlueprintAttribute",
"attributeType": "PLUGINS:dm-core-plugins/job/JobInput"
"attributeType": "PLUGINS:dm-core-plugins/job/TargetAddress"
}
]
}
34 changes: 0 additions & 34 deletions packages/dm-core-plugins/blueprints/job/JobInput.json

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "JobTargetAddress",
"name": "TargetAddress",
"type": "CORE:Blueprint",
"description": "",
"attributes": [
Expand All @@ -9,12 +9,14 @@
"attributeType": "string"
},
{
"name": "jobAddressScope",
"name": "addressScope",
"type": "CORE:BlueprintAttribute",
"attributeType": "string"
"attributeType": "string",
"optional": true,
"default": "local"
},
{
"name": "jobAddress",
"name": "targetAddress",
"type": "CORE:BlueprintAttribute",
"attributeType": "string"
}
Expand Down
4 changes: 2 additions & 2 deletions packages/dm-core-plugins/package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"name": "@development-framework/dm-core-plugins",
"license": "MIT",
"version": "1.7.2",
"version": "1.8.1",
"main": "dist/index.js",
"dependencies": {
"@development-framework/dm-core": "^1.6.2",
"@development-framework/dm-core": "^1.6.4",
"@equinor/eds-core-react": "^0.33.0",
"@equinor/eds-icons": "^0.19.3",
"@equinor/eds-tokens": "^0.9.0",
Expand Down
Loading

0 comments on commit 8fd333a

Please sign in to comment.