Not sure if you got this working or not, but here is a link to another post that shows how this works.
https://community.nintex.com/t5/Community-Blogs/Using-Javascript-to-update-a-repeating-section/ba-p/82584
Go to form settings and under Custom JavaScript add the following code:
NWF.FormFiller.Events.RegisterAfterReady(function () {
NWF$(document).ready(function () {
NWF$("#" + varDropdown).change(function () {
ClearRSData();
GetRSDataFromLookup();
});
});
});
function ClearRSData() {
var rsdata = NWF$('.rsdata');
var labels = NWF$(rsdata).find('.dwgDimension');
NWF$.each(labels, function (index) {
NWF$('.rsdata .nf-repeater-row:last').find('.nf-repeater-deleterow-image').click();
});
NWF$('.rsdata .nf-repeater-row:last').each(function () {
var $row = NWF$(this);
$row.find('.dwgDimension input').val('');
$row.find('.ddOperation input').val('');
});
}
function GetRSDataFromLookup() {
var lookupId = NWF.RuntimeFunctions.parseLookup(NWF$('#' + varDropdown).val(), true);
if (lookupId != '') {
NWF$('#errorMsg').empty();
var requestUri = _spPageContextInfo.webAbsoluteUrl + '/_api/Web/Lists/getByTitle('ListA')/items?$filter=Title eq '' + lookupId + ''';
try {
NWF$.ajax({
url: requestUri,
type: 'GET',
headers: { 'ACCEPT': 'application/json;odata=verbose' },
success: GetRSDataFromLookupSuccess,
error: GetRSDataFromLookupError
});
}
catch (err) {
NWF$('#errorMsg').html('getListData Error: ' + err);
}
}
}
function GetRSDataFromLookupSuccess(data) {
if (data.d.results.length > 0) {
var rsdata = data.d.results[0].rsdata;
parser = new DOMParser();
xmlDoc = parser.parseFromString(rsdata, 'text/xml');
var items = xmlDoc.getElementsByTagName('Item');
for (var i = 0; i < items.length; i++) {
NWF$('.rsdata .nf-repeater-row:last').each(function () {
var $row = NWF$(this);
$row.find('.dwgDimension input').val(xmlDoc.getElementsByTagName('dwgDimension')[i].childNodes[0].nodeValue);
$row.find('.ddOperation input').val(xmlDoc.getElementsByTagName('ddOperation')[i].childNodes[0].nodeValue);
});
NWF$('.rsdata').find('a').click();
}
NWF$('.rsdata .nf-repeater-row:last').find('.nf-repeater-deleterow-image').click();
}
} function GetRSDataFromLookupError() {
alert('Failed to load Lookup Items');
}