Commit 2bead3b5 authored by Aurel's avatar Aurel

Merge remote-tracking branch 'origin/master' into cmf_upgrade_versions

parents bade10f8 25ce6bb7
......@@ -6,6 +6,7 @@ person = context.getDestinationDecisionValue(portal_type="Person")
# Person Mapping
person_mapping = (
# (credential, person)
('social_title', 'social_title'),
('first_name', 'first_name'),
('last_name', 'last_name'),
('gender', 'gender'),
......
......@@ -111,6 +111,7 @@
<key> <string>left (Personal Information)</string> </key>
<value>
<list>
<string>my_social_title</string>
<string>my_first_name</string>
<string>my_last_name</string>
<string>my_gender</string>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>title</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>my_social_title</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_view_mode_category</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Title</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -2017,7 +2017,7 @@ def calculateHateoas(is_portal=None, is_site_root=None, traversed_document=None,
elif isinstance(default_field_value, datetime.date):
default_field_value = formatdate(time.mktime(default_field_value.timetuple()))
contents_item[select] = default_field_value
contents_item[select] = ensureUTF8(default_field_value)
else:
# If the contents_item has field rendering in it, better is to add an
......
......@@ -81,9 +81,9 @@ def createIndexedDocument(quantity=1):
def decorator(func):
def wrapped(self, *args, **kwargs):
wipeFolder(self.portal.foo_module)
if quantity <= 1:
if quantity == 1:
kwargs.update(document=self._makeDocument())
else:
elif quantity > 1:
kwargs.update(document_list=[self._makeDocument() for _ in range(quantity)])
self.portal.portal_caches.clearAllCache()
self.tic()
......@@ -2332,6 +2332,31 @@ return context.getPortalObject().portal_catalog(portal_type='Foo', sort_on=[('id
self.assertEqual(result_dict['_embedded']['_view']['listbox']['selection_name'], selection_name)
self.assertEqual(result_dict['_embedded']['_view']['listbox']['checked_uid_list'], [9876, 1234])
@simulate('Base_getRequestUrl', '*args, **kwargs', 'return "http://example.org/bar"')
@simulate('Base_getRequestHeader', '*args, **kwargs', 'return "application/hal+json"')
@createIndexedDocument(quantity=1)
@changeSkin('Hal')
def test_getHateoas_property_corrupted_encoding(self, document):
# this sequence of bytes does not encode to UTF-8
document.setTitle('\xe9\xcf\xf3\xaf')
# self.tic()
fake_request = do_fake_request("GET")
result = self.portal.web_site_module.hateoas.ERP5Document_getHateoas(
REQUEST=fake_request,
mode="search",
query='uid:"%s"' % document.getUid(),
select_list=['title'],
)
self.assertEquals(fake_request.RESPONSE.status, 200)
self.assertEquals(fake_request.RESPONSE.getHeader('Content-Type'),
"application/hal+json"
)
result_dict = json.loads(result)
self.assertEqual(len(result_dict['_embedded']['contents']), 1)
self.assertEqual(result_dict['_embedded']['contents'][0]["title"], u'\ufffd\ufffd\ufffd')
class TestERP5Person_getHateoas_mode_search(ERP5HALJSONStyleSkinsMixin):
"""Test HAL_JSON operations on cataloged Persons and other allowed content types of Person Module."""
......
......@@ -86,32 +86,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......@@ -146,32 +146,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -111,32 +111,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -86,32 +86,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......@@ -157,31 +157,31 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
\ No newline at end of file
......@@ -111,32 +111,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -88,32 +88,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......@@ -148,32 +148,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<!-- This part (actually loading the notebook) requires a recent version
......
......@@ -111,32 +111,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -111,32 +111,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -86,32 +86,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForOnlyOffice/macros/wait_for_load_presentation"/>
......@@ -167,32 +167,32 @@
<tal:block metal:use-macro="here/Zuite_CommonTemplateForOnlyOffice/macros/wait_for_load_presentation"/>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -111,32 +111,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -86,32 +86,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForOnlyOffice/macros/wait_for_load_spreadsheet"/>
......@@ -167,32 +167,32 @@
<tal:block metal:use-macro="here/Zuite_CommonTemplateForOnlyOffice/macros/wait_for_load_spreadsheet"/>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -86,32 +86,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForOnlyOffice/macros/wait_for_load"/>
......@@ -167,32 +167,32 @@
<tal:block metal:use-macro="here/Zuite_CommonTemplateForOnlyOffice/macros/wait_for_load"/>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -111,32 +111,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -87,32 +87,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......@@ -152,31 +152,31 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
\ No newline at end of file
......@@ -111,32 +111,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -88,32 +88,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
......@@ -160,32 +160,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
......
......@@ -111,32 +111,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -306,7 +306,7 @@
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='field_your_description']</td>
<td>This is a reply test</td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/submit_dialog" />
......
......@@ -87,32 +87,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......@@ -158,31 +158,31 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
\ No newline at end of file
......@@ -111,32 +111,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -91,32 +91,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......@@ -163,32 +163,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......@@ -240,12 +240,12 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
......@@ -255,7 +255,7 @@
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${cloned_title}</td>
</tr>
<tr>
......@@ -309,32 +309,32 @@
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${cloned_title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -90,32 +90,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......@@ -162,32 +162,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......@@ -228,12 +228,12 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
......@@ -243,7 +243,7 @@
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${cloned_title}</td>
</tr>
<tr>
......@@ -297,32 +297,32 @@
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${cloned_title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -111,32 +111,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......
......@@ -86,32 +86,32 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>type</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
<tr>
......@@ -157,31 +157,31 @@
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Title']</td>
<td>//input[@name='title']</td>
<td>${title}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Reference']</td>
<td>//input[@name='reference']</td>
<td>${reference}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Version']</td>
<td>//input[@name='version']</td>
<td>${version}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@title='Language']</td>
<td>//input[@name='language']</td>
<td>${language}</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//textarea[@title='Description']</td>
<td>//textarea[@name='description']</td>
<td>${description}</td>
</tr>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ActionInformation" module="Products.CMFCore.ActionInformation"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>action</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>categories</string> </key>
<value>
<tuple>
<string>action_type/object_view</string>
</tuple>
</value>
</item>
<item>
<key> <string>category</string> </key>
<value> <string>object_view</string> </value>
</item>
<item>
<key> <string>condition</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>icon</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>xhtml_style_preference</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
<value>
<tuple>
<string>View</string>
</tuple>
</value>
</item>
<item>
<key> <string>priority</string> </key>
<value> <float>50.0</float> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>XHTML</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
<value> <int>1</int> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/SystemPreference_viewXhtmlStyleDisabled</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Alarm" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>active_sense_method_id</string> </key>
<value> <string>Alarm_disableXHtmlStyle</string> </value>
</item>
<item>
<key> <string>automatic_solve</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>alarm_disable_xhtml_style</string> </value>
</item>
<item>
<key> <string>periodicity_day_frequency</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>periodicity_hour</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>periodicity_hour_frequency</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>periodicity_minute</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>periodicity_minute_frequency</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>periodicity_month</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>periodicity_month_day</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>periodicity_start_date</string> </key>
<value>
<object>
<klass>
<global name="DateTime" module="DateTime.DateTime"/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>1608048660.0</float>
<string>GMT</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key> <string>periodicity_week</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Alarm</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Disable XHtml Style</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Alarm" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>active_sense_method_id</string> </key>
<value> <string>Alarm_enableXHtmlStyle</string> </value>
</item>
<item>
<key> <string>automatic_solve</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>alarm_enable_xhtml_style</string> </value>
</item>
<item>
<key> <string>periodicity_day_frequency</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>periodicity_hour</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>periodicity_hour_frequency</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>periodicity_minute</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>periodicity_minute_frequency</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>periodicity_month</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>periodicity_month_day</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>periodicity_start_date</string> </key>
<value>
<object>
<klass>
<global name="DateTime" module="DateTime.DateTime"/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>1608048660.0</float>
<string>GMT</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key> <string>periodicity_week</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Alarm</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Enable XHtml Style</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -23,7 +23,7 @@
editable: field_json.editable,
id: field_json.key,
name: field_json.key,
title: field_json.title,
title: field_json.description,
error_text: field_json.error_text,
hidden: field_json.hidden,
// Force calling subfield render
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>987.16243.63478.16486</string> </value>
<value> <string>988.26496.42040.8686</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1602527335.51</float>
<float>1609253252.87</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -64,7 +64,7 @@
id: field_json.key,
name: field_json.key,
key: field_json.key,
title: field_json.title,
title: field_json.description,
error_text: field_json.error_text,
timezone_style: field_json.timezone_style,
date_only: field_json.date_only,
......
......@@ -228,7 +228,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>986.51894.21525.38502</string> </value>
<value> <string>988.26496.42040.8686</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -246,7 +246,7 @@
</tuple>
<state>
<tuple>
<float>1600894302.31</float>
<float>1609253131.45</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -13,7 +13,7 @@
value: field_json.value || field_json.default || "",
editable: field_json.editable,
name: field_json.key,
title: field_json.title,
title: field_json.description,
hidden: field_json.hidden,
// Force calling subfield render
// as user may have modified the input value
......
......@@ -240,7 +240,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>969.56695.26145.14506</string> </value>
<value> <string>988.25406.64322.64716</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -258,7 +258,7 @@
</tuple>
<state>
<tuple>
<float>1535383243.32</float>
<float>1609253329.45</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -15,7 +15,7 @@
editable: field_json.editable,
required: field_json.required,
name: field_json.key,
title: field_json.title,
title: field_json.description,
type: 'email',
hidden: field_json.hidden,
// Force calling subfield render
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>965.241.13759.3805</string> </value>
<value> <string>988.25406.64322.64716</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1517321664.03</float>
<float>1609253291.34</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -28,7 +28,7 @@
editable: field_json.editable,
required: field_json.required,
name: field_json.key,
title: field_json.title,
title: field_json.description,
hidden: field_json.hidden,
view: field_json.view,
// field_json._embedded is HATEOASed subobj specs included in FormBox
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>986.61483.49376.1638</string> </value>
<value> <string>988.26496.42040.8686</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1601393999.02</float>
<float>1609253301.89</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -15,7 +15,7 @@
editable: field_json.editable,
required: field_json.required,
name: field_json.key,
title: field_json.title,
title: field_json.description,
hidden: field_json.hidden,
// Force calling subfield render
// as user may have modified the input value
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>983.13203.65355.60228</string> </value>
<value> <string>988.25406.64322.64716</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1586873574.82</float>
<float>1609253314.08</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -33,7 +33,7 @@
hidden: field_json.hidden,
id: field_json.key,
name: field_json.key,
title: field_json.title,
title: field_json.description,
precision: window.parseFloat(field_json.precision),
error_text: field_json.error_text,
// erp5 always put value into "default" (never "value")
......
......@@ -220,7 +220,7 @@
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>nicolas</string> </value>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>986.14570.51196.18756</string> </value>
<value> <string>988.26496.42040.8686</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1598579261.92</float>
<float>1609253214.03</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -19,7 +19,7 @@
id: field_json.key,
error_text: options.field_json.error_text || "",
name: field_json.key,
title: field_json.title,
title: field_json.description,
hidden: field_json.hidden,
// Force calling subfield render
// as user may have modified the input value
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>986.11537.50394.34935</string> </value>
<value> <string>988.26496.42040.8686</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1598397556.71</float>
<float>1609253348.53</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>986.32404.49746.11571</string> </value>
<value> <string>988.26965.13575.15547</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1601565748.05</float>
<float>1607016321.86</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -20,7 +20,7 @@
"editable": options.field_json.editable,
"required": options.field_json.required,
"hidden": options.field_json.hidden,
"title": options.field_json.title,
"title": options.field_json.description,
"key": options.field_json.key,
// Force calling subfield render
// as user may have modified the input value
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>964.58561.19908.14080</string> </value>
<value> <string>988.25406.64322.64716</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1517321571.05</float>
<float>1609253276.81</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -20,7 +20,7 @@
item_list: JSON.stringify(item_list),
required: field_json.required,
name: field_json.key,
title: field_json.title,
title: field_json.description,
first_item: field_json.first_item,
hidden: field_json.hidden,
error_text: field_json.error_text,
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>986.42821.5680.17442</string> </value>
<value> <string>988.26496.42040.8686</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1600275350.99</float>
<float>1609253338.77</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -43,7 +43,7 @@
editable: field_json.editable,
required: field_json.required,
name: field_json.key,
title: field_json.title,
title: field_json.description,
key: field_json.key,
sub_select_key: field_json.sub_select_key,
sub_input_key: field_json.sub_input_key,
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>977.38881.34981.23125</string> </value>
<value> <string>986.32404.49746.11571</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1570192783.86</float>
<float>1609253179.35</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -53,7 +53,7 @@
catalog_index: field_json.catalog_index,
allow_jump: field_json.allow_jump,
required: field_json.required,
title: field_json.title,
title: field_json.description,
key: field_json.key,
view: field_json.view,
search_view: field_json.search_view,
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>976.44236.22845.43076</string> </value>
<value> <string>988.25406.64322.64716</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1561643243.53</float>
<float>1609253156.62</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -67,6 +67,7 @@
workflow_list,
view_list,
action_list,
clone_list,
jump_list,
i;
......@@ -86,6 +87,7 @@
action_list = ensureArray(erp5_document._links.action_object_jio_action)
.concat(ensureArray(erp5_document._links.action_object_jio_button))
.concat(ensureArray(erp5_document._links.action_object_jio_fast_input));
clone_list = ensureArray(erp5_document._links.action_object_clone_action);
jump_list = ensureArray(erp5_document._links.action_object_jio_jump);
if (view === 'view') {
......@@ -102,6 +104,9 @@
for (i = 0; i < action_list.length; i += 1) {
action_list[i].class_name = action_list[i].href === view ? 'active' : '';
}
for (i = 0; i < clone_list.length; i += 1) {
clone_list[i].class_name = clone_list[i].href === view ? 'active' : '';
}
for (i = 0; i < jump_list.length; i += 1) {
jump_list[i].class_name = ((jump_list[i].href === jump_view) || (jump_list[i].href === view)) ? 'active' : '';
}
......@@ -111,6 +116,7 @@
workflow_list = JSON.stringify(workflow_list);
view_list = JSON.stringify(view_list);
action_list = JSON.stringify(action_list);
clone_list = JSON.stringify(clone_list);
jump_list = JSON.stringify(jump_list);
}
return context.getUrlParameter('editable')
......@@ -121,6 +127,7 @@
workflow_list: workflow_list,
view_list: view_list,
action_list: action_list,
clone_list: clone_list,
jump_list: jump_list,
global: true,
jio_key: jio_key,
......@@ -246,6 +253,7 @@
modification_dict.hasOwnProperty("jump_view") ||
modification_dict.hasOwnProperty("workflow_list") ||
modification_dict.hasOwnProperty("action_list") ||
modification_dict.hasOwnProperty("clone_list") ||
modification_dict.hasOwnProperty("jump_list") ||
modification_dict.hasOwnProperty("jio_key") ||
modification_dict.hasOwnProperty("view_list"))) {
......@@ -258,6 +266,7 @@
parameter_list = [],
view_list = JSON.parse(gadget.state.view_list),
action_list = JSON.parse(gadget.state.action_list),
clone_list = JSON.parse(gadget.state.clone_list),
jump_list = JSON.parse(gadget.state.jump_list);
workflow_list = JSON.parse(gadget.state.workflow_list);
......@@ -288,6 +297,16 @@
}
});
}
for (i = 0; i < clone_list.length; i += 1) {
parameter_list.push({
command: 'display_dialog_with_history',
options: {
jio_key: gadget.state.jio_key,
view: clone_list[i].href,
editable: true
}
});
}
for (i = 0; i < jump_list.length; i += 1) {
parameter_list.push({
command: 'display_dialog_with_history',
......@@ -308,6 +327,7 @@
dl_fragment = document.createDocumentFragment(),
view_list = JSON.parse(gadget.state.view_list),
action_list = JSON.parse(gadget.state.action_list),
clone_list = JSON.parse(gadget.state.clone_list),
jump_list = JSON.parse(gadget.state.jump_list);
appendDt(dl_fragment, result_list[1][0], 'eye',
......@@ -318,12 +338,12 @@
workflow_list, result_list[0], view_list.length);
}
appendDt(dl_fragment, result_list[1][2], 'cogs',
action_list, result_list[0],
action_list.concat(clone_list), result_list[0],
view_list.length + workflow_list.length);
appendDt(dl_fragment, result_list[1][3], 'plane',
jump_list, result_list[0],
view_list.length + workflow_list.length +
action_list.length);
action_list.length + clone_list.length);
dl_element = gadget.element.querySelector("dl");
while (dl_element.firstChild) {
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>987.27464.21813.55483</string> </value>
<value> <string>988.65434.35774.5563</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1604411452.55</float>
<float>1609322633.89</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -16,7 +16,7 @@
required: field_json.required,
id: field_json.key,
name: field_json.key,
title: field_json.title,
title: field_json.description,
type: 'password',
hidden: field_json.hidden,
// Force calling subfield render
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>965.12118.35525.1655</string> </value>
<value> <string>988.25406.64322.64716</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1517929207.17</float>
<float>1609253076.41</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -47,7 +47,7 @@
editable: field_json.editable,
error_text: field_json.error_text,
name: field_json.key,
title: field_json.title,
title: field_json.description,
item_list: field_json.items,
hidden: field_json.hidden,
// Force calling subfield render
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>987.27464.21813.55483</string> </value>
<value> <string>988.26496.42040.8686</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1603368485.32</float>
<float>1609253241.8</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -19,7 +19,7 @@
catalog_index: field_json.catalog_index,
allow_jump: field_json.allow_jump,
// required: field_json.required,
title: field_json.title,
title: field_json.description,
key: field_json.key,
view: field_json.view,
error_text: field_json.error_text,
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>986.41646.43198.36846</string> </value>
<value> <string>988.26496.42040.8686</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1600685092.05</float>
<float>1609253201.77</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -10,6 +10,7 @@
data-i18n=At least one (OR)
data-i18n=Contains
data-i18n=Equal to
data-i18n=Not equal to
data-i18n=Equal to (at least one)
data-i18n=Greater than
data-i18n=Less than
......
......@@ -238,7 +238,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>981.59263.63131.63590</string> </value>
<value> <string>986.51245.10858.8089</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -256,7 +256,7 @@
</tuple>
<state>
<tuple>
<float>1581947972.8</float>
<float>1609255883.37</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -7,11 +7,13 @@
var NUMERIC = [
["Equal to", "="], ["Greater than", ">"],
["Less than", "<"], ["Less than or Equal to", "<="],
["Greater than or Equal to", ">="]
["Greater than or Equal to", ">="],
["Not equal to", "!="]
],
OTHER = [
["Equal to", "exact_match"],
["Equal to (at least one)", "at_least_one_exact_match"],
["Not equal to", "!="],
["Contains", "keyword"]
],
DOMAIN = [
......@@ -701,7 +703,8 @@
'Less than or Equal to',
'Greater than or Equal to',
'Searchable Text',
'Search Expression'
'Search Expression',
'Not equal to'
])
.push(function (translation_list) {
var duplicated_query_key_dict = {},
......@@ -714,6 +717,7 @@
{
'Contains': translation_list[7],
'Equal to': translation_list[8],
'Not equal to': translation_list[16],
'Equal to (at least one)': translation_list[9],
'Greater than': translation_list[10],
'Less than': translation_list[11],
......@@ -819,7 +823,7 @@
if (query.operator === 'keyword') {
query.value = '%' + query.value + '%';
query.operator = '';
} else if (["", ">", "<", "<=", ">="].indexOf(query.operator) === -1) {
} else if (["", ">", "<", "<=", ">=", "!="].indexOf(query.operator) === -1) {
query.operator = '';
}
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>986.30784.11275.3089</string> </value>
<value> <string>988.64322.54806.6826</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1599552227.76</float>
<float>1609255951.43</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -17,7 +17,7 @@
id: field_json.key,
name: field_json.key,
error_text: field_json.error_text,
title: field_json.title,
title: field_json.description,
hidden: field_json.hidden,
trim: true,
// Force calling subfield render
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>986.42689.22481.46592</string> </value>
<value> <string>988.26496.42040.8686</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1600380471.64</float>
<float>1609253229.32</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -15,7 +15,7 @@
name: field_json.key,
id: field_json.key,
error_text: field_json.error_text,
title: field_json.title,
title: field_json.description,
hidden: field_json.hidden,
// Force calling subfield render
// as user may have modified the input value
......
......@@ -240,7 +240,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>986.42841.34859.34594</string> </value>
<value> <string>988.26496.42040.8686</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -258,7 +258,7 @@
</tuple>
<state>
<tuple>
<float>1600277966.0</float>
<float>1609253264.97</float>
<string>UTC</string>
</tuple>
</state>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Property Sheet" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_count</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>_mt_index</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>_tree</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAQ=</string> </persistent>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>HtmlStyleDisabledPreference</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Property Sheet</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="Length" module="BTrees.Length"/>
</pickle>
<pickle> <int>0</int> </pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="OOBTree" module="BTrees.OOBTree"/>
</pickle>
<pickle>
<none/>
</pickle>
</record>
<record id="4" aka="AAAAAAAAAAQ=">
<pickle>
<global name="OOBTree" module="BTrees.OOBTree"/>
</pickle>
<pickle>
<none/>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Standard Property" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_local_properties</string> </key>
<value>
<tuple>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>mode</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>string</string> </value>
</item>
</dictionary>
</tuple>
</value>
</item>
<item>
<key> <string>categories</string> </key>
<value>
<tuple>
<string>elementary_type/lines</string>
</tuple>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string>List of user ID who can still access xhtml style even if disallowed</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>preferred_html_style_allowed_user_id_property</string> </value>
</item>
<item>
<key> <string>mode</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Standard Property</string> </value>
</item>
<item>
<key> <string>preference</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>property_default</string> </key>
<value> <string>python: []</string> </value>
</item>
<item>
<key> <string>write_permission</string> </key>
<value> <string>Manage properties</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Standard Property" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>categories</string> </key>
<value>
<tuple>
<string>elementary_type/boolean</string>
</tuple>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string>When true, accessing xhtml style will raise a Forbidden error</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>preferred_html_style_disabled_property</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Standard Property</string> </value>
</item>
<item>
<key> <string>preference</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>property_default</string> </key>
<value> <string>python: False</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -3,4 +3,8 @@
<skin_folder>erp5_web_renderjs_ui</skin_folder>
<skin_selection>RJS</skin_selection>
</skin_folder_selection>
<skin_folder_selection>
<skin_folder>erp5_xhtml_disabled</skin_folder>
<skin_selection>View</skin_selection>
</skin_folder_selection>
</registered_skin_selection>
\ No newline at end of file
portal = context.getPortalObject()
portal_preferences = portal.portal_preferences
if not portal_preferences.isPreferredHtmlStyleDisabled():
system_preference = portal_preferences.getActiveSystemPreference()
if system_preference is None:
system_preference = portal_preferences.newContent(
portal_type="System Preference",
title="Created by Alarm",
activate_kw={'tag': tag})
system_preference.enable()
system_preference.edit(
preferred_html_style_disabled=True
)
context.activate(after_tag=tag).getId()
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>tag, fixit, params</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Alarm_disableXHtmlStyle</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
portal = context.getPortalObject()
portal_preferences = portal.portal_preferences
if portal_preferences.isPreferredHtmlStyleDisabled():
system_preference = portal_preferences.getActiveSystemPreference()
if system_preference is None:
system_preference = portal_preferences.newContent(
portal_type="System Preference",
title="Created by Alarm",
activate_kw={'tag': tag})
system_preference.enable()
system_preference.edit(
preferred_html_style_disabled=False
)
context.activate(after_tag=tag).getId()
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>tag, fixit, params</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Alarm_enableXHtmlStyle</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5 Form" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>action</string> </key>
<value> <string>Base_edit</string> </value>
</item>
<item>
<key> <string>action_title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>edit_order</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>encoding</string> </key>
<value> <string>UTF-8</string> </value>
</item>
<item>
<key> <string>enctype</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>group_list</string> </key>
<value>
<list>
<string>left</string>
<string>right</string>
<string>center</string>
</list>
</value>
</item>
<item>
<key> <string>groups</string> </key>
<value>
<dictionary>
<item>
<key> <string>center</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>left</string> </key>
<value>
<list>
<string>my_preferred_html_style_disabled</string>
<string>my_preferred_html_style_allowed_user_id_list</string>
</list>
</value>
</item>
<item>
<key> <string>right</string> </key>
<value>
<list/>
</value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>SystemPreference_viewXhtmlStyleDisabled</string> </value>
</item>
<item>
<key> <string>method</string> </key>
<value> <string>POST</string> </value>
</item>
<item>
<key> <string>name</string> </key>
<value> <string>Preference_viewAuthenticationPolicy</string> </value>
</item>
<item>
<key> <string>pt</string> </key>
<value> <string>form_view</string> </value>
</item>
<item>
<key> <string>row_length</string> </key>
<value> <int>4</int> </value>
</item>
<item>
<key> <string>stored_encoding</string> </key>
<value> <string>UTF-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Xhtml Style</string> </value>
</item>
<item>
<key> <string>unicode_mode</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>update_action</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>update_action_title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>title</string>
<string>width</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>my_preferred_html_style_allowed_user_id_list</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_lines_field</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Allowed User ID</string> </value>
</item>
<item>
<key> <string>width</string> </key>
<value> <int>20</int> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>title</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>my_preferred_html_style_disabled</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_checkbox</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Disable XHtml Style</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Folder" module="OFS.Folder"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_local_properties</string> </key>
<value>
<tuple>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>business_template_skin_layer_priority</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>float</string> </value>
</item>
</dictionary>
</tuple>
</value>
</item>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>business_template_skin_layer_priority</string> </key>
<value> <float>40.0</float> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>erp5_xhtml_disabled</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
from zExceptions import Forbidden
from AccessControl import getSecurityManager
preference_tool = context.getPortalObject().portal_preferences
if preference_tool.isPreferredHtmlStyleDisabled():
u = getSecurityManager().getUser()
user_id = u.getId()
if user_id not in preference_tool.getPreferredHtmlStyleAllowedUserIdList():
raise Forbidden('xhtml_style is disabled. Please use ERP5JS')
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Base_checkUserCanViewERP5XHTMLStyleOrRaise</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
System Preference | xhtml_style_preference
Web Manifest | version_view
Web Manifest | view
Web Manifest | view_editor
......
image_module/rjs_*
portal_alarms/alarm_disable_xhtml_style
portal_alarms/alarm_enable_xhtml_style
portal_contribution_registry/web_script_by_content
portal_contribution_registry/web_script_extension
portal_contribution_registry/web_script_mimetype
......
WebSiteRenderJSUpgradeConstraint
HtmlStyleDisabledPreference
\ No newline at end of file
erp5_web_renderjs_ui | RJS
erp5_xhtml_disabled | View
\ No newline at end of file
erp5_web_renderjs
erp5_web_renderjs_ui
erp5_xhtml_disabled
\ No newline at end of file
......@@ -105,7 +105,7 @@
<tr><td>verifyElementPresent</td>
<td>//div[@data-gadget-url="${renderjs_url}/gadget_erp5_field_listbox.html"]//table/tbody/tr[1]//input[@value="2016-12-24" and @type="date"]</td><td></td></tr>
<tr><td>verifyValue</td>
<td>//div[@data-gadget-url="${renderjs_url}/gadget_erp5_field_listbox.html"]//table/tbody/tr[1]//input[@title="Title"]</td>
<td>//div[@data-gadget-url="${renderjs_url}/gadget_erp5_field_listbox.html"]//table/tbody/tr[1]//input[contains(@name, "field_listbox_title_")]</td>
<td>FooLine</td></tr>
</tbody></table>
......
......@@ -99,12 +99,17 @@
</tr>
<tr>
<td>assertElementPresent</td>
<td>//div[@class='filter_item_container']/div[1]//select[2]//option[3][@value='keyword' and text()='Contains']</td>
<td>//div[@class='filter_item_container']/div[1]//select[2]//option[3][@value='!=' and text()='Not equal to']</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//div[@class='filter_item_container']/div[1]//select[2]//option[4][@value='keyword' and text()='Contains']</td>
<td></td>
</tr>
<tr>
<td>assertElementNotPresent</td>
<td>//div[@class='filter_item_container']/div[1]//select[2]//option[4]</td>
<td>//div[@class='filter_item_container']/div[1]//select[2]//option[5]</td>
<td></td>
</tr>
<tr>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testFilterNotEqualOperator</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal"
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test RenderJS UI</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">Test RenderJS UI</td></tr>
</thead><tbody>
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<!-- Clean Up -->
<tr>
<td>open</td>
<td>${base_url}/bar_module/ListBoxZuite_reset</td>
<td></td>
</tr>
<tr>
<td>assertTextPresent</td>
<td>Reset Successfully.</td>
<td></td>
</tr>
<tr>
<td>open</td>
<td>${base_url}/foo_module/FooModule_createObjects</td>
<td></td>
</tr>
<tr>
<td>assertTextPresent</td>
<td>Created Successfully.</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/wait_for_activities" />
<!-- Initialize -->
<tr>
<td>open</td>
<td>${base_url}/web_site_module/renderjs_runner/#/foo_module</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded" />
<tal:block tal:define="search_query python: 'title:!=&#34;31085&#34;'">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/search_in_form_list" />
</tal:block>
<!-- Open the panel and submit it. Check that the new query string is not to much changed -->
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/triggle_filter_and" />
<tal:block tal:define="filter_section_configuration python: {'key': 'COLUMN_title', 'value': '31085', 'index': 0, 'operator': '!='}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/check_filter_section" />
</tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/submit_filter" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tal:block tal:define="parsed_query python: 'title: != &#34;31085&#34;';
search_query python: ''">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/check_search_in_form_list" />
</tal:block>
<!-- Open the panel a second time and submit it. Check that the new query string is identical -->
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/triggle_filter_and" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/submit_filter" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tal:block tal:define="parsed_query python: 'title: != &#34;31085&#34;';
search_query python: ''">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/check_search_in_form_list" />
</tal:block>
</tbody></table>
</body>
</html>
\ No newline at end of file
......@@ -135,7 +135,7 @@
</tr>
<tr>
<td>click</td>
<td>//input[@name="field_your_seventh_failure" and @title="Seventh Failure"]</td>
<td>//input[@name="field_your_seventh_failure"]</td>
<td></td>
</tr>
<tr>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testFormViewMenuActionLink</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal"
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Page Front</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">Test Page Tab Link List</td></tr>
</thead><tbody>
<tal:block metal:use-macro="here/PTZuite_CommonTemplate/macros/init" />
<tr>
<td>open</td>
<td>${base_url}/web_site_module/renderjs_runner/#/foo_module/1</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<!-- Go to the action from the panel -->
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/open_menu_panel" />
<tr>
<td>assertElementPresent</td>
<td>//div[@data-gadget-scope='panel']//a[text()='Clone Document' and contains(@href, '#!display_dialog_with_history') and contains(@href, 'clone_document')]</td>
<td></td>
</tr>
<!-- Follow one link -->
<tal:block tal:define="click_configuration python: {'text': 'Clone Document'}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_panel_link" />
</tal:block>
<tal:block tal:define="notification_configuration python: {'class': 'success',
'text': 'Created Clone Foo.'}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_notification" />
</tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tr>
<td>assertElementPresent</td>
<td>//div[@data-gadget-url='${base_url}/web_site_module/renderjs_runner/gadget_erp5_pt_form_view_editable.html']</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/verify_is_editable_mode" />
</tbody></table>
</body>
</html>
\ No newline at end of file
......@@ -217,13 +217,13 @@
<tr>
<td>type</td>
<td>//tbody//tr[1]//input[@title="Quantity"]</td>
<td>//tbody//tr[1]//input[contains(@name, "field_listbox_quantity_")]</td>
<td>2.3</td>
</tr>
<tr>
<td>type</td>
<td>//tbody//tr[1]//input[@title="Quantity"]</td>
<td>//tbody//tr[1]//input[contains(@name, "field_listbox_quantity_")]</td>
<td>2.3</td>
</tr>
......@@ -236,7 +236,7 @@
<tr>
<td>type</td>
<td>//tbody//tr[2]//input[@title="Quantity"]</td>
<td>//tbody//tr[2]//input[contains(@name, "field_listbox_quantity_")]</td>
<td>10.1</td>
</tr>
......@@ -334,7 +334,7 @@
<tr>
<td>assertValue</td>
<td>//tbody//tr[1]//input[@title="Quantity"]</td>
<td>//tbody//tr[1]//input[contains(@name, "field_listbox_quantity_")]</td>
<td>2.3</td>
</tr>
......@@ -348,7 +348,7 @@
<tr>
<td>assertValue</td>
<td>//tbody//tr[2]//input[@title="Quantity"]</td>
<td>//tbody//tr[2]//input[contains(@name, "field_listbox_quantity_")]</td>
<td>10.1</td>
</tr>
......@@ -476,7 +476,7 @@
<tr>
<td>assertNotValue</td>
<td>//tbody//tr[1]//input[@title="Quantity"]</td>
<td>//tbody//tr[1]//input[contains(@name, "field_listbox_quantity_")]</td>
<td>2.3</td>
</tr>
......@@ -490,7 +490,7 @@
<tr>
<td>assertNotValue</td>
<td>//tbody//tr[2]//input[@title="Quantity"]</td>
<td>//tbody//tr[2]//input[contains(@name, "field_listbox_quantity_")]</td>
<td>10.1</td>
</tr>
......
......@@ -66,7 +66,7 @@
<tr>
<td>verifySelectOptions</td>
<td>//div[@class="filter_item_container"]/div[1]//select[2]</td>
<td>dengyu,dengyu(zhishaoyige),baohang</td>
<td>dengyu,dengyu(zhishaoyige),budengyu,baohang</td>
</tr>
......
......@@ -80,14 +80,14 @@
<tr>
<td>type</td>
<td>//input[@title="Short Title"]</td>
<td>field_my_short_title</td>
<td>test_clone</td>
</tr>
<tr>
<td>check</td>
<td>//input[@title="Frozen"]</td>
<td>field_my_frozen</td>
<td></td>
</tr>
......@@ -150,7 +150,7 @@
<tr>
<td>verifyValue</td>
<td>//input[@title='Frozen']</td>
<td>field_my_frozen</td>
<td>on</td>
</tr>
......@@ -182,7 +182,7 @@
<tr>
<td>waitForElementPresent</td>
<td>//input[@title="Short Title"]</td>
<td>field_my_short_title</td>
<td></td>
</tr>
......@@ -190,7 +190,7 @@
<tr>
<td>verifyValue</td>
<td>//input[@title="Short Title"]</td>
<td>field_my_short_title</td>
<td>test_clone</td>
</tr>
......@@ -202,7 +202,7 @@
<tr>
<td>verifyValue</td>
<td>//input[@title='Frozen']</td>
<td>field_my_frozen</td>
<td>on</td>
</tr>
......
......@@ -6,6 +6,7 @@ param_dict = [
{ 'message': 'Proceed', 'translation': 'jixu', 'language': 'wo'},
{ 'message': 'Title', 'translation': 'biaoti', 'language': 'wo'},
{ 'message': 'Equal to', 'translation': 'dengyu', 'language': 'wo'},
{ 'message': 'Not equal to', 'translation': 'budengyu', 'language': 'wo'},
{ 'message': 'Equal to (at least one)', 'translation': 'dengyu(zhishaoyige)', 'language': 'wo'},
{ 'message': 'Contains', 'translation': 'baohang', 'language': 'wo'},
{ 'message': 'Search', 'translation': 'soushuo', 'language': 'wo'},
......
......@@ -150,17 +150,16 @@ class BaseAmountDict(Implicit):
return value
def _getGeneratedAmountQuantity(self, base_amount, variation_category_list):
amount_generator_line = self.aq_base._amount_generator_line
try:
method = self._cache[(amount_generator_line, base_amount)]
method = self._cache[base_amount]
except KeyError:
method = amount_generator_line._getTypeBasedMethod(
method = self.aq_base._amount_generator_line._getTypeBasedMethod(
'getBaseAmountQuantityMethod')
if method is not None:
method = method(base_amount)
if method is None:
method = amount_generator_line.getBaseAmountQuantity
self._cache[(amount_generator_line, base_amount)] = method
method = self.aq_base._amount_generator_line.getBaseAmountQuantity
self._cache[base_amount] = method
if variation_category_list:
kw = dict(self._method_kw,
variation_category_list=variation_category_list)
......
......@@ -182,115 +182,4 @@
});
};
/** Internal function to prepare gadget to hold a mutex */
function ensureLockable(gadget) {
if (gadget.props === undefined) {
gadget.props = {};
}
// waiting_line is container of mutexes which already blocks some Promise
if (gadget.props.waiting_line === undefined) {
gadget.props.waiting_line = [];
}
}
/** Synchronously lock gadget and return previous lock's promise.
NON-RECURSIVE lock! If you lock inside locked execution you will wait forever.
If used in a Queue (@see lockGadgetInQueue) it blocks when acquiring the lock.
*/
window.lockGadget = function (gadget) {
var ahead_of_me;
ensureLockable(gadget);
// step in line
gadget.props.waiting_line.push(RSVP.defer());
if (gadget.props.waiting_line.length >= 2) {
// wait for the promise ahead of me
ahead_of_me = gadget.props.waiting_line[gadget.props.waiting_line.length - 2].promise;
} else {
ahead_of_me = RSVP.resolve();
}
// return previous lock's Promise to postpone execution
return ahead_of_me;
};
/** Lock gadget as a step in RSVP.Queue waiting for previous lock to unlock.
Use in RSVP.Queue to block execution until manually called `unlockGadget`.
Both lock/unlockGadget pass through any value in RSVP.Queue manner.
Pass through any value.
Example:
new RSVP.Queue()
.push(function () {return some_value;})
.push(lockGadgetInQueue(gadget), lockGadgetInFailedQueue(gadget))
.push(function (some_value) {return someWork(some_value);})
.push(unlockGadgetInQueue(gadget), unlockGadgetInFailedQueue(gadget));
*/
window.lockGadgetInQueue = function (gadget) {
// return function to be used in RSVP.Queue
return function (pass_through) {
return new RSVP.Queue()
.push(function () {
return window.lockGadget(gadget);
})
.push(function () {
return pass_through;
});
};
};
/** Lock Gagdet in Queue but intended to be used in "fail" branch (the second function).
Rethrows any argument.
*/
window.lockGadgetInFailedQueue = function (gadget) {
// return function to be used in RSVP.Queue
return function (error) {
return new RSVP.Queue()
.push(function () {
return window.lockGadget(gadget);
})
.push(function () {
throw error;
});
};
};
/** Synchronously unlock gadget by resolving props.mutex.promise.
That promise is most likely blocking some RSVP.Queue or is then-ed on another
Promise.
*/
window.unlockGadget = function (gadget) {
if (gadget.props === undefined ||
gadget.props.waiting_line === undefined ||
gadget.props.waiting_line.length === 0) {
throw new Error("Gadget " + gadget + " is not locked!");
}
gadget.props.waiting_line.shift().resolve();
};
/** Unlock gadget without blocking as a step in RSVP.Queue.
Pass through any value. Not re-throwing errors in fail branch!
For example @see lockGadgetInQueue.
*/
window.unlockGadgetInQueue = function (gadget) {
return function (pass_through) {
window.unlockGadget(gadget);
return pass_through;
};
};
/** Unlock gadget without blocking and throw any argument received. */
window.unlockGadgetInFailedQueue = function (gadget) {
return function (error) {
window.unlockGadget(gadget);
throw error;
};
};
}(window, RSVP, FileReader));
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment