@builttocreate/engine-utils 1.8.1-rc.1.3.1 → 1.8.1-rc.1.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/activityHelper.js +0 -2
- package/dist/fieldHelper.js +0 -22
- package/dist/tableHelper.js +0 -6
- package/package.json +1 -1
package/dist/activityHelper.js
CHANGED
|
@@ -116,9 +116,7 @@ var addDocumentDataToActivities = function addDocumentDataToActivities(activitie
|
|
|
116
116
|
* Added as a fix for table bug that did not display proper output for formula cells
|
|
117
117
|
* as rowIndex was messy
|
|
118
118
|
*/
|
|
119
|
-
console.log('tableDoc field value', docFieldValue);
|
|
120
119
|
var nextDocFieldValue = (0, _tableHelper.getRows)(docFieldValue);
|
|
121
|
-
console.log('nextDocFiedlValues', nextDocFieldValue);
|
|
122
120
|
|
|
123
121
|
if (!fieldRowsLookup[templateField._id]) {
|
|
124
122
|
fieldRowsLookup[templateField._id] = (0, _tableHelper.getTableRowLookupWithPopulatedDropdownCells)(templateField.tableColumns, nextDocFieldValue);
|
package/dist/fieldHelper.js
CHANGED
|
@@ -182,28 +182,6 @@ var getImportFieldValues = function getImportFieldValues(template, importSource,
|
|
|
182
182
|
* @param {} template
|
|
183
183
|
* @returns
|
|
184
184
|
*/
|
|
185
|
-
// export const getTemplateWithLookups = (template) => {
|
|
186
|
-
// const nextTemplate = { ...template };
|
|
187
|
-
// nextTemplate.fields = template.fields.map((field) => {
|
|
188
|
-
// const nextField = { ...field };
|
|
189
|
-
// nextField.optionsLookup = {};
|
|
190
|
-
// if (nextField.options) {
|
|
191
|
-
// nextField.options.forEach((option) => nextField.optionsLookup[option._id] = option);
|
|
192
|
-
// }
|
|
193
|
-
// if (nextField.tableColumns) {
|
|
194
|
-
// nextField.tableColumnsLookup = {};
|
|
195
|
-
// nextField.tableColumns.forEach((column, index) => {
|
|
196
|
-
// const nextColumn = { ...column, optionsLookup: {} }
|
|
197
|
-
// if (nextColumn.options) {
|
|
198
|
-
// nextColumn.options.forEach((option) => nextColumn.optionsLookup[option._id] = option);
|
|
199
|
-
// }
|
|
200
|
-
// nextField.tableColumns[index] = nextColumn
|
|
201
|
-
// });
|
|
202
|
-
// }
|
|
203
|
-
// return nextField;
|
|
204
|
-
// });
|
|
205
|
-
// return nextTemplate;
|
|
206
|
-
// }
|
|
207
185
|
|
|
208
186
|
|
|
209
187
|
exports.getImportFieldValues = getImportFieldValues;
|
package/dist/tableHelper.js
CHANGED
|
@@ -733,9 +733,6 @@ var getTableRowLookupWithPopulatedDropdownCells = function getTableRowLookupWith
|
|
|
733
733
|
var tableLookup = generateTableLookup(rows, columns);
|
|
734
734
|
var validRows = getRows(rows);
|
|
735
735
|
var validColumns = getColumns(columns);
|
|
736
|
-
console.log('---------------------------------------------------------');
|
|
737
|
-
console.log('rows, columns', rows, columns);
|
|
738
|
-
console.log('valid rows , columns', validRows, validColumns);
|
|
739
736
|
validRows.forEach(function (row, rowIndex) {
|
|
740
737
|
var nextRow = _objectSpread(_objectSpread({}, row), {}, {
|
|
741
738
|
cells: _objectSpread({}, row.cells)
|
|
@@ -743,10 +740,7 @@ var getTableRowLookupWithPopulatedDropdownCells = function getTableRowLookupWith
|
|
|
743
740
|
|
|
744
741
|
validColumns.forEach(function (column, i) {
|
|
745
742
|
var cellOperand = getCellOperand(column.operand, rowIndex + 1);
|
|
746
|
-
console.log('column, rowIndex, cellOpearand', column, rowIndex, cellOperand);
|
|
747
743
|
var value = tableLookup[cellOperand];
|
|
748
|
-
console.log('tableLookup, tableLookup[cellOpearnad]', tableLookup, tableLookup[cellOperand]);
|
|
749
|
-
console.log('***************************************************************************************');
|
|
750
744
|
|
|
751
745
|
if (value && column.type === _FieldTableColumnTypes["default"].dropdown) {
|
|
752
746
|
nextRow.cells[column._id] = column.optionsLookup[value] ? column.optionsLookup[value].value : value;
|