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
from Products.ERP5.Document.Item import Item
from Products.ERP5.Document.TextDocument import TextDocument
class SoftwareLicence(Item, TextDocument):
class SoftwareLicence(TextDocument, Item):
"""
"""
......@@ -43,3 +43,19 @@ class SoftwareLicence(Item, TextDocument):
# Declarative security
security = ClassSecurityInfo()
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 @@
<item>
<key> <string>bottom</string> </key>
<value>
<list/>
<list>
<string>listbox</string>
</list>
</value>
</item>
<item>
......@@ -95,9 +97,7 @@
<item>
<key> <string>left</string> </key>
<value>
<list>
<string>listbox</string>
</list>
<list/>
</value>
</item>
<item>
......
......@@ -81,7 +81,7 @@
<value>
<list>
<string>iframe_content</string>
<string>text_content</string>
<string>my_text_content</string>
</list>
</value>
</item>
......
......@@ -12,12 +12,14 @@
<item>
<key> <string>delegated_list</string> </key>
<value>
<list/>
<list>
<string>enabled</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>text_content</string> </value>
<value> <string>my_text_content</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
......@@ -53,6 +55,10 @@
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>enabled</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
......@@ -72,6 +78,10 @@
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>enabled</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string>text_content</string> </value>
......
62
\ No newline at end of file
63
\ 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