Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Sven Franck
erp5
Commits
ead071d4
Commit
ead071d4
authored
Jan 06, 2012
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Convert worklist gadget to listbox representation.
parent
bd311fb1
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
411 additions
and
61 deletions
+411
-61
bt5/erp5_knowledge_pad/SkinTemplateItem/portal_skins/erp5_gadget/ERP5Site_getWorklistObjectList.xml
...rtal_skins/erp5_gadget/ERP5Site_getWorklistObjectList.xml
+81
-0
bt5/erp5_knowledge_pad/SkinTemplateItem/portal_skins/erp5_gadget/ERP5Site_viewWorklistGadget.xml
.../portal_skins/erp5_gadget/ERP5Site_viewWorklistGadget.xml
+110
-60
bt5/erp5_knowledge_pad/SkinTemplateItem/portal_skins/erp5_gadget/ERP5Site_viewWorklistGadget/listbox.xml
...skins/erp5_gadget/ERP5Site_viewWorklistGadget/listbox.xml
+152
-0
bt5/erp5_knowledge_pad/SkinTemplateItem/portal_skins/erp5_gadget/Worklist_getUrl.xml
...TemplateItem/portal_skins/erp5_gadget/Worklist_getUrl.xml
+67
-0
bt5/erp5_knowledge_pad/bt/revision
bt5/erp5_knowledge_pad/bt/revision
+1
-1
No files found.
bt5/erp5_knowledge_pad/SkinTemplateItem/portal_skins/erp5_gadget/ERP5Site_getWorklistObjectList.xml
0 → 100644
View file @
ead071d4
<?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>
_body
</string>
</key>
<value>
<string>
from Products.ERP5Type.Document import newTempDocument\n
return_list = []\n
i = 1\n
for worklist in context.portal_workflow.listActionInfos():\n
o = newTempDocument(context, str(i))\n
o.edit(\n
count=worklist[\'count\'],\n
title=worklist[\'title\'],\n
worklist_url=worklist[\'url\'],\n
\n
)\n
return_list.append(o)\n
i+=1\n
\n
return return_list\n
</string>
</value>
</item>
<item>
<key>
<string>
_params
</string>
</key>
<value>
<string>
*args, **kwargs
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
ERP5Site_getWorklistObjectList
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_knowledge_pad/SkinTemplateItem/portal_skins/erp5_gadget/ERP5Site_viewWorklistGadget.xml
View file @
ead071d4
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
<ZopeData>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<pickle>
<global
name=
"
ZopePageTemplate"
module=
"Products.PageTemplates.ZopePageTemplate
"
/>
<global
name=
"
ERP5Form"
module=
"Products.ERP5Form.Form
"
/>
</pickle>
</pickle>
<pickle>
<pickle>
<dictionary>
<dictionary>
...
@@ -19,12 +19,7 @@
...
@@ -19,12 +19,7 @@
<item>
<item>
<key>
<string>
_asgns
</string>
</key>
<key>
<string>
_asgns
</string>
</key>
<value>
<value>
<dictionary>
<dictionary/>
<item>
<key>
<string>
name_subpath
</string>
</key>
<value>
<string>
traverse_subpath
</string>
</value>
</item>
</dictionary>
</value>
</value>
</item>
</item>
</dictionary>
</dictionary>
...
@@ -33,68 +28,123 @@
...
@@ -33,68 +28,123 @@
</value>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
_text
</string>
</key>
<key>
<string>
_objects
</string>
</key>
<value>
<unicode
encoding=
"cdata"
>
<![CDATA[
<value>
<tuple/>
<tal:block tal:define="request python: context.REQUEST;\n
</value>
box_relative_url python: request.get(\'box_relative_url\',\'\');\n
</item>
box python: context.restrictedTraverse(box_relative_url);\n
<item>
preferences box/KnowledgeBox_getDefaultPreferencesDict;\n
<key>
<string>
action
</string>
</key>
actions python:getattr(context,\'portal_workflow\').listActionInfos();\n
<value>
<string></string>
</value>
absolute_url context/absolute_url;\n
</item>
portal_url context/portal_url;\n
<item>
box_id python: \'visual_\'+str(box.getId())">
\n
<key>
<string>
description
</string>
</key>
\n
<value>
<string></string>
</value>
<div
class=
"worklist_list"
>
\n
</item>
\n
<item>
<!-- Refresh -->
\n
<key>
<string>
edit_order
</string>
</key>
\n
<value>
<a
class=
"right"
\n
<list/>
tal:attributes=
"id python:\'title_\'+box.getId();\n
</value>
onclick python:context.KnowledgePad_generateAjaxCall(absolute_url+\'/\'+\'ERP5Site_viewWorklistGadget\',box,box_id)"
><img
alt =
""
src=
"refresh.png"
/></a>
\n
</item>
\n
<item>
<!-- Message if Worklists are empty -->
\n
<key>
<string>
encoding
</string>
</key>
\n
<value>
<string>
UTF-8
</string>
</value>
<h5
tal:condition=
"not:actions"
>
For the moment, all your worklists are empty
</h5>
\n
</item>
\n
<item>
<!-- List of Worklists -->
\n
<key>
<string>
enctype
</string>
</key>
\n
<value>
<string></string>
</value>
<ul
tal:condition=
"actions"
>
\n
</item>
<li
tal:repeat=
"action actions"
\n
<item>
tal:attributes=
"id python:\'li\'+box_id+\'_\'+str(repeat[\'action\'].index)"
>
\n
<key>
<string>
group_list
</string>
</key>
<tal:block
>
\n
<value>
<a
tal:attributes=
"href python: absolute_url+action[\'url\'][len(portal_url):]"
\n
<list>
tal:content=
"action/title"
></a>
\n
<string>
left
</string>
<div
tal:attributes=
"id python:\'div_\'+box.getId()+\'_\'+str(repeat[\'action\'].index)"
></div>
\n
<string>
right
</string>
</tal:block>
\n
<string>
center
</string>
</li>
\n
<string>
bottom
</string>
</ul>
\n
<string>
hidden
</string>
\n
</list>
</div>
\n
</value>
</tal:block>
\n
</item>
<item>
<key>
<string>
groups
</string>
</key>
]]>
</unicode>
</value>
<value>
</item>
<dictionary>
<item>
<item>
<key>
<string>
content_type
</string>
</key>
<key>
<string>
bottom
</string>
</key>
<value>
<string>
text/html
</string>
</value>
<value>
</item>
<list>
<item>
<string>
listbox
</string>
<key>
<string>
expand
</string>
</key>
</list>
<value>
<int>
0
</int>
</value>
</value>
</item>
<item>
<key>
<string>
center
</string>
</key>
<value>
<list/>
</value>
</item>
<item>
<key>
<string>
hidden
</string>
</key>
<value>
<list/>
</value>
</item>
<item>
<key>
<string>
left
</string>
</key>
<value>
<list/>
</value>
</item>
<item>
<key>
<string>
right
</string>
</key>
<value>
<list/>
</value>
</item>
</dictionary>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
id
</string>
</key>
<key>
<string>
id
</string>
</key>
<value>
<string>
ERP5Site_viewWorklistGadget
</string>
</value>
<value>
<string>
ERP5Site_viewWorklistGadget
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
output_encoding
</string>
</key>
<key>
<string>
method
</string>
</key>
<value>
<string>
utf-8
</string>
</value>
<value>
<string>
POST
</string>
</value>
</item>
<item>
<key>
<string>
name
</string>
</key>
<value>
<string>
ERP5Site_viewWorklistGadget
</string>
</value>
</item>
<item>
<key>
<string>
pt
</string>
</key>
<value>
<string>
gadget_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>
<item>
<item>
<key>
<string>
title
</string>
</key>
<key>
<string>
title
</string>
</key>
<value>
<unicode></unicode>
</value>
<value>
<string>
Worklists
</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>
</item>
</dictionary>
</dictionary>
</pickle>
</pickle>
...
...
bt5/erp5_knowledge_pad/SkinTemplateItem/portal_skins/erp5_gadget/ERP5Site_viewWorklistGadget/listbox.xml
0 → 100644
View file @
ead071d4
<?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>
columns
</string>
<string>
editable_columns
</string>
<string>
list_method
</string>
<string>
search
</string>
<string>
title
</string>
<string>
url_columns
</string>
</list>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
listbox
</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>
columns
</string>
</key>
<value>
<list>
<tuple>
<string>
title
</string>
<string>
Title
</string>
</tuple>
</list>
</value>
</item>
<item>
<key>
<string>
editable_columns
</string>
</key>
<value>
<list/>
</value>
</item>
<item>
<key>
<string>
field_id
</string>
</key>
<value>
<string>
my_gadget_listbox
</string>
</value>
</item>
<item>
<key>
<string>
form_id
</string>
</key>
<value>
<string>
Base_viewKnowledgePadFieldLibrary
</string>
</value>
</item>
<item>
<key>
<string>
list_method
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
search
</string>
</key>
<value>
<int>
0
</int>
</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>
Worklist
</string>
</value>
</item>
<item>
<key>
<string>
url_columns
</string>
</key>
<value>
<list>
<tuple>
<string>
title
</string>
<string>
Worklist_getUrl
</string>
</tuple>
</list>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"Method"
module=
"Products.Formulator.MethodField"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
method_name
</string>
</key>
<value>
<string>
ERP5Site_getWorklistObjectList
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_knowledge_pad/SkinTemplateItem/portal_skins/erp5_gadget/Worklist_getUrl.xml
0 → 100644
View file @
ead071d4
<?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>
_body
</string>
</key>
<value>
<string>
return context.getProperty(\'worklist_url\')\n
</string>
</value>
</item>
<item>
<key>
<string>
_params
</string>
</key>
<value>
<string>
*args, **kwargs
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
Worklist_getUrl
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_knowledge_pad/bt/revision
View file @
ead071d4
740
741
\ No newline at end of file
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment