Skip to content
Snippets Groups Projects
Commit 34daf5f5 authored by vkovtun's avatar vkovtun
Browse files

Merge branch 'master' into ssdm-10474-collection-form-views-config

# Conflicts:
#	openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/master-data/common-data-model.xls
parents 17e6e177 3ca54962
No related branches found
No related tags found
No related merge requests found
......@@ -42,6 +42,7 @@ if not ELNFixes.isMultiGroup():
props = CustomASServiceExecutionOptions().withParameter('xls', helper.getByteArray("single-group-data-model.xls"))\
.withParameter('xls_name', 'ELN-LIMS').withParameter('update_mode', 'UPDATE_IF_EXISTS')\
.withParameter('scripts', helper.getAllScripts())
result = api.executeCustomASService(sessionToken, CustomASServiceCode("xls-import-api"), props)
ELNCollectionTypeMigration.afterUpgrade()
......
No preview for this file type
......@@ -138,15 +138,17 @@ function SampleTableView(sampleTableController, sampleTableModel) {
}
var title = "NEW Batch Register " + ELNDictionary.Samples;
var $xslBatchRegisterOption = $("<li>", { 'role' : 'presentation' }).append($("<a>", {'title' : title, 'id' : 'xsl-register-' + ELNDictionary.Sample.toLowerCase() + '-btn'}).append(title));
var label = "XLS Batch Register " + ELNDictionary.Samples;
var id = 'xsl-register-' + ELNDictionary.Sample.toLowerCase() + '-btn';
var $xslBatchRegisterOption = $("<li>", { 'role' : 'presentation' }).append($("<a>", {'title' : label, 'id' : id}).append(label));
$xslBatchRegisterOption.click(function() {
_this._sampleTableController.registerSamples(_this._sampleTableModel.experimentIdentifier);
});
$list.append($xslBatchRegisterOption);
var title = "NEW Batch Update " + ELNDictionary.Samples;
var $xslBatchUpdateOption = $("<li>", { 'role' : 'presentation' }).append($("<a>", {'title' : title, 'id' : 'xsl-update-' + ELNDictionary.Sample.toLowerCase() + '-btn'}).append(title));
var label = "XLS Batch Update " + ELNDictionary.Samples;
var id = 'xsl-update-' + ELNDictionary.Sample.toLowerCase() + '-btn';
var $xslBatchUpdateOption = $("<li>", { 'role' : 'presentation' }).append($("<a>", {'title' : label, 'id' : id}).append(label));
$xslBatchUpdateOption.click(function() {
_this._sampleTableController.updateSamples(_this._sampleTableModel.experimentIdentifier);
});
......
......@@ -3,13 +3,18 @@ from org.apache.poi.ss.usermodel import CellType
from org.apache.poi.ss.usermodel import WorkbookFactory
from org.apache.poi.ss.util import NumberToTextConverter
from java.io import ByteArrayInputStream
from ch.systemsx.cisd.common.exceptions import UserFailureException
class ExcelToPoiParser(object):
@staticmethod
def parse(excel_byte_array):
workbook = WorkbookFactory.create(ByteArrayInputStream(excel_byte_array))
try:
workbook = WorkbookFactory.create(ByteArrayInputStream(excel_byte_array))
except:
raise UserFailureException("Couldn't import file because it has probably a wrong format. " +
"Only spreadsheet (aka Excel) files of type .xls or .xlsx can be imported.")
definitions = []
for sheet in workbook.sheetIterator():
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment