[[PageOutline]] = Documentation for Web admin interface = See also [wiki:ServerSetup Server Setup] and [wiki:DEBVisDicServer DEBVisDic Server Setup] guides The Web admin API calls are described at the [wiki:WebAdminAPI Web admin API] documentation. Ubuntu installation package: '''debserver-common''' == Password change == ''(change my password)'' Available to all users. Here they can change their password. == Dictionaries == Dictionary files and features definition. code:: short dictionary code, used as a dictionary identification name:: dictionary name, displayed to users file:: name of dbxml file class:: Ruby class used for dictionary API, list is fixed and contains all possible classes. File containing class definition must be included in runner script. ''Dictionary'' class is the most common. root tag:: root element of each entry key:: XPath of each entry key indexes:: List of indexed elements/attributes, pairs of element name (attributes name without @) and index type (choose the right type, or the wrong index may cause performance issues). For Wordnet dictionaries, basic set of indexes is filled automatically. xslt:: List of XSLT templates for entries preview, pairs of template name (used in code) and XSLT filename. For Wordnet dictionaries, basic set of templates is filled automatically. packages:: ''(for Wordnet and Cornetto dictionaries)'' list of client packages, pairs of package code (used for identification) and package name (displayed to users). At the moment, only one package is used, but it's possible to have two different packages displaying data in different form for one dictionary. Usually, package code is the same as dictionary code with number 1. eq tags:: ''(for Wordnet and Cornetto dictionaries)'' List of equivalence tags relations to do lookup in other dictionary. Path of element used for relation (same syntax as for WN queries) and dictionary package code. lookup dict:: ''(for Wordnet and Cornetto dictionaries)'' List of dictionary packages to allow (auto)lookup to. List of package codes, separated by comma (,). reload dict:: ''(for Wordnet and Cornetto dictionaries)'' List of dictionaries to reload in client after entry edit. List of dictionary codes, separated by comma (,). Dictionary itself is always included. === Example === * code = wnen * name = English Wordnet * file = wnen.dbxml * class = !WordNet * root tag = SYNSET, cid * key = /SYNSET/ID, /cid/@cid_id * indexes = ID:node-element-equality-string, LITERAL:node-element-substring-string * xslt = xml:xmlpretty.xsl (for neat XML preview), preview:wn-preview.xslt, vb:wnvb.xslt * packages = wneng1:English WN * eq tags = cid.@d_sy_id:cdbsyn1, cid.@c_lu_id:cdblu1 * lookup dict = wncze1,wngre1,wnfre1 * reload dict = wncz == Services == Service is one DEB server running on separate port. Several services can use the same dictionaries. code:: short service code, used as an identification. This code is also used in start script, for example in ''bin/wordnet_services.rb'': {{{ wninfo = WordNetAdmin.new(db_path, 'admininfo.dbxml', '', env) wninfo.service_name = 'debvisdic' }}} name:: service name htpasswd:: enter filename where to save htpasswd file with users for this service dictionaries:: check the box for dictionaries that should be part of this service == Users == List of server users, each of them may have access to different services and dictionaries. login:: user login name:: real name organization:: user organization address:: user address email:: user email, account information (creation, removal, password reminder) are mailed to this address comment:: any comment about the user password:: If you fill in this field, password is set to entered value (when creating or editing user entry). If left empty while creating new user, password is generated randomly and mail to the user. admin checkbox:: If checked, user has access to admin interface. services + dictionaries:: If you check the box next to the service name, user is given access to this service. But this may not give user access to the dictionary data, as each service may deal with user access rights differently. If service don't require detailed access rights, checking the box is enough. But if more detailed access rights are used, you must fill in access rights to the textboxes next to each dictionary code. Usually, it's 'r' for reading the data and 'w' for read+write access. new pass:: After clicking on this link, new random password is generated for the user and mailed to specified email address. == Browse & upload == You can browse several directories (XSLT templates, admin interface templates, generated xpi files) on server and download files in them. And also you can upload files into these directories. This way it's possible to change templates without direct access to server files. == Dump dictionary == Save content of whole dictionary to the file. Select dictionary and enter a path to the file. File is saved on server so you should enter the path where user ''debsrv'' has write permission. By default, path in ''/var/lib/deb-server/files/'' is filled in so you can download the file using web interface. Dump progress is logged and last 20 lines of the log files are displayed continuously. When the dump is complete, server reminds the file path and if you left default path unchanged, link to file download is provided. == Import dictionary == Imports data from a file into dictionary database. File must be present on the server beforehand (you can upload it using web interface). Enter path to the file and select dictionary. If you want to delete all the data from the dictionary before importing, check the box ''delete current data''. The ''overwrite entries'' checkbox defines what to do, when entry already stored in database is imported. If checked, existing entry will be overwritten with the new one, otherwise current entry will be left intact. You can select ''read method'' for file parsing (''grep'' is recommended as it is much quicker) - ''grep'' reads one entry at the time from file using regular expression and then parse each entry, ''parser'' tries to parse the whole file as XML and then selects entries. Import progress is logged and last 20 lines of the log files are displayed continuously. Note: before importing the data, stop all services that use affected dictionary. == Sequences == Definition of ID sequences for each dictionary. You can set pattern and number for each dictionary. Whenever a new entry is created, number is raised by 1 and new ID is created by substituting [id] in pattern with new number. For example: for ''cdb_syn'' dictionary, the pattern is '''c_[id]''' and if a new number is 29, then new ID is c_29 == Locks == Lock management. Locks are shown grouped by dictionaries. For each lock, username, entry ID and lock time is displayed. It's possible to remove single lock, all locks for given dictionary, locks for specific user (for all dictionaries or one specified), or all locks.