Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 30 additions & 9 deletions components/monday/actions/create-column/create-column.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import monday from "../../monday.app.mjs";
export default {
key: "monday-create-column",
name: "Create Column",
description: "Creates a column. [See the documentation](https://developer.monday.com/api-reference/docs/columns-queries-1)",
description: "Creates a column. [See the documentation](https://developer.monday.com/api-reference/reference/columns#create-a-column)",
type: "action",
version: "0.0.7",
version: "0.0.8",
props: {
monday,
boardId: {
Expand All @@ -25,12 +25,7 @@ export default {
label: "Column Type",
description: "The new column's title",
options: constants.COLUMN_TYPE_OPTIONS,
},
defaults: {
type: "object",
label: "Defaults",
description: "The new column's defaults.",
optional: true,
reloadProps: true,
},
description: {
type: "string",
Expand All @@ -39,6 +34,28 @@ export default {
optional: true,
},
},
async additionalProps() {
const props = {};
const defaults = {
type: "string",
label: "Defaults",
description: "The new column's defaults. For use with column types `status` or `dropdown`. [See the documentation](https://developer.monday.com/api-reference/reference/columns#create-a-status-or-dropdown-column-with-custom-labels) for additional information.",
optional: true,
};
if (this.columnType === "status") {
props.defaults = {
...defaults,
default: "{\"labels\":{\"1\":\"Option1\",\"2\":\"Option2\",\"3\":\"Option3\",\"4\": \"Option4\"}}",
};
}
if (this.columnType === "dropdown") {
props.defaults = {
...defaults,
default: "{\"settings\":{\"labels\":[{\"id\":1,\"name\":\"Option1\"}, {\"id\":2,\"name\":\"Option2\"}, {\"id\":3,\"name\":\"Option3\"}]}}",
};
}
return props;
},
async run({ $ }) {
const {
data,
Expand All @@ -49,7 +66,11 @@ export default {
boardId: +this.boardId,
title: this.title,
columnType: this.columnType,
defaults: this.defaults,
defaults: this.defaults
? typeof this.defaults !== "string"
? JSON.stringify(this.defaults)
: this.defaults
: undefined,
description: this.description,
});

Expand Down
11 changes: 2 additions & 9 deletions components/monday/actions/create-subitem/create-subitem.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ export default {
...commonCreateItem,
key: "monday-create-subitem",
name: "Create Subitem",
description: "Creates a subitem. [See the documentation](https://developer.monday.com/api-reference/docs/introduction-to-graphql#mondaycom-schema)",
description: "Creates a subitem. [See the documentation](https://developer.monday.com/api-reference/reference/subitems#create-a-subitem)",
type: "action",
version: "0.0.2",
version: "0.0.3",
props: {
monday,
boardId: {
Expand All @@ -35,12 +35,6 @@ export default {
],
description: "The new subitem's name",
},
createLabels: {
propDefinition: [
monday,
"itemCreateLabels",
],
},
...commonCreateItem.props,
},
methods: {
Expand All @@ -50,7 +44,6 @@ export default {
parentItemId: utils.emptyStrToUndefined(this.parentItemId),
itemName: utils.emptyStrToUndefined(this.itemName),
columnValues: utils.strinfied(columnValues),
createLabels: utils.emptyStrToUndefined(this.createLabels),
});
},
getItemId(data) {
Expand Down
4 changes: 2 additions & 2 deletions components/monday/actions/create-update/create-update.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import monday from "../../monday.app.mjs";
export default {
key: "monday-create-update",
name: "Create an Update",
description: "Creates a new update. [See the documentation](https://api.developer.monday.com/docs/updates-queries#create-an-update)",
description: "Creates a new update. [See the documentation](https://developer.monday.com/api-reference/reference/updates#create-an-update)",
type: "action",
version: "0.0.9",
version: "0.0.10",
props: {
monday,
updateBody: {
Expand Down
4 changes: 2 additions & 2 deletions components/monday/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@pipedream/monday",
"version": "0.6.2",
"version": "0.6.3",
"description": "Pipedream Monday Components",
"main": "monday.app.mjs",
"keywords": [
Expand All @@ -14,7 +14,7 @@
"access": "public"
},
"dependencies": {
"@pipedream/platform": "^1.6.0",
"@pipedream/platform": "^3.0.3",
"form-data": "^4.0.0",
"lodash.flatmap": "^4.5.0",
"lodash.map": "^4.6.0",
Expand Down
22 changes: 22 additions & 0 deletions components/monday_oauth/actions/create-board/create-board.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import app from "../../monday_oauth.app.mjs";
import common from "../../../monday/actions/create-board/create-board.mjs";

import { adjustPropDefinitions } from "../../common/utils.mjs";

const {
name, description, type, ...others
} = common;
const props = adjustPropDefinitions(others.props, app);

export default {
...others,
key: "monday_oauth-create-board",
version: "0.0.1",
name,
description,
type,
props: {
monday: app,
...props,
},
};
22 changes: 22 additions & 0 deletions components/monday_oauth/actions/create-column/create-column.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import app from "../../monday_oauth.app.mjs";
import common from "../../../monday/actions/create-column/create-column.mjs";

import { adjustPropDefinitions } from "../../common/utils.mjs";

const {
name, description, type, ...others
} = common;
const props = adjustPropDefinitions(others.props, app);

export default {
...others,
key: "monday_oauth-create-column",
version: "0.0.1",
name,
description,
type,
props: {
monday: app,
...props,
},
};
22 changes: 22 additions & 0 deletions components/monday_oauth/actions/create-group/create-group.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import app from "../../monday_oauth.app.mjs";
import common from "../../../monday/actions/create-group/create-group.mjs";

import { adjustPropDefinitions } from "../../common/utils.mjs";

const {
name, description, type, ...others
} = common;
const props = adjustPropDefinitions(others.props, app);

export default {
...others,
key: "monday_oauth-create-group",
version: "0.0.1",
name,
description,
type,
props: {
monday: app,
...props,
},
};
22 changes: 22 additions & 0 deletions components/monday_oauth/actions/create-item/create-item.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import app from "../../monday_oauth.app.mjs";
import common from "../../../monday/actions/create-item/create-item.mjs";

import { adjustPropDefinitions } from "../../common/utils.mjs";

const {
name, description, type, ...others
} = common;
const props = adjustPropDefinitions(others.props, app);

export default {
...others,
key: "monday_oauth-create-item",
version: "0.0.1",
name,
description,
type,
props: {
monday: app,
...props,
},
};
22 changes: 22 additions & 0 deletions components/monday_oauth/actions/create-subitem/create-subitem.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import app from "../../monday_oauth.app.mjs";
import common from "../../../monday/actions/create-subitem/create-subitem.mjs";

import { adjustPropDefinitions } from "../../common/utils.mjs";

const {
name, description, type, ...others
} = common;
const props = adjustPropDefinitions(others.props, app);

export default {
...others,
key: "monday_oauth-create-subitem",
version: "0.0.1",
name,
description,
type,
props: {
monday: app,
...props,
},
};
22 changes: 22 additions & 0 deletions components/monday_oauth/actions/create-update/create-update.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import app from "../../monday_oauth.app.mjs";
import common from "../../../monday/actions/create-update/create-update.mjs";

import { adjustPropDefinitions } from "../../common/utils.mjs";

const {
name, description, type, ...others
} = common;
const props = adjustPropDefinitions(others.props, app);

export default {
...others,
key: "monday_oauth-create-update",
version: "0.0.1",
name,
description,
type,
props: {
monday: app,
...props,
},
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import app from "../../monday_oauth.app.mjs";
import common from "../../../monday/actions/get-column-values/get-column-values.mjs";

import { adjustPropDefinitions } from "../../common/utils.mjs";

const {
name, description, type, ...others
} = common;
const props = adjustPropDefinitions(others.props, app);

export default {
...others,
key: "monday_oauth-get-column-values",
version: "0.0.1",
name,
description,
type,
props: {
monday: app,
...props,
},
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import app from "../../monday_oauth.app.mjs";
import common from "../../../monday/actions/get-items-by-column-value/get-items-by-column-value.mjs";

import { adjustPropDefinitions } from "../../common/utils.mjs";

const {
name, description, type, ...others
} = common;
const props = adjustPropDefinitions(others.props, app);

export default {
...others,
key: "monday_oauth-get-items-by-column-value",
version: "0.0.1",
name,
description,
type,
props: {
monday: app,
...props,
},
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import app from "../../monday_oauth.app.mjs";
import common from "../../../monday/actions/update-column-values/update-column-values.mjs";

import { adjustPropDefinitions } from "../../common/utils.mjs";

const {
name, description, type, ...others
} = common;
const props = adjustPropDefinitions(others.props, app);

export default {
...others,
key: "monday_oauth-update-column-values",
version: "0.0.1",
name,
description,
type,
props: {
monday: app,
...props,
},
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import app from "../../monday_oauth.app.mjs";
import common from "../../../monday/actions/update-item-name/update-item-name.mjs";

import { adjustPropDefinitions } from "../../common/utils.mjs";

const {
name, description, type, ...others
} = common;
const props = adjustPropDefinitions(others.props, app);

export default {
...others,
key: "monday_oauth-update-item-name",
version: "0.0.1",
name,
description,
type,
props: {
monday: app,
...props,
},
};
Loading
Loading