Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@8base/utils

Package Overview
Dependencies
Maintainers
2
Versions
235
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@8base/utils - npm Package Compare versions

Comparing version 0.16.9 to 0.16.10

15

dist/queryGenerators/queryGenerators.js

@@ -10,3 +10,3 @@ "use strict";

});
exports.createTableRowDeleteTag = exports.createTableRowQueryTag = exports.createTableRowUpdateTag = exports.createTableRowCreateTag = exports.createTableFilterGraphqlTag = void 0;
exports.createTableRowDeleteTag = exports.createTableRowQueryTag = exports.createTableRowUpdateTag = exports.createTableRowCreateManyTag = exports.createTableRowCreateTag = exports.createTableFilterGraphqlTag = void 0;

@@ -78,2 +78,15 @@ var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread"));

var createTableRowCreateManyTag = function createTableRowCreateManyTag(tablesList, tableName) {
var table = getTableByName(tablesList, tableName);
var hasNonMetaFields = tableSelectors.hasNonMetaFields(table);
if (hasNonMetaFields) {
return "\n mutation DataViewer".concat(upperFirst(tableName), "RowCreateMany($data: [").concat(_schemaNameGenerator.SchemaNameGenerator.getCreateManyInputName(tableName), "]!) {\n ").concat(_schemaNameGenerator.SchemaNameGenerator.getCreateManyItemFieldName(tableName), "(data: $data) {\n count\n }\n }");
}
return "\n mutation DataViewer".concat(upperFirst(tableName), "RowCreateMany {\n ").concat(_schemaNameGenerator.SchemaNameGenerator.getCreateManyItemFieldName(tableName), " {\n count\n }\n }");
};
exports.createTableRowCreateManyTag = createTableRowCreateManyTag;
var createTableRowUpdateTag = function createTableRowUpdateTag(tablesList, tableName) {

@@ -80,0 +93,0 @@ var config = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};

2

package.json
{
"name": "@8base/utils",
"version": "0.16.9",
"version": "0.16.10",
"main": "dist/index.js",

@@ -5,0 +5,0 @@ "module": "dist/index.js",

@@ -86,2 +86,23 @@ // @flow

export const createTableRowCreateManyTag = (tablesList: TableSchema[], tableName: string) => {
const table = getTableByName(tablesList, tableName);
const hasNonMetaFields = tableSelectors.hasNonMetaFields(table);
if (hasNonMetaFields) {
return `
mutation DataViewer${upperFirst(tableName)}RowCreateMany($data: [${SchemaNameGenerator.getCreateManyInputName(tableName)}]!) {
${SchemaNameGenerator.getCreateManyItemFieldName(tableName)}(data: $data) {
count
}
}`;
}
return `
mutation DataViewer${upperFirst(tableName)}RowCreateMany {
${SchemaNameGenerator.getCreateManyItemFieldName(tableName)} {
count
}
}`;
};
export const createTableRowUpdateTag = (tablesList: TableSchema[], tableName: string, config: QueryGeneratorConfig = {}) => `

@@ -88,0 +109,0 @@ mutation DataViewer${upperFirst(tableName)}RowUpdate($data: ${SchemaNameGenerator.getUpdateInputName(tableName)}!, $filter: ${SchemaNameGenerator.getKeyFilterInputTypeName(tableName)}) {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc