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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Nicolas Wavrant
erp5
Commits
ba96bd2d
Commit
ba96bd2d
authored
Mar 14, 2018
by
Nicolas Wavrant
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_interface_post: action to export all exportable Letter Post in only one PDF document
parent
3e3908b7
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
291 additions
and
1 deletion
+291
-1
bt5/erp5_interface_post/ActionTemplateItem/portal_types/Letter%20Post%20Module/export_letter_post_list.xml
..._types/Letter%20Post%20Module/export_letter_post_list.xml
+85
-0
bt5/erp5_interface_post/SkinTemplateItem/portal_skins/erp5_interface_post/LetterPostModule_exportExportableLetterPost.py
...rface_post/LetterPostModule_exportExportableLetterPost.py
+18
-0
bt5/erp5_interface_post/SkinTemplateItem/portal_skins/erp5_interface_post/LetterPostModule_exportExportableLetterPost.xml
...face_post/LetterPostModule_exportExportableLetterPost.xml
+62
-0
bt5/erp5_interface_post/SkinTemplateItem/portal_skins/erp5_interface_post/LetterPostModule_exportExportableLetterPostDialog.xml
...ost/LetterPostModule_exportExportableLetterPostDialog.xml
+123
-0
bt5/erp5_interface_post/bt/dependency_list
bt5/erp5_interface_post/bt/dependency_list
+2
-1
bt5/erp5_interface_post/bt/template_action_path_list
bt5/erp5_interface_post/bt/template_action_path_list
+1
-0
No files found.
bt5/erp5_interface_post/ActionTemplateItem/portal_types/Letter%20Post%20Module/export_letter_post_list.xml
0 → 100644
View file @
ba96bd2d
<?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_action
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
category
</string>
</key>
<value>
<string>
object_action
</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>
export_letter_post_list
</string>
</value>
</item>
<item>
<key>
<string>
permissions
</string>
</key>
<value>
<tuple>
<string>
View
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Action Information
</string>
</value>
</item>
<item>
<key>
<string>
priority
</string>
</key>
<value>
<float>
5.0
</float>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Export Letter Posts
</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}/LetterPostModule_exportExportableLetterPostDialog
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_interface_post/SkinTemplateItem/portal_skins/erp5_interface_post/LetterPostModule_exportExportableLetterPost.py
0 → 100644
View file @
ba96bd2d
portal
=
context
.
getPortalObject
()
letter_post_list
=
context
.
searchFolder
(
simulation_state
=
'exportable'
)
merged_pdf_content
=
""
for
letter_post
in
letter_post_list
:
letter_post
=
letter_post
.
getObject
()
merged_pdf_content
=
portal
.
ERP5Site_mergePDFList
([
letter_post
.
getData
(),
letter_post
.
getData
()])
letter_post
.
activate
().
export
()
result_pdf
=
portal
.
document_module
.
newContent
(
portal_type
=
'PDF'
,
title
=
'Impression of Letter Post'
,
data
=
merged_pdf_content
,
)
return
result_pdf
.
Base_redirect
()
bt5/erp5_interface_post/SkinTemplateItem/portal_skins/erp5_interface_post/LetterPostModule_exportExportableLetterPost.xml
0 → 100644
View file @
ba96bd2d
<?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>
**kw
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
LetterPostModule_exportExportableLetterPost
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_interface_post/SkinTemplateItem/portal_skins/erp5_interface_post/LetterPostModule_exportExportableLetterPostDialog.xml
0 → 100644
View file @
ba96bd2d
<?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>
action
</string>
</key>
<value>
<string>
LetterPostModule_exportExportableLetterPost
</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>
<string>
bottom
</string>
<string>
hidden
</string>
</list>
</value>
</item>
<item>
<key>
<string>
groups
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
bottom
</string>
</key>
<value>
<list/>
</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>
<key>
<string>
id
</string>
</key>
<value>
<string>
LetterPostModule_exportExportableLetterPostDialog
</string>
</value>
</item>
<item>
<key>
<string>
method
</string>
</key>
<value>
<string>
POST
</string>
</value>
</item>
<item>
<key>
<string>
name
</string>
</key>
<value>
<string>
LetterPostModule_exportExportableLetterPostDialog
</string>
</value>
</item>
<item>
<key>
<string>
pt
</string>
</key>
<value>
<string>
form_dialog
</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>
Export Letter Posts
</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>
bt5/erp5_interface_post/bt/dependency_list
View file @
ba96bd2d
erp5_crm
erp5_dms
\ No newline at end of file
erp5_dms
erp5_pdf_merge
\ No newline at end of file
bt5/erp5_interface_post/bt/template_action_path_list
View file @
ba96bd2d
Internet Message Post Module | view
Internet Message Post | view
Internet Message Post | view_editor
Letter Post Module | export_letter_post_list
Letter Post Module | view
Letter Post | preview_pdf
Letter Post | view
...
...
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