Commit 39b98c16 authored by Безуглый Андрей's avatar Безуглый Андрей
Browse files

Version: 2.0.0-alpha.1

Adopted to UB 4.0.0-alpha.3
parent f1cbb208
# 2.0.0-alpha.1
Updated references to UB packages.
Breaking change - it won't work with UB version less then 4.0.0-alpha.
# 1.1.1
- Patched `loadAdm` to recognized users and groups
const
path = require('path'),
_ = require('lodash'),
dataLoader = require('dataLoader'),
COMMON_UB_MODEL_PREFIX = 'ub_model_';
dataLoader = require('@unitybase/base/dataLoader');
/**
* @param {number} entityNameColIndex Index of column with entity name.
......@@ -70,9 +69,6 @@ function _getModelName(dirName) {
dirName = path.dirname(dirName);
modelName = path.basename(dirName);
}
if (modelName.startsWith(COMMON_UB_MODEL_PREFIX)) {
modelName = modelName.slice(COMMON_UB_MODEL_PREFIX.length);
}
return modelName;
}
......@@ -169,7 +165,7 @@ function loadLocaleFromCsv(session, dirName, locale, entityName, attrs, keyAttrs
}
// TODO: remove as soon as Pasha add this to dataLoader module
const csv = require('csv1'), fs = require('fs');
const csv = require('@unitybase/base/csv1'), fs = require('fs');
/**
* Load data from CSV with delimiter (";" by default)
* @param {string} fileName Full path to file
......
{
"name": "@unitybase/csv-loader-utils",
"version": "1.1.1",
"version": "2.0.0-alpha.1",
"description": "Extension of '@unitybase/dataLoader' package, which contains helper methods to initialize UnityBase models from csv files.",
"dependencies": {
"@unitybase/base": "^4.0.7",
"lodash": "^4"
},
"devDependencies": {},
"engines": {
"UnityBase": ">=4.0"
"UnityBase": "^4.0.0-alpha.3"
},
"publishConfig": {
"registry": "http://registry.unitybase.info"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment