<commit_before>(function (module) {
    mifosX.controllers = _.extend(module, {
        CreateCenterController: function (scope, resourceFactory, location, dateFilter) {
            scope.offices = [];
            scope.staffs = [];
            scope.data = {};
            scope.first = {};
            scope.first.submitondate = new Date ();
            scope.formData = {};
            scope.restrictDate = new Date();
            scope.first.date = new Date();
            scope.addedGroups = [];
            resourceFactory.centerTemplateResource.get({staffInSelectedOfficeOnly:true},function (data) {
                scope.offices = data.officeOptions;
                scope.staffs = data.staffOptions;
                scope.groups = data.groupMembersOptions;
                scope.formData.officeId = data.officeOptions[0].id;
                scope.getGroups();
            });

            scope.getGroups = function() {
                resourceFactory.groupResource.getAllGroups({officeId: scope.formData.officeId }, function (data) {
                    scope.groups = data;
                });
            }

            scope.changeOffice = function () {
                resourceFactory.centerTemplateResource.get({staffInSelectedOfficeOnly:true, officeId: scope.formData.officeId
                }, function (data) {
                    scope.staffs = data.staffOptions;
                });
                scope.getGroups();

            };
            scope.setChoice = function () {
                if (this.formData.active) {
                    scope.choice = 1;<commit_msg>Fix #3070 - Fixes wrong group display (#3171)<commit_after>(function (module) {
    mifosX.controllers = _.extend(module, {
        CreateCenterController: function (scope, resourceFactory, location, dateFilter) {
            scope.offices = [];
            scope.staffs = [];
            scope.data = {};
            scope.first = {};
            scope.first.submitondate = new Date ();
            scope.formData = {};
            scope.restrictDate = new Date();
            scope.first.date = new Date();
            scope.addedGroups = [];
            resourceFactory.centerTemplateResource.get({staffInSelectedOfficeOnly:true},function (data) {
                scope.offices = data.officeOptions;
                scope.staffs = data.staffOptions;
                scope.groups = data.groupMembersOptions;
                scope.formData.officeId = data.officeOptions[0].id;
                scope.getGroups();
            });

            scope.getGroups = function() {
                resourceFactory.groupResource.getAllGroups({officeId: scope.formData.officeId }, function (data) {
                    scope.groups = data.filter(function (group) {
                        return !group.centerId;
                    });
                });
            }

            scope.changeOffice = function () {
                resourceFactory.centerTemplateResource.get({staffInSelectedOfficeOnly:true, officeId: scope.formData.officeId
                }, function (data) {
                    scope.staffs = data.staffOptions;
                });
                scope.getGroups();

            };
            scope.setChoice = function () {
                if (this.formData.active) {
                    scope.choice = 1;
{'fraction_non_alphanumeric': 0.10896468457591307, 'fraction_numerical': 0.003622094778146695, 'mean_word_length': 1.59717868338558, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '528382', 'n_tokens_mistral': 840, 'n_tokens_neox': 774, 'n_words': 128}