Connector fails when id contains an underscore

The connector fails to insert/update/delete when the id of the item contains an underscore. I believe it is due to the row data being separated by an underscore as well?

DataProcessor object initialized
Test_1__{group_param}_tr_id => Test 1__{group_param}
Test_1__{group_param}_tr_pid => 0
Test_1__{group_param}_tr_order => 2
Test_1__{group_param}_tr_text => Test 1
Test_1__{group_param}_!nativeeditor_status => inserted
ids => Test 1__{group_param}

Row data [Test 1__{group_param}]

exception 'Exception' with message 'Status of record [Test 1__{group_param}] not found in incoming request' in [path]/dataprocessor.php:72

Edit operation finished

Unfortunately this is expected. The “_” character is used as separator for id values and this can’t be changed without code modifications.

The TreeGroup Connector automatically is adding these underscores in the IDs of each group folder. Is there a way to change that?

Please update connector files from github

The updated version will use comma for data separation in the group connector, so it will not conflict with data saving logic.

I am using the most recent code from github. I probably should have made this clearer:

I’m only retrieving data with the TreeGroup Connector (not saving). I’ve got one tree that is a TreeGroup tree and I’ve got a second tree that is just Tree Connector. I’m then dragging items from the TreeGroup tree into the Tree Connector tree and saving only the Tree Connector tree.

This makes the Tree Connector tree fail to save whenever I:

  1. Drag a TreeGroup folder in (because of the “__{group_param}” being added to the folder id)
  2. Whenever I drag an item with duplicate IDs (because it appends “_”+new Date())

I’ve sort of solved the issue by adding this ugly thing just after making my Tree Connector tree:

//Do not allow underscores in ID because DataProcessor fails
(function(addId) {
	tree._globalIdStorageAdd = function (itemId, itemObject) {
		itemId = itemId.replace(/_/g, "");
		return, itemId, itemObject);

Is there a better way than this?