lib/impl/refactorRules.js
function getSourceRepeatingSections(rule) {
    return _.chain(rule.ruleConditionalStatements)
      .map(function(ruleConditionalStatement) {
        var sourceId = ruleConditionalStatement.sourceField.toString();
        return fieldSectionMapping[sourceId];
      })
      .filter(function(section) {
        return section && section.repeating;
      })
      .map(function(repeatingSection) {
        return repeatingSection._id.toString();
      })
      .uniq()
      .value();
  }
function getSourceRepeatingSections(rule) {
    return _.chain(rule.ruleConditionalStatements)
      .map(function(ruleConditionalStatement) {
        var sourceId = ruleConditionalStatement.sourceField.toString();
        return fieldSectionMapping[sourceId];
      })
      .filter(function(section) {
        return section && section.repeating;
      })
      .map(function(repeatingSection) {
        return repeatingSection._id.toString();
      })
      .uniq()
      .value();
  }
function getSourceRepeatingSections ( rule ) { return _ . chain ( rule . ruleConditionalStatements ) . map ( function ( ruleConditionalStatement ) { var sourceId = ruleConditionalStatement . sourceField . toString ( ) ; return fieldSectionMapping [ sourceId ] ; } ) . filter ( function ( section ) { return section && section . repeating ; } ) . map ( function ( repeatingSection ) { return repeatingSection . _id . toString ( ) ; } ) . uniq ( ) . value ( ) ; }
Get ids of repeating sections with fields which act as sources in a rule
@param rule
@returns {String[]}
Get ids of repeating sections with fields which act as sources in a rule