summaryrefslogtreecommitdiffstats
path: root/install/static/search.js
Commit message (Collapse)AuthorAgeFilesLines
* Change FreeIPA license to GPLv3+Jakub Hrozek2010-12-201-5/+5
| | | | | | | | | | The changes include: * Change license blobs in source files to mention GPLv3+ not GPLv2 only * Add GPLv3+ license text * Package COPYING not LICENSE as the license blobs (even the old ones) mention COPYING specifically, it is also more common, I think https://fedorahosted.org/freeipa/ticket/239
* button and table stylingKyle Baker2010-12-101-2/+2
| | | | | | replaced expand contract +- with icons removed background for action buttons and gave them their own class Major css cleanup
* Column i18nEndi S. Dewata2010-12-061-7/+4
| | | | | | | | | | The ipa_column has been modified to get the label from metadata during initialization. The ipa_table_widget has been modified to initialize the columns. Hard-coded labels have been removed from column declarations. The ipa_adder_dialog has been modified to execute a search at the end of setup.
* entity i18nAdam Young2010-12-061-0/+7
| | | | | | | | | | | Updated the user,group,host, hostgroup, netgroup, service, and all policy entities to use the newer framework functions, in order to replaced the old array style definitions which did not support i18n. update a few of the newer framerwork functions to get the lables from the meta data. Fixed the unit tests which were expecting a details facet for users, no longer automatically created
* Multicolumn enrollment dialogEndi S. Dewata2010-12-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | The enrollment dialog has been modified to use scrollable tables that supports multiple columns to display the search results and selected entries. The columns are specified by calling create_adder_column() on the association facet. By default the tables will use only one column which is to display the primary keys. The following enrollment dialogs have been modified to use multiple columns: - Group's member_user - Service's managedby_host - HBAC Service Group's member_hbacsvc - SUDO Command Group's member_sudocmd The ipa_association_table_widget's add() and remove() have been moved into ipa_association_facet so they can be customized by facet's subclass. The ipa_table's add_row() has been renamed to add_record(). Some old code has been removed from ipa_facet_create_action_panel(). The code was used to generate association links from a single facet. It's no longer needed because now each association has its own facet. The test data has been updated. The IPA.nested_tabs() has been fixed to return the entity itself if IPA.tab_set is not defined. This is needed to pass unit test.
* Multicolumn association facetEndi S. Dewata2010-11-301-15/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The association facet has been modified to support multiple columns. By default the facet will have one column which is the primary key of the associated object (e.g. username of a group member), so the existing code will work like before. Other fields (e.g. user's full name) can be added by subclassing the ipa_association_facet class and specifying the additional columns to display. These additional fields will be retrieved using a batch operation. Previously a single association facet instance will be used for all associations in an entity. Now each association will have its own association facet. This way each association facet can be customized differently as needed. The <entity>-enroll URL parameter has been removed because it's no longer needed. The ipa_entity.create_association_facets() is provided to generate the default association facets with one column for the primary key. The column click handler has been moved out of ipa_column to provide more flexibility for customization. The get_action_panel() and get_client_area() have been modified to search within the entity's container. The group entity has been fully converted to use the new UI framework. Association facets that have been modified to use multiple columns are: - User Group's member_user - HBAC Service Group's member_hbacsvc - SUDO Command Group's member_sudocmd - Service's managedby_host New test data files have been added. Unit tests have been updated.
* action panel formattingAdam Young2010-11-241-2/+1
| | | | | Cleans up the indentation of the action panel Puts the sudo and HBAC entries in a consistent order
* Fixed action panel queriesEndi S. Dewata2010-11-221-14/+16
| | | | | | | | | | | | | | | Previously the queries for action panel were done globally. Since each entity container has its own action panel, the queries will return multiple results. This is fixed by qualifying the query to run within the entity container. The query has also been moved into ipa_facet.get_action_panel(). Entities that do not have their own entity container (e.g. HBAC services and service groups) will need to override this method to get the action panel from the right entity container (e.g. HBAC rules). The facet.setup_views() has been renamed to facet.create_action_panel(). New test data for SUDO rules have been added.
* SUDO Rule Search and Details PagesEndi S. Dewata2010-11-191-29/+66
| | | | | | | | | | | | | | | | | | | | The search and details pages for SUDO Rule have been added. Codes that are shared with HBAC have been moved to rule.js. The following methods were renamed for consistency: - ipa_details_load() -> ipa_details_refresh() - ipa_details_display() -> ipa_details_load() The ipa_details_cache has been removed because the cache is now stored in each widget. The index.xhtml has been removed. All references to it has been changed to index.html. The Unselect All checkbox has been fixed. Unnecessary parameter 'container' has been removed. The unit test has been updated and new test data has been added.
* Service and Host ProvisioningEndi S. Dewata2010-11-181-0/+2
| | | | | | | | | | | | | | | The service and host details pages have been modified to display Kerberos key provisioning status and to provide a way to unprovision. The host enrollment via OTP has not been implemented yet. The ipa_details_field has been modified to remove any old <dd> tags it created in the previous load operation. This is to support other widgets that need to perform load operation without removing <dd> tags. The certificate_status_panel has been converted into a widget. The host entity has been rewritten using the new framework. The unit tests has been updated.
* action selectAdam Young2010-11-171-0/+24
| | | | | if exactly one entity is selected, it enables the entity-facet links in the action panel, and sets the pkey in bbq to the pkey of the selected
* buttons to action panel puts the buttons as the top li in the action panelAdam Young2010-11-161-1/+1
|
* HBAC details page enhancementEndi S. Dewata2010-11-151-34/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The HBAC details page has been enhanced to support Undo and Reset operations. The functionality is implemented in the base widget class so the behavior will be more consistent across widgets. A <span> tag now used to define the field boundary in the HTML doc. The tag contains the visual representation of the field which include the input tag and optionally the undo link. The Update method on HBAC details page has been modified so that it executes several operations using a batch command. The operations being executed depends on the changes made to the fields. These operations may include: - removing access time if access time is changed to any time - removing memberships if member category is changed to all - modifying rule attributes if description or rule type is changed - enabling/disabling the rule if rule status is changed The behavior of the Add & Remove buttons also has been changed such that it adjust the category attribute properly in addition to adding the memberships using batch command. For example, if category is initially set to all, adding a new member will also change the category to empty. The ipa_command have been modified to store the on_success and on_error handlers as properties. When the command is executed as a part of batch operation, the result of each command will be passed to the appropriate handler. The unit tests and test data have been updated as well.
* buttons to action panelAdam Young2010-11-141-11/+14
|
* super to superiorAdam Young2010-11-141-4/+4
|
* layoutAdam Young2010-11-141-1/+0
| | | | | | Closer to the layout from the spec The facets have been moved to the action panel, to the left of the page the facets are now rendered in an area of the screen with a client class
* HBAC ServicesEndi S. Dewata2010-11-111-238/+195
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The HBAC Service search and details pages have been added under the HBAC tab. This requires some changes to the framework. Currently the navigation framework doesn't support multiple entities under one tab. As a temporary solution, an 'entity' URL parameter is used to determine the entity to be displayed. This parameter is now only used by HBAC tab, but its use might be expanded later. The navigation framework needs be redesigned to provide more flexibility. The search page in all entities except DNS records have been changed to use the ipa_search_widget. The Select/Unselect All checbox and Delete button now work correctly and consistently. The Add dialog has been enhanced to render and work in a more consistent way while still supporting custom widgets & layouts. For the search page, the Add button will refresh the search results and clear the fields in the dialog box. The framework now provides some extension points which can be overriden by the subclasses: - init(): for initialization and configuration - create(): for creating the layout dynamically or from template - setup(): for setting the look and feel - load(): for loading the data Entity and facet initialization is now done after IPA.init(). This is to ensure the metadata is loaded first so the entities and facets can use localized messages/labels/titles. The group entity has been partially converted to use the new framework. The unit tests have been updated accordingly.
* delete to remove THe keyword delete is reserved in Javascript Using it ↵Adam Young2010-11-091-2/+2
| | | | breaks the WebUI on Chrome. This fixes replaces the word with delete.
* HBAC Access TimeEndi S. Dewata2010-11-081-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | IPA commands now can be defined in these classes: - ipa_command: a single IPA command - ipa_batch_command: a batch command for executing multiple commands on the server side using the new batch plugin The dialog boxes for adding and removing entries have been refactored: - ipa_dialog: base class for dialog boxes - ipa_adder_dialog: generic adder dialog box - ipa_deleter_dialog: generic deleter dialog box - ipa_association_adder_dialog: adding entity association - ipa_association_deleter_dialog: removing entity association Dialog boxes for adding/deleting HBAC users, hosts, services, and sourcehosts are implemented using the association dialog boxes. The dialog box for adding access time is implemented using ipa_dialog and currently contains only a text field. This will be replaced with a custom dialog box in a separate patch. The dialog box for removing access time is implemented using the generic deleter class because it's not an association. Removing multiple access times is implemented using batch operations. New test data files for access times have been added.
* HBAC Details PageEndi S. Dewata2010-11-041-27/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The UI framework has been extended to include a collection of widgets: - ipa_widget: base class - ipa_text_widget: text field - ipa_radio_widget: radio button - ipa_textarea_widget: textarea - ipa_button_widget: button - ipa_column_widget: column for table - ipa_table_widget: table These widgets can be used to create input controls. They can also be extended to create custom controls. The framework has also been enhanced to support custom layouts. This can be used to change the look of the application without changing the code. Initially this is only available in details section. Layout consists of a collection of HTML templates. Each template is a complete and valid HTML file representing a portion of a page. The template will be loaded and initialized by the code, then filled with the data from the server. The layouts are located in install/static/layouts/<name> folder. By default, if no templates are used, the fields in the details page are rendered vertically using dd/dt/dd tags. For pages that require different layout, a custom UI needs to be developed. There are two ways to do that: - write a custom widget to generate the UI dynamically - create an HTML template and write the initialization code For components that are quite complex or used frequently, it's might be better to use the first method. For simple pages that are used only in one location or need to support customization, the second method might be preferable. Other benefits of templates: - cleaner code and UI separation - more flexibility in customization - new pages can be developed quickly and require less coding - multiple templates can be used with the same initialization code - easier to maintain The HBAC details page has been implemented using both methods. By default it will use custom widgets to generate the page. To use a custom layout, add the following parameter to the URL, then reload the page: &layout=<name> Currently the only available layout is 'default' which produces the same look as the custom widgets. The HBAC details page is usable, but it still needs additional work. The access time is not working yet. There is no undo button, hint, or validation yet. The table in the association facet has also been changed to use ipa_association_widget which is derived from ipa_table_widget. The Makefile has been updated to include the layouts. The unit tests have been updated as well.
* Dialog boxes for AJAX, HTTP, and IPA errors.Endi S. Dewata2010-10-281-1/+1
| | | | | | | The ipa_cmd() has been modified to identity the type of the error it has received and display the error using the right dialog box. The dialog box can be customized further to display the appropriate amount of information for each type of error.
* Framework for custom UIEndi S. Dewata2010-10-281-46/+159
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch introduces a new framework for implementing custom UI. It consists of the following classes: Main: - IPA: global namespace and object repository - ipa_entity: base class for entities - ipa_facet: base class for facets Add dialog: - ipa_add_dialog: default add dialog - ipa_add_field: the fields used in the dialog Search facet: - ipa_search_facet: default search facet - ipa_search_column: the columns in the search result Details facet: - ipa_details_facet: default details facet - ipa_details_section: the sections in the details facet - ipa_details_field: the fields in the details facet Association facet: - ipa_association_facet: default association facet - ipa_association_config: the association configurations To use this framework, create a class extending the ipa_entity (e.g. ipa_hbac). Use the create_* methods to create add dialog, search facet, details facet, and association facet. The fields/columns for the dialog and facets can be specified using the init() function. Custom UI can be defined by overwriting the base methods (e.g. setup, save, load). The entity must be added into the repository using IPA.add_entity(). The original ipa_entity_setup() has been generalized by moving facet- specific codes into the corresponding facet. Some facet names are still hard-coded. This will be fixed in follow-up patches. Some global variables have been removed because their function has been replaced by the object repository: - ipa_entity_add_list - ipa_entity_search_list - ipa_entity_details_list - window_hash_cache Some functions and variables have been moved into IPA namespace: - ipa_json_url -> IPA.json_url - ipa_use_static_files -> IPA.use_static_files - ipa_ajax_options -> IPA.ajax_options - ipa_objs -> IPA.metadata - ipa_messages -> IPA.messages - ipa_dialog -> IPA.error_dialog - ipa_init() -> IPA.init() Initially the HBAC and Service entities have been rewritten to use the new framework. The DNS is partially converted, the ipa_records_facet is used to define custom records facet. Other entities can still work using the old framework. The old framework has been modified to be a wrapper for the new framework. Eventually all entities will be converted to use the new framework. Some unit tests have been modified to use the new framework.
* Remove size limits.Adam Young2010-10-191-2/+2
| | | | Now use the system wide settings instead of hardcoded size limits.
* multivalue fixesAdam Young2010-10-151-5/+7
| | | | | | | | | | | | metadata for phone numbers test date for users Undo works for multivalue JQuery UI buttons have custom classes inputs/fields are now managed inside of objects removed the use of .call. as it was confusing the issue of mismatched parameter lists. Fixed the parameter lists, too.
* record limitAdam Young2010-10-081-2/+2
|
* Displaying AJAX URL in error message.Endi S. Dewata2010-10-061-0/+1
| | | | | | The ipa_error_handler() has been modified to display the AJAX URL that is having a problem. The ipa_cmd() error handler is now invoked using call() to pass 'this' object which contains the URL.
* Add Delete capabilities to Search facet in the WebUI.Pavel Zuna2010-10-011-2/+101
| | | | Ticket #206
* Added error handler for ipa_cmd().Endi S. Dewata2010-09-291-13/+25
| | | | | | | | | | | | | | | | | | | | | | | The ipa_cmd() has been modified such that when an error occurs a dialog box will appear showing the error message with 2 buttons: Retry and Cancel. If Retry is clicked, it will attempt to execute the same operation again. If Cancel is clicked, the operation will be canceled and the control is returned to the caller. New unit tests have been added to test ipa_cmd() on successfull and unsuccessfull cases. The associate.js, details.js, entity.js, search.js, and webui.js have been modified to display the error message inside the page. This behavior can be changed in the future (e.g. redirect to error page). The navigation.js and webui.js have been modified to render only the visible tabs. This improves the performance and reduce hidden errors. The navigation unit test has been modified to reflect this behavior. Some variables/functions also have been renamed for consistency.
* I18N for webAdam Young2010-09-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | Performing I18N completely on the server, to leverage the existing gettext architecture. Also, the browser does not have access to the Language header. Added the additional po files for a set of required languages conflict with install/static/ipa.js was resolved. Note that the addition of the .po files in this patch is necessary. In order to get Transifex support, we need to update the LINGUAS file with the languages for which we want support. If we don't add the .po files in, they get automatically generated by the rpmbuild process. Our implementation of gettext has a bug in it (It might be F13 thing) where the the Plurals line is not getting correctly transformed, which causes a build failure. However, since the RPM would have the .po files anyway, we should revision control the ones we have, even if they are empty. Fixed the Bug reporting url to the original value. Corrected the Chartype encoding for UK
* Whoami linkAdam Young2010-09-241-0/+4
| | | | | | | | | The 'logged in as' message in the header into an active hypoerlink that loads the details page for the current user. Also fixed a bug where, when reloading, the search page would fail due to scl being undefined. Fixed a typo replaced {'user-facet':'details', 'pkey':whoami_pkey},2); with {'user-facet':'details', 'user-pkey':whoami_pkey},2);
* Adding quick links in user and group search results.Endi Sukma Dewata2010-09-171-3/+3
| | | | | | | | The render_call() signature has been modified to pass the entry_attrs so each callback function can construct the appropriate quick links using any attributes from the search results. The callback function has been implemented for user and group entities.
* Big webUI patch.Pavel Zuna2010-09-171-118/+150
| | | | | | | | | | | | | Quick summary: - use jQuery UI and jQuery BBQ libraries - code restructuring The patch has so many changes they can't be listed here. Many parts of the code have been rewritten from scrach. See freeipa-devel mailing list: webUI code restructuring [wall of text, diagrams, ... you've been warned!] 2010-09-07
* associationsAdam Young2010-09-071-57/+53
| | | | | | | | | | | | | -Refactored the associations code into a set of objects that are configured by the entities -Added support for associations that can be done in a single rpc -hostgroup to host and group to user associations working -Restructed sampledata so that the file is matched automatically by the RPC method name -The new ipa_cmd/sampledata scheme insists on there being sample data for any commands or the ipa_command fails. -Added sampledata files for all the calls we make -renamed several of the sampledata files to match their rpc calls -Started a pattern of refactoring where all the forms for the entity fall under a single object
* hashchangeAdam Young2010-08-261-59/+78
| | | | | | | | | | We now catch the hashchange event and use that to drive most of the site. To trigger page transitions, modify location.hash. Params start with # not ?. Removed user-group.inc. converted tabs to spaces trivial imlementation of add and details for netgroup and hostgroup lots of bug fixes based on routing problems and the refactorings.
* Changes the URL parsing from standard HTML params ( starting with ?)Adam Young2010-08-191-46/+40
| | | | | | | | to hash params ( starting with # ). User Details are now part of index.xhtml, ao one more .inc file has been removed. Updated commit to catch a few things that had been left out, including sampledata handling and updateing Makefile.am
* Remove search field on group buttonAdam Young2010-08-091-0/+3
| | | | | | Hide the search bar when showing the groups listed for a user, and resotre it when doing other searches. The enroll button is added only on the groups page, and removed along with anything else in the searchButtons div when a new search is started.
* The Javascript code for the new web UIAdam Young2010-08-061-0/+127
Now with whitespace cleanup.