PM-2973: Fourth migration ldapAdvanced

This commit is contained in:
Paula V. Quispe
2015-06-15 17:12:59 -04:00
parent 3e4e5582ad
commit 0cc89a62f9
7 changed files with 536 additions and 6 deletions

View File

@@ -0,0 +1,46 @@
var synchronizeDepartmentsLDAPADV = function() {
iGrid = Ext.getCmp('infoGrid');
rowSelected = iGrid.getSelectionModel().getSelected();
if (rowSelected) {
location.href = 'authSourcesSynchronize?authUid=' + rowSelected.data.AUTH_SOURCE_UID + '&tab=synchronizeDepartments';
}
};
var synchronizeGroupsLDAPADV = function() {
iGrid = Ext.getCmp('infoGrid');
rowSelected = iGrid.getSelectionModel().getSelected();
if (rowSelected) {
location.href = 'authSourcesSynchronize?authUid=' + rowSelected.data.AUTH_SOURCE_UID + '&tab=synchronizeGroups';
}
};
var synchronizeDepartmentsButtonLDAPADV = new Ext.Action({
text: 'Synchronize Departments',
iconCls: 'ICON_DEPARTAMENTS',
disabled: true,
handler: synchronizeDepartmentsLDAPADV
});
var synchronizeGroupsButtonLDAPADV = new Ext.Action({
text: 'Synchronize Groups',
iconCls: 'ICON_GROUPS',
disabled: true,
handler: synchronizeGroupsLDAPADV
});
var _rowselectLDAPADV = function(sm, index, record) {
if (record.get('AUTH_SOURCE_PROVIDER') == 'ldapAdvanced') {
synchronizeDepartmentsButtonLDAPADV.enable();
synchronizeGroupsButtonLDAPADV.enable();
}
};
var _rowdeselectLDAPADV = function(sm, index, record) {
synchronizeDepartmentsButtonLDAPADV.disable();
synchronizeGroupsButtonLDAPADV.disable();
};
_rowselect.push(_rowselectLDAPADV);
_rowdeselect.push(_rowdeselectLDAPADV);
_pluginActionButtons.push(synchronizeDepartmentsButtonLDAPADV);
_pluginActionButtons.push(synchronizeGroupsButtonLDAPADV);