diff --git a/addons/web/common/http.py b/addons/web/common/http.py index 71a280f27eb..9294808fda4 100644 --- a/addons/web/common/http.py +++ b/addons/web/common/http.py @@ -405,14 +405,14 @@ def session_context(request, storage_path, session_cookie='sessionid'): #---------------------------------------------------------- addons_module = {} addons_manifest = {} -controllers_class = {} +controllers_class = [] controllers_object = {} controllers_path = {} class ControllerType(type): def __init__(cls, name, bases, attrs): super(ControllerType, cls).__init__(name, bases, attrs) - controllers_class["%s.%s" % (cls.__module__, cls.__name__)] = cls + controllers_class.append(("%s.%s" % (cls.__module__, cls.__name__), cls)) class Controller(object): __metaclass__ = ControllerType @@ -440,12 +440,12 @@ class Root(object): self.root = '/web/webclient/home' self.config = options - if self.config.backend == 'local': - conn = LocalConnector() - else: - conn = openerplib.get_connector(hostname=self.config.server_host, - port=self.config.server_port) - self.config.connector = conn + if not hasattr(self.config, 'connector'): + if self.config.backend == 'local': + self.config.connector = LocalConnector() + else: + self.config.connector = openerplib.get_connector( + hostname=self.config.server_host, port=self.config.server_port) self.session_cookie = 'sessionid' self.addons = {} @@ -526,7 +526,7 @@ class Root(object): addons_module[module] = m addons_manifest[module] = manifest statics['/%s/static' % module] = path_static - for k, v in controllers_class.items(): + for k, v in controllers_class: if k not in controllers_object: o = v() controllers_object[k] = o diff --git a/addons/web/controllers/main.py b/addons/web/controllers/main.py index 1cdeb50cf25..9b4c8335e35 100644 --- a/addons/web/controllers/main.py +++ b/addons/web/controllers/main.py @@ -909,11 +909,6 @@ class Menu(openerpweb.Controller): class DataSet(openerpweb.Controller): _cp_path = "/web/dataset" - @openerpweb.jsonrequest - def fields(self, req, model): - return {'fields': req.session.model(model).fields_get(False, - req.session.eval_context(req.context))} - @openerpweb.jsonrequest def search_read(self, req, model, fields=False, offset=0, limit=False, domain=None, sort=None): return self.do_search_read(req, model, fields, offset, limit, domain, sort) @@ -949,7 +944,6 @@ class DataSet(openerpweb.Controller): if fields and fields == ['id']: # shortcut read if we only want the ids return { - 'ids': ids, 'length': length, 'records': [{'id': id} for id in ids] } @@ -957,46 +951,10 @@ class DataSet(openerpweb.Controller): records = Model.read(ids, fields or False, context) records.sort(key=lambda obj: ids.index(obj['id'])) return { - 'ids': ids, 'length': length, 'records': records } - - @openerpweb.jsonrequest - def read(self, req, model, ids, fields=False): - return self.do_search_read(req, model, ids, fields) - - @openerpweb.jsonrequest - def get(self, req, model, ids, fields=False): - return self.do_get(req, model, ids, fields) - - def do_get(self, req, model, ids, fields=False): - """ Fetches and returns the records of the model ``model`` whose ids - are in ``ids``. - - The results are in the same order as the inputs, but elements may be - missing (if there is no record left for the id) - - :param req: the JSON-RPC2 request object - :type req: openerpweb.JsonRequest - :param model: the model to read from - :type model: str - :param ids: a list of identifiers - :type ids: list - :param fields: a list of fields to fetch, ``False`` or empty to fetch - all fields in the model - :type fields: list | False - :returns: a list of records, in the same order as the list of ids - :rtype: list - """ - Model = req.session.model(model) - records = Model.read(ids, fields, req.session.eval_context(req.context)) - - record_map = dict((record['id'], record) for record in records) - - return [record_map[id] for id in ids if record_map.get(id)] - @openerpweb.jsonrequest def load(self, req, model, id, fields): m = req.session.model(model) @@ -1006,23 +964,6 @@ class DataSet(openerpweb.Controller): value = r[0] return {'value': value} - @openerpweb.jsonrequest - def create(self, req, model, data): - m = req.session.model(model) - r = m.create(data, req.session.eval_context(req.context)) - return {'result': r} - - @openerpweb.jsonrequest - def save(self, req, model, id, data): - m = req.session.model(model) - r = m.write([id], data, req.session.eval_context(req.context)) - return {'result': r} - - @openerpweb.jsonrequest - def unlink(self, req, model, ids=()): - Model = req.session.model(model) - return Model.unlink(ids, req.session.eval_context(req.context)) - def call_common(self, req, model, method, args, domain_id=None, context_id=None): has_domain = domain_id is not None and domain_id < len(args) has_context = context_id is not None and context_id < len(args) @@ -1098,19 +1039,7 @@ class DataSet(openerpweb.Controller): @openerpweb.jsonrequest def exec_workflow(self, req, model, id, signal): - r = req.session.exec_workflow(model, id, signal) - return {'result': r} - - @openerpweb.jsonrequest - def default_get(self, req, model, fields): - Model = req.session.model(model) - return Model.default_get(fields, req.session.eval_context(req.context)) - - @openerpweb.jsonrequest - def name_search(self, req, model, search_str, domain=[], context={}): - m = req.session.model(model) - r = m.name_search(search_str+'%', domain, '=ilike', context) - return {'result': r} + return req.session.exec_workflow(model, id, signal) class DataGroup(openerpweb.Controller): _cp_path = "/web/group" diff --git a/addons/web/i18n/bs.po b/addons/web/i18n/bs.po new file mode 100644 index 00000000000..e2470a334ec --- /dev/null +++ b/addons/web/i18n/bs.po @@ -0,0 +1,1544 @@ +# Bosnian translation for openerp-web +# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012 +# This file is distributed under the same license as the openerp-web package. +# FIRST AUTHOR , 2012. +# +msgid "" +msgstr "" +"Project-Id-Version: openerp-web\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2012-02-14 15:27+0100\n" +"PO-Revision-Date: 2012-04-13 20:46+0000\n" +"Last-Translator: FULL NAME \n" +"Language-Team: Bosnian \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2012-04-14 05:04+0000\n" +"X-Generator: Launchpad (build 15070)\n" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:172 +#: addons/web/static/src/js/chrome.js:198 +#: addons/web/static/src/js/chrome.js:414 +#: addons/web/static/src/js/view_form.js:419 +#: addons/web/static/src/js/view_form.js:1233 +#: addons/web/static/src/xml/base.xml:1695 +#: addons/web/static/src/js/view_form.js:424 +#: addons/web/static/src/js/view_form.js:1239 +msgid "Ok" +msgstr "Uredu" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:180 +msgid "Send OpenERP Enterprise Report" +msgstr "Pošalji OpenERP Enterprise Izvještaj" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:194 +msgid "Dont send" +msgstr "Nemoj Poslat" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:256 +#, python-format +msgid "Loading (%d)" +msgstr "Punim (%d)" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:288 +msgid "Invalid database name" +msgstr "Nevažeće ime baze podataka" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:483 +msgid "Backed" +msgstr "Spašeno" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:484 +msgid "Database backed up successfully" +msgstr "Baza podataka uspješno kopirana" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:527 +msgid "Restored" +msgstr "Obnovljeno" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:527 +msgid "Database restored successfully" +msgstr "Baza podataka uspješno obnovljena" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:708 +#: addons/web/static/src/xml/base.xml:359 +msgid "About" +msgstr "O programu" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:787 +#: addons/web/static/src/xml/base.xml:356 +msgid "Preferences" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:790 +#: addons/web/static/src/js/search.js:239 +#: addons/web/static/src/js/search.js:288 +#: addons/web/static/src/js/view_editor.js:95 +#: addons/web/static/src/js/view_editor.js:836 +#: addons/web/static/src/js/view_editor.js:962 +#: addons/web/static/src/js/view_form.js:1228 +#: addons/web/static/src/xml/base.xml:738 +#: addons/web/static/src/xml/base.xml:1496 +#: addons/web/static/src/xml/base.xml:1506 +#: addons/web/static/src/xml/base.xml:1515 +#: addons/web/static/src/js/search.js:293 +#: addons/web/static/src/js/view_form.js:1234 +msgid "Cancel" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:791 +msgid "Change password" +msgstr "Promijeni šifru" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:792 +#: addons/web/static/src/js/view_editor.js:73 +#: addons/web/static/src/js/views.js:962 +#: addons/web/static/src/xml/base.xml:737 +#: addons/web/static/src/xml/base.xml:1500 +#: addons/web/static/src/xml/base.xml:1514 +msgid "Save" +msgstr "Sačuvaj" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:811 +#: addons/web/static/src/xml/base.xml:226 +#: addons/web/static/src/xml/base.xml:1729 +msgid "Change Password" +msgstr "Promijeni šifru" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:1096 +#: addons/web/static/src/js/chrome.js:1100 +msgid "OpenERP - Unsupported/Community Version" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:1131 +#: addons/web/static/src/js/chrome.js:1135 +msgid "Client Error" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:6 +msgid "Export Data" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:19 +#: addons/web/static/src/js/data_import.js:69 +#: addons/web/static/src/js/view_editor.js:49 +#: addons/web/static/src/js/view_editor.js:398 +#: addons/web/static/src/js/view_form.js:692 +#: addons/web/static/src/js/view_form.js:3044 +#: addons/web/static/src/js/views.js:963 +#: addons/web/static/src/js/view_form.js:698 +#: addons/web/static/src/js/view_form.js:3067 +msgid "Close" +msgstr "Zatvori" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:20 +msgid "Export To File" +msgstr "Eksportuj do fajla" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:125 +msgid "Please enter save field list name" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:360 +msgid "Please select fields to save export list..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:373 +msgid "Please select fields to export..." +msgstr "Molimo odaberite mjesto za eksportovanje.." + +#. openerp-web +#: addons/web/static/src/js/data_import.js:34 +msgid "Import Data" +msgstr "Uvezi podatke" + +#. openerp-web +#: addons/web/static/src/js/data_import.js:70 +msgid "Import File" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_import.js:105 +msgid "External ID" +msgstr "Externi ID" + +#. openerp-web +#: addons/web/static/src/js/formats.js:300 +#: addons/web/static/src/js/view_page.js:245 +#: addons/web/static/src/js/formats.js:322 +#: addons/web/static/src/js/view_page.js:251 +msgid "Download" +msgstr "Preuzimanje" + +#. openerp-web +#: addons/web/static/src/js/formats.js:305 +#: addons/web/static/src/js/formats.js:327 +#, python-format +msgid "Download \"%s\"" +msgstr "Preuzimanje \"%s\"" + +#. openerp-web +#: addons/web/static/src/js/search.js:191 +msgid "Filter disabled due to invalid syntax" +msgstr "Filter onemogučen zbog ne validne sintakse" + +#. openerp-web +#: addons/web/static/src/js/search.js:237 +msgid "Filter Entry" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:242 +#: addons/web/static/src/js/search.js:291 +#: addons/web/static/src/js/search.js:296 +msgid "OK" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:286 +#: addons/web/static/src/xml/base.xml:1292 +#: addons/web/static/src/js/search.js:291 +msgid "Add to Dashboard" +msgstr "Dodaj u Dashboard" + +#. openerp-web +#: addons/web/static/src/js/search.js:415 +#: addons/web/static/src/js/search.js:420 +msgid "Invalid Search" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:415 +#: addons/web/static/src/js/search.js:420 +msgid "triggered from search view" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:503 +#: addons/web/static/src/js/search.js:508 +#, python-format +msgid "Incorrect value for field %(fieldname)s: [%(value)s] is %(message)s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:839 +#: addons/web/static/src/js/search.js:844 +msgid "not a valid integer" +msgstr "ne važeći integer" + +#. openerp-web +#: addons/web/static/src/js/search.js:853 +#: addons/web/static/src/js/search.js:858 +msgid "not a valid number" +msgstr "Ne važeći broj" + +#. openerp-web +#: addons/web/static/src/js/search.js:931 +#: addons/web/static/src/xml/base.xml:968 +#: addons/web/static/src/js/search.js:936 +msgid "Yes" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:932 +#: addons/web/static/src/js/search.js:937 +msgid "No" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1290 +#: addons/web/static/src/js/search.js:1295 +msgid "contains" +msgstr "sadrži" + +#. openerp-web +#: addons/web/static/src/js/search.js:1291 +#: addons/web/static/src/js/search.js:1296 +msgid "doesn't contain" +msgstr "Ne sarži" + +#. openerp-web +#: addons/web/static/src/js/search.js:1292 +#: addons/web/static/src/js/search.js:1306 +#: addons/web/static/src/js/search.js:1325 +#: addons/web/static/src/js/search.js:1344 +#: addons/web/static/src/js/search.js:1365 +#: addons/web/static/src/js/search.js:1297 +#: addons/web/static/src/js/search.js:1311 +#: addons/web/static/src/js/search.js:1330 +#: addons/web/static/src/js/search.js:1349 +#: addons/web/static/src/js/search.js:1370 +msgid "is equal to" +msgstr "je jednako" + +#. openerp-web +#: addons/web/static/src/js/search.js:1293 +#: addons/web/static/src/js/search.js:1307 +#: addons/web/static/src/js/search.js:1326 +#: addons/web/static/src/js/search.js:1345 +#: addons/web/static/src/js/search.js:1366 +#: addons/web/static/src/js/search.js:1298 +#: addons/web/static/src/js/search.js:1312 +#: addons/web/static/src/js/search.js:1331 +#: addons/web/static/src/js/search.js:1350 +#: addons/web/static/src/js/search.js:1371 +msgid "is not equal to" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1294 +#: addons/web/static/src/js/search.js:1308 +#: addons/web/static/src/js/search.js:1327 +#: addons/web/static/src/js/search.js:1346 +#: addons/web/static/src/js/search.js:1367 +#: addons/web/static/src/js/search.js:1299 +#: addons/web/static/src/js/search.js:1313 +#: addons/web/static/src/js/search.js:1332 +#: addons/web/static/src/js/search.js:1351 +#: addons/web/static/src/js/search.js:1372 +msgid "greater than" +msgstr "veće od" + +#. openerp-web +#: addons/web/static/src/js/search.js:1295 +#: addons/web/static/src/js/search.js:1309 +#: addons/web/static/src/js/search.js:1328 +#: addons/web/static/src/js/search.js:1347 +#: addons/web/static/src/js/search.js:1368 +#: addons/web/static/src/js/search.js:1300 +#: addons/web/static/src/js/search.js:1314 +#: addons/web/static/src/js/search.js:1333 +#: addons/web/static/src/js/search.js:1352 +#: addons/web/static/src/js/search.js:1373 +msgid "less than" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1296 +#: addons/web/static/src/js/search.js:1310 +#: addons/web/static/src/js/search.js:1329 +#: addons/web/static/src/js/search.js:1348 +#: addons/web/static/src/js/search.js:1369 +#: addons/web/static/src/js/search.js:1301 +#: addons/web/static/src/js/search.js:1315 +#: addons/web/static/src/js/search.js:1334 +#: addons/web/static/src/js/search.js:1353 +#: addons/web/static/src/js/search.js:1374 +msgid "greater or equal than" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1297 +#: addons/web/static/src/js/search.js:1311 +#: addons/web/static/src/js/search.js:1330 +#: addons/web/static/src/js/search.js:1349 +#: addons/web/static/src/js/search.js:1370 +#: addons/web/static/src/js/search.js:1302 +#: addons/web/static/src/js/search.js:1316 +#: addons/web/static/src/js/search.js:1335 +#: addons/web/static/src/js/search.js:1354 +#: addons/web/static/src/js/search.js:1375 +msgid "less or equal than" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1360 +#: addons/web/static/src/js/search.js:1383 +#: addons/web/static/src/js/search.js:1365 +#: addons/web/static/src/js/search.js:1388 +msgid "is" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1384 +#: addons/web/static/src/js/search.js:1389 +msgid "is not" +msgstr "nije" + +#. openerp-web +#: addons/web/static/src/js/search.js:1396 +#: addons/web/static/src/js/search.js:1401 +msgid "is true" +msgstr "je istinito" + +#. openerp-web +#: addons/web/static/src/js/search.js:1397 +#: addons/web/static/src/js/search.js:1402 +msgid "is false" +msgstr "je pogrešno" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:20 +#, python-format +msgid "Manage Views (%s)" +msgstr "Upravljanje pregledom (%s)" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:46 +#: addons/web/static/src/js/view_list.js:17 +#: addons/web/static/src/xml/base.xml:100 +#: addons/web/static/src/xml/base.xml:327 +#: addons/web/static/src/xml/base.xml:756 +msgid "Create" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:47 +#: addons/web/static/src/xml/base.xml:483 +#: addons/web/static/src/xml/base.xml:755 +msgid "Edit" +msgstr "Uređivanje" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:48 +#: addons/web/static/src/xml/base.xml:1647 +msgid "Remove" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:71 +#, python-format +msgid "Create a view (%s)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:168 +msgid "Do you really want to remove this view?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:364 +#, python-format +msgid "View Editor %d - %s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:367 +msgid "Inherited View" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:371 +msgid "Do you really wants to create an inherited view here?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:381 +msgid "Preview" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:501 +msgid "Do you really want to remove this node?" +msgstr "Da li sigurno želite uklonuti ovaj čvor?" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:815 +#: addons/web/static/src/js/view_editor.js:939 +msgid "Properties" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:818 +#: addons/web/static/src/js/view_editor.js:942 +msgid "Update" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:16 +msgid "Form" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:121 +#: addons/web/static/src/js/views.js:803 +msgid "Customize" +msgstr "Podesi" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:123 +#: addons/web/static/src/js/view_form.js:686 +#: addons/web/static/src/js/view_form.js:692 +msgid "Set Default" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:469 +#: addons/web/static/src/js/view_form.js:475 +msgid "" +"Warning, the record has been modified, your changes will be discarded." +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:693 +#: addons/web/static/src/js/view_form.js:699 +msgid "Save default" +msgstr "Snimi zadano" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:754 +#: addons/web/static/src/js/view_form.js:760 +msgid "Attachments" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:792 +#: addons/web/static/src/js/view_form.js:798 +#, python-format +msgid "Do you really want to delete the attachment %s?" +msgstr "Da li sigurno želite izbrisati dodatak %s?" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:822 +#: addons/web/static/src/js/view_form.js:828 +#, python-format +msgid "Unknown operator %s in domain %s" +msgstr "Nepoznat operator %s na domeni %s" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:830 +#: addons/web/static/src/js/view_form.js:836 +#, python-format +msgid "Unknown field %s in domain %s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:868 +#: addons/web/static/src/js/view_form.js:874 +#, python-format +msgid "Unsupported operator %s in domain %s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:1225 +#: addons/web/static/src/js/view_form.js:1231 +msgid "Confirm" +msgstr "Portvrdi" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:1921 +#: addons/web/static/src/js/view_form.js:2578 +#: addons/web/static/src/js/view_form.js:2741 +#: addons/web/static/src/js/view_form.js:1933 +#: addons/web/static/src/js/view_form.js:2590 +#: addons/web/static/src/js/view_form.js:2760 +msgid "Open: " +msgstr "Otvori: " + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2049 +#: addons/web/static/src/js/view_form.js:2061 +msgid "   Search More..." +msgstr "   Traži Više..." + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2062 +#: addons/web/static/src/js/view_form.js:2074 +#, python-format +msgid "   Create \"%s\"" +msgstr "   Kreiraj\"%s\"" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2068 +#: addons/web/static/src/js/view_form.js:2080 +msgid "   Create and Edit..." +msgstr "   Kreiraj i Uredi..." + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2101 +#: addons/web/static/src/js/views.js:675 +#: addons/web/static/src/js/view_form.js:2113 +msgid "Search: " +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2101 +#: addons/web/static/src/js/view_form.js:2550 +#: addons/web/static/src/js/view_form.js:2113 +#: addons/web/static/src/js/view_form.js:2562 +msgid "Create: " +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2661 +#: addons/web/static/src/xml/base.xml:750 +#: addons/web/static/src/xml/base.xml:772 +#: addons/web/static/src/xml/base.xml:1646 +#: addons/web/static/src/js/view_form.js:2680 +msgid "Add" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2721 +#: addons/web/static/src/js/view_form.js:2740 +msgid "Add: " +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:8 +msgid "List" +msgstr "Lista" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:269 +msgid "Unlimited" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:305 +#: addons/web/static/src/js/view_list.js:309 +#, python-format +msgid "[%(first_record)d to %(last_record)d] of %(records_count)d" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:524 +#: addons/web/static/src/js/view_list.js:528 +msgid "Do you really want to remove these records?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:1230 +#: addons/web/static/src/js/view_list.js:1232 +msgid "Undefined" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:1327 +#: addons/web/static/src/js/view_list.js:1331 +#, python-format +msgid "%(page)d/%(page_count)d" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_page.js:8 +msgid "Page" +msgstr "Stranica" + +#. openerp-web +#: addons/web/static/src/js/view_page.js:52 +msgid "Do you really want to delete this record?" +msgstr "Jeste li sigurni da želite izbrisati ovaj zapis?" + +#. openerp-web +#: addons/web/static/src/js/view_tree.js:11 +msgid "Tree" +msgstr "Stablo" + +#. openerp-web +#: addons/web/static/src/js/views.js:565 +#: addons/web/static/src/xml/base.xml:480 +msgid "Fields View Get" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:573 +#, python-format +msgid "View Log (%s)" +msgstr "Pogledaj Log (%s)" + +#. openerp-web +#: addons/web/static/src/js/views.js:600 +#, python-format +msgid "Model %s fields" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:610 +#: addons/web/static/src/xml/base.xml:482 +msgid "Manage Views" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:611 +msgid "Could not find current view declaration" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:805 +msgid "Translate" +msgstr "Prevedi" + +#. openerp-web +#: addons/web/static/src/js/views.js:807 +msgid "Technical translation" +msgstr "Tehnički prevod" + +#. openerp-web +#: addons/web/static/src/js/views.js:811 +msgid "Other Options" +msgstr "Ostale opcije" + +#. openerp-web +#: addons/web/static/src/js/views.js:814 +#: addons/web/static/src/xml/base.xml:1736 +msgid "Import" +msgstr "Uvezi" + +#. openerp-web +#: addons/web/static/src/js/views.js:817 +#: addons/web/static/src/xml/base.xml:1606 +msgid "Export" +msgstr "Izvoz" + +#. openerp-web +#: addons/web/static/src/js/views.js:825 +msgid "Reports" +msgstr "Izvještaji" + +#. openerp-web +#: addons/web/static/src/js/views.js:825 +msgid "Actions" +msgstr "Akcije" + +#. openerp-web +#: addons/web/static/src/js/views.js:825 +msgid "Links" +msgstr "Linkovi" + +#. openerp-web +#: addons/web/static/src/js/views.js:919 +msgid "You must choose at least one record." +msgstr "Morate izabrati barem jedan zapis" + +#. openerp-web +#: addons/web/static/src/js/views.js:920 +msgid "Warning" +msgstr "Upozorenje" + +#. openerp-web +#: addons/web/static/src/js/views.js:957 +msgid "Translations" +msgstr "Prevodi" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:44 +#: addons/web/static/src/xml/base.xml:315 +msgid "Powered by" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:44 +#: addons/web/static/src/xml/base.xml:315 +#: addons/web/static/src/xml/base.xml:1813 +msgid "OpenERP" +msgstr "OpenERP" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:52 +msgid "Loading..." +msgstr "Učitavam..." + +#. openerp-web +#: addons/web/static/src/xml/base.xml:61 +msgid "CREATE DATABASE" +msgstr "Kreiraj Bazu podataka" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:68 +#: addons/web/static/src/xml/base.xml:211 +msgid "Master password:" +msgstr "Glavni Password:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:72 +#: addons/web/static/src/xml/base.xml:191 +msgid "New database name:" +msgstr "Naziv nove baze podataka:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:77 +msgid "Load Demonstration data:" +msgstr "Učitavam Demonstrativne podatke" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:81 +msgid "Default language:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:91 +msgid "Admin password:" +msgstr "Administratorov pasword:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:95 +msgid "Confirm password:" +msgstr "Potvrdi password:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:109 +msgid "DROP DATABASE" +msgstr "Izbaci Bazu podataka" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:116 +#: addons/web/static/src/xml/base.xml:150 +#: addons/web/static/src/xml/base.xml:301 +msgid "Database:" +msgstr "Baza podataka:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:128 +#: addons/web/static/src/xml/base.xml:162 +#: addons/web/static/src/xml/base.xml:187 +msgid "Master Password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:132 +#: addons/web/static/src/xml/base.xml:328 +msgid "Drop" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:143 +msgid "BACKUP DATABASE" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:166 +#: addons/web/static/src/xml/base.xml:329 +msgid "Backup" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:175 +msgid "RESTORE DATABASE" +msgstr "Povrati Bazu podataka" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:182 +msgid "File:" +msgstr "Datoteka:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:195 +#: addons/web/static/src/xml/base.xml:330 +msgid "Restore" +msgstr "Vrati" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:204 +msgid "CHANGE MASTER PASSWORD" +msgstr "Promijeni glavni password" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:216 +msgid "New master password:" +msgstr "Novi glavni password" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:221 +msgid "Confirm new master password:" +msgstr "Potvrdi glavni password" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:251 +msgid "" +"Your version of OpenERP is unsupported. Support & maintenance services are " +"available here:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:251 +msgid "OpenERP Entreprise" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:256 +msgid "OpenERP Enterprise Contract." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:257 +msgid "Your report will be sent to the OpenERP Enterprise team." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:259 +msgid "Summary:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:263 +msgid "Description:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:267 +msgid "What you did:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:297 +msgid "Invalid username or password" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:306 +msgid "Username" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:308 +#: addons/web/static/src/xml/base.xml:331 +msgid "Password" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:310 +msgid "Log in" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:314 +msgid "Manage Databases" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:332 +msgid "Back to Login" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:353 +msgid "Home" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:363 +msgid "LOGOUT" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:388 +msgid "Fold menu" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:389 +msgid "Unfold menu" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:454 +msgid "Hide this tip" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:455 +msgid "Disable all tips" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:463 +msgid "Add / Remove Shortcut..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:471 +msgid "More…" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:477 +msgid "Debug View#" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:478 +msgid "View Log (perm_read)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:479 +msgid "View Fields" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:483 +msgid "View" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:484 +msgid "Edit SearchView" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:485 +msgid "Edit Action" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:486 +msgid "Edit Workflow" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:491 +msgid "ID:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:494 +msgid "XML ID:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:497 +msgid "Creation User:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:500 +msgid "Creation Date:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:503 +msgid "Latest Modification by:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:506 +msgid "Latest Modification Date:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:542 +msgid "Field" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:632 +#: addons/web/static/src/xml/base.xml:758 +#: addons/web/static/src/xml/base.xml:1708 +msgid "Delete" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:757 +msgid "Duplicate" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:775 +msgid "Add attachment" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:801 +msgid "Default:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:818 +msgid "Condition:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:837 +msgid "Only you" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:844 +msgid "All users" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:851 +msgid "Unhandled widget" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:900 +msgid "Notebook Page \"" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:905 +#: addons/web/static/src/xml/base.xml:964 +msgid "Modifiers:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:931 +msgid "(nolabel)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:936 +msgid "Field:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:940 +msgid "Object:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:944 +msgid "Type:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:948 +msgid "Widget:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:952 +msgid "Size:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:956 +msgid "Context:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:960 +msgid "Domain:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:968 +msgid "Change default:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:972 +msgid "On change:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:976 +msgid "Relation:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:980 +msgid "Selection:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1020 +msgid "Send an e-mail with your default e-mail client" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1034 +msgid "Open this resource" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1056 +msgid "Select date" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1090 +msgid "Open..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1091 +msgid "Create..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1092 +msgid "Search..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1095 +msgid "..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1155 +#: addons/web/static/src/xml/base.xml:1198 +msgid "Set Image" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1163 +#: addons/web/static/src/xml/base.xml:1213 +#: addons/web/static/src/xml/base.xml:1215 +#: addons/web/static/src/xml/base.xml:1272 +msgid "Clear" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1172 +#: addons/web/static/src/xml/base.xml:1223 +msgid "Uploading ..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1200 +#: addons/web/static/src/xml/base.xml:1495 +msgid "Select" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1207 +#: addons/web/static/src/xml/base.xml:1209 +msgid "Save As" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1238 +msgid "Button" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1241 +msgid "(no string)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1248 +msgid "Special:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1253 +msgid "Button Type:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1257 +msgid "Method:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1261 +msgid "Action ID:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1271 +msgid "Search" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1279 +msgid "Filters" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1280 +msgid "-- Filters --" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1289 +msgid "-- Actions --" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1290 +msgid "Add Advanced Filter" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1291 +msgid "Save Filter" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1293 +msgid "Manage Filters" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1298 +msgid "Filter Name:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1300 +msgid "(Any existing filter with the same name will be replaced)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1305 +msgid "Select Dashboard to add this filter to:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1309 +msgid "Title of new Dashboard item:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1416 +msgid "Advanced Filters" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1426 +msgid "Any of the following conditions must match" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1427 +msgid "All the following conditions must match" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1428 +msgid "None of the following conditions must match" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1435 +msgid "Add condition" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1436 +msgid "and" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1503 +msgid "Save & New" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1504 +msgid "Save & Close" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1611 +msgid "" +"This wizard will export all data that matches the current search criteria to " +"a CSV file.\n" +" You can export all data or only the fields that can be " +"reimported after modification." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1618 +msgid "Export Type:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1620 +msgid "Import Compatible Export" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1621 +msgid "Export all Data" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1624 +msgid "Export Formats" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1630 +msgid "Available fields" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1632 +msgid "Fields to export" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1634 +msgid "Save fields list" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1648 +msgid "Remove All" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1660 +msgid "Name" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1693 +msgid "Save as:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1700 +msgid "Saved exports:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1714 +msgid "Old Password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1719 +msgid "New Password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1724 +msgid "Confirm Password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1742 +msgid "1. Import a .CSV file" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1743 +msgid "" +"Select a .CSV file to import. If you need a sample of file to import,\n" +" you should use the export tool with the \"Import Compatible\" option." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1747 +msgid "CSV File:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1750 +msgid "2. Check your file format" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1753 +msgid "Import Options" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1757 +msgid "Does your file have titles?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1763 +msgid "Separator:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1765 +msgid "Delimiter:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1769 +msgid "Encoding:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1772 +msgid "UTF-8" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1773 +msgid "Latin 1" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1776 +msgid "Lines to skip" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1776 +msgid "" +"For use if CSV files have titles on multiple lines, skips more than a single " +"line during import" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1803 +msgid "The import failed due to:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1805 +msgid "Here is a preview of the file we could not import:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1812 +msgid "Activate the developper mode" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1814 +msgid "Version" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1815 +msgid "Copyright © 2004-TODAY OpenERP SA. All Rights Reserved." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1816 +msgid "OpenERP is a trademark of the" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1817 +msgid "OpenERP SA Company" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1819 +msgid "Licenced under the terms of" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1820 +msgid "GNU Affero General Public License" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1822 +msgid "For more information visit" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1823 +msgid "OpenERP.com" +msgstr "" diff --git a/addons/web/i18n/es_CL.po b/addons/web/i18n/es_CL.po new file mode 100644 index 00000000000..261d8e8d9e4 --- /dev/null +++ b/addons/web/i18n/es_CL.po @@ -0,0 +1,1547 @@ +# Spanish (Chile) translation for openerp-web +# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012 +# This file is distributed under the same license as the openerp-web package. +# FIRST AUTHOR , 2012. +# +msgid "" +msgstr "" +"Project-Id-Version: openerp-web\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2012-02-14 15:27+0100\n" +"PO-Revision-Date: 2012-04-14 15:27+0000\n" +"Last-Translator: FULL NAME \n" +"Language-Team: Spanish (Chile) \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2012-04-15 04:48+0000\n" +"X-Generator: Launchpad (build 15070)\n" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:172 +#: addons/web/static/src/js/chrome.js:198 +#: addons/web/static/src/js/chrome.js:414 +#: addons/web/static/src/js/view_form.js:419 +#: addons/web/static/src/js/view_form.js:1233 +#: addons/web/static/src/xml/base.xml:1695 +#: addons/web/static/src/js/view_form.js:424 +#: addons/web/static/src/js/view_form.js:1239 +msgid "Ok" +msgstr "Ok" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:180 +msgid "Send OpenERP Enterprise Report" +msgstr "Enviar informe OpenERP Enterprise" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:194 +msgid "Dont send" +msgstr "No enviar" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:256 +#, python-format +msgid "Loading (%d)" +msgstr "Cargando (%d)" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:288 +msgid "Invalid database name" +msgstr "Nombre de base de datos incorrecto" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:483 +msgid "Backed" +msgstr "Guardado" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:484 +msgid "Database backed up successfully" +msgstr "Base de datos guardada correctamente" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:527 +msgid "Restored" +msgstr "Restaurada" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:527 +msgid "Database restored successfully" +msgstr "Base de datos restaurada correctamente" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:708 +#: addons/web/static/src/xml/base.xml:359 +msgid "About" +msgstr "Acerca de" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:787 +#: addons/web/static/src/xml/base.xml:356 +msgid "Preferences" +msgstr "Preferencias" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:790 +#: addons/web/static/src/js/search.js:239 +#: addons/web/static/src/js/search.js:288 +#: addons/web/static/src/js/view_editor.js:95 +#: addons/web/static/src/js/view_editor.js:836 +#: addons/web/static/src/js/view_editor.js:962 +#: addons/web/static/src/js/view_form.js:1228 +#: addons/web/static/src/xml/base.xml:738 +#: addons/web/static/src/xml/base.xml:1496 +#: addons/web/static/src/xml/base.xml:1506 +#: addons/web/static/src/xml/base.xml:1515 +#: addons/web/static/src/js/search.js:293 +#: addons/web/static/src/js/view_form.js:1234 +msgid "Cancel" +msgstr "Cancelar" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:791 +msgid "Change password" +msgstr "Cambiar la Contraseña" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:792 +#: addons/web/static/src/js/view_editor.js:73 +#: addons/web/static/src/js/views.js:962 +#: addons/web/static/src/xml/base.xml:737 +#: addons/web/static/src/xml/base.xml:1500 +#: addons/web/static/src/xml/base.xml:1514 +msgid "Save" +msgstr "Guardar" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:811 +#: addons/web/static/src/xml/base.xml:226 +#: addons/web/static/src/xml/base.xml:1729 +msgid "Change Password" +msgstr "Cambiar Contraseña" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:1096 +#: addons/web/static/src/js/chrome.js:1100 +msgid "OpenERP - Unsupported/Community Version" +msgstr "OpenERP - Versión Community" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:1131 +#: addons/web/static/src/js/chrome.js:1135 +msgid "Client Error" +msgstr "Error en el cliente" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:6 +msgid "Export Data" +msgstr "Exportar datos" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:19 +#: addons/web/static/src/js/data_import.js:69 +#: addons/web/static/src/js/view_editor.js:49 +#: addons/web/static/src/js/view_editor.js:398 +#: addons/web/static/src/js/view_form.js:692 +#: addons/web/static/src/js/view_form.js:3044 +#: addons/web/static/src/js/views.js:963 +#: addons/web/static/src/js/view_form.js:698 +#: addons/web/static/src/js/view_form.js:3067 +msgid "Close" +msgstr "Cerrar" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:20 +msgid "Export To File" +msgstr "Exportar a fichero" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:125 +msgid "Please enter save field list name" +msgstr "Por favor, introduzca el nombre de la lista de campos a guardar" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:360 +msgid "Please select fields to save export list..." +msgstr "" +"Por favor, seleccione los campos para guardar la lista de exportación..." + +#. openerp-web +#: addons/web/static/src/js/data_export.js:373 +msgid "Please select fields to export..." +msgstr "Por favor, seleccione los campos a exportar" + +#. openerp-web +#: addons/web/static/src/js/data_import.js:34 +msgid "Import Data" +msgstr "Importar datos" + +#. openerp-web +#: addons/web/static/src/js/data_import.js:70 +msgid "Import File" +msgstr "Importar archivo" + +#. openerp-web +#: addons/web/static/src/js/data_import.js:105 +msgid "External ID" +msgstr "ID externo" + +#. openerp-web +#: addons/web/static/src/js/formats.js:300 +#: addons/web/static/src/js/view_page.js:245 +#: addons/web/static/src/js/formats.js:322 +#: addons/web/static/src/js/view_page.js:251 +msgid "Download" +msgstr "Descargar" + +#. openerp-web +#: addons/web/static/src/js/formats.js:305 +#: addons/web/static/src/js/formats.js:327 +#, python-format +msgid "Download \"%s\"" +msgstr "Descargar \"%s\"" + +#. openerp-web +#: addons/web/static/src/js/search.js:191 +msgid "Filter disabled due to invalid syntax" +msgstr "Filtro desactivado debido a sintaxis inválida" + +#. openerp-web +#: addons/web/static/src/js/search.js:237 +msgid "Filter Entry" +msgstr "Entrada del filtro" + +#. openerp-web +#: addons/web/static/src/js/search.js:242 +#: addons/web/static/src/js/search.js:291 +#: addons/web/static/src/js/search.js:296 +msgid "OK" +msgstr "Aceptar" + +#. openerp-web +#: addons/web/static/src/js/search.js:286 +#: addons/web/static/src/xml/base.xml:1292 +#: addons/web/static/src/js/search.js:291 +msgid "Add to Dashboard" +msgstr "Añadir al tablero" + +#. openerp-web +#: addons/web/static/src/js/search.js:415 +#: addons/web/static/src/js/search.js:420 +msgid "Invalid Search" +msgstr "Búsqueda incorrecta" + +#. openerp-web +#: addons/web/static/src/js/search.js:415 +#: addons/web/static/src/js/search.js:420 +msgid "triggered from search view" +msgstr "Disparador activado desde la vista de búsqueda" + +#. openerp-web +#: addons/web/static/src/js/search.js:503 +#: addons/web/static/src/js/search.js:508 +#, python-format +msgid "Incorrect value for field %(fieldname)s: [%(value)s] is %(message)s" +msgstr "" +"Valor incorrecto para el campo %(fieldname)s: [%(value)s] es %(message)s" + +#. openerp-web +#: addons/web/static/src/js/search.js:839 +#: addons/web/static/src/js/search.js:844 +msgid "not a valid integer" +msgstr "entero no válido" + +#. openerp-web +#: addons/web/static/src/js/search.js:853 +#: addons/web/static/src/js/search.js:858 +msgid "not a valid number" +msgstr "no es un número válido" + +#. openerp-web +#: addons/web/static/src/js/search.js:931 +#: addons/web/static/src/xml/base.xml:968 +#: addons/web/static/src/js/search.js:936 +msgid "Yes" +msgstr "Sí" + +#. openerp-web +#: addons/web/static/src/js/search.js:932 +#: addons/web/static/src/js/search.js:937 +msgid "No" +msgstr "No" + +#. openerp-web +#: addons/web/static/src/js/search.js:1290 +#: addons/web/static/src/js/search.js:1295 +msgid "contains" +msgstr "contiene" + +#. openerp-web +#: addons/web/static/src/js/search.js:1291 +#: addons/web/static/src/js/search.js:1296 +msgid "doesn't contain" +msgstr "no contiene" + +#. openerp-web +#: addons/web/static/src/js/search.js:1292 +#: addons/web/static/src/js/search.js:1306 +#: addons/web/static/src/js/search.js:1325 +#: addons/web/static/src/js/search.js:1344 +#: addons/web/static/src/js/search.js:1365 +#: addons/web/static/src/js/search.js:1297 +#: addons/web/static/src/js/search.js:1311 +#: addons/web/static/src/js/search.js:1330 +#: addons/web/static/src/js/search.js:1349 +#: addons/web/static/src/js/search.js:1370 +msgid "is equal to" +msgstr "es igual a" + +#. openerp-web +#: addons/web/static/src/js/search.js:1293 +#: addons/web/static/src/js/search.js:1307 +#: addons/web/static/src/js/search.js:1326 +#: addons/web/static/src/js/search.js:1345 +#: addons/web/static/src/js/search.js:1366 +#: addons/web/static/src/js/search.js:1298 +#: addons/web/static/src/js/search.js:1312 +#: addons/web/static/src/js/search.js:1331 +#: addons/web/static/src/js/search.js:1350 +#: addons/web/static/src/js/search.js:1371 +msgid "is not equal to" +msgstr "es distinto de" + +#. openerp-web +#: addons/web/static/src/js/search.js:1294 +#: addons/web/static/src/js/search.js:1308 +#: addons/web/static/src/js/search.js:1327 +#: addons/web/static/src/js/search.js:1346 +#: addons/web/static/src/js/search.js:1367 +#: addons/web/static/src/js/search.js:1299 +#: addons/web/static/src/js/search.js:1313 +#: addons/web/static/src/js/search.js:1332 +#: addons/web/static/src/js/search.js:1351 +#: addons/web/static/src/js/search.js:1372 +msgid "greater than" +msgstr "mayor que" + +#. openerp-web +#: addons/web/static/src/js/search.js:1295 +#: addons/web/static/src/js/search.js:1309 +#: addons/web/static/src/js/search.js:1328 +#: addons/web/static/src/js/search.js:1347 +#: addons/web/static/src/js/search.js:1368 +#: addons/web/static/src/js/search.js:1300 +#: addons/web/static/src/js/search.js:1314 +#: addons/web/static/src/js/search.js:1333 +#: addons/web/static/src/js/search.js:1352 +#: addons/web/static/src/js/search.js:1373 +msgid "less than" +msgstr "menor que" + +#. openerp-web +#: addons/web/static/src/js/search.js:1296 +#: addons/web/static/src/js/search.js:1310 +#: addons/web/static/src/js/search.js:1329 +#: addons/web/static/src/js/search.js:1348 +#: addons/web/static/src/js/search.js:1369 +#: addons/web/static/src/js/search.js:1301 +#: addons/web/static/src/js/search.js:1315 +#: addons/web/static/src/js/search.js:1334 +#: addons/web/static/src/js/search.js:1353 +#: addons/web/static/src/js/search.js:1374 +msgid "greater or equal than" +msgstr "mayor o igual que" + +#. openerp-web +#: addons/web/static/src/js/search.js:1297 +#: addons/web/static/src/js/search.js:1311 +#: addons/web/static/src/js/search.js:1330 +#: addons/web/static/src/js/search.js:1349 +#: addons/web/static/src/js/search.js:1370 +#: addons/web/static/src/js/search.js:1302 +#: addons/web/static/src/js/search.js:1316 +#: addons/web/static/src/js/search.js:1335 +#: addons/web/static/src/js/search.js:1354 +#: addons/web/static/src/js/search.js:1375 +msgid "less or equal than" +msgstr "menor o igual que" + +#. openerp-web +#: addons/web/static/src/js/search.js:1360 +#: addons/web/static/src/js/search.js:1383 +#: addons/web/static/src/js/search.js:1365 +#: addons/web/static/src/js/search.js:1388 +msgid "is" +msgstr "es" + +#. openerp-web +#: addons/web/static/src/js/search.js:1384 +#: addons/web/static/src/js/search.js:1389 +msgid "is not" +msgstr "no es" + +#. openerp-web +#: addons/web/static/src/js/search.js:1396 +#: addons/web/static/src/js/search.js:1401 +msgid "is true" +msgstr "es verdadero" + +#. openerp-web +#: addons/web/static/src/js/search.js:1397 +#: addons/web/static/src/js/search.js:1402 +msgid "is false" +msgstr "es falso" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:20 +#, python-format +msgid "Manage Views (%s)" +msgstr "Gestionar vistas (%s)" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:46 +#: addons/web/static/src/js/view_list.js:17 +#: addons/web/static/src/xml/base.xml:100 +#: addons/web/static/src/xml/base.xml:327 +#: addons/web/static/src/xml/base.xml:756 +msgid "Create" +msgstr "Crear" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:47 +#: addons/web/static/src/xml/base.xml:483 +#: addons/web/static/src/xml/base.xml:755 +msgid "Edit" +msgstr "Editar" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:48 +#: addons/web/static/src/xml/base.xml:1647 +msgid "Remove" +msgstr "Eliminar" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:71 +#, python-format +msgid "Create a view (%s)" +msgstr "Crear una vista (%s)" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:168 +msgid "Do you really want to remove this view?" +msgstr "¿Realmente desea elimar esta vista?" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:364 +#, python-format +msgid "View Editor %d - %s" +msgstr "Ver Editor %d - %s" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:367 +msgid "Inherited View" +msgstr "Vista heredada" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:371 +msgid "Do you really wants to create an inherited view here?" +msgstr "¿Realmente desea crear una vista heredada aquí?" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:381 +msgid "Preview" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:501 +msgid "Do you really want to remove this node?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:815 +#: addons/web/static/src/js/view_editor.js:939 +msgid "Properties" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:818 +#: addons/web/static/src/js/view_editor.js:942 +msgid "Update" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:16 +msgid "Form" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:121 +#: addons/web/static/src/js/views.js:803 +msgid "Customize" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:123 +#: addons/web/static/src/js/view_form.js:686 +#: addons/web/static/src/js/view_form.js:692 +msgid "Set Default" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:469 +#: addons/web/static/src/js/view_form.js:475 +msgid "" +"Warning, the record has been modified, your changes will be discarded." +msgstr "" +"Advertencia, el registro se ha modificado, los cambios serán descartados." + +#. openerp-web +#: addons/web/static/src/js/view_form.js:693 +#: addons/web/static/src/js/view_form.js:699 +msgid "Save default" +msgstr "Guardar por defecto" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:754 +#: addons/web/static/src/js/view_form.js:760 +msgid "Attachments" +msgstr "Archivos adjuntos" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:792 +#: addons/web/static/src/js/view_form.js:798 +#, python-format +msgid "Do you really want to delete the attachment %s?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:822 +#: addons/web/static/src/js/view_form.js:828 +#, python-format +msgid "Unknown operator %s in domain %s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:830 +#: addons/web/static/src/js/view_form.js:836 +#, python-format +msgid "Unknown field %s in domain %s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:868 +#: addons/web/static/src/js/view_form.js:874 +#, python-format +msgid "Unsupported operator %s in domain %s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:1225 +#: addons/web/static/src/js/view_form.js:1231 +msgid "Confirm" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:1921 +#: addons/web/static/src/js/view_form.js:2578 +#: addons/web/static/src/js/view_form.js:2741 +#: addons/web/static/src/js/view_form.js:1933 +#: addons/web/static/src/js/view_form.js:2590 +#: addons/web/static/src/js/view_form.js:2760 +msgid "Open: " +msgstr "Abrir " + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2049 +#: addons/web/static/src/js/view_form.js:2061 +msgid "   Search More..." +msgstr "   Buscar más..." + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2062 +#: addons/web/static/src/js/view_form.js:2074 +#, python-format +msgid "   Create \"%s\"" +msgstr "   Crear \"%s\"" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2068 +#: addons/web/static/src/js/view_form.js:2080 +msgid "   Create and Edit..." +msgstr "   Crear y Editar..." + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2101 +#: addons/web/static/src/js/views.js:675 +#: addons/web/static/src/js/view_form.js:2113 +msgid "Search: " +msgstr "Buscar: " + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2101 +#: addons/web/static/src/js/view_form.js:2550 +#: addons/web/static/src/js/view_form.js:2113 +#: addons/web/static/src/js/view_form.js:2562 +msgid "Create: " +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2661 +#: addons/web/static/src/xml/base.xml:750 +#: addons/web/static/src/xml/base.xml:772 +#: addons/web/static/src/xml/base.xml:1646 +#: addons/web/static/src/js/view_form.js:2680 +msgid "Add" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2721 +#: addons/web/static/src/js/view_form.js:2740 +msgid "Add: " +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:8 +msgid "List" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:269 +msgid "Unlimited" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:305 +#: addons/web/static/src/js/view_list.js:309 +#, python-format +msgid "[%(first_record)d to %(last_record)d] of %(records_count)d" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:524 +#: addons/web/static/src/js/view_list.js:528 +msgid "Do you really want to remove these records?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:1230 +#: addons/web/static/src/js/view_list.js:1232 +msgid "Undefined" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:1327 +#: addons/web/static/src/js/view_list.js:1331 +#, python-format +msgid "%(page)d/%(page_count)d" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_page.js:8 +msgid "Page" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_page.js:52 +msgid "Do you really want to delete this record?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_tree.js:11 +msgid "Tree" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:565 +#: addons/web/static/src/xml/base.xml:480 +msgid "Fields View Get" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:573 +#, python-format +msgid "View Log (%s)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:600 +#, python-format +msgid "Model %s fields" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:610 +#: addons/web/static/src/xml/base.xml:482 +msgid "Manage Views" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:611 +msgid "Could not find current view declaration" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:805 +msgid "Translate" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:807 +msgid "Technical translation" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:811 +msgid "Other Options" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:814 +#: addons/web/static/src/xml/base.xml:1736 +msgid "Import" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:817 +#: addons/web/static/src/xml/base.xml:1606 +msgid "Export" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:825 +msgid "Reports" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:825 +msgid "Actions" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:825 +msgid "Links" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:919 +msgid "You must choose at least one record." +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:920 +msgid "Warning" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:957 +msgid "Translations" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:44 +#: addons/web/static/src/xml/base.xml:315 +msgid "Powered by" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:44 +#: addons/web/static/src/xml/base.xml:315 +#: addons/web/static/src/xml/base.xml:1813 +msgid "OpenERP" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:52 +msgid "Loading..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:61 +msgid "CREATE DATABASE" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:68 +#: addons/web/static/src/xml/base.xml:211 +msgid "Master password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:72 +#: addons/web/static/src/xml/base.xml:191 +msgid "New database name:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:77 +msgid "Load Demonstration data:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:81 +msgid "Default language:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:91 +msgid "Admin password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:95 +msgid "Confirm password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:109 +msgid "DROP DATABASE" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:116 +#: addons/web/static/src/xml/base.xml:150 +#: addons/web/static/src/xml/base.xml:301 +msgid "Database:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:128 +#: addons/web/static/src/xml/base.xml:162 +#: addons/web/static/src/xml/base.xml:187 +msgid "Master Password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:132 +#: addons/web/static/src/xml/base.xml:328 +msgid "Drop" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:143 +msgid "BACKUP DATABASE" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:166 +#: addons/web/static/src/xml/base.xml:329 +msgid "Backup" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:175 +msgid "RESTORE DATABASE" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:182 +msgid "File:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:195 +#: addons/web/static/src/xml/base.xml:330 +msgid "Restore" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:204 +msgid "CHANGE MASTER PASSWORD" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:216 +msgid "New master password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:221 +msgid "Confirm new master password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:251 +msgid "" +"Your version of OpenERP is unsupported. Support & maintenance services are " +"available here:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:251 +msgid "OpenERP Entreprise" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:256 +msgid "OpenERP Enterprise Contract." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:257 +msgid "Your report will be sent to the OpenERP Enterprise team." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:259 +msgid "Summary:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:263 +msgid "Description:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:267 +msgid "What you did:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:297 +msgid "Invalid username or password" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:306 +msgid "Username" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:308 +#: addons/web/static/src/xml/base.xml:331 +msgid "Password" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:310 +msgid "Log in" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:314 +msgid "Manage Databases" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:332 +msgid "Back to Login" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:353 +msgid "Home" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:363 +msgid "LOGOUT" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:388 +msgid "Fold menu" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:389 +msgid "Unfold menu" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:454 +msgid "Hide this tip" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:455 +msgid "Disable all tips" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:463 +msgid "Add / Remove Shortcut..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:471 +msgid "More…" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:477 +msgid "Debug View#" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:478 +msgid "View Log (perm_read)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:479 +msgid "View Fields" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:483 +msgid "View" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:484 +msgid "Edit SearchView" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:485 +msgid "Edit Action" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:486 +msgid "Edit Workflow" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:491 +msgid "ID:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:494 +msgid "XML ID:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:497 +msgid "Creation User:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:500 +msgid "Creation Date:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:503 +msgid "Latest Modification by:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:506 +msgid "Latest Modification Date:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:542 +msgid "Field" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:632 +#: addons/web/static/src/xml/base.xml:758 +#: addons/web/static/src/xml/base.xml:1708 +msgid "Delete" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:757 +msgid "Duplicate" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:775 +msgid "Add attachment" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:801 +msgid "Default:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:818 +msgid "Condition:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:837 +msgid "Only you" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:844 +msgid "All users" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:851 +msgid "Unhandled widget" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:900 +msgid "Notebook Page \"" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:905 +#: addons/web/static/src/xml/base.xml:964 +msgid "Modifiers:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:931 +msgid "(nolabel)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:936 +msgid "Field:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:940 +msgid "Object:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:944 +msgid "Type:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:948 +msgid "Widget:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:952 +msgid "Size:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:956 +msgid "Context:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:960 +msgid "Domain:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:968 +msgid "Change default:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:972 +msgid "On change:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:976 +msgid "Relation:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:980 +msgid "Selection:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1020 +msgid "Send an e-mail with your default e-mail client" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1034 +msgid "Open this resource" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1056 +msgid "Select date" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1090 +msgid "Open..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1091 +msgid "Create..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1092 +msgid "Search..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1095 +msgid "..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1155 +#: addons/web/static/src/xml/base.xml:1198 +msgid "Set Image" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1163 +#: addons/web/static/src/xml/base.xml:1213 +#: addons/web/static/src/xml/base.xml:1215 +#: addons/web/static/src/xml/base.xml:1272 +msgid "Clear" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1172 +#: addons/web/static/src/xml/base.xml:1223 +msgid "Uploading ..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1200 +#: addons/web/static/src/xml/base.xml:1495 +msgid "Select" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1207 +#: addons/web/static/src/xml/base.xml:1209 +msgid "Save As" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1238 +msgid "Button" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1241 +msgid "(no string)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1248 +msgid "Special:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1253 +msgid "Button Type:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1257 +msgid "Method:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1261 +msgid "Action ID:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1271 +msgid "Search" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1279 +msgid "Filters" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1280 +msgid "-- Filters --" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1289 +msgid "-- Actions --" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1290 +msgid "Add Advanced Filter" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1291 +msgid "Save Filter" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1293 +msgid "Manage Filters" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1298 +msgid "Filter Name:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1300 +msgid "(Any existing filter with the same name will be replaced)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1305 +msgid "Select Dashboard to add this filter to:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1309 +msgid "Title of new Dashboard item:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1416 +msgid "Advanced Filters" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1426 +msgid "Any of the following conditions must match" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1427 +msgid "All the following conditions must match" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1428 +msgid "None of the following conditions must match" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1435 +msgid "Add condition" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1436 +msgid "and" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1503 +msgid "Save & New" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1504 +msgid "Save & Close" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1611 +msgid "" +"This wizard will export all data that matches the current search criteria to " +"a CSV file.\n" +" You can export all data or only the fields that can be " +"reimported after modification." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1618 +msgid "Export Type:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1620 +msgid "Import Compatible Export" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1621 +msgid "Export all Data" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1624 +msgid "Export Formats" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1630 +msgid "Available fields" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1632 +msgid "Fields to export" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1634 +msgid "Save fields list" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1648 +msgid "Remove All" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1660 +msgid "Name" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1693 +msgid "Save as:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1700 +msgid "Saved exports:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1714 +msgid "Old Password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1719 +msgid "New Password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1724 +msgid "Confirm Password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1742 +msgid "1. Import a .CSV file" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1743 +msgid "" +"Select a .CSV file to import. If you need a sample of file to import,\n" +" you should use the export tool with the \"Import Compatible\" option." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1747 +msgid "CSV File:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1750 +msgid "2. Check your file format" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1753 +msgid "Import Options" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1757 +msgid "Does your file have titles?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1763 +msgid "Separator:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1765 +msgid "Delimiter:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1769 +msgid "Encoding:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1772 +msgid "UTF-8" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1773 +msgid "Latin 1" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1776 +msgid "Lines to skip" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1776 +msgid "" +"For use if CSV files have titles on multiple lines, skips more than a single " +"line during import" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1803 +msgid "The import failed due to:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1805 +msgid "Here is a preview of the file we could not import:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1812 +msgid "Activate the developper mode" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1814 +msgid "Version" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1815 +msgid "Copyright © 2004-TODAY OpenERP SA. All Rights Reserved." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1816 +msgid "OpenERP is a trademark of the" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1817 +msgid "OpenERP SA Company" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1819 +msgid "Licenced under the terms of" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1820 +msgid "GNU Affero General Public License" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1822 +msgid "For more information visit" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1823 +msgid "OpenERP.com" +msgstr "" diff --git a/addons/web/i18n/gu.po b/addons/web/i18n/gu.po new file mode 100644 index 00000000000..4f675076ece --- /dev/null +++ b/addons/web/i18n/gu.po @@ -0,0 +1,1544 @@ +# Gujarati translation for openerp-web +# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012 +# This file is distributed under the same license as the openerp-web package. +# FIRST AUTHOR , 2012. +# +msgid "" +msgstr "" +"Project-Id-Version: openerp-web\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2012-02-14 15:27+0100\n" +"PO-Revision-Date: 2012-04-16 11:31+0000\n" +"Last-Translator: FULL NAME \n" +"Language-Team: Gujarati \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2012-04-17 05:24+0000\n" +"X-Generator: Launchpad (build 15099)\n" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:172 +#: addons/web/static/src/js/chrome.js:198 +#: addons/web/static/src/js/chrome.js:414 +#: addons/web/static/src/js/view_form.js:419 +#: addons/web/static/src/js/view_form.js:1233 +#: addons/web/static/src/xml/base.xml:1695 +#: addons/web/static/src/js/view_form.js:424 +#: addons/web/static/src/js/view_form.js:1239 +msgid "Ok" +msgstr "બરાબર" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:180 +msgid "Send OpenERP Enterprise Report" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:194 +msgid "Dont send" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:256 +#, python-format +msgid "Loading (%d)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:288 +msgid "Invalid database name" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:483 +msgid "Backed" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:484 +msgid "Database backed up successfully" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:527 +msgid "Restored" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:527 +msgid "Database restored successfully" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:708 +#: addons/web/static/src/xml/base.xml:359 +msgid "About" +msgstr "ના વિશે" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:787 +#: addons/web/static/src/xml/base.xml:356 +msgid "Preferences" +msgstr "સામાન્ય પસંદગીઓ" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:790 +#: addons/web/static/src/js/search.js:239 +#: addons/web/static/src/js/search.js:288 +#: addons/web/static/src/js/view_editor.js:95 +#: addons/web/static/src/js/view_editor.js:836 +#: addons/web/static/src/js/view_editor.js:962 +#: addons/web/static/src/js/view_form.js:1228 +#: addons/web/static/src/xml/base.xml:738 +#: addons/web/static/src/xml/base.xml:1496 +#: addons/web/static/src/xml/base.xml:1506 +#: addons/web/static/src/xml/base.xml:1515 +#: addons/web/static/src/js/search.js:293 +#: addons/web/static/src/js/view_form.js:1234 +msgid "Cancel" +msgstr "રદ કરો" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:791 +msgid "Change password" +msgstr "પાસવર્ડ બદલો" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:792 +#: addons/web/static/src/js/view_editor.js:73 +#: addons/web/static/src/js/views.js:962 +#: addons/web/static/src/xml/base.xml:737 +#: addons/web/static/src/xml/base.xml:1500 +#: addons/web/static/src/xml/base.xml:1514 +msgid "Save" +msgstr "સાચવો" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:811 +#: addons/web/static/src/xml/base.xml:226 +#: addons/web/static/src/xml/base.xml:1729 +msgid "Change Password" +msgstr "પાસવર્ડ બદલો" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:1096 +#: addons/web/static/src/js/chrome.js:1100 +msgid "OpenERP - Unsupported/Community Version" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/chrome.js:1131 +#: addons/web/static/src/js/chrome.js:1135 +msgid "Client Error" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:6 +msgid "Export Data" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:19 +#: addons/web/static/src/js/data_import.js:69 +#: addons/web/static/src/js/view_editor.js:49 +#: addons/web/static/src/js/view_editor.js:398 +#: addons/web/static/src/js/view_form.js:692 +#: addons/web/static/src/js/view_form.js:3044 +#: addons/web/static/src/js/views.js:963 +#: addons/web/static/src/js/view_form.js:698 +#: addons/web/static/src/js/view_form.js:3067 +msgid "Close" +msgstr "બંધ કરો" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:20 +msgid "Export To File" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:125 +msgid "Please enter save field list name" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:360 +msgid "Please select fields to save export list..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_export.js:373 +msgid "Please select fields to export..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/data_import.js:34 +msgid "Import Data" +msgstr "માહિતી આયાત કરો" + +#. openerp-web +#: addons/web/static/src/js/data_import.js:70 +msgid "Import File" +msgstr "ફાઈલ આયાત કરો" + +#. openerp-web +#: addons/web/static/src/js/data_import.js:105 +msgid "External ID" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/formats.js:300 +#: addons/web/static/src/js/view_page.js:245 +#: addons/web/static/src/js/formats.js:322 +#: addons/web/static/src/js/view_page.js:251 +msgid "Download" +msgstr "ડાઉનલોડ" + +#. openerp-web +#: addons/web/static/src/js/formats.js:305 +#: addons/web/static/src/js/formats.js:327 +#, python-format +msgid "Download \"%s\"" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:191 +msgid "Filter disabled due to invalid syntax" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:237 +msgid "Filter Entry" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:242 +#: addons/web/static/src/js/search.js:291 +#: addons/web/static/src/js/search.js:296 +msgid "OK" +msgstr "ઓકે" + +#. openerp-web +#: addons/web/static/src/js/search.js:286 +#: addons/web/static/src/xml/base.xml:1292 +#: addons/web/static/src/js/search.js:291 +msgid "Add to Dashboard" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:415 +#: addons/web/static/src/js/search.js:420 +msgid "Invalid Search" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:415 +#: addons/web/static/src/js/search.js:420 +msgid "triggered from search view" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:503 +#: addons/web/static/src/js/search.js:508 +#, python-format +msgid "Incorrect value for field %(fieldname)s: [%(value)s] is %(message)s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:839 +#: addons/web/static/src/js/search.js:844 +msgid "not a valid integer" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:853 +#: addons/web/static/src/js/search.js:858 +msgid "not a valid number" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:931 +#: addons/web/static/src/xml/base.xml:968 +#: addons/web/static/src/js/search.js:936 +msgid "Yes" +msgstr "હાં" + +#. openerp-web +#: addons/web/static/src/js/search.js:932 +#: addons/web/static/src/js/search.js:937 +msgid "No" +msgstr "નહીં" + +#. openerp-web +#: addons/web/static/src/js/search.js:1290 +#: addons/web/static/src/js/search.js:1295 +msgid "contains" +msgstr "સમાવે છે" + +#. openerp-web +#: addons/web/static/src/js/search.js:1291 +#: addons/web/static/src/js/search.js:1296 +msgid "doesn't contain" +msgstr "સમાવતું નથી" + +#. openerp-web +#: addons/web/static/src/js/search.js:1292 +#: addons/web/static/src/js/search.js:1306 +#: addons/web/static/src/js/search.js:1325 +#: addons/web/static/src/js/search.js:1344 +#: addons/web/static/src/js/search.js:1365 +#: addons/web/static/src/js/search.js:1297 +#: addons/web/static/src/js/search.js:1311 +#: addons/web/static/src/js/search.js:1330 +#: addons/web/static/src/js/search.js:1349 +#: addons/web/static/src/js/search.js:1370 +msgid "is equal to" +msgstr "ને બરાબર છે" + +#. openerp-web +#: addons/web/static/src/js/search.js:1293 +#: addons/web/static/src/js/search.js:1307 +#: addons/web/static/src/js/search.js:1326 +#: addons/web/static/src/js/search.js:1345 +#: addons/web/static/src/js/search.js:1366 +#: addons/web/static/src/js/search.js:1298 +#: addons/web/static/src/js/search.js:1312 +#: addons/web/static/src/js/search.js:1331 +#: addons/web/static/src/js/search.js:1350 +#: addons/web/static/src/js/search.js:1371 +msgid "is not equal to" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1294 +#: addons/web/static/src/js/search.js:1308 +#: addons/web/static/src/js/search.js:1327 +#: addons/web/static/src/js/search.js:1346 +#: addons/web/static/src/js/search.js:1367 +#: addons/web/static/src/js/search.js:1299 +#: addons/web/static/src/js/search.js:1313 +#: addons/web/static/src/js/search.js:1332 +#: addons/web/static/src/js/search.js:1351 +#: addons/web/static/src/js/search.js:1372 +msgid "greater than" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1295 +#: addons/web/static/src/js/search.js:1309 +#: addons/web/static/src/js/search.js:1328 +#: addons/web/static/src/js/search.js:1347 +#: addons/web/static/src/js/search.js:1368 +#: addons/web/static/src/js/search.js:1300 +#: addons/web/static/src/js/search.js:1314 +#: addons/web/static/src/js/search.js:1333 +#: addons/web/static/src/js/search.js:1352 +#: addons/web/static/src/js/search.js:1373 +msgid "less than" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1296 +#: addons/web/static/src/js/search.js:1310 +#: addons/web/static/src/js/search.js:1329 +#: addons/web/static/src/js/search.js:1348 +#: addons/web/static/src/js/search.js:1369 +#: addons/web/static/src/js/search.js:1301 +#: addons/web/static/src/js/search.js:1315 +#: addons/web/static/src/js/search.js:1334 +#: addons/web/static/src/js/search.js:1353 +#: addons/web/static/src/js/search.js:1374 +msgid "greater or equal than" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1297 +#: addons/web/static/src/js/search.js:1311 +#: addons/web/static/src/js/search.js:1330 +#: addons/web/static/src/js/search.js:1349 +#: addons/web/static/src/js/search.js:1370 +#: addons/web/static/src/js/search.js:1302 +#: addons/web/static/src/js/search.js:1316 +#: addons/web/static/src/js/search.js:1335 +#: addons/web/static/src/js/search.js:1354 +#: addons/web/static/src/js/search.js:1375 +msgid "less or equal than" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1360 +#: addons/web/static/src/js/search.js:1383 +#: addons/web/static/src/js/search.js:1365 +#: addons/web/static/src/js/search.js:1388 +msgid "is" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1384 +#: addons/web/static/src/js/search.js:1389 +msgid "is not" +msgstr "એ નથી" + +#. openerp-web +#: addons/web/static/src/js/search.js:1396 +#: addons/web/static/src/js/search.js:1401 +msgid "is true" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/search.js:1397 +#: addons/web/static/src/js/search.js:1402 +msgid "is false" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:20 +#, python-format +msgid "Manage Views (%s)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:46 +#: addons/web/static/src/js/view_list.js:17 +#: addons/web/static/src/xml/base.xml:100 +#: addons/web/static/src/xml/base.xml:327 +#: addons/web/static/src/xml/base.xml:756 +msgid "Create" +msgstr "બનાવો" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:47 +#: addons/web/static/src/xml/base.xml:483 +#: addons/web/static/src/xml/base.xml:755 +msgid "Edit" +msgstr "ફેરફાર કરો" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:48 +#: addons/web/static/src/xml/base.xml:1647 +msgid "Remove" +msgstr "દૂર કરો" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:71 +#, python-format +msgid "Create a view (%s)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:168 +msgid "Do you really want to remove this view?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:364 +#, python-format +msgid "View Editor %d - %s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:367 +msgid "Inherited View" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:371 +msgid "Do you really wants to create an inherited view here?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:381 +msgid "Preview" +msgstr "પૂર્વદર્શન" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:501 +msgid "Do you really want to remove this node?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:815 +#: addons/web/static/src/js/view_editor.js:939 +msgid "Properties" +msgstr "ગુણધર્મો" + +#. openerp-web +#: addons/web/static/src/js/view_editor.js:818 +#: addons/web/static/src/js/view_editor.js:942 +msgid "Update" +msgstr "સુધારો" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:16 +msgid "Form" +msgstr "ફોર્મ" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:121 +#: addons/web/static/src/js/views.js:803 +msgid "Customize" +msgstr "વૈવિધ્યપૂર્ણ" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:123 +#: addons/web/static/src/js/view_form.js:686 +#: addons/web/static/src/js/view_form.js:692 +msgid "Set Default" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:469 +#: addons/web/static/src/js/view_form.js:475 +msgid "" +"Warning, the record has been modified, your changes will be discarded." +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:693 +#: addons/web/static/src/js/view_form.js:699 +msgid "Save default" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:754 +#: addons/web/static/src/js/view_form.js:760 +msgid "Attachments" +msgstr "જોડાણો" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:792 +#: addons/web/static/src/js/view_form.js:798 +#, python-format +msgid "Do you really want to delete the attachment %s?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:822 +#: addons/web/static/src/js/view_form.js:828 +#, python-format +msgid "Unknown operator %s in domain %s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:830 +#: addons/web/static/src/js/view_form.js:836 +#, python-format +msgid "Unknown field %s in domain %s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:868 +#: addons/web/static/src/js/view_form.js:874 +#, python-format +msgid "Unsupported operator %s in domain %s" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:1225 +#: addons/web/static/src/js/view_form.js:1231 +msgid "Confirm" +msgstr "ખાતરી" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:1921 +#: addons/web/static/src/js/view_form.js:2578 +#: addons/web/static/src/js/view_form.js:2741 +#: addons/web/static/src/js/view_form.js:1933 +#: addons/web/static/src/js/view_form.js:2590 +#: addons/web/static/src/js/view_form.js:2760 +msgid "Open: " +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2049 +#: addons/web/static/src/js/view_form.js:2061 +msgid "   Search More..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2062 +#: addons/web/static/src/js/view_form.js:2074 +#, python-format +msgid "   Create \"%s\"" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2068 +#: addons/web/static/src/js/view_form.js:2080 +msgid "   Create and Edit..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2101 +#: addons/web/static/src/js/views.js:675 +#: addons/web/static/src/js/view_form.js:2113 +msgid "Search: " +msgstr "શોધો: " + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2101 +#: addons/web/static/src/js/view_form.js:2550 +#: addons/web/static/src/js/view_form.js:2113 +#: addons/web/static/src/js/view_form.js:2562 +msgid "Create: " +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2661 +#: addons/web/static/src/xml/base.xml:750 +#: addons/web/static/src/xml/base.xml:772 +#: addons/web/static/src/xml/base.xml:1646 +#: addons/web/static/src/js/view_form.js:2680 +msgid "Add" +msgstr "ઉમેરવું" + +#. openerp-web +#: addons/web/static/src/js/view_form.js:2721 +#: addons/web/static/src/js/view_form.js:2740 +msgid "Add: " +msgstr "ઉમેરવું: " + +#. openerp-web +#: addons/web/static/src/js/view_list.js:8 +msgid "List" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:269 +msgid "Unlimited" +msgstr "અમર્યાદિત" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:305 +#: addons/web/static/src/js/view_list.js:309 +#, python-format +msgid "[%(first_record)d to %(last_record)d] of %(records_count)d" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:524 +#: addons/web/static/src/js/view_list.js:528 +msgid "Do you really want to remove these records?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:1230 +#: addons/web/static/src/js/view_list.js:1232 +msgid "Undefined" +msgstr "અવ્યાખ્યાયિત" + +#. openerp-web +#: addons/web/static/src/js/view_list.js:1327 +#: addons/web/static/src/js/view_list.js:1331 +#, python-format +msgid "%(page)d/%(page_count)d" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_page.js:8 +msgid "Page" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_page.js:52 +msgid "Do you really want to delete this record?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/view_tree.js:11 +msgid "Tree" +msgstr "ટ્રી" + +#. openerp-web +#: addons/web/static/src/js/views.js:565 +#: addons/web/static/src/xml/base.xml:480 +msgid "Fields View Get" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:573 +#, python-format +msgid "View Log (%s)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:600 +#, python-format +msgid "Model %s fields" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:610 +#: addons/web/static/src/xml/base.xml:482 +msgid "Manage Views" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:611 +msgid "Could not find current view declaration" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:805 +msgid "Translate" +msgstr "ભાષાંતર" + +#. openerp-web +#: addons/web/static/src/js/views.js:807 +msgid "Technical translation" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:811 +msgid "Other Options" +msgstr "અન્ય વિકલ્પો" + +#. openerp-web +#: addons/web/static/src/js/views.js:814 +#: addons/web/static/src/xml/base.xml:1736 +msgid "Import" +msgstr "આયાત" + +#. openerp-web +#: addons/web/static/src/js/views.js:817 +#: addons/web/static/src/xml/base.xml:1606 +msgid "Export" +msgstr "નિકાસ" + +#. openerp-web +#: addons/web/static/src/js/views.js:825 +msgid "Reports" +msgstr "અહેવાલો" + +#. openerp-web +#: addons/web/static/src/js/views.js:825 +msgid "Actions" +msgstr "ક્રિયાઓ" + +#. openerp-web +#: addons/web/static/src/js/views.js:825 +msgid "Links" +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:919 +msgid "You must choose at least one record." +msgstr "" + +#. openerp-web +#: addons/web/static/src/js/views.js:920 +msgid "Warning" +msgstr "ચેતવણી" + +#. openerp-web +#: addons/web/static/src/js/views.js:957 +msgid "Translations" +msgstr "ભાષાંતરો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:44 +#: addons/web/static/src/xml/base.xml:315 +msgid "Powered by" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:44 +#: addons/web/static/src/xml/base.xml:315 +#: addons/web/static/src/xml/base.xml:1813 +msgid "OpenERP" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:52 +msgid "Loading..." +msgstr "લાવી રહ્યા છીએ..." + +#. openerp-web +#: addons/web/static/src/xml/base.xml:61 +msgid "CREATE DATABASE" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:68 +#: addons/web/static/src/xml/base.xml:211 +msgid "Master password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:72 +#: addons/web/static/src/xml/base.xml:191 +msgid "New database name:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:77 +msgid "Load Demonstration data:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:81 +msgid "Default language:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:91 +msgid "Admin password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:95 +msgid "Confirm password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:109 +msgid "DROP DATABASE" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:116 +#: addons/web/static/src/xml/base.xml:150 +#: addons/web/static/src/xml/base.xml:301 +msgid "Database:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:128 +#: addons/web/static/src/xml/base.xml:162 +#: addons/web/static/src/xml/base.xml:187 +msgid "Master Password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:132 +#: addons/web/static/src/xml/base.xml:328 +msgid "Drop" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:143 +msgid "BACKUP DATABASE" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:166 +#: addons/web/static/src/xml/base.xml:329 +msgid "Backup" +msgstr "બેકઅપ" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:175 +msgid "RESTORE DATABASE" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:182 +msgid "File:" +msgstr "ફાઇલ:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:195 +#: addons/web/static/src/xml/base.xml:330 +msgid "Restore" +msgstr "પુનઃસ્થાપિત કરો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:204 +msgid "CHANGE MASTER PASSWORD" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:216 +msgid "New master password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:221 +msgid "Confirm new master password:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:251 +msgid "" +"Your version of OpenERP is unsupported. Support & maintenance services are " +"available here:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:251 +msgid "OpenERP Entreprise" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:256 +msgid "OpenERP Enterprise Contract." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:257 +msgid "Your report will be sent to the OpenERP Enterprise team." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:259 +msgid "Summary:" +msgstr "સાર:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:263 +msgid "Description:" +msgstr "વર્ણન:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:267 +msgid "What you did:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:297 +msgid "Invalid username or password" +msgstr "અયોગ્ય વપરાશકર્તા નામ અથવા પાસવર્ડ" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:306 +msgid "Username" +msgstr "વપરાશકર્તા નામ" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:308 +#: addons/web/static/src/xml/base.xml:331 +msgid "Password" +msgstr "પાસવર્ડ" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:310 +msgid "Log in" +msgstr "લોગ ઇન" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:314 +msgid "Manage Databases" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:332 +msgid "Back to Login" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:353 +msgid "Home" +msgstr "હોમ" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:363 +msgid "LOGOUT" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:388 +msgid "Fold menu" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:389 +msgid "Unfold menu" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:454 +msgid "Hide this tip" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:455 +msgid "Disable all tips" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:463 +msgid "Add / Remove Shortcut..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:471 +msgid "More…" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:477 +msgid "Debug View#" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:478 +msgid "View Log (perm_read)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:479 +msgid "View Fields" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:483 +msgid "View" +msgstr "દેખાવ" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:484 +msgid "Edit SearchView" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:485 +msgid "Edit Action" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:486 +msgid "Edit Workflow" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:491 +msgid "ID:" +msgstr "ID:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:494 +msgid "XML ID:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:497 +msgid "Creation User:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:500 +msgid "Creation Date:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:503 +msgid "Latest Modification by:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:506 +msgid "Latest Modification Date:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:542 +msgid "Field" +msgstr "ક્ષેત્ર" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:632 +#: addons/web/static/src/xml/base.xml:758 +#: addons/web/static/src/xml/base.xml:1708 +msgid "Delete" +msgstr "રદ્દ કરો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:757 +msgid "Duplicate" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:775 +msgid "Add attachment" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:801 +msgid "Default:" +msgstr "મૂળભૂત:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:818 +msgid "Condition:" +msgstr "શરત:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:837 +msgid "Only you" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:844 +msgid "All users" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:851 +msgid "Unhandled widget" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:900 +msgid "Notebook Page \"" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:905 +#: addons/web/static/src/xml/base.xml:964 +msgid "Modifiers:" +msgstr "સુધારકો:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:931 +msgid "(nolabel)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:936 +msgid "Field:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:940 +msgid "Object:" +msgstr "વસ્તુ:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:944 +msgid "Type:" +msgstr "પ્રકાર:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:948 +msgid "Widget:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:952 +msgid "Size:" +msgstr "કદ:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:956 +msgid "Context:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:960 +msgid "Domain:" +msgstr "ડોમેઇન:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:968 +msgid "Change default:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:972 +msgid "On change:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:976 +msgid "Relation:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:980 +msgid "Selection:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1020 +msgid "Send an e-mail with your default e-mail client" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1034 +msgid "Open this resource" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1056 +msgid "Select date" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1090 +msgid "Open..." +msgstr "ખોલો..." + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1091 +msgid "Create..." +msgstr "બનાવો..." + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1092 +msgid "Search..." +msgstr "શોધ..." + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1095 +msgid "..." +msgstr "..." + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1155 +#: addons/web/static/src/xml/base.xml:1198 +msgid "Set Image" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1163 +#: addons/web/static/src/xml/base.xml:1213 +#: addons/web/static/src/xml/base.xml:1215 +#: addons/web/static/src/xml/base.xml:1272 +msgid "Clear" +msgstr "સાફ" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1172 +#: addons/web/static/src/xml/base.xml:1223 +msgid "Uploading ..." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1200 +#: addons/web/static/src/xml/base.xml:1495 +msgid "Select" +msgstr "પસંદ કરો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1207 +#: addons/web/static/src/xml/base.xml:1209 +msgid "Save As" +msgstr "આ રીતે સંગ્રહિત કરો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1238 +msgid "Button" +msgstr "બટન" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1241 +msgid "(no string)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1248 +msgid "Special:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1253 +msgid "Button Type:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1257 +msgid "Method:" +msgstr "પદ્દતિ:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1261 +msgid "Action ID:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1271 +msgid "Search" +msgstr "શોધો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1279 +msgid "Filters" +msgstr "ફિલ્ટરો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1280 +msgid "-- Filters --" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1289 +msgid "-- Actions --" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1290 +msgid "Add Advanced Filter" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1291 +msgid "Save Filter" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1293 +msgid "Manage Filters" +msgstr "ફિલ્ટરો ને સંચાલિત કરો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1298 +msgid "Filter Name:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1300 +msgid "(Any existing filter with the same name will be replaced)" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1305 +msgid "Select Dashboard to add this filter to:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1309 +msgid "Title of new Dashboard item:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1416 +msgid "Advanced Filters" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1426 +msgid "Any of the following conditions must match" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1427 +msgid "All the following conditions must match" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1428 +msgid "None of the following conditions must match" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1435 +msgid "Add condition" +msgstr "શરત ઉમેરો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1436 +msgid "and" +msgstr "અને" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1503 +msgid "Save & New" +msgstr "સંગ્રહો અને નવું" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1504 +msgid "Save & Close" +msgstr "સંગ્રહો અને બંધ કરો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1611 +msgid "" +"This wizard will export all data that matches the current search criteria to " +"a CSV file.\n" +" You can export all data or only the fields that can be " +"reimported after modification." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1618 +msgid "Export Type:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1620 +msgid "Import Compatible Export" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1621 +msgid "Export all Data" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1624 +msgid "Export Formats" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1630 +msgid "Available fields" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1632 +msgid "Fields to export" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1634 +msgid "Save fields list" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1648 +msgid "Remove All" +msgstr "બધું દૂર કરો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1660 +msgid "Name" +msgstr "નામ" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1693 +msgid "Save as:" +msgstr "આ રૂપમાં સાચવો:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1700 +msgid "Saved exports:" +msgstr "સચવાયેલા નિકાસ:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1714 +msgid "Old Password:" +msgstr "જૂનું પાસવર્ડ:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1719 +msgid "New Password:" +msgstr "નવો પાસવર્ડ:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1724 +msgid "Confirm Password:" +msgstr "પાસવર્ડની પુષ્ટિ કરો:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1742 +msgid "1. Import a .CSV file" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1743 +msgid "" +"Select a .CSV file to import. If you need a sample of file to import,\n" +" you should use the export tool with the \"Import Compatible\" option." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1747 +msgid "CSV File:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1750 +msgid "2. Check your file format" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1753 +msgid "Import Options" +msgstr "આયાત વિકલ્પો" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1757 +msgid "Does your file have titles?" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1763 +msgid "Separator:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1765 +msgid "Delimiter:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1769 +msgid "Encoding:" +msgstr "એનકોડીંગ:" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1772 +msgid "UTF-8" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1773 +msgid "Latin 1" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1776 +msgid "Lines to skip" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1776 +msgid "" +"For use if CSV files have titles on multiple lines, skips more than a single " +"line during import" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1803 +msgid "The import failed due to:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1805 +msgid "Here is a preview of the file we could not import:" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1812 +msgid "Activate the developper mode" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1814 +msgid "Version" +msgstr "આવૃત્તિ" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1815 +msgid "Copyright © 2004-TODAY OpenERP SA. All Rights Reserved." +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1816 +msgid "OpenERP is a trademark of the" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1817 +msgid "OpenERP SA Company" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1819 +msgid "Licenced under the terms of" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1820 +msgid "GNU Affero General Public License" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1822 +msgid "For more information visit" +msgstr "" + +#. openerp-web +#: addons/web/static/src/xml/base.xml:1823 +msgid "OpenERP.com" +msgstr "" diff --git a/addons/web/i18n/nl.po b/addons/web/i18n/nl.po index 78cd13ffd97..d2f97026967 100644 --- a/addons/web/i18n/nl.po +++ b/addons/web/i18n/nl.po @@ -8,14 +8,14 @@ msgstr "" "Project-Id-Version: openerp-web\n" "Report-Msgid-Bugs-To: FULL NAME \n" "POT-Creation-Date: 2012-02-14 15:27+0100\n" -"PO-Revision-Date: 2012-04-02 13:15+0000\n" +"PO-Revision-Date: 2012-04-16 12:21+0000\n" "Last-Translator: Erwin \n" "Language-Team: Dutch \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2012-04-03 05:16+0000\n" -"X-Generator: Launchpad (build 15052)\n" +"X-Launchpad-Export-Date: 2012-04-17 05:23+0000\n" +"X-Generator: Launchpad (build 15099)\n" #. openerp-web #: addons/web/static/src/js/chrome.js:172 @@ -53,7 +53,7 @@ msgstr "Ongeldige database naam" #. openerp-web #: addons/web/static/src/js/chrome.js:483 msgid "Backed" -msgstr "" +msgstr "Back-up gereed" #. openerp-web #: addons/web/static/src/js/chrome.js:484 diff --git a/addons/web/static/lib/qunit/qunit.css b/addons/web/static/lib/qunit/qunit.css old mode 100755 new mode 100644 index bcecc4c0daf..58101ea34ce --- a/addons/web/static/lib/qunit/qunit.css +++ b/addons/web/static/lib/qunit/qunit.css @@ -1,9 +1,9 @@ /** - * QUnit v1.2.0 - A JavaScript Unit Testing Framework + * QUnit v1.4.0pre - A JavaScript Unit Testing Framework * * http://docs.jquery.com/QUnit * - * Copyright (c) 2011 John Resig, Jörn Zaefferer + * Copyright (c) 2012 John Resig, Jörn Zaefferer * Dual licensed under the MIT (MIT-LICENSE.txt) * or GPL (GPL-LICENSE.txt) licenses. */ @@ -54,6 +54,10 @@ color: #fff; } +#qunit-header label { + display: inline-block; +} + #qunit-banner { height: 5px; } @@ -223,4 +227,6 @@ position: absolute; top: -10000px; left: -10000px; + width: 1000px; + height: 1000px; } diff --git a/addons/web/static/lib/qunit/qunit.js b/addons/web/static/lib/qunit/qunit.js old mode 100755 new mode 100644 index 6d2a8a7b8ab..b71381313c7 --- a/addons/web/static/lib/qunit/qunit.js +++ b/addons/web/static/lib/qunit/qunit.js @@ -1,9 +1,9 @@ /** - * QUnit v1.2.0 - A JavaScript Unit Testing Framework + * QUnit v1.4.0pre - A JavaScript Unit Testing Framework * * http://docs.jquery.com/QUnit * - * Copyright (c) 2011 John Resig, Jörn Zaefferer + * Copyright (c) 2012 John Resig, Jörn Zaefferer * Dual licensed under the MIT (MIT-LICENSE.txt) * or GPL (GPL-LICENSE.txt) licenses. */ @@ -13,8 +13,11 @@ var defined = { setTimeout: typeof window.setTimeout !== "undefined", sessionStorage: (function() { + var x = "qunit-test-string"; try { - return !!sessionStorage.getItem; + sessionStorage.setItem(x, x); + sessionStorage.removeItem(x); + return true; } catch(e) { return false; } @@ -25,11 +28,10 @@ var testId = 0, toString = Object.prototype.toString, hasOwn = Object.prototype.hasOwnProperty; -var Test = function(name, testName, expected, testEnvironmentArg, async, callback) { +var Test = function(name, testName, expected, async, callback) { this.name = name; this.testName = testName; this.expected = expected; - this.testEnvironmentArg = testEnvironmentArg; this.async = async; this.callback = callback; this.assertions = []; @@ -62,6 +64,10 @@ Test.prototype = { runLoggingCallbacks( 'moduleStart', QUnit, { name: this.module } ); + } else if (config.autorun) { + runLoggingCallbacks( 'moduleStart', QUnit, { + name: this.module + } ); } config.current = this; @@ -69,9 +75,6 @@ Test.prototype = { setup: function() {}, teardown: function() {} }, this.moduleTestEnvironment); - if (this.testEnvironmentArg) { - extend(this.testEnvironment, this.testEnvironmentArg); - } runLoggingCallbacks( 'testStart', QUnit, { name: this.testName, @@ -274,17 +277,12 @@ var QUnit = { }, test: function(testName, expected, callback, async) { - var name = '' + testName + '', testEnvironmentArg; + var name = '' + escapeInnerText(testName) + ''; if ( arguments.length === 2 ) { callback = expected; expected = null; } - // is 2nd argument a testEnvironment? - if ( expected && typeof expected === 'object') { - testEnvironmentArg = expected; - expected = null; - } if ( config.currentModule ) { name = '' + config.currentModule + ": " + name; @@ -294,7 +292,7 @@ var QUnit = { return; } - var test = new Test(name, testName, expected, testEnvironmentArg, async, callback); + var test = new Test(name, testName, expected, async, callback); test.module = config.currentModule; test.moduleTestEnvironment = config.currentModuleTestEnviroment; test.queue(); @@ -312,6 +310,9 @@ var QUnit = { * @example ok( "asdfasdf".length > 5, "There must be at least 5 chars" ); */ ok: function(a, msg) { + if (!config.current) { + throw new Error("ok() assertion outside test context, was " + sourceFromStacktrace(2)); + } a = !!a; var details = { result: a, @@ -447,9 +448,14 @@ var QUnit = { QUnit.constructor = F; })(); -// Backwards compatibility, deprecated -QUnit.equals = QUnit.equal; -QUnit.same = QUnit.deepEqual; +// deprecated; still export them to window to provide clear error messages +// next step: remove entirely +QUnit.equals = function() { + throw new Error("QUnit.equals has been deprecated since 2009 (e88049a0), use QUnit.equal instead"); +}; +QUnit.same = function() { + throw new Error("QUnit.same has been deprecated since 2009 (e88049a0), use QUnit.deepEqual instead"); +}; // Maintain internal state var config = { @@ -513,8 +519,7 @@ if ( typeof exports === "undefined" || typeof require === "undefined" ) { extend(window, QUnit); window.QUnit = QUnit; } else { - extend(exports, QUnit); - exports.QUnit = QUnit; + module.exports = QUnit; } // define these after exposing globals to keep them in these QUnit namespace only @@ -536,6 +541,16 @@ extend(QUnit, { semaphore: 0 }); + var qunit = id( "qunit" ); + if ( qunit ) { + qunit.innerHTML = + '

' + escapeInnerText( document.title ) + '

' + + '

' + + '
' + + '

' + + '
    '; + } + var tests = id( "qunit-tests" ), banner = id( "qunit-banner" ), result = id( "qunit-testresult" ); @@ -564,15 +579,15 @@ extend(QUnit, { /** * Resets the test setup. Useful for tests that modify the DOM. * - * If jQuery is available, uses jQuery's html(), otherwise just innerHTML. + * If jQuery is available, uses jQuery's replaceWith(), otherwise use replaceChild */ reset: function() { - if ( window.jQuery ) { - jQuery( "#qunit-fixture" ).html( config.fixture ); - } else { - var main = id( 'qunit-fixture' ); - if ( main ) { - main.innerHTML = config.fixture; + var main = id( 'qunit-fixture' ); + if ( main ) { + if ( window.jQuery ) { + jQuery( main ).replaceWith( config.fixture.cloneNode(true) ); + } else { + main.parentNode.replaceChild(config.fixture.cloneNode(true), main); } } }, @@ -636,6 +651,9 @@ extend(QUnit, { }, push: function(result, actual, expected, message) { + if (!config.current) { + throw new Error("assertion outside test context, was " + sourceFromStacktrace()); + } var details = { result: result, message: message, @@ -645,21 +663,22 @@ extend(QUnit, { message = escapeInnerText(message) || (result ? "okay" : "failed"); message = '' + message + ""; - expected = escapeInnerText(QUnit.jsDump.parse(expected)); - actual = escapeInnerText(QUnit.jsDump.parse(actual)); - var output = message + ''; - if (actual != expected) { - output += ''; - output += ''; - } + var output = message; if (!result) { + expected = escapeInnerText(QUnit.jsDump.parse(expected)); + actual = escapeInnerText(QUnit.jsDump.parse(actual)); + output += '
    Expected:
    ' + expected + '
    Result:
    ' + actual + '
    Diff:
    ' + QUnit.diff(expected, actual) +'
    '; + if (actual != expected) { + output += ''; + output += ''; + } var source = sourceFromStacktrace(); if (source) { details.source = source; output += ''; } + output += "
    Expected:
    ' + expected + '
    Result:
    ' + actual + '
    Diff:
    ' + QUnit.diff(expected, actual) +'
    Source:
    ' + escapeInnerText(source) + '
    "; } - output += ""; runLoggingCallbacks( 'log', QUnit, details ); @@ -779,7 +798,7 @@ QUnit.load = function() { var main = id('qunit-fixture'); if ( main ) { - config.fixture = main.innerHTML; + config.fixture = main.cloneNode(true); } if (config.autostart) { @@ -847,6 +866,15 @@ function done() { ].join(" "); } + // clear own sessionStorage items if all tests passed + if ( config.reorder && defined.sessionStorage && config.stats.bad === 0 ) { + for (var key in sessionStorage) { + if (sessionStorage.hasOwnProperty(key) && key.indexOf("qunit-") === 0 ) { + sessionStorage.removeItem(key); + } + } + } + runLoggingCallbacks( 'done', QUnit, { failed: config.stats.bad, passed: passed, @@ -881,16 +909,21 @@ function validTest( name ) { // so far supports only Firefox, Chrome and Opera (buggy) // could be extended in the future to use something like https://github.com/csnover/TraceKit -function sourceFromStacktrace() { +function sourceFromStacktrace(offset) { + offset = offset || 3; try { throw new Error(); } catch ( e ) { if (e.stacktrace) { // Opera - return e.stacktrace.split("\n")[6]; + return e.stacktrace.split("\n")[offset + 3]; } else if (e.stack) { // Firefox, Chrome - return e.stack.split("\n")[4]; + var stack = e.stack.split("\n"); + if (/^error$/i.test(stack[0])) { + stack.shift(); + } + return stack[offset]; } else if (e.sourceURL) { // Safari, PhantomJS // TODO sourceURL points at the 'throw new Error' line above, useless @@ -989,6 +1022,7 @@ function fail(message, exception, callback) { if ( typeof console !== "undefined" && console.error && console.warn ) { console.error(message); console.error(exception); + console.error(exception.stack); console.warn(callback.toString()); } else if ( window.opera && opera.postError ) { @@ -1368,9 +1402,9 @@ QUnit.jsDump = (function() { var ret = [ ]; QUnit.jsDump.up(); for ( var key in map ) { - var val = map[key]; + var val = map[key]; ret.push( QUnit.jsDump.parse(key,'key') + ': ' + QUnit.jsDump.parse(val, undefined, stack)); - } + } QUnit.jsDump.down(); return join( '{', ret, '}' ); }, @@ -1594,4 +1628,5 @@ QUnit.diff = (function() { }; })(); -})(this); +// get at whatever the global object is, like window in browsers +})( (function() {return this}).call() ); diff --git a/addons/web/static/src/css/base.css b/addons/web/static/src/css/base.css index 5288ce13a17..2b90d47c002 100644 --- a/addons/web/static/src/css/base.css +++ b/addons/web/static/src/css/base.css @@ -21,16 +21,13 @@ color: #4c4c4c; font-size: 13px; background: white; -} -.openerp a { - text-decoration: none; -} - -.openerp { /* http://www.quirksmode.org/dom/inputfile.html * http://stackoverflow.com/questions/2855589/replace-input-type-file-by-an-image */ } +.openerp a { + text-decoration: none; +} .openerp table { padding: 0; font-size: 13px; @@ -904,6 +901,9 @@ color: white; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4); } +.openerp .oe_view_manager_header2 .oe_view_manager_buttons { + white-space: nowrap; +} .openerp .oe_view_manager_body h4 { margin: 8px 0; } @@ -1042,6 +1042,9 @@ -webkit-box-shadow: none; -box-shadow: none; } +.openerp .oe_sidebar { + white-space: nowrap; +} .openerp .oe_searchview { position: relative; float: right; @@ -1614,6 +1617,15 @@ height: auto; line-height: 16px; } +.openerp .oe_listview_nocontent > img { + float: left; + margin-right: 1.5em; +} +.openerp .oe_listview_nocontent > div { + overflow: hidden; + padding: 6px; + font-size: 125%; +} .openerp .oe-listview-content { width: 100%; } @@ -1771,23 +1783,13 @@ font-weight: bold; } .openerp .oe_layout_debugging .oe_form_group { - border: 2px dashed red; + outline: 2px dashed green; } .openerp .oe_layout_debugging .oe_form_group_cell { - border: 1px solid blue; - padding-bottom: 1em; + outline: 1px solid blue; } -.openerp .oe_layout_debugging .oe_layout_debug_cell { - color: white; - background: #669966; - font-size: 80%; - text-align: center; -} -.openerp .oe_layout_debugging .oe_layout_debug_cell { - display: block; -} -.openerp .oe_layout_debug_cell { - display: none; +.openerp .oe_layout_debugging .oe_form_group:hover, .openerp .oe_layout_debugging .oe_form_group_cell:hover { + outline-color: red; } .openerp .oe_debug_view { float: left; diff --git a/addons/web/static/src/css/base.sass b/addons/web/static/src/css/base.sass index 6afddbee2fa..fc645a92e44 100644 --- a/addons/web/static/src/css/base.sass +++ b/addons/web/static/src/css/base.sass @@ -78,12 +78,10 @@ $colour4: #8a89ba color: #4c4c4c font-size: 13px background: white + // }}} + // Tag reset {{{ a text-decoration: none - // }}} - -.openerp - // Tag reset {{{ table padding: 0 font-size: 13px @@ -705,6 +703,8 @@ $colour4: #8a89ba a color: #fff text-shadow: 0 1px 2px rgba(0,0,0,0.4) + .oe_view_manager_buttons + white-space: nowrap // }}} // ViewManager.body {{{ .oe_view_manager_body @@ -814,7 +814,8 @@ $colour4: #8a89ba text-decoration: none @include vertical-gradient(#f0f0fa, #eeeef6) @include box-shadow(none) - + .oe_sidebar + white-space: nowrap // }}} // SearchView xmo {{{ .oe_searchview @@ -1363,6 +1364,15 @@ $colour4: #8a89ba // }}} // ListView {{{ + .oe_listview_nocontent + > img + float: left + margin-right: 1.5em + > div + // don't encroach on my arrow + overflow: hidden + padding: 6px + font-size: 125% .oe-listview-content width: 100% thead, tfoot @@ -1477,23 +1487,14 @@ $colour4: #8a89ba .oe_tooltip_technical_title font-weight: bold // }}} - // Debugging stuff {{{ .oe_layout_debugging .oe_form_group - border: 2px dashed red + outline: 2px dashed green .oe_form_group_cell - border: 1px solid blue - padding-bottom: 1em - .oe_layout_debug_cell - color: white - background: #696 - font-size: 80% - text-align: center - .oe_layout_debug_cell - display: block - .oe_layout_debug_cell - display: none + outline: 1px solid blue + .oe_form_group:hover, .oe_form_group_cell:hover + outline-color: red .oe_debug_view float: left @@ -1526,4 +1527,3 @@ $colour4: #8a89ba // au BufWritePost,FileWritePost *.sass :!sass --style expanded --line-numbers > "%:p:r.css" // vim:tabstop=4:shiftwidth=4:softtabstop=4:fdm=marker: - diff --git a/addons/web/static/src/img/list_empty_arrow.png b/addons/web/static/src/img/list_empty_arrow.png new file mode 100644 index 00000000000..b0b1372adfd Binary files /dev/null and b/addons/web/static/src/img/list_empty_arrow.png differ diff --git a/addons/web/static/src/img/topbar-avatar.png b/addons/web/static/src/img/user_menu_avatar.png similarity index 100% rename from addons/web/static/src/img/topbar-avatar.png rename to addons/web/static/src/img/user_menu_avatar.png diff --git a/addons/web/static/src/js/chrome.js b/addons/web/static/src/js/chrome.js index 892c86f2a92..f43da0431ff 100644 --- a/addons/web/static/src/js/chrome.js +++ b/addons/web/static/src/js/chrome.js @@ -1,16 +1,16 @@ /*--------------------------------------------------------- * OpenERP Web chrome *---------------------------------------------------------*/ -openerp.web.chrome = function(openerp) { -var QWeb = openerp.web.qweb, - _t = openerp.web._t; +openerp.web.chrome = function(instance) { +var QWeb = instance.web.qweb, + _t = instance.web._t; -openerp.web.Notification = openerp.web.Widget.extend({ +instance.web.Notification = instance.web.Widget.extend({ template: 'Notification', init: function() { this._super.apply(this, arguments); - // move to openerp.web.notification - openerp.notification = this; + // move to instance.web.notification + instance.notification = this; }, start: function() { this._super.apply(this, arguments); @@ -43,13 +43,13 @@ openerp.web.Notification = openerp.web.Widget.extend({ } }); -openerp.web.dialog = function(element) { +instance.web.dialog = function(element) { var result = element.dialog.apply(element, _.rest(_.toArray(arguments))); result.dialog("widget").addClass("openerp"); return result; } -openerp.web.Dialog = openerp.web.Widget.extend({ +instance.web.Dialog = instance.web.Widget.extend({ dialog_title: "", init: function (parent, options, content) { var self = this; @@ -83,7 +83,7 @@ openerp.web.Dialog = openerp.web.Widget.extend({ if (this.dialog_options.autoOpen) { this.open(); } else { - openerp.web.dialog(this.$element, this.get_options()); + instance.web.dialog(this.$element, this.get_options()); } }, get_options: function(options) { @@ -122,7 +122,7 @@ openerp.web.Dialog = openerp.web.Widget.extend({ this.$element.html(this.renderElement()); } var o = this.get_options(options); - openerp.web.dialog(this.$element, o).dialog('open'); + instance.web.dialog(this.$element, o).dialog('open'); if (o.height === 'auto' && o.max_height) { this.$element.css({ 'max-height': o.max_height, 'overflow-y': 'auto' }); } @@ -146,7 +146,7 @@ openerp.web.Dialog = openerp.web.Widget.extend({ } }); -openerp.web.CrashManager = openerp.web.CallbackEnabled.extend({ +instance.web.CrashManager = instance.web.CallbackEnabled.extend({ on_rpc_error: function(error) { if (error.data.fault_code) { var split = ("" + error.data.fault_code).split('\n')[0].split(' -- '); @@ -162,7 +162,7 @@ openerp.web.CrashManager = openerp.web.CallbackEnabled.extend({ } }, on_managed_error: function(error) { - openerp.web.dialog($('
    ' + QWeb.render('CrashManager.warning', {error: error}) + '
    '), { + instance.web.dialog($('
    ' + QWeb.render('CrashManager.warning', {error: error}) + '
    '), { title: "OpenERP " + _.str.capitalize(error.type), buttons: [ {text: _t("Ok"), click: function() { $(this).dialog("close"); }} @@ -172,14 +172,14 @@ openerp.web.CrashManager = openerp.web.CallbackEnabled.extend({ on_traceback: function(error) { var self = this; var buttons = {}; - if (openerp.connection.openerp_entreprise) { + if (instance.connection.openerp_entreprise) { buttons[_t("Send OpenERP Enterprise Report")] = function() { var $this = $(this); var issuename = $('#issuename').val(); var explanation = $('#explanation').val(); var remark = $('#remark').val(); // Call the send method from server to send mail with details - new openerp.web.DataSet(self, 'publisher_warranty.contract').call_and_eval('send', [error.data,explanation,remark,issuename]).then(function(result){ + new instance.web.DataSet(self, 'publisher_warranty.contract').call_and_eval('send', [error.data,explanation,remark,issuename]).then(function(result){ if (result === false) { alert('There was a communication error.') } else { @@ -195,7 +195,7 @@ openerp.web.CrashManager = openerp.web.CallbackEnabled.extend({ $(this).dialog("close"); }; } - var dialog = new openerp.web.Dialog(this, { + var dialog = new instance.web.Dialog(this, { title: "OpenERP " + _.str.capitalize(error.type), width: '80%', height: '50%', @@ -203,11 +203,11 @@ openerp.web.CrashManager = openerp.web.CallbackEnabled.extend({ min_height: '600px', buttons: buttons }).open(); - dialog.$element.html(QWeb.render('CrashManager.error', {session: openerp.connection, error: error})); + dialog.$element.html(QWeb.render('CrashManager.error', {session: instance.connection, error: error})); } }); -openerp.web.Loading = openerp.web.Widget.extend({ +instance.web.Loading = instance.web.Widget.extend({ template: 'Loading', init: function(parent) { this._super(parent); @@ -258,7 +258,7 @@ openerp.web.Loading = openerp.web.Widget.extend({ } }); -openerp.web.DatabaseManager = openerp.web.Widget.extend({ +instance.web.DatabaseManager = instance.web.Widget.extend({ init: function(parent) { this._super(parent); this.unblockUIFunction = $.unblockUI; @@ -344,7 +344,7 @@ openerp.web.DatabaseManager = openerp.web.Widget.extend({ * @param {String} error.error message of the error dialog */ display_error: function (error) { - return openerp.web.dialog($('
    '), { + return instance.web.dialog($('
    '), { modal: true, title: error.title, buttons: [ @@ -388,7 +388,7 @@ openerp.web.DatabaseManager = openerp.web.Widget.extend({ success: function () { self.do_notify(_t("Backed"), _t("Database backed up successfully")); }, - error: openerp.webclient.crashmanager.on_rpc_error, + error: instance.webclient.crashmanager.on_rpc_error, complete: function() { self.unblockUI(); } @@ -439,7 +439,7 @@ openerp.web.DatabaseManager = openerp.web.Widget.extend({ } }); -openerp.web.Login = openerp.web.Widget.extend({ +instance.web.Login = instance.web.Widget.extend({ template: "Login", remember_credentials: true, init: function(parent) { @@ -464,7 +464,7 @@ openerp.web.Login = openerp.web.Widget.extend({ self.$element.find('.oe_login_manage_db').click(function() { self.$element.find('.oe_login_bottom').hide(); self.$element.find('.oe_login_pane').hide(); - self.databasemanager = new openerp.web.DatabaseManager(self); + self.databasemanager = new instance.web.DatabaseManager(self); self.databasemanager.appendTo(self.$element); self.databasemanager.do_exit.add_last(function() { self.databasemanager.destroy(); @@ -486,7 +486,7 @@ openerp.web.Login = openerp.web.Widget.extend({ }); }, set_db_list: function (list) { - this.$element.find("[name=db]").replaceWith(openerp.web.qweb.render('Login.dblist', { db_list: list, selected_db: this.selected_db})) + this.$element.find("[name=db]").replaceWith(instance.web.qweb.render('Login.dblist', { db_list: list, selected_db: this.selected_db})) }, on_submit: function(ev) { if(ev) { @@ -538,7 +538,7 @@ openerp.web.Login = openerp.web.Widget.extend({ } }); -openerp.web.Menu = openerp.web.Widget.extend({ +instance.web.Menu = instance.web.Widget.extend({ template: 'Menu', init: function() { this._super.apply(this, arguments); @@ -638,6 +638,7 @@ openerp.web.Menu = openerp.web.Widget.extend({ } }, on_menu_click: function(ev, id) { + // TODO If first level menu doesnt have action trigger first leaf this.do_hide_more(); id = id || 0; var $clicked_menu, manual = false; @@ -682,7 +683,7 @@ openerp.web.Menu = openerp.web.Widget.extend({ } }); -openerp.web.UserMenu = openerp.web.Widget.extend({ +instance.web.UserMenu = instance.web.Widget.extend({ template: "UserMenu", init: function(parent) { this._super(parent); @@ -707,7 +708,7 @@ openerp.web.UserMenu = openerp.web.Widget.extend({ }, change_password :function() { var self = this; - this.dialog = new openerp.web.Dialog(this, { + this.dialog = new instance.web.Dialog(this, { title: _t("Change Password"), width : 'auto' }).open(); @@ -721,14 +722,14 @@ openerp.web.UserMenu = openerp.web.Widget.extend({ self.display_error(result); return; } else { - openerp.webclient.on_logout(); + instance.webclient.on_logout(); } }); } }); }, display_error: function (error) { - return openerp.web.dialog($('
    '), { + return instance.web.dialog($('
    '), { modal: true, title: error.title, buttons: [ @@ -743,10 +744,10 @@ openerp.web.UserMenu = openerp.web.Widget.extend({ $avatar.attr('src', $avatar.data('default-src')); if (!self.session.uid) return; - var func = new openerp.web.Model("res.users").get_func("read"); + var func = new instance.web.Model("res.users").get_func("read"); return func(self.session.uid, ["name", "company_id"]).pipe(function(res) { // TODO: Show company if multicompany is in use - var topbar_name = _.str.sprintf("%s (%s)", res.name, openerp.connection.db, res.company_id[1]); + var topbar_name = _.str.sprintf("%s (%s)", res.name, instance.connection.db, res.company_id[1]); self.$element.find('.oe_topbar_name').text(topbar_name); var avatar_src = _.str.sprintf('%s/web/binary/image?session_id=%s&model=res.users&field=avatar&id=%s', self.session.prefix, self.session.session_id, self.session.uid); $avatar.attr('src', avatar_src); @@ -760,7 +761,7 @@ openerp.web.UserMenu = openerp.web.Widget.extend({ shortcut_load :function(){ var self = this, sc = self.session.shortcuts, - shortcuts_ds = new openerp.web.DataSet(this, 'ir.ui.view_sc'); + shortcuts_ds = new instance.web.DataSet(this, 'ir.ui.view_sc'); self.$element.find('.oe_dropdown_options a[data-menu=shortcut]').each(function() { $(this).parent().remove(); }); @@ -807,8 +808,8 @@ openerp.web.UserMenu = openerp.web.Widget.extend({ }, on_menu_settings: function() { var self = this; - var action_manager = new openerp.web.ActionManager(this); - var dataset = new openerp.web.DataSet (this,'res.users',this.context); + var action_manager = new instance.web.ActionManager(this); + var dataset = new instance.web.DataSet (this,'res.users',this.context); dataset.call ('action_get','',function (result){ self.rpc('/web/action/load', {action_id:result}, function(result){ action_manager.do_action(_.extend(result['result'], { @@ -825,7 +826,7 @@ openerp.web.UserMenu = openerp.web.Widget.extend({ })); }); }); - this.dialog = new openerp.web.Dialog(this,{ + this.dialog = new instance.web.Dialog(this,{ title: _t("Preferences"), width: '700px', buttons: [ @@ -855,7 +856,7 @@ openerp.web.UserMenu = openerp.web.Widget.extend({ window.location = $.param.querystring( window.location.href, 'debug'); }); - openerp.web.dialog($help, {autoOpen: true, + instance.web.dialog($help, {autoOpen: true, modal: true, width: 960, title: _t("About")}); }); }, @@ -871,11 +872,11 @@ openerp.web.UserMenu = openerp.web.Widget.extend({ } }); -openerp.web.WebClient = openerp.web.Widget.extend({ +instance.web.WebClient = instance.web.Widget.extend({ init: function(parent) { var self = this; this._super(parent); - openerp.webclient = this; + instance.webclient = this; this.querystring = '?' + jQuery.param.querystring(); this._current_state = null; }, @@ -900,7 +901,7 @@ openerp.web.WebClient = openerp.web.Widget.extend({ self.menu.do_reload(); if(self.action_manager) self.action_manager.destroy(); - self.action_manager = new openerp.web.ActionManager(self); + self.action_manager = new instance.web.ActionManager(self); self.action_manager.appendTo(self.$element.find('.oe_application')); self.bind_hashchange(); var version_label = _t("OpenERP - Unsupported/Community Version"); @@ -917,7 +918,7 @@ openerp.web.WebClient = openerp.web.Widget.extend({ var self = this; this.destroy_content(); this.show_common(); - self.login = new openerp.web.Login(self); + self.login = new instance.web.Login(self); self.login.appendTo(self.$element); }, show_application: function() { @@ -926,10 +927,10 @@ openerp.web.WebClient = openerp.web.Widget.extend({ this.show_common(); self.$table = $(QWeb.render("WebClient", {})); self.$element.append(self.$table); - self.menu = new openerp.web.Menu(self); + self.menu = new instance.web.Menu(self); self.menu.replace(this.$element.find('.oe_menu_placeholder')); self.menu.on_action.add(this.proxy('on_menu_action')); - self.user_menu = new openerp.web.UserMenu(self); + self.user_menu = new instance.web.UserMenu(self); self.user_menu.replace(this.$element.find('.oe_user_menu_placeholder')); self.user_menu.on_menu_logout.add(this.proxy('on_logout')); self.user_menu.on_action.add(this.proxy('on_menu_action')); @@ -937,8 +938,8 @@ openerp.web.WebClient = openerp.web.Widget.extend({ show_common: function() { var self = this; if (!this.crashmanager) { - this.crashmanager = new openerp.web.CrashManager(); - openerp.connection.on_rpc_error.add(this.crashmanager.on_rpc_error); + this.crashmanager = new instance.web.CrashManager(); + instance.connection.on_rpc_error.add(this.crashmanager.on_rpc_error); window.onerror = function (message, file, line) { self.crashmanager.on_traceback({ type: _t("Client Error"), @@ -947,9 +948,9 @@ openerp.web.WebClient = openerp.web.Widget.extend({ }); } } - this.notification = new openerp.web.Notification(this); + this.notification = new instance.web.Notification(this); this.notification.appendTo(this.$element); - this.loading = new openerp.web.Loading(this); + this.loading = new instance.web.Loading(this); this.loading.appendTo(this.$element); }, destroy_content: function() { @@ -961,7 +962,7 @@ openerp.web.WebClient = openerp.web.Widget.extend({ do_reload: function() { var self = this; return this.session.session_reload().pipe(function () { - openerp.connection.load_modules(true).pipe( + instance.connection.load_modules(true).pipe( self.menu.proxy('do_reload')); }); }, @@ -984,13 +985,18 @@ openerp.web.WebClient = openerp.web.Widget.extend({ }); }, bind_hashchange: function() { + var self = this; $(window).bind('hashchange', this.on_hashchange); var state = $.bbq.getState(true); if (! _.isEmpty(state)) { $(window).trigger('hashchange'); } else { - this.action_manager.do_action({type: 'ir.actions.client', tag: 'default_home'}); + self.menu.has_been_loaded.then(function() { + var first_menu_id = self.menu.$element.find("a:first").data("menu"); + if(first_menu_id) + self.menu.on_menu_click(null,first_menu_id); + }); } }, on_hashchange: function(event) { @@ -1025,14 +1031,14 @@ openerp.web.WebClient = openerp.web.Widget.extend({ } }); -openerp.web.EmbeddedClient = openerp.web.Widget.extend({ +instance.web.EmbeddedClient = instance.web.Widget.extend({ template: 'EmptyComponent', init: function(parent, action_id, options) { this._super(parent); // TODO take the xmlid of a action instead of its id this.action_id = action_id; this.options = options || {}; - this.am = new openerp.web.ActionManager(this); + this.am = new instance.web.ActionManager(this); }, start: function() { var self = this; @@ -1052,7 +1058,7 @@ openerp.web.EmbeddedClient = openerp.web.Widget.extend({ } }); -openerp.web.embed = function (origin, dbname, login, key, action, options) { +instance.web.embed = function (origin, dbname, login, key, action, options) { $('head').append($('', { 'rel': 'stylesheet', 'type': 'text/css', @@ -1063,9 +1069,9 @@ openerp.web.embed = function (origin, dbname, login, key, action, options) { var sc = document.getElementsByTagName('script'); currentScript = sc[sc.length-1]; } - openerp.connection.session_bind(origin).then(function () { - openerp.connection.session_authenticate(dbname, login, key, true).then(function () { - var client = new openerp.web.EmbeddedClient(null, action, options); + instance.connection.session_bind(origin).then(function () { + instance.connection.session_authenticate(dbname, login, key, true).then(function () { + var client = new instance.web.EmbeddedClient(null, action, options); client.insertAfter(currentScript); }); }); diff --git a/addons/web/static/src/js/corelib.js b/addons/web/static/src/js/corelib.js index 2da804c3d2c..32e35575933 100644 --- a/addons/web/static/src/js/corelib.js +++ b/addons/web/static/src/js/corelib.js @@ -23,7 +23,7 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -openerp.web.corelib = function(openerp) { +openerp.web.corelib = function(instance) { /** * Improved John Resig's inheritance, based on: @@ -39,7 +39,7 @@ openerp.web.corelib = function(openerp) { * * Example: * - * var Person = openerp.web.Class.extend({ + * var Person = instance.web.Class.extend({ * init: function(isDancing){ * this.dancing = isDancing; * }, @@ -75,14 +75,14 @@ openerp.web.corelib = function(openerp) { var initializing = false, fnTest = /xyz/.test(function(){xyz;}) ? /\b_super\b/ : /.*/; // The web Class implementation (does nothing) - openerp.web.Class = function(){}; + instance.web.Class = function(){}; /** * Subclass an existing class * * @param {Object} prop class-level properties (class attributes and instance methods) to set on the new class */ - openerp.web.Class.extend = function() { + instance.web.Class.extend = function() { var _super = this.prototype; // Support mixins arguments var args = _.toArray(arguments); @@ -180,7 +180,7 @@ openerp.web.corelib = function(openerp) { * When an object is destroyed, all its children are destroyed too releasing * any resource they could have reserved before. */ -openerp.web.ParentedMixin = { +instance.web.ParentedMixin = { __parentedMixin : true, init: function() { this.__parentedDestroyed = false; @@ -239,9 +239,7 @@ openerp.web.ParentedMixin = { }; /** - * TODO al: move into the the mixin - * - * Backbone's events + * Backbone's events. Do not ever use it directly, use EventDispatcherMixin instead. * * (c) 2010-2012 Jeremy Ashkenas, DocumentCloud Inc. * Backbone may be freely distributed under the MIT license. @@ -253,8 +251,7 @@ openerp.web.ParentedMixin = { * events is done in EventDispatcherMixin. * */ -openerp.web.Events = openerp.web.Class.extend({ - +var Events = instance.web.Class.extend({ on : function(events, callback, context) { var ev; events = events.split(/\s+/); @@ -323,12 +320,13 @@ openerp.web.Events = openerp.web.Class.extend({ return this; } }); +// end of Jeremy Ashkenas' code -openerp.web.EventDispatcherMixin = _.extend({}, openerp.web.ParentedMixin, { +instance.web.EventDispatcherMixin = _.extend({}, instance.web.ParentedMixin, { __eventDispatcherMixin: true, init: function() { - openerp.web.ParentedMixin.init.call(this); - this.__edispatcherEvents = new openerp.web.Events(); + instance.web.ParentedMixin.init.call(this); + this.__edispatcherEvents = new Events(); this.__edispatcherRegisteredEvents = []; }, on: function(events, dest, func) { @@ -369,13 +367,13 @@ openerp.web.EventDispatcherMixin = _.extend({}, openerp.web.ParentedMixin, { debugger; } this.__edispatcherEvents.off(); - openerp.web.ParentedMixin.destroy.call(this); + instance.web.ParentedMixin.destroy.call(this); } }); -openerp.web.GetterSetterMixin = _.extend({}, openerp.web.EventDispatcherMixin, { +instance.web.PropertiesMixin = _.extend({}, instance.web.EventDispatcherMixin, { init: function() { - openerp.web.EventDispatcherMixin.init.call(this); + instance.web.EventDispatcherMixin.init.call(this); this.__getterSetterInternalMap = {}; }, set: function(map) { @@ -400,9 +398,9 @@ openerp.web.GetterSetterMixin = _.extend({}, openerp.web.EventDispatcherMixin, { } }); -openerp.web.CallbackEnabledMixin = _.extend({}, openerp.web.GetterSetterMixin, { +instance.web.CallbackEnabledMixin = _.extend({}, instance.web.PropertiesMixin, { init: function() { - openerp.web.GetterSetterMixin.init.call(this); + instance.web.PropertiesMixin.init.call(this); var self = this; var callback_maker = function(obj, name, method) { var callback = function() { @@ -421,7 +419,7 @@ openerp.web.CallbackEnabledMixin = _.extend({}, openerp.web.GetterSetterMixin, { r = result; } // TODO special value to stop the chain - // openerp.web.callback_stop + // instance.web.callback_stop } return r; }; @@ -500,7 +498,7 @@ openerp.web.CallbackEnabledMixin = _.extend({}, openerp.web.GetterSetterMixin, { } }); -openerp.web.WidgetMixin = _.extend({},openerp.web.CallbackEnabledMixin, { +instance.web.WidgetMixin = _.extend({},instance.web.CallbackEnabledMixin, { /** * Tag name when creating a default $element. * @type string @@ -509,10 +507,10 @@ openerp.web.WidgetMixin = _.extend({},openerp.web.CallbackEnabledMixin, { /** * Constructs the widget and sets its parent if a parent is given. * - * @constructs openerp.web.Widget - * @extends openerp.web.CallbackEnabled + * @constructs instance.web.Widget + * @extends instance.web.CallbackEnabled * - * @param {openerp.web.Widget} parent Binds the current instance to the given Widget instance. + * @param {instance.web.Widget} parent Binds the current instance to the given Widget instance. * When that widget is destroyed by calling destroy(), the current instance will be * destroyed too. Can be null. * @param {String} element_id Deprecated. Sets the element_id. Only useful when you want @@ -521,7 +519,7 @@ openerp.web.WidgetMixin = _.extend({},openerp.web.CallbackEnabledMixin, { * for new components this argument should not be provided any more. */ init: function(parent) { - openerp.web.CallbackEnabledMixin.init.call(this); + instance.web.CallbackEnabledMixin.init.call(this); this.$element = $(document.createElement(this.tagName)); this.setParent(parent); }, @@ -535,7 +533,7 @@ openerp.web.WidgetMixin = _.extend({},openerp.web.CallbackEnabledMixin, { if(this.$element != null) { this.$element.remove(); } - openerp.web.GetterSetterMixin.destroy.call(this); + instance.web.PropertiesMixin.destroy.call(this); }, /** * Renders the current widget and appends it to the given jQuery object or Widget. @@ -616,9 +614,9 @@ openerp.web.WidgetMixin = _.extend({},openerp.web.CallbackEnabledMixin, { // Classes -openerp.web.CallbackEnabled = openerp.web.Class.extend(openerp.web.CallbackEnabledMixin, { +instance.web.CallbackEnabled = instance.web.Class.extend(instance.web.CallbackEnabledMixin, { init: function() { - openerp.web.CallbackEnabledMixin.init.call(this); + instance.web.CallbackEnabledMixin.init.call(this); } }); @@ -637,7 +635,7 @@ openerp.web.CallbackEnabled = openerp.web.Class.extend(openerp.web.CallbackEnabl * * Here is a sample child class: * - * MyWidget = openerp.base.Widget.extend({ + * MyWidget = instance.base.Widget.extend({ * // the name of the QWeb template to use for rendering * template: "MyQWebTemplate", * @@ -670,7 +668,7 @@ openerp.web.CallbackEnabled = openerp.web.Class.extend(openerp.web.CallbackEnabl * * That will kill the widget in a clean way and erase its content from the dom. */ -openerp.web.Widget = openerp.web.Class.extend(openerp.web.WidgetMixin, { +instance.web.Widget = instance.web.Class.extend(instance.web.WidgetMixin, { /** * The name of the QWeb template that will be used for rendering. Must be * redefined in subclasses or the default render() method can not be used. @@ -681,10 +679,10 @@ openerp.web.Widget = openerp.web.Class.extend(openerp.web.WidgetMixin, { /** * Constructs the widget and sets its parent if a parent is given. * - * @constructs openerp.web.Widget - * @extends openerp.web.CallbackEnabled + * @constructs instance.web.Widget + * @extends instance.web.CallbackEnabled * - * @param {openerp.web.Widget} parent Binds the current instance to the given Widget instance. + * @param {instance.web.Widget} parent Binds the current instance to the given Widget instance. * When that widget is destroyed by calling destroy(), the current instance will be * destroyed too. Can be null. * @param {String} element_id Deprecated. Sets the element_id. Only useful when you want @@ -693,8 +691,8 @@ openerp.web.Widget = openerp.web.Class.extend(openerp.web.WidgetMixin, { * for new components this argument should not be provided any more. */ init: function(parent) { - openerp.web.WidgetMixin.init.call(this,parent); - this.session = openerp.connection; + instance.web.WidgetMixin.init.call(this,parent); + this.session = instance.connection; }, /** * Renders the element. The default implementation renders the widget using QWeb, @@ -704,7 +702,7 @@ openerp.web.Widget = openerp.web.Class.extend(openerp.web.WidgetMixin, { renderElement: function() { var rendered = null; if (this.template) - rendered = openerp.web.qweb.render(this.template, {widget: this}); + rendered = instance.web.qweb.render(this.template, {widget: this}); if (_.str.trim(rendered)) { var elem = $(rendered); this.$element.replaceWith(elem); @@ -737,7 +735,7 @@ openerp.web.Widget = openerp.web.Class.extend(openerp.web.WidgetMixin, { rpc: function(url, data, success, error) { var def = $.Deferred().then(success, error); var self = this; - openerp.connection.rpc(url, data). then(function() { + instance.connection.rpc(url, data). then(function() { if (!self.isDestroyed()) def.resolve.apply(def, arguments); }, function() { @@ -748,7 +746,7 @@ openerp.web.Widget = openerp.web.Class.extend(openerp.web.WidgetMixin, { } }); -openerp.web.Registry = openerp.web.Class.extend({ +instance.web.Registry = instance.web.Class.extend({ /** * Stores a mapping of arbitrary key (strings) to object paths (as strings * as well). @@ -757,11 +755,11 @@ openerp.web.Registry = openerp.web.Class.extend({ * object, even if those objects have been overloaded/replaced after the * registry was created. * - * An object path is simply a dotted name from the openerp root to the - * object pointed to (e.g. ``"openerp.web.Connection"`` for an OpenERP + * An object path is simply a dotted name from the instance root to the + * object pointed to (e.g. ``"instance.web.Connection"`` for an OpenERP * connection object). * - * @constructs openerp.web.Registry + * @constructs instance.web.Registry * @param {Object} mapping a mapping of keys to object-paths */ init: function (mapping) { @@ -785,7 +783,7 @@ openerp.web.Registry = openerp.web.Class.extend({ return null; } - var object_match = openerp; + var object_match = instance; var path = path_string.split('.'); // ignore first section for(var i=1; i} + */ + first: function () { + var self = this; + return this.clone({limit: 1})._execute().pipe(function (records) { + delete self._count; + if (records.length) { return records[0]; } + return null; + }); + }, + /** + * Fetches all records matching the query + * + * @returns {jQuery.Deferred>} + */ + all: function () { + return this._execute(); + }, + /** + * Fetches the number of records matching the query in the database + * + * @returns {jQuery.Deferred} + */ + count: function () { + if (this._count != undefined) { return $.when(this._count); } + return this._model.call( + 'search_count', [this._filter], { + context: this._model.context(this._context)}); + }, + /** + * Performs a groups read according to the provided grouping criterion + * + * @param {String|Array} grouping + * @returns {jQuery.Deferred> | null} + */ + group_by: function (grouping) { + if (grouping === undefined) { + return null; + } + + if (!(grouping instanceof Array)) { + grouping = _.toArray(arguments); + } + if (_.isEmpty(grouping)) { return null; } + + var self = this; + return this._model.call('read_group', { + groupby: grouping, + fields: _.uniq(grouping.concat(this._fields || [])), + domain: this._model.domain(this._filter), + context: this._model.context(this._context), + offset: this._offset, + limit: this._limit, + orderby: instance.web.serialize_sort(this._order_by) || false + }).pipe(function (results) { + return _(results).map(function (result) { + return new instance.web.data.Group( + self._model.name, grouping[0], result); + }); + }); + }, + /** + * Creates a new query with the union of the current query's context and + * the new context. + * + * @param context context data to add to the query + * @returns {openerp.web.Query} + */ + context: function (context) { + if (!context) { return this; } + return this.clone({context: context}); + }, + /** + * Creates a new query with the union of the current query's filter and + * the new domain. + * + * @param domain domain data to AND with the current query filter + * @returns {openerp.web.Query} + */ + filter: function (domain) { + if (!domain) { return this; } + return this.clone({filter: domain}); + }, + /** + * Creates a new query with the provided limit replacing the current + * query's own limit + * + * @param {Number} limit maximum number of records the query should retrieve + * @returns {openerp.web.Query} + */ + limit: function (limit) { + return this.clone({limit: limit}); + }, + /** + * Creates a new query with the provided offset replacing the current + * query's own offset + * + * @param {Number} offset number of records the query should skip before starting its retrieval + * @returns {openerp.web.Query} + */ + offset: function (offset) { + return this.clone({offset: offset}); + }, + /** + * Creates a new query with the provided ordering parameters replacing + * those of the current query + * + * @param {String...} fields ordering clauses + * @returns {openerp.web.Query} + */ + order_by: function (fields) { + if (fields === undefined) { return this; } + if (!(fields instanceof Array)) { + fields = _.toArray(arguments); + } + if (_.isEmpty(fields)) { return this; } + return this.clone({order_by: fields}); + } +}); + +instance.web.Model = instance.web.Class.extend(/** @lends openerp.web.Model# */{ + /** + * @constructs instance.web.Model + * @extends instance.web.Class + * + * @param {String} model_name name of the OpenERP model this object is bound to + * @param {Object} [context] + * @param {Array} [domain] + */ + init: function (model_name, context, domain) { + this.name = model_name; + this._context = context || {}; + this._domain = domain || []; + }, + /** + * @deprecated does not allow to specify kwargs, directly use call() instead + */ + get_func: function (method_name) { + var self = this; + return function () { + return self.call(method_name, _.toArray(arguments)); + }; + }, + /** + * Call a method (over RPC) on the bound OpenERP model. + * + * @param {String} method name of the method to call + * @param {Array} [args] positional arguments + * @param {Object} [kwargs] keyword arguments + * @returns {jQuery.Deferred<>} call result + */ + call: function (method, args, kwargs) { + args = args || []; + kwargs = kwargs || {}; + if (!_.isArray(args)) { + // call(method, kwargs) + kwargs = args; + args = []; + } + return instance.connection.rpc('/web/dataset/call_kw', { + model: this.name, + method: method, + args: args, + kwargs: kwargs + }); + }, + /** + * Fetches a Query instance bound to this model, for searching + * + * @param {Array} [fields] fields to ultimately fetch during the search + * @returns {openerp.web.Query} + */ + query: function (fields) { + return new instance.web.Query(this, fields); + }, + /** + * Executes a signal on the designated workflow, on the bound OpenERP model + * + * @param {Number} id workflow identifier + * @param {String} signal signal to trigger on the workflow + */ + exec_workflow: function (id, signal) { + return instance.connection.rpc('/web/dataset/exec_workflow', { + model: this.name, + id: id, + signal: signal + }); + }, + /** + * Fetches the model's domain, combined with the provided domain if any + * + * @param {Array} [domain] to combine with the model's internal domain + * @returns The model's internal domain, or the AND-ed union of the model's internal domain and the provided domain + */ + domain: function (domain) { + if (!domain) { return this._domain; } + return new instance.web.CompoundDomain( + this._domain, domain); + }, + /** + * Fetches the combination of the user's context and the domain context, + * combined with the provided context if any + * + * @param {Object} [context] to combine with the model's internal context + * @returns The union of the user's context and the model's internal context, as well as the provided context if any. In that order. + */ + context: function (context) { + return new instance.web.CompoundContext( + instance.connection.user_context, this._context, context || {}); + }, + /** + * Button action caller, needs to perform cleanup if an action is returned + * from the button (parsing of context and domain, and fixup of the views + * collection for act_window actions) + * + * FIXME: remove when evaluator integrated + */ + call_button: function (method, args) { + return instance.connection.rpc('/web/dataset/call_button', { + model: this.name, + method: method, + domain_id: null, + context_id: args.length - 1, + args: args || [] + }); + }, +}); + +instance.web.Traverser = instance.web.Class.extend(/** @lends openerp.web.Traverser# */{ + /** + * @constructs instance.web.Traverser + * @extends instance.web.Class + * + * @param {instance.web.Model} model instance this traverser is bound to + */ + init: function (model) { + this._model = model; + this._index = 0; + }, + + /** + * Gets and sets the current index + * + * @param {Number} [idx] + * @returns {Number} current index + */ + index: function (idx) { + if (idx) { this._index = idx; } + return this._index; + }, + /** + * Returns the model this traverser is currently bound to + * + * @returns {openerp.web.Model} + */ + model: function () { + return this._model; + }, + /** + * Fetches the size of the backing model's match + * + * @returns {Deferred} deferred count + */ + size: function () { + return this._model.query().count(); + }, + + /** + * Record at the current index for the collection, fails if there is no + * record at the current index. + * + * @returns {Deferred<>} + */ + current: function (fields) { + return this._model.query(fields).first().pipe(function (record) { + if (record == null) { + return $.Deferred() + .reject('No record at index' + this._index) + .promise(); + } + return record; + }); + }, + next: function (fields) { + var self = this; + this._index++; + return this.size().pipe(function (s) { + if (self._index >= s) { + self._index = 0; + } + return self.current(fields); + }); + }, + previous: function (fields) { + var self = this; + this._index--; + if (this._index < 0) { + return this.size().pipe(function (s) { + self._index = s-1; + return self.current(fields); + }); + } + return this.current(fields); + } + +}); + +/** + * Utility objects, should never need to be instantiated from outside of this + * module + * + * @namespace + */ +instance.web.data = { + Group: instance.web.Class.extend(/** @lends openerp.web.data.Group# */{ + /** + * @constructs instance.web.data.Group + * @extends instance.web.Class + */ + init: function (model, grouping_field, read_group_group) { + // In cases where group_by_no_leaf and no group_by, the result of + // read_group has aggregate fields but no __context or __domain. + // Create default (empty) values for those so that things don't break + var fixed_group = _.extend( + {__context: {group_by: []}, __domain: []}, + read_group_group); + + var aggregates = {}; + _(fixed_group).each(function (value, key) { + if (key.indexOf('__') === 0 + || key === grouping_field + || key === grouping_field + '_count') { + return; + } + aggregates[key] = value || 0; + }); + + this.model = new instance.web.Model( + model, fixed_group.__context, fixed_group.__domain); + + var group_size = fixed_group[grouping_field + '_count'] || fixed_group.__count || 0; + var leaf_group = fixed_group.__context.group_by.length === 0; + this.attributes = { + grouped_on: grouping_field, + // if terminal group (or no group) and group_by_no_leaf => use group.__count + length: group_size, + value: fixed_group[grouping_field], + // A group is open-able if it's not a leaf in group_by_no_leaf mode + has_children: !(leaf_group && fixed_group.__context['group_by_no_leaf']), + + aggregates: aggregates + }; + }, + get: function (key) { + return this.attributes[key]; + }, + subgroups: function () { + return this.model.query().group_by(this.model.context().group_by); + }, + query: function () { + return this.model.query.apply(this.model, arguments); + } + }) +}; + +instance.web.DataGroup = instance.web.OldWidget.extend( /** @lends openerp.web.DataGroup# */{ /** * Management interface between views and grouped collections of OpenERP * records. @@ -26,13 +447,13 @@ openerp.web.DataGroup = openerp.web.OldWidget.extend( /** @lends openerp.web.Da * The root DataGroup is instantiated with the relevant information * (a session, a model, a domain, a context and a group_by sequence), the * domain and context may be empty. It is then interacted with via - * :js:func:`~openerp.web.DataGroup.list`, which is used to read the + * :js:func:`~instance.web.DataGroup.list`, which is used to read the * content of the current grouping level. * - * @constructs openerp.web.DataGroup - * @extends openerp.web.OldWidget + * @constructs instance.web.DataGroup + * @extends instance.web.OldWidget * - * @param {openerp.web.OldWidget} parent widget + * @param {instance.web.OldWidget} parent widget * @param {String} model name of the model managed by this DataGroup * @param {Array} domain search domain for this DataGroup * @param {Object} context context of the DataGroup's searches @@ -41,188 +462,58 @@ openerp.web.DataGroup = openerp.web.OldWidget.extend( /** @lends openerp.web.Da */ init: function(parent, model, domain, context, group_by, level) { this._super(parent, null); - if (group_by) { - if (group_by.length || context['group_by_no_leaf']) { - return new openerp.web.ContainerDataGroup( this, model, domain, context, group_by, level); - } else { - return new openerp.web.GrouplessDataGroup( this, model, domain, context, level); - } - } - - this.model = model; + this.model = new instance.web.Model(model, context, domain); + this.group_by = group_by; this.context = context; this.domain = domain; this.level = level || 0; }, - cls: 'DataGroup' -}); -openerp.web.ContainerDataGroup = openerp.web.DataGroup.extend( /** @lends openerp.web.ContainerDataGroup# */ { - /** - * - * @constructs openerp.web.ContainerDataGroup - * @extends openerp.web.DataGroup - * - * @param session - * @param model - * @param domain - * @param context - * @param group_by - * @param level - */ - init: function (parent, model, domain, context, group_by, level) { - this._super(parent, model, domain, context, null, level); - - this.group_by = group_by; - }, - /** - * The format returned by ``read_group`` is absolutely dreadful: - * - * * A ``__context`` key provides future grouping levels - * * A ``__domain`` key provides the domain for the next search - * * The current grouping value is provided through the name of the - * current grouping name e.g. if currently grouping on ``user_id``, then - * the ``user_id`` value for this group will be provided through the - * ``user_id`` key. - * * Similarly, the number of items in the group (not necessarily direct) - * is provided via ``${current_field}_count`` - * * Other aggregate fields are just dumped there - * - * This function slightly improves the grouping records by: - * - * * Adding a ``grouped_on`` property providing the current grouping field - * * Adding a ``value`` and a ``length`` properties which replace the - * ``$current_field`` and ``${current_field}_count`` ones - * * Moving aggregate values into an ``aggregates`` property object - * - * Context and domain keys remain as-is, they should not be used externally - * but in case they're needed... - * - * @param {Object} group ``read_group`` record - */ - transform_group: function (group) { - var field_name = this.group_by[0]; - // In cases where group_by_no_leaf and no group_by, the result of - // read_group has aggregate fields but no __context or __domain. - // Create default (empty) values for those so that things don't break - var fixed_group = _.extend( - {__context: {group_by: []}, __domain: []}, - group); - - var aggregates = {}; - _(fixed_group).each(function (value, key) { - if (key.indexOf('__') === 0 - || key === field_name - || key === field_name + '_count') { - return; - } - aggregates[key] = value || 0; - }); - - var group_size = fixed_group[field_name + '_count'] || fixed_group.__count || 0; - var leaf_group = fixed_group.__context.group_by.length === 0; - return { - __context: fixed_group.__context, - __domain: fixed_group.__domain, - - grouped_on: field_name, - // if terminal group (or no group) and group_by_no_leaf => use group.__count - length: group_size, - value: fixed_group[field_name], - // A group is openable if it's not a leaf in group_by_no_leaf mode - openable: !(leaf_group && this.context['group_by_no_leaf']), - - aggregates: aggregates - }; - }, - fetch: function (fields) { - // internal method - var d = new $.Deferred(); - var self = this; - - this.rpc('/web/group/read', { - model: this.model, - context: this.context, - domain: this.domain, - fields: _.uniq(this.group_by.concat(fields)), - group_by_fields: this.group_by, - sort: openerp.web.serialize_sort(this.sort) - }, function () { }).then(function (response) { - var data_groups = _(response).map( - _.bind(self.transform_group, self)); - self.groups = data_groups; - d.resolveWith(self, [data_groups]); - }, function () { - d.rejectWith.apply(d, [self, arguments]); - }); - return d.promise(); - }, - /** - * The items of a list have the following properties: - * - * ``length`` - * the number of records contained in the group (and all of its - * sub-groups). This does *not* provide the size of the "next level" - * of the group, unless the group is terminal (no more groups within - * it). - * ``grouped_on`` - * the name of the field this level was grouped on, this is mostly - * used for display purposes, in order to know the name of the current - * level of grouping. The ``grouped_on`` should be the same for all - * objects of the list. - * ``value`` - * the value which led to this group (this is the value all contained - * records have for the current ``grouped_on`` field name). - * ``aggregates`` - * a mapping of other aggregation fields provided by ``read_group`` - * - * @param {Array} fields the list of fields to aggregate in each group, can be empty - * @param {Function} ifGroups function executed if any group is found (DataGroup.group_by is non-null and non-empty), called with a (potentially empty) list of groups as parameters. - * @param {Function} ifRecords function executed if there is no grouping left to perform, called with a DataSet instance as parameter - */ list: function (fields, ifGroups, ifRecords) { var self = this; - this.fetch(fields).then(function (group_records) { - ifGroups(_(group_records).map(function (group) { - var child_context = _.extend({}, self.context, group.__context); + $.when(this.model.query(fields) + .order_by(this.sort) + .group_by(this.group_by)).then(function (groups) { + if (!groups) { + ifRecords(_.extend( + new instance.web.DataSetSearch( + self, self.model.name, + self.model.context(), + self.model.domain()), + {_sort: self.sort})); + return; + } + ifGroups(_(groups).map(function (group) { + var child_context = _.extend( + {}, self.model.context(), group.model.context()); return _.extend( - new openerp.web.DataGroup( - self, self.model, group.__domain, - child_context, child_context.group_by, + new instance.web.DataGroup( + self, self.model.name, group.model.domain(), + child_context, group.model._context.group_by, self.level + 1), - group, {sort: self.sort}); + { + __context: child_context, + __domain: group.model.domain(), + grouped_on: group.get('grouped_on'), + length: group.get('length'), + value: group.get('value'), + openable: group.get('has_children'), + aggregates: group.get('aggregates') + }, {sort: self.sort}); })); }); } }); -openerp.web.GrouplessDataGroup = openerp.web.DataGroup.extend( /** @lends openerp.web.GrouplessDataGroup# */ { - /** - * - * @constructs openerp.web.GrouplessDataGroup - * @extends openerp.web.DataGroup - * - * @param session - * @param model - * @param domain - * @param context - * @param level - */ - init: function (parent, model, domain, context, level) { - this._super(parent, model, domain, context, null, level); - }, - list: function (fields, ifGroups, ifRecords) { - ifRecords(_.extend( - new openerp.web.DataSetSearch(this, this.model), - {domain: this.domain, context: this.context, _sort: this.sort})); - } -}); -openerp.web.StaticDataGroup = openerp.web.GrouplessDataGroup.extend( /** @lends openerp.web.StaticDataGroup# */ { +instance.web.ContainerDataGroup = instance.web.DataGroup.extend({ }); +instance.web.GrouplessDataGroup = instance.web.DataGroup.extend({ }); + +instance.web.StaticDataGroup = instance.web.GrouplessDataGroup.extend( /** @lends openerp.web.StaticDataGroup# */ { /** * A specialization of groupless data groups, relying on a single static * dataset as its records provider. * - * @constructs openerp.web.StaticDataGroup - * @extends openerp.web.GrouplessDataGroup + * @constructs instance.web.StaticDataGroup + * @extends instance.web.GrouplessDataGroup * @param {openep.web.DataSetStatic} dataset a static dataset backing the groups */ init: function (dataset) { @@ -233,13 +524,13 @@ openerp.web.StaticDataGroup = openerp.web.GrouplessDataGroup.extend( /** @lends } }); -openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.DataSet# */{ +instance.web.DataSet = instance.web.OldWidget.extend( /** @lends openerp.web.DataSet# */{ /** * DateaManagement interface between views and the collection of selected * OpenERP records (represents the view's state?) * - * @constructs openerp.web.DataSet - * @extends openerp.web.OldWidget + * @constructs instance.web.DataSet + * @extends instance.web.OldWidget * * @param {String} model the OpenERP model this dataset will manage */ @@ -249,6 +540,7 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data this.context = context || {}; this.index = null; this._sort = []; + this._model = new instance.web.Model(model, context); }, previous: function () { this.index -= 1; @@ -296,13 +588,11 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data * @returns {$.Deferred} */ read_ids: function (ids, fields, options) { - var options = options || {}; - return this.rpc('/web/dataset/get', { - model: this.model, - ids: ids, - fields: fields, - context: this.get_context(options.context) - }); + options = options || {}; + // TODO: reorder results to match ids list + return this._model.call('read', + [ids, fields || false], + {context: this._model.context(options.context)}); }, /** * Read a slice of the records represented by this DataSet, based on its @@ -315,7 +605,14 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data * @returns {$.Deferred} */ read_slice: function (fields, options) { - return null; + var self = this; + options = options || {}; + return this._model.query(fields) + .limit(options.limit || false) + .offset(options.offset || 0) + .all().then(function (records) { + self.ids = _(records).pluck('id'); + }); }, /** * Reads the current dataset record (from its index) @@ -325,18 +622,11 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data * @returns {$.Deferred} */ read_index: function (fields, options) { - var def = $.Deferred(); - if (_.isEmpty(this.ids)) { - def.reject(); - } else { - fields = fields || false; - this.read_ids([this.ids[this.index]], fields, options).then(function(records) { - def.resolve(records[0]); - }, function() { - def.reject.apply(def, arguments); - }); - } - return def.promise(); + options = options || {}; + return this.read_ids([this.ids[this.index]], fields, options).pipe(function (records) { + if (_.isEmpty(records)) { return $.Deferred().reject().promise(); } + return records[0]; + }); }, /** * Reads default values for the current model @@ -346,12 +636,9 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data * @returns {$.Deferred} */ default_get: function(fields, options) { - var options = options || {}; - return this.rpc('/web/dataset/default_get', { - model: this.model, - fields: fields, - context: this.get_context(options.context) - }); + options = options || {}; + return this._model.call('default_get', + [fields], {context: this._model.context(options.context)}); }, /** * Creates a new record in db @@ -362,11 +649,10 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data * @returns {$.Deferred} */ create: function(data, callback, error_callback) { - return this.rpc('/web/dataset/create', { - model: this.model, - data: data, - context: this.get_context() - }, callback, error_callback); + return this._model.call('create', + [data], {context: this._model.context()}) + .pipe(function (r) { return {result: r}; }) + .then(callback, error_callback); }, /** * Saves the provided data in an existing db record @@ -379,12 +665,10 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data */ write: function (id, data, options, callback, error_callback) { options = options || {}; - return this.rpc('/web/dataset/save', { - model: this.model, - id: id, - data: data, - context: this.get_context(options.context) - }, callback, error_callback); + return this._model.call('write', + [[id], data], {context: this._model.context(options.context)}) + .pipe(function (r) { return {result: r}}) + .then(callback, error_callback); }, /** * Deletes an existing record from the database @@ -394,9 +678,9 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data * @param {Function} error_callback function called in case of deletion error */ unlink: function(ids, callback, error_callback) { - var self = this; - return this.call_and_eval("unlink", [ids, this.get_context()], null, 1, - callback, error_callback); + return this._model.call('unlink', + [ids], {context: this._model.context()}) + .then(callback, error_callback); }, /** * Calls an arbitrary RPC method @@ -408,11 +692,7 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data * @returns {$.Deferred} */ call: function (method, args, callback, error_callback) { - return this.rpc('/web/dataset/call', { - model: this.model, - method: method, - args: args || [] - }, callback, error_callback); + return this._model.call(method, args).then(callback, error_callback); }, /** * Calls an arbitrary method, with more crazy @@ -431,9 +711,7 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data method: method, domain_id: domain_index == undefined ? null : domain_index, context_id: context_index == undefined ? null : context_index, - args: args || [], - // FIXME: API which does not suck for aborting requests in-flight - aborter: this + args: args || [] }, callback, error_callback); }, /** @@ -446,13 +724,8 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data * @returns {$.Deferred} */ call_button: function (method, args, callback, error_callback) { - return this.rpc('/web/dataset/call_button', { - model: this.model, - method: method, - domain_id: null, - context_id: args.length - 1, - args: args || [] - }, callback, error_callback); + return this._model.call_button(method, args) + .then(callback, error_callback); }, /** * Fetches the "readable name" for records, based on intrinsic rules @@ -462,7 +735,9 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data * @returns {$.Deferred} */ name_get: function(ids, callback) { - return this.call_and_eval('name_get', [ids, this.get_context()], null, 1, callback); + return this._model.call('name_get', + [ids], {context: this._model.context()}) + .then(callback); }, /** * @@ -474,29 +749,30 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data * @returns {$.Deferred} */ name_search: function (name, domain, operator, limit, callback) { - return this.call_and_eval('name_search', - [name || '', domain || false, operator || 'ilike', this.get_context(), limit || 0], - 1, 3, callback); + return this._model.call('name_search', { + name: name || '', + args: domain || false, + operator: operator || 'ilike', + context: this._model.context(), + limit: limit || 0 + }).then(callback); }, /** * @param name * @param callback */ name_create: function(name, callback) { - return this.call_and_eval('name_create', [name, this.get_context()], null, 1, callback); + return this._model.call('name_create', + [name], {context: this._model.context()}) + .then(callback); }, exec_workflow: function (id, signal, callback) { - return this.rpc('/web/dataset/exec_workflow', { - model: this.model, - id: id, - signal: signal - }, callback); + return this._model.exec_workflow(id, signal) + .pipe(function (result) { return { result: result }; }) + .then(callback); }, get_context: function(request_context) { - if (request_context) { - return new openerp.web.CompoundContext(this.context, request_context); - } - return this.context; + return this._model.context(request_context); }, /** * Reads or changes sort criteria on the dataset. @@ -513,7 +789,7 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data */ sort: function (field, force_reverse) { if (!field) { - return openerp.web.serialize_sort(this._sort); + return instance.web.serialize_sort(this._sort); } var reverse = force_reverse || (this._sort[0] === field); this._sort.splice.apply( @@ -530,7 +806,7 @@ openerp.web.DataSet = openerp.web.OldWidget.extend( /** @lends openerp.web.Data this.ids = n_ids; }, }); -openerp.web.DataSetStatic = openerp.web.DataSet.extend({ +instance.web.DataSetStatic = instance.web.DataSet.extend({ init: function(parent, model, context, ids) { this._super(parent, model, context); // all local records @@ -560,10 +836,10 @@ openerp.web.DataSetStatic = openerp.web.DataSet.extend({ this.set_ids(_.without.apply(null, [this.ids].concat(ids))); } }); -openerp.web.DataSetSearch = openerp.web.DataSet.extend(/** @lends openerp.web.DataSetSearch */{ +instance.web.DataSetSearch = instance.web.DataSet.extend(/** @lends openerp.web.DataSetSearch */{ /** - * @constructs openerp.web.DataSetSearch - * @extends openerp.web.DataSet + * @constructs instance.web.DataSetSearch + * @extends instance.web.DataSet * * @param {Object} parent * @param {String} model @@ -573,11 +849,9 @@ openerp.web.DataSetSearch = openerp.web.DataSet.extend(/** @lends openerp.web.D init: function(parent, model, context, domain) { this._super(parent, model, context); this.domain = domain || []; - this.offset = 0; - this._length; - // subset records[offset:offset+limit] - // is it necessary ? + this._length = null; this.ids = []; + this._model = new instance.web.Model(model, context, domain); }, /** * Read a slice of the records represented by this DataSet, based on its @@ -594,32 +868,29 @@ openerp.web.DataSetSearch = openerp.web.DataSet.extend(/** @lends openerp.web.D read_slice: function (fields, options) { options = options || {}; var self = this; - var offset = options.offset || 0; - return this.rpc('/web/dataset/search_read', { - model: this.model, - fields: fields || false, - domain: this.get_domain(options.domain), - context: this.get_context(options.context), - sort: this.sort(), - offset: offset, - limit: options.limit || false - }).pipe(function (result) { - self.ids = result.ids; - self.offset = offset; - self._length = result.length; - return result.records; + var q = this._model.query(fields || false) + .filter(options.domain) + .context(options.context) + .offset(options.offset || 0) + .limit(options.limit || false); + q = q.order_by.apply(q, this._sort); + + return q.all().then(function (records) { + // FIXME: not sure about that one, *could* have discarded count + q.count().then(function (count) { self._length = count; }); + self.ids = _(records).pluck('id'); }); }, get_domain: function (other_domain) { - if (other_domain) { - return new openerp.web.CompoundDomain(this.domain, other_domain); - } - return this.domain; + this._model.domain(other_domain); }, unlink: function(ids, callback, error_callback) { var self = this; return this._super(ids, function(result) { - self.ids = _.without.apply(_, [self.ids].concat(ids)); + self.ids = _(self.ids).difference(ids); + if (self._length) { + self._length -= 1; + } if (this.index !== null) { self.index = self.index <= self.ids.length - 1 ? self.index : (self.ids.length > 0 ? self.ids.length -1 : 0); @@ -635,7 +906,7 @@ openerp.web.DataSetSearch = openerp.web.DataSet.extend(/** @lends openerp.web.D return this._super(); } }); -openerp.web.BufferedDataSet = openerp.web.DataSetStatic.extend({ +instance.web.BufferedDataSet = instance.web.DataSetStatic.extend({ virtual_id_prefix: "one2many_v_id_", debug_mode: true, init: function() { @@ -800,9 +1071,9 @@ openerp.web.BufferedDataSet = openerp.web.DataSetStatic.extend({ this.on_change(); }, }); -openerp.web.BufferedDataSet.virtual_id_regex = /^one2many_v_id_.*$/; +instance.web.BufferedDataSet.virtual_id_regex = /^one2many_v_id_.*$/; -openerp.web.ProxyDataSet = openerp.web.DataSetSearch.extend({ +instance.web.ProxyDataSet = instance.web.DataSetSearch.extend({ init: function() { this._super.apply(this, arguments); this.create_function = null; @@ -848,35 +1119,7 @@ openerp.web.ProxyDataSet = openerp.web.DataSetSearch.extend({ on_unlink: function(ids) {} }); -openerp.web.Model = openerp.web.CallbackEnabled.extend({ - init: function(model_name) { - this._super(); - this.model_name = model_name; - }, - rpc: function() { - var c = openerp.connection; - return c.rpc.apply(c, arguments); - }, - /* - * deprecated because it does not allow to specify kwargs, directly use call() instead - */ - get_func: function(method_name) { - var self = this; - return function() { - return self.call(method_name, _.toArray(arguments), {}); - }; - }, - call: function (method, args, kwargs) { - return this.rpc('/web/dataset/call_kw', { - model: this.model_name, - method: method, - args: args, - kwargs: kwargs - }); - } -}); - -openerp.web.CompoundContext = openerp.web.Class.extend({ +instance.web.CompoundContext = instance.web.Class.extend({ init: function () { this.__ref = "compound_context"; this.__contexts = []; @@ -899,7 +1142,7 @@ openerp.web.CompoundContext = openerp.web.Class.extend({ } }); -openerp.web.CompoundDomain = openerp.web.Class.extend({ +instance.web.CompoundDomain = instance.web.Class.extend({ init: function () { this.__ref = "compound_domain"; this.__domains = []; @@ -921,6 +1164,46 @@ openerp.web.CompoundDomain = openerp.web.Class.extend({ return this.__eval_context; } }); + +instance.web.DropMisordered = instance.web.Class.extend(/** @lends openerp.web.DropMisordered# */{ + /** + * @constructs instance.web.DropMisordered + * @extends instance.web.Class + * + * @param {Boolean} [failMisordered=false] whether mis-ordered responses should be failed or just ignored + */ + init: function (failMisordered) { + // local sequence number, for requests sent + this.lsn = 0; + // remote sequence number, seqnum of last received request + this.rsn = -1; + this.failMisordered = failMisordered || false; + }, + /** + * Adds a deferred (usually an async request) to the sequencer + * + * @param {$.Deferred} deferred to ensure add + * @returns {$.Deferred} + */ + add: function (deferred) { + var res = $.Deferred(); + + var self = this, seq = this.lsn++; + deferred.then(function () { + if (seq > self.rsn) { + self.rsn = seq; + res.resolve.apply(res, arguments); + } else if (self.failMisordered) { + res.reject(); + } + }, function () { + res.reject.apply(res, arguments); + }); + + return res.promise(); + } +}); + }; // vim:et fdc=0 fdl=0 foldnestmax=3 fdm=syntax: diff --git a/addons/web/static/src/js/data_export.js b/addons/web/static/src/js/data_export.js index 3d15a4e3607..ebe82ddb4b4 100644 --- a/addons/web/static/src/js/data_export.js +++ b/addons/web/static/src/js/data_export.js @@ -1,14 +1,14 @@ -openerp.web.data_export = function(openerp) { -var QWeb = openerp.web.qweb, - _t = openerp.web._t; -openerp.web.DataExport = openerp.web.Dialog.extend({ +openerp.web.data_export = function(instance) { +var QWeb = instance.web.qweb, + _t = instance.web._t; +instance.web.DataExport = instance.web.Dialog.extend({ template: 'ExportTreeView', dialog_title: {toString: function () { return _t("Export Data"); }}, init: function(parent, dataset) { this._super(parent); this.records = {}; this.dataset = dataset; - this.exports = new openerp.web.DataSetSearch( + this.exports = new instance.web.DataSetSearch( this, 'ir.exports', this.dataset.get_context()); }, start: function() { diff --git a/addons/web/static/src/js/data_import.js b/addons/web/static/src/js/data_import.js index 3054a7784c4..30f9323f723 100644 --- a/addons/web/static/src/js/data_import.js +++ b/addons/web/static/src/js/data_import.js @@ -1,6 +1,6 @@ -openerp.web.data_import = function(openerp) { -var QWeb = openerp.web.qweb, - _t = openerp.web._t; +openerp.web.data_import = function(instance) { +var QWeb = instance.web.qweb, + _t = instance.web._t; /** * Safari does not deal well at all with raw JSON data being returned. As a * result, we're going to cheat by using a pseudo-jsonp: instead of getting @@ -29,7 +29,7 @@ function jsonp(form, attributes, callback) { $(form).ajaxSubmit(attributes); } -openerp.web.DataImport = openerp.web.Dialog.extend({ +instance.web.DataImport = instance.web.Dialog.extend({ template: 'ImportDataView', dialog_title: {toString: function () { return _t("Import Data"); }}, init: function(parent, dataset){ @@ -79,10 +79,10 @@ openerp.web.DataImport = openerp.web.Dialog.extend({ this.$element.delegate('fieldset legend', 'click', function() { $(this).parent().toggleClass('oe-closed'); }); - this.ready.push(new openerp.web.DataSet(this, this.model).call( + this.ready.push(new instance.web.DataSet(this, this.model).call( 'fields_get', [], function (fields) { self.graft_fields(fields); - self.ready.push(new openerp.web.DataSet(self, self.model) + self.ready.push(new instance.web.DataSet(self, self.model) .default_get(_.pluck(self.fields, 'id')).then(function (fields) { _.each(fields, function(val, key) { if (val) { @@ -140,7 +140,7 @@ openerp.web.DataImport = openerp.web.Dialog.extend({ f.fields = []; // only fetch sub-fields to a depth of 2 levels if (level < 2) { - self.ready.push(new openerp.web.DataSet(self, field.relation).call( + self.ready.push(new instance.web.DataSet(self, field.relation).call( 'fields_get', [], function (fields) { self.graft_fields(fields, f, level+1); })); @@ -151,7 +151,7 @@ openerp.web.DataImport = openerp.web.Dialog.extend({ }); }, toggle_import_button: function (newstate) { - openerp.web.dialog(this.$element, 'widget') + instance.web.dialog(this.$element, 'widget') .find('.oe-dialog-import-button') .button('option', 'disabled', !newstate); }, diff --git a/addons/web/static/src/js/dates.js b/addons/web/static/src/js/dates.js index d61223113f8..3db48c8412a 100644 --- a/addons/web/static/src/js/dates.js +++ b/addons/web/static/src/js/dates.js @@ -1,5 +1,5 @@ -openerp.web.dates = function(openerp) { +openerp.web.dates = function(instance) { /** * Converts a string to a Date javascript object using OpenERP's @@ -11,7 +11,7 @@ openerp.web.dates = function(openerp) { * @param {String} str A string representing a datetime. * @returns {Date} */ -openerp.web.str_to_datetime = function(str) { +instance.web.str_to_datetime = function(str) { if(!str) { return str; } @@ -38,7 +38,7 @@ openerp.web.str_to_datetime = function(str) { * @param {String} str A string representing a date. * @returns {Date} */ -openerp.web.str_to_date = function(str) { +instance.web.str_to_date = function(str) { if(!str) { return str; } @@ -65,7 +65,7 @@ openerp.web.str_to_date = function(str) { * @param {String} str A string representing a time. * @returns {Date} */ -openerp.web.str_to_time = function(str) { +instance.web.str_to_time = function(str) { if(!str) { return str; } @@ -104,7 +104,7 @@ var zpad = function(str, size) { * @param {Date} obj * @returns {String} A string representing a datetime. */ -openerp.web.datetime_to_str = function(obj) { +instance.web.datetime_to_str = function(obj) { if (!obj) { return false; } @@ -124,7 +124,7 @@ openerp.web.datetime_to_str = function(obj) { * @param {Date} obj * @returns {String} A string representing a date. */ -openerp.web.date_to_str = function(obj) { +instance.web.date_to_str = function(obj) { if (!obj) { return false; } @@ -143,7 +143,7 @@ openerp.web.date_to_str = function(obj) { * @param {Date} obj * @returns {String} A string representing a time. */ -openerp.web.time_to_str = function(obj) { +instance.web.time_to_str = function(obj) { if (!obj) { return false; } diff --git a/addons/web/static/src/js/formats.js b/addons/web/static/src/js/formats.js index 53863e63e97..640ba4d5a93 100644 --- a/addons/web/static/src/js/formats.js +++ b/addons/web/static/src/js/formats.js @@ -1,6 +1,6 @@ -openerp.web.formats = function(openerp) { -var _t = openerp.web._t; +openerp.web.formats = function(instance) { +var _t = instance.web._t; /** * Intersperses ``separator`` in ``str`` at the positions indicated by @@ -23,7 +23,7 @@ var _t = openerp.web._t; * @param {String} separator * @returns {String} */ -openerp.web.intersperse = function (str, indices, separator) { +instance.web.intersperse = function (str, indices, separator) { separator = separator || ''; var result = [], last = str.length; @@ -55,10 +55,10 @@ openerp.web.intersperse = function (str, indices, separator) { * @param {String} num * @returns {String} */ -openerp.web.insert_thousand_seps = function (num) { +instance.web.insert_thousand_seps = function (num) { var negative = num[0] === '-'; num = (negative ? num.slice(1) : num); - return (negative ? '-' : '') + openerp.web.intersperse( + return (negative ? '-' : '') + instance.web.intersperse( num, _t.database.parameters.grouping, _t.database.parameters.thousands_sep); }; @@ -69,7 +69,7 @@ openerp.web.insert_thousand_seps = function (num) { * * @param {String} value original format */ -openerp.web.strip_raw_chars = function (value) { +instance.web.strip_raw_chars = function (value) { var isletter = /[a-zA-Z]/, output = []; for(var index=0; index < value.length; ++index) { var character = value[index]; @@ -81,7 +81,7 @@ openerp.web.strip_raw_chars = function (value) { return output.join(''); }; var normalize_format = function (format) { - return Date.normalizeFormat(openerp.web.strip_raw_chars(format)); + return Date.normalizeFormat(instance.web.strip_raw_chars(format)); }; /** * Formats a single atomic value based on a field descriptor @@ -93,7 +93,7 @@ var normalize_format = function (format) { * @param {Object} [descriptor.digits] used for the formatting of floats * @param {String} [value_if_empty=''] returned if the ``value`` argument is considered empty */ -openerp.web.format_value = function (value, descriptor, value_if_empty) { +instance.web.format_value = function (value, descriptor, value_if_empty) { // If NaN value, display as with a `false` (empty cell) if (typeof value === 'number' && isNaN(value)) { value = false; @@ -111,16 +111,16 @@ openerp.web.format_value = function (value, descriptor, value_if_empty) { return value_if_empty === undefined ? '' : value_if_empty; } var l10n = _t.database.parameters; - switch (descriptor.widget || descriptor.type) { + switch (descriptor.type || (descriptor.field && descriptor.field.type)) { case 'id': return value.toString(); case 'integer': - return openerp.web.insert_thousand_seps( + return instance.web.insert_thousand_seps( _.str.sprintf('%d', value)); case 'float': var precision = descriptor.digits ? descriptor.digits[1] : 2; var formatted = _.str.sprintf('%.' + precision + 'f', value).split('.'); - formatted[0] = openerp.web.insert_thousand_seps(formatted[0]); + formatted[0] = instance.web.insert_thousand_seps(formatted[0]); return formatted.join(l10n.decimal_point); case 'float_time': var pattern = '%02d:%02d'; @@ -136,17 +136,17 @@ openerp.web.format_value = function (value, descriptor, value_if_empty) { return value[1]; case 'datetime': if (typeof(value) == "string") - value = openerp.web.auto_str_to_date(value); + value = instance.web.auto_str_to_date(value); return value.toString(normalize_format(l10n.date_format) + ' ' + normalize_format(l10n.time_format)); case 'date': if (typeof(value) == "string") - value = openerp.web.auto_str_to_date(value); + value = instance.web.auto_str_to_date(value); return value.toString(normalize_format(l10n.date_format)); case 'time': if (typeof(value) == "string") - value = openerp.web.auto_str_to_date(value); + value = instance.web.auto_str_to_date(value); return value.toString(normalize_format(l10n.time_format)); case 'selection': case 'statusbar': // Each choice is [value, label] @@ -163,7 +163,7 @@ openerp.web.format_value = function (value, descriptor, value_if_empty) { } }; -openerp.web.parse_value = function (value, descriptor, value_if_empty) { +instance.web.parse_value = function (value, descriptor, value_if_empty) { var date_pattern = normalize_format(_t.database.parameters.date_format), time_pattern = normalize_format(_t.database.parameters.time_format); switch (value) { @@ -171,12 +171,12 @@ openerp.web.parse_value = function (value, descriptor, value_if_empty) { case "": return value_if_empty === undefined ? false : value_if_empty; } - switch (descriptor.widget || descriptor.type) { + switch (descriptor.type || (descriptor.field && descriptor.field.type)) { case 'integer': var tmp; do { tmp = value; - value = value.replace(openerp.web._t.database.parameters.thousands_sep, ""); + value = value.replace(instance.web._t.database.parameters.thousands_sep, ""); } while(tmp !== value); tmp = Number(value); if (isNaN(tmp)) @@ -190,9 +190,9 @@ openerp.web.parse_value = function (value, descriptor, value_if_empty) { var tmp2 = value; do { tmp = tmp2; - tmp2 = tmp.replace(openerp.web._t.database.parameters.thousands_sep, ""); + tmp2 = tmp.replace(instance.web._t.database.parameters.thousands_sep, ""); } while(tmp !== tmp2); - var reformatted_value = tmp.replace(openerp.web._t.database.parameters.decimal_point, "."); + var reformatted_value = tmp.replace(instance.web._t.database.parameters.decimal_point, "."); var parsed = Number(reformatted_value); if (isNaN(parsed)) throw new Error(value + " is not a correct float"); @@ -205,62 +205,62 @@ openerp.web.parse_value = function (value, descriptor, value_if_empty) { } var float_time_pair = value.split(":"); if (float_time_pair.length != 2) - return factor * openerp.web.parse_value(value, {type: "float"}); - var hours = openerp.web.parse_value(float_time_pair[0], {type: "integer"}); - var minutes = openerp.web.parse_value(float_time_pair[1], {type: "integer"}); + return factor * instance.web.parse_value(value, {type: "float"}); + var hours = instance.web.parse_value(float_time_pair[0], {type: "integer"}); + var minutes = instance.web.parse_value(float_time_pair[1], {type: "integer"}); return factor * (hours + (minutes / 60)); case 'progressbar': - return openerp.web.parse_value(value, {type: "float"}); + return instance.web.parse_value(value, {type: "float"}); case 'datetime': var datetime = Date.parseExact( value, (date_pattern + ' ' + time_pattern)); if (datetime !== null) - return openerp.web.datetime_to_str(datetime); + return instance.web.datetime_to_str(datetime); datetime = Date.parse(value); if (datetime !== null) - return openerp.web.datetime_to_str(datetime); + return instance.web.datetime_to_str(datetime); throw new Error(value + " is not a valid datetime"); case 'date': var date = Date.parseExact(value, date_pattern); if (date !== null) - return openerp.web.date_to_str(date); + return instance.web.date_to_str(date); date = Date.parse(value); if (date !== null) - return openerp.web.date_to_str(date); + return instance.web.date_to_str(date); throw new Error(value + " is not a valid date"); case 'time': var time = Date.parseExact(value, time_pattern); if (time !== null) - return openerp.web.time_to_str(time); + return instance.web.time_to_str(time); time = Date.parse(value); if (time !== null) - return openerp.web.time_to_str(time); + return instance.web.time_to_str(time); throw new Error(value + " is not a valid time"); } return value; }; -openerp.web.auto_str_to_date = function(value, type) { +instance.web.auto_str_to_date = function(value, type) { try { - return openerp.web.str_to_datetime(value); + return instance.web.str_to_datetime(value); } catch(e) {} try { - return openerp.web.str_to_date(value); + return instance.web.str_to_date(value); } catch(e) {} try { - return openerp.web.str_to_time(value); + return instance.web.str_to_time(value); } catch(e) {} throw new Error("'" + value + "' is not a valid date, datetime nor time"); }; -openerp.web.auto_date_to_str = function(value, type) { +instance.web.auto_date_to_str = function(value, type) { switch(type) { case 'datetime': - return openerp.web.datetime_to_str(value); + return instance.web.datetime_to_str(value); case 'date': - return openerp.web.date_to_str(value); + return instance.web.date_to_str(value); case 'time': - return openerp.web.time_to_str(value); + return instance.web.time_to_str(value); default: throw new Error(type + " is not convertible to date, datetime nor time"); } @@ -290,7 +290,7 @@ openerp.web.auto_date_to_str = function(value, type) { * @param {Number} [options.id] current record's id * */ -openerp.web.format_cell = function (row_data, column, options) { +instance.web.format_cell = function (row_data, column, options) { options = options || {}; var attrs = {}; if (options.process_modifiers !== false) { @@ -303,9 +303,9 @@ openerp.web.format_cell = function (row_data, column, options) { '<%-alt%>' + '', { title: column.string || '', - additional_attributes: isNaN(row_data["id"].value) && openerp.web.BufferedDataSet.virtual_id_regex.test(row_data["id"].value) ? + additional_attributes: isNaN(row_data["id"].value) && instance.web.BufferedDataSet.virtual_id_regex.test(row_data["id"].value) ? 'disabled="disabled" class="oe-listview-button-disabled"' : '', - prefix: openerp.connection.prefix, + prefix: instance.connection.prefix, icon: column.icon, alt: column.string || '' }); @@ -320,11 +320,11 @@ openerp.web.format_cell = function (row_data, column, options) { row_data[column.id].value ? 'checked="checked"' : ''); case "binary": var text = _t("Download"), - download_url = _.str.sprintf('/web/binary/saveas?session_id=%s&model=%s&field=%s&id=%d', openerp.connection.session_id, options.model, column.id, options.id); + download_url = _.str.sprintf('/web/binary/saveas?session_id=%s&model=%s&field=%s&id=%d', instance.connection.session_id, options.model, column.id, options.id); if (column.filename) { download_url += '&filename_field=' + column.filename; if (row_data[column.filename]) { - text = _.str.sprintf(_t("Download \"%s\""), openerp.web.format_value( + text = _.str.sprintf(_t("Download \"%s\""), instance.web.format_value( row_data[column.filename].value, {type: 'char'})); } } @@ -340,7 +340,7 @@ openerp.web.format_cell = function (row_data, column, options) { }); } - return _.escape(openerp.web.format_value( + return _.escape(instance.web.format_value( row_data[column.id].value, column, options.value_if_empty)); } diff --git a/addons/web/static/src/js/search.js b/addons/web/static/src/js/search.js index 6e1026b48a1..c2df866b5c6 100644 --- a/addons/web/static/src/js/search.js +++ b/addons/web/static/src/js/search.js @@ -1,7 +1,7 @@ -openerp.web.search = function(openerp) { -var QWeb = openerp.web.qweb, - _t = openerp.web._t, - _lt = openerp.web._lt; +openerp.web.search = function(instance) { +var QWeb = instance.web.qweb, + _t = instance.web._t, + _lt = instance.web._lt; _.mixin({ sum: function (obj) { return _.reduce(obj, function (a, b) { return a + b; }, 0); } }); @@ -70,11 +70,11 @@ _.extend(VS.model.SearchFacet.prototype, { } }); -openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.SearchView# */{ +instance.web.SearchView = instance.web.Widget.extend(/** @lends instance.web.SearchView# */{ template: "SearchView", /** - * @constructs openerp.web.SearchView - * @extends openerp.web.OldWidget + * @constructs instance.web.SearchView + * @extends instance.web.OldWidget * * @param parent * @param element_id @@ -178,7 +178,7 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search var running_count = 0; // get total filters count - var is_group = function (i) { return i instanceof openerp.web.search.FilterGroup; }; + var is_group = function (i) { return i instanceof instance.web.search.FilterGroup; }; var filters_count = _(this.controls).chain() .flatten() .filter(is_group) @@ -212,12 +212,12 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search name: _t("Custom Filters"), filters: _.map(this.custom_filters, function (filter) { // FIXME: handling of ``disabled`` being set - var f = new openerp.web.search.Filter({attrs: { + var f = new instance.web.search.Filter({attrs: { string: filter.name, context: filter.context, domain: filter.domain }}, self); - return new openerp.web.search.FilterGroup([f], self); + return new instance.web.search.FilterGroup([f], self); }), length: 3 }); @@ -225,7 +225,7 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search return $.when( this.render_column(col1, $('
    ').appendTo($filters)), this.render_column(col2, $('
    ').appendTo($filters)), - (new openerp.web.search.Advanced(this).appendTo($drawer))); + (new instance.web.search.Advanced(this).appendTo($drawer))); }, render_column: function (column, $el) { return $.when.apply(null, _(column).map(function (group) { @@ -314,10 +314,10 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search * @param {VS.model.SearchFacet} options.model facet object to render */ make_visualsearch_facet: function (options) { - return new openerp.web.search.FilterGroupFacet(options); + return new instance.web.search.FilterGroupFacet(options); -// if (options.model.get('field') instanceof openerp.web.search.FilterGroup) { -// return new openerp.web.search.FilterGroupFacet(options); +// if (options.model.get('field') instanceof instance.web.search.FilterGroup) { +// return new instance.web.search.FilterGroupFacet(options); // } // return new VS.ui.SearchFacet(options); }, @@ -363,7 +363,7 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search var filters = []; _.each(items, function (item) { if (filters.length && item.tag !== 'filter') { - group.push(new openerp.web.search.FilterGroup(filters, this)); + group.push(new instance.web.search.FilterGroup(filters, this)); filters = []; } @@ -371,7 +371,7 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search case 'separator': case 'newline': break; case 'filter': - filters.push(new openerp.web.search.Filter(item, this)); + filters.push(new instance.web.search.Filter(item, this)); break; case 'group': self.make_widgets(item.children, fields, item.attrs.string); @@ -385,7 +385,7 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search }, this); if (filters.length) { - group.push(new openerp.web.search.FilterGroup(filters, this)); + group.push(new instance.web.search.FilterGroup(filters, this)); } }, /** @@ -394,10 +394,10 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search * * @param {Object} item fields_view_get node for the field * @param {Object} field fields_get result for the field - * @returns openerp.web.search.Field + * @returns instance.web.search.Field */ make_field: function (item, field) { - var obj = openerp.web.search.fields.get_any( [item.attrs.widget, field.type]); + var obj = instance.web.search.fields.get_any( [item.attrs.widget, field.type]); if(obj) { return new (obj) (item, field, this); } else { @@ -460,11 +460,11 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search break; case 'save_filter': var data = this.build_search_data(); - var context = new openerp.web.CompoundContext(); + var context = new instance.web.CompoundContext(); _.each(data.contexts, function(x) { context.add(x); }); - var domain = new openerp.web.CompoundDomain(); + var domain = new instance.web.CompoundDomain(); _.each(data.domains, function(x) { domain.add(x); }); @@ -472,7 +472,7 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search context.add({"group_by": groupbys}); var dial_html = QWeb.render("SearchView.managed-filters.add"); var $dial = $(dial_html); - openerp.web.dialog($dial, { + instance.web.dialog($dial, { modal: true, title: _t("Filter Entry"), buttons: [ @@ -525,13 +525,13 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search on_add_to_dashboard: function() { this.$element.find(".oe_search-view-filters-management")[0].selectedIndex = 0; var self = this, - menu = openerp.webclient.menu, + menu = instance.webclient.menu, $dialog = $(QWeb.render("SearchView.add_to_dashboard", { dashboards : menu.data.data.children, selected_menu_id : menu.$element.find('a.active').data('menu') })); $dialog.find('input').val(this.fields_view.name); - openerp.web.dialog($dialog, { + instance.web.dialog($dialog, { modal: true, title: _t("Add to Dashboard"), buttons: [ @@ -543,8 +543,8 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search var menu_id = $(this).find("select").val(), title = $(this).find("input").val(), data = self.build_search_data(), - context = new openerp.web.CompoundContext(), - domain = new openerp.web.CompoundDomain(); + context = new instance.web.CompoundContext(), + domain = new instance.web.CompoundDomain(); _.each(data.contexts, function(x) { context.add(x); }); @@ -573,10 +573,10 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search * Performs the search view collection of widget data. * * If the collection went well (all fields are valid), then triggers - * :js:func:`openerp.web.SearchView.on_search`. + * :js:func:`instance.web.SearchView.on_search`. * * If at least one field failed its validation, triggers - * :js:func:`openerp.web.SearchView.on_invalid` instead. + * :js:func:`instance.web.SearchView.on_invalid` instead. * * @param e jQuery event object coming from the "Search" button */ @@ -599,7 +599,7 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search groupbys.push.apply(groupbys, group_by); } } catch (e) { - if (e instanceof openerp.web.search.Invalid) { + if (e instanceof instance.web.search.Invalid) { errors.push(e); } else { throw e; @@ -648,9 +648,9 @@ openerp.web.SearchView = openerp.web.Widget.extend(/** @lends openerp.web.Search }); /** @namespace */ -openerp.web.search = {}; +instance.web.search = {}; -openerp.web.search.FilterGroupFacet = VS.ui.SearchFacet.extend({ +instance.web.search.FilterGroupFacet = VS.ui.SearchFacet.extend({ events: _.extend({ 'click': 'selectFacet' }, VS.ui.SearchFacet.prototype.events), @@ -682,30 +682,30 @@ openerp.web.search.FilterGroupFacet = VS.ui.SearchFacet.extend({ } }); /** - * Registry of search fields, called by :js:class:`openerp.web.SearchView` to + * Registry of search fields, called by :js:class:`instance.web.SearchView` to * find and instantiate its field widgets. */ -openerp.web.search.fields = new openerp.web.Registry({ - 'char': 'openerp.web.search.CharField', - 'text': 'openerp.web.search.CharField', - 'boolean': 'openerp.web.search.BooleanField', - 'integer': 'openerp.web.search.IntegerField', - 'id': 'openerp.web.search.IntegerField', - 'float': 'openerp.web.search.FloatField', - 'selection': 'openerp.web.search.SelectionField', - 'datetime': 'openerp.web.search.DateTimeField', - 'date': 'openerp.web.search.DateField', - 'many2one': 'openerp.web.search.ManyToOneField', - 'many2many': 'openerp.web.search.CharField', - 'one2many': 'openerp.web.search.CharField' +instance.web.search.fields = new instance.web.Registry({ + 'char': 'instance.web.search.CharField', + 'text': 'instance.web.search.CharField', + 'boolean': 'instance.web.search.BooleanField', + 'integer': 'instance.web.search.IntegerField', + 'id': 'instance.web.search.IntegerField', + 'float': 'instance.web.search.FloatField', + 'selection': 'instance.web.search.SelectionField', + 'datetime': 'instance.web.search.DateTimeField', + 'date': 'instance.web.search.DateField', + 'many2one': 'instance.web.search.ManyToOneField', + 'many2many': 'instance.web.search.CharField', + 'one2many': 'instance.web.search.CharField' }); -openerp.web.search.Invalid = openerp.web.Class.extend( /** @lends openerp.web.search.Invalid# */{ +instance.web.search.Invalid = instance.web.Class.extend( /** @lends instance.web.search.Invalid# */{ /** * Exception thrown by search widgets when they hold invalid values, * which they can not return when asked. * - * @constructs openerp.web.search.Invalid - * @extends openerp.web.Class + * @constructs instance.web.search.Invalid + * @extends instance.web.Class * * @param field the name of the field holding an invalid value * @param value the invalid value @@ -723,13 +723,13 @@ openerp.web.search.Invalid = openerp.web.Class.extend( /** @lends openerp.web.se ); } }); -openerp.web.search.Widget = openerp.web.OldWidget.extend( /** @lends openerp.web.search.Widget# */{ +instance.web.search.Widget = instance.web.OldWidget.extend( /** @lends instance.web.search.Widget# */{ template: null, /** * Root class of all search widgets * - * @constructs openerp.web.search.Widget - * @extends openerp.web.OldWidget + * @constructs instance.web.search.Widget + * @extends instance.web.OldWidget * * @param view the ancestor view of this widget */ @@ -738,14 +738,14 @@ openerp.web.search.Widget = openerp.web.OldWidget.extend( /** @lends openerp.web this.view = view; } }); -openerp.web.search.add_expand_listener = function($root) { +instance.web.search.add_expand_listener = function($root) { $root.find('a.searchview_group_string').click(function (e) { $root.toggleClass('folded expanded'); e.stopPropagation(); e.preventDefault(); }); }; -openerp.web.search.Group = openerp.web.search.Widget.extend({ +instance.web.search.Group = instance.web.search.Widget.extend({ template: 'SearchView.group', init: function (view_section, view, fields) { this._super(view); @@ -755,10 +755,10 @@ openerp.web.search.Group = openerp.web.search.Widget.extend({ } }); -openerp.web.search.Input = openerp.web.search.Widget.extend( /** @lends openerp.web.search.Input# */{ +instance.web.search.Input = instance.web.search.Widget.extend( /** @lends instance.web.search.Input# */{ /** - * @constructs openerp.web.search.Input - * @extends openerp.web.search.Widget + * @constructs instance.web.search.Input + * @extends instance.web.search.Widget * * @param view */ @@ -784,7 +784,7 @@ openerp.web.search.Input = openerp.web.search.Widget.extend( /** @lends openerp. * they apply to this widget, or null if they don't. * * This default implementation will try calling - * :js:func:`openerp.web.search.Input#facet_for` if the widget's name + * :js:func:`instance.web.search.Input#facet_for` if the widget's name * matches the input key * * @param {Object} defaults @@ -820,17 +820,17 @@ openerp.web.search.Input = openerp.web.search.Widget.extend( /** @lends openerp. this.attrs = attrs; } }); -openerp.web.search.FilterGroup = openerp.web.search.Input.extend(/** @lends openerp.web.search.FilterGroup# */{ +instance.web.search.FilterGroup = instance.web.search.Input.extend(/** @lends instance.web.search.FilterGroup# */{ template: 'SearchView.filters', /** * Inclusive group of filters, creates a continuous "button" with clickable * sections (the normal display for filters is to be a self-contained button) * - * @constructs openerp.web.search.FilterGroup - * @extends openerp.web.search.Input + * @constructs instance.web.search.FilterGroup + * @extends instance.web.search.Input * - * @param {Array} filters elements of the group - * @param {openerp.web.SearchView} view view in which the filters are contained + * @param {Array} filters elements of the group + * @param {instance.web.SearchView} view view in which the filters are contained */ init: function (filters, view) { this._super(view); @@ -868,7 +868,7 @@ openerp.web.search.FilterGroup = openerp.web.search.Input.extend(/** @lends open if (!contexts.length) { return; } if (contexts.length === 1) { return contexts[0]; } - return _.extend(new openerp.web.CompoundContext, { + return _.extend(new instance.web.CompoundContext, { __contexts: contexts }); }, @@ -901,7 +901,7 @@ openerp.web.search.FilterGroup = openerp.web.search.Input.extend(/** @lends open for (var i=domains.length; --i;) { domains.unshift(['|']); } - return _.extend(new openerp.web.CompoundDomain(), { + return _.extend(new instance.web.CompoundDomain(), { __domains: domains }); }, @@ -945,7 +945,7 @@ openerp.web.search.FilterGroup = openerp.web.search.Input.extend(/** @lends open }); } }); -openerp.web.search.Filter = openerp.web.search.Input.extend(/** @lends openerp.web.search.Filter# */{ +instance.web.search.Filter = instance.web.search.Input.extend(/** @lends instance.web.search.Filter# */{ template: 'SearchView.filter', /** * Implementation of the OpenERP filters (button with a context and/or @@ -955,8 +955,8 @@ openerp.web.search.Filter = openerp.web.search.Input.extend(/** @lends openerp.w * domains and contexts, converting between facets and filters) is * performed by the filter group. * - * @constructs openerp.web.search.Filter - * @extends openerp.web.search.Input + * @constructs instance.web.search.Filter + * @extends instance.web.search.Input * * @param node * @param view @@ -969,12 +969,12 @@ openerp.web.search.Filter = openerp.web.search.Input.extend(/** @lends openerp.w get_context: function () { }, get_domain: function () { }, }); -openerp.web.search.Field = openerp.web.search.Input.extend( /** @lends openerp.web.search.Field# */ { +instance.web.search.Field = instance.web.search.Input.extend( /** @lends instance.web.search.Field# */ { template: 'SearchView.field', default_operator: '=', /** - * @constructs openerp.web.search.Field - * @extends openerp.web.search.Input + * @constructs instance.web.search.Field + * @extends instance.web.search.Input * * @param view_section * @param field @@ -1005,7 +1005,7 @@ openerp.web.search.Field = openerp.web.search.Input.extend( /** @lends openerp.w if (!(has_value && context)) { return; } - return new openerp.web.CompoundContext(context) + return new instance.web.CompoundContext(context) .set_eval_context({self: val}); }, get_groupby: function () { }, @@ -1036,7 +1036,7 @@ openerp.web.search.Field = openerp.web.search.Input.extend( /** @lends openerp.w this.attrs.operator || this.default_operator, facet); } - return new openerp.web.CompoundDomain(domain) + return new instance.web.CompoundDomain(domain) .set_eval_context({self: val}); } }); @@ -1048,9 +1048,9 @@ openerp.web.search.Field = openerp.web.search.Input.extend( /** @lends openerp.w * * The Javascript and the HTML values are identical (strings) * * @class - * @extends openerp.web.search.Field + * @extends instance.web.search.Field */ -openerp.web.search.CharField = openerp.web.search.Field.extend( /** @lends openerp.web.search.CharField# */ { +instance.web.search.CharField = instance.web.search.Field.extend( /** @lends instance.web.search.CharField# */ { default_operator: 'ilike', complete: function (value) { if (_.isEmpty(value)) { return $.when(null); } @@ -1066,7 +1066,7 @@ openerp.web.search.CharField = openerp.web.search.Field.extend( /** @lends opene }]); } }); -openerp.web.search.NumberField = openerp.web.search.Field.extend(/** @lends openerp.web.search.NumberField# */{ +instance.web.search.NumberField = instance.web.search.Field.extend(/** @lends instance.web.search.NumberField# */{ get_value: function () { if (!this.$element.val()) { return null; @@ -1075,7 +1075,7 @@ openerp.web.search.NumberField = openerp.web.search.Field.extend(/** @lends open check = Number(this.$element.val()); if (isNaN(val) || val !== check) { this.$element.addClass('error'); - throw new openerp.web.search.Invalid( + throw new instance.web.search.Invalid( this.attrs.name, this.$element.val(), this.error_message); } this.$element.removeClass('error'); @@ -1084,13 +1084,13 @@ openerp.web.search.NumberField = openerp.web.search.Field.extend(/** @lends open }); /** * @class - * @extends openerp.web.search.NumberField + * @extends instance.web.search.NumberField */ -openerp.web.search.IntegerField = openerp.web.search.NumberField.extend(/** @lends openerp.web.search.IntegerField# */{ +instance.web.search.IntegerField = instance.web.search.NumberField.extend(/** @lends instance.web.search.IntegerField# */{ error_message: _t("not a valid integer"), parse: function (value) { try { - return openerp.web.parse_value(value, {'widget': 'integer'}); + return instance.web.parse_value(value, {'widget': 'integer'}); } catch (e) { return NaN; } @@ -1098,13 +1098,13 @@ openerp.web.search.IntegerField = openerp.web.search.NumberField.extend(/** @len }); /** * @class - * @extends openerp.web.search.NumberField + * @extends instance.web.search.NumberField */ -openerp.web.search.FloatField = openerp.web.search.NumberField.extend(/** @lends openerp.web.search.FloatField# */{ +instance.web.search.FloatField = instance.web.search.NumberField.extend(/** @lends instance.web.search.FloatField# */{ error_message: _t("not a valid number"), parse: function (value) { try { - return openerp.web.parse_value(value, {'widget': 'float'}); + return instance.web.parse_value(value, {'widget': 'float'}); } catch (e) { return NaN; } @@ -1112,9 +1112,9 @@ openerp.web.search.FloatField = openerp.web.search.NumberField.extend(/** @lends }); /** * @class - * @extends openerp.web.search.Field + * @extends instance.web.search.Field */ -openerp.web.search.SelectionField = openerp.web.search.Field.extend(/** @lends openerp.web.search.SelectionField# */{ +instance.web.search.SelectionField = instance.web.search.Field.extend(/** @lends instance.web.search.SelectionField# */{ // This implementation is a basic + + + + + + +