Commit f3c98766 authored by Fabien Morin's avatar Fabien Morin

unify Licence from my project (wich is more advanced) with Licence from erp5_software_pdm

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@37085 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent cbaf23f0
...@@ -32,7 +32,7 @@ from Products.ERP5Type import Permissions, PropertySheet ...@@ -32,7 +32,7 @@ from Products.ERP5Type import Permissions, PropertySheet
from Products.ERP5.Document.Item import Item from Products.ERP5.Document.Item import Item
from Products.ERP5.Document.TextDocument import TextDocument from Products.ERP5.Document.TextDocument import TextDocument
class SoftwareLicence(Item, TextDocument): class SoftwareLicence(TextDocument, Item):
""" """
""" """
...@@ -43,3 +43,19 @@ class SoftwareLicence(Item, TextDocument): ...@@ -43,3 +43,19 @@ class SoftwareLicence(Item, TextDocument):
# Declarative security # Declarative security
security = ClassSecurityInfo() security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation) security.declareObjectProtected(Permissions.AccessContentsInformation)
def getSearchableText(self):
"""Text for full text search"""
text_list = []
for prop in ( self.getTitle(),
self.getDescription(),
self.getShortTitle(),
):
if prop:
text_list.append(str(prop))
for subject in self.getSubjectList():
text_list.append(str(subject))
return ' '.join(text_list)
SearchableText = getSearchableText
...@@ -77,7 +77,9 @@ ...@@ -77,7 +77,9 @@
<item> <item>
<key> <string>bottom</string> </key> <key> <string>bottom</string> </key>
<value> <value>
<list/> <list>
<string>listbox</string>
</list>
</value> </value>
</item> </item>
<item> <item>
...@@ -95,9 +97,7 @@ ...@@ -95,9 +97,7 @@
<item> <item>
<key> <string>left</string> </key> <key> <string>left</string> </key>
<value> <value>
<list> <list/>
<string>listbox</string>
</list>
</value> </value>
</item> </item>
<item> <item>
......
...@@ -81,7 +81,7 @@ ...@@ -81,7 +81,7 @@
<value> <value>
<list> <list>
<string>iframe_content</string> <string>iframe_content</string>
<string>text_content</string> <string>my_text_content</string>
</list> </list>
</value> </value>
</item> </item>
......
...@@ -12,12 +12,14 @@ ...@@ -12,12 +12,14 @@
<item> <item>
<key> <string>delegated_list</string> </key> <key> <string>delegated_list</string> </key>
<value> <value>
<list/> <list>
<string>enabled</string>
</list>
</value> </value>
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>text_content</string> </value> <value> <string>my_text_content</string> </value>
</item> </item>
<item> <item>
<key> <string>message_values</string> </key> <key> <string>message_values</string> </key>
...@@ -53,6 +55,10 @@ ...@@ -53,6 +55,10 @@
<key> <string>tales</string> </key> <key> <string>tales</string> </key>
<value> <value>
<dictionary> <dictionary>
<item>
<key> <string>enabled</string> </key>
<value> <string></string> </value>
</item>
<item> <item>
<key> <string>field_id</string> </key> <key> <string>field_id</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
...@@ -72,6 +78,10 @@ ...@@ -72,6 +78,10 @@
<key> <string>values</string> </key> <key> <string>values</string> </key>
<value> <value>
<dictionary> <dictionary>
<item>
<key> <string>enabled</string> </key>
<value> <int>1</int> </value>
</item>
<item> <item>
<key> <string>field_id</string> </key> <key> <string>field_id</string> </key>
<value> <string>text_content</string> </value> <value> <string>text_content</string> </value>
......
62 63
\ No newline at end of file \ 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