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
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Roque
erp5
Commits
4922dd5b
Commit
4922dd5b
authored
Aug 10, 2020
by
Xiaowu Zhang
Browse files
Options
Browse Files
Download
Plain Diff
erp5_corporate_identity: display as data url for organisation logo
See merge request
nexedi/erp5!1233
parents
4f9569d2
413bec0c
Changes
14
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
1056 additions
and
12 deletions
+1056
-12
bt5/erp5_corporate_identity/SkinTemplateItem/portal_skins/erp5_corporate_identity/Base_getSourceDict.py
...ortal_skins/erp5_corporate_identity/Base_getSourceDict.py
+9
-8
bt5/erp5_corporate_identity/SkinTemplateItem/portal_skins/erp5_corporate_identity/Base_getTemplateProxyParameter.py
...erp5_corporate_identity/Base_getTemplateProxyParameter.py
+4
-1
bt5/erp5_corporate_identity/SkinTemplateItem/portal_skins/erp5_corporate_identity/WebPage_viewAsSlideshow.py
..._skins/erp5_corporate_identity/WebPage_viewAsSlideshow.py
+2
-2
bt5/erp5_corporate_identity_test/PathTemplateItem/image_module/template_test_slideshow_for_anonymous_en_bmp.bmp
...e_module/template_test_slideshow_for_anonymous_en_bmp.bmp
+0
-0
bt5/erp5_corporate_identity_test/PathTemplateItem/image_module/template_test_slideshow_for_anonymous_en_bmp.xml
...e_module/template_test_slideshow_for_anonymous_en_bmp.xml
+155
-0
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view.xml
...tion_module/template_test_organisation_for_slide_view.xml
+134
-0
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view/default_address.xml
...late_test_organisation_for_slide_view/default_address.xml
+38
-0
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view/default_bank_account.xml
...test_organisation_for_slide_view/default_bank_account.xml
+167
-0
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view/default_email.xml
...mplate_test_organisation_for_slide_view/default_email.xml
+30
-0
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view/default_image.xml
...mplate_test_organisation_for_slide_view/default_image.xml
+245
-0
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view/default_telephone.xml
...te_test_organisation_for_slide_view/default_telephone.xml
+30
-0
bt5/erp5_corporate_identity_test/PathTemplateItem/web_page_module/template_test_organisation_logo_in_slide_view.html
...module/template_test_organisation_logo_in_slide_view.html
+98
-0
bt5/erp5_corporate_identity_test/PathTemplateItem/web_page_module/template_test_organisation_logo_in_slide_view.xml
..._module/template_test_organisation_logo_in_slide_view.xml
+121
-0
bt5/erp5_corporate_identity_test/TestTemplateItem/portal_components/test.erp5.testCorporateIdentityTemplateList.py
...components/test.erp5.testCorporateIdentityTemplateList.py
+23
-1
No files found.
bt5/erp5_corporate_identity/SkinTemplateItem/portal_skins/erp5_corporate_identity/Base_getSourceDict.py
View file @
4922dd5b
...
@@ -26,7 +26,6 @@ if source is None:
...
@@ -26,7 +26,6 @@ if source is None:
source_person
=
None
source_person
=
None
source_person_list
=
[]
source_person_list
=
[]
source_organisation_list
=
[]
source_organisation_list
=
[]
source_set
=
None
# source person => override => contributor => source_decision
# source person => override => contributor => source_decision
if
override_source_person_title
is
not
None
or
override_source_person_title
==
blank
:
if
override_source_person_title
is
not
None
or
override_source_person_title
==
blank
:
...
@@ -102,14 +101,16 @@ if source.get("corporate_registration_code") is blank:
...
@@ -102,14 +101,16 @@ if source.get("corporate_registration_code") is blank:
# XXX images stored on organisation (as do images in skin folders)
# XXX images stored on organisation (as do images in skin folders)
if
override_logo_reference
:
if
override_logo_reference
:
source_logo_url
=
html_quote
(
override_logo_reference
)
+
"?format=png"
source_logo_url
=
html_quote
(
override_logo_reference
)
+
"?format=png"
source_set
=
True
else
:
if
source_logo_url
is
None
:
source_logo_url
=
source
.
get
(
"logo_url"
,
blank
)
source_logo_url
=
source
.
get
(
"logo_url"
,
blank
)
if
source_logo_url
!=
blank
and
source_set
is
None
:
if
source_logo_url
!=
blank
:
# XXX: test environment fails if url with parameters are supplied
# XXX: test environment fails if url with parameters are supplied
source_logo_url
=
source_logo_url
+
"?format=png"
source_logo_url
=
source_logo_url
+
"?format=png"
if
source_logo_url
==
blank
and
theme_logo_url
is
not
None
:
#logo_url is organisation default image, which is not accessible for anounymous
source_logo_url
=
theme_logo_url
source
[
"enhanced_logo_data_url"
]
=
source
.
get
(
"logo_data_url"
)
elif
theme_logo_url
is
not
None
:
source_logo_url
=
theme_logo_url
source
[
"enhanced_logo_url"
]
=
source_logo_url
source
[
"enhanced_logo_url"
]
=
source_logo_url
return
source
return
source
bt5/erp5_corporate_identity/SkinTemplateItem/portal_skins/erp5_corporate_identity/Base_getTemplateProxyParameter.py
View file @
4922dd5b
...
@@ -8,7 +8,7 @@ Return local parameters that require proxy role to access
...
@@ -8,7 +8,7 @@ Return local parameters that require proxy role to access
# pass_parameter (portal-) type of data to fetch
# pass_parameter (portal-) type of data to fetch
# pass_source_data followup uid or context for retrieving info
# pass_source_data followup uid or context for retrieving info
# pass_flag_site whether called from a web site (no follow-up)
# pass_flag_site whether called from a web site (no follow-up)
from
base64
import
b64encode
portal_type_valid_template_list
=
[
"Web Site"
,
"Web Section"
,
"Web Page"
,
"Letter"
]
portal_type_valid_template_list
=
[
"Web Site"
,
"Web Section"
,
"Web Page"
,
"Letter"
]
portal_type_valid_report_list
=
[
"Project"
,
"Sale Order"
,
"Sale Opportunity"
,
"Requirement Document"
,
"Person"
]
portal_type_valid_report_list
=
[
"Project"
,
"Sale Order"
,
"Sale Opportunity"
,
"Requirement Document"
,
"Person"
]
portal_type
=
context
.
getPortalType
()
portal_type
=
context
.
getPortalType
()
...
@@ -127,6 +127,9 @@ def populateOrganisationDict(my_organisation_list):
...
@@ -127,6 +127,9 @@ def populateOrganisationDict(my_organisation_list):
#output_dict["logo_url"] = organisation.getDefaultImageAbsoluteUrl() or err("logo_url")
#output_dict["logo_url"] = organisation.getDefaultImageAbsoluteUrl() or err("logo_url")
if
organisation_default_image
is
not
None
:
if
organisation_default_image
is
not
None
:
output_dict
[
"logo_url"
]
=
organisation_default_image
.
getRelativeUrl
()
output_dict
[
"logo_url"
]
=
organisation_default_image
.
getRelativeUrl
()
output_dict
[
"logo_data_url"
]
=
'data:image/png;;base64,%s'
%
(
b64encode
(
organisation_default_image
.
convert
(
format
=
"png"
,
display
=
"thumbnail"
)[
1
])
)
else
:
else
:
output_dict
[
"logo_url"
]
=
err
(
"logo_url"
)
output_dict
[
"logo_url"
]
=
err
(
"logo_url"
)
...
...
bt5/erp5_corporate_identity/SkinTemplateItem/portal_skins/erp5_corporate_identity/WebPage_viewAsSlideshow.py
View file @
4922dd5b
...
@@ -334,7 +334,7 @@ if doc_format == "html": #or doc_format == "mhtml":
...
@@ -334,7 +334,7 @@ if doc_format == "html": #or doc_format == "mhtml":
doc_theme_css_font_list=doc_theme.get("
theme_css_font_list
"),
doc_theme_css_font_list=doc_theme.get("
theme_css_font_list
"),
doc_theme_css_url=doc_theme.get("
theme_css_url
"),
doc_theme_css_url=doc_theme.get("
theme_css_url
"),
doc_footer_url_description=doc_theme.get("
theme_logo_description
"),
doc_footer_url_description=doc_theme.get("
theme_logo_description
"),
doc_footer_url=doc
.Base_setUrl(path=doc_source.get("
enhanced_logo_url
"), display=None
),
doc_footer_url=doc
_source.get("
enhanced_logo_data_url
", doc.Base_setUrl(path=doc_source.get("
enhanced_logo_url
"), display=None)
),
doc_description=doc_description,
doc_description=doc_description,
doc_creation_year=doc_creation_year,
doc_creation_year=doc_creation_year,
doc_copyright=doc_source.get("
organisation_title
", blank),
doc_copyright=doc_source.get("
organisation_title
", blank),
...
@@ -372,7 +372,7 @@ if doc_format == "pdf" or doc_format == "mhtml":
...
@@ -372,7 +372,7 @@ if doc_format == "pdf" or doc_format == "mhtml":
doc_theme_css_font_list=doc_theme.get("
theme_css_font_list
"),
doc_theme_css_font_list=doc_theme.get("
theme_css_font_list
"),
doc_theme_css_url=doc_theme.get("
theme_css_url
"),
doc_theme_css_url=doc_theme.get("
theme_css_url
"),
doc_footer_url_description=doc_theme.get("
theme_logo_description
"),
doc_footer_url_description=doc_theme.get("
theme_logo_description
"),
doc_footer_url=doc
.Base_setUrl(path=doc_source.get("
enhanced_logo_url
"), display=None
),
doc_footer_url=doc
_source.get("
enhanced_logo_data_url
", doc.Base_setUrl(path=doc_source.get("
enhanced_logo_url
"), display=None)
),
doc_description=doc_description,
doc_description=doc_description,
doc_creation_year=doc_creation_year,
doc_creation_year=doc_creation_year,
doc_copyright=doc_source.get("
organisation_title
", blank),
doc_copyright=doc_source.get("
organisation_title
", blank),
...
...
bt5/erp5_corporate_identity_test/PathTemplateItem/image_module/template_test_slideshow_for_anonymous_en_bmp.bmp
0 → 100644
View file @
4922dd5b
1.91 MB
bt5/erp5_corporate_identity_test/PathTemplateItem/image_module/template_test_slideshow_for_anonymous_en_bmp.xml
0 → 100644
View file @
4922dd5b
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Image"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_Access_contents_information_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Add_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Change_local_roles_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Modify_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_View_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<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>
content_md5
</string>
</key>
<value>
<string>
9fdf281f148030d11f0f3e72c1057e10
</string>
</value>
</item>
<item>
<key>
<string>
content_type
</string>
</key>
<value>
<string>
image/x-bmp
</string>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
Template.Test.Slideshow.Slide
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<string>
Screenshot generated from template_test_slideshow_input_001_en_pdf
</string>
</value>
</item>
<item>
<key>
<string>
height
</string>
</key>
<value>
<int>
595
</int>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
template_test_slideshow_for_anonymous_en_bmp
</string>
</value>
</item>
<item>
<key>
<string>
language
</string>
</key>
<value>
<string>
en
</string>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Image
</string>
</value>
</item>
<item>
<key>
<string>
short_title
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Template Test Slideshow Slide
</string>
</value>
</item>
<item>
<key>
<string>
version
</string>
</key>
<value>
<string>
001
</string>
</value>
</item>
<item>
<key>
<string>
width
</string>
</key>
<value>
<int>
842
</int>
</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>
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view.xml
0 → 100644
View file @
4922dd5b
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Organisation"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_Access_contents_information_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Author
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Add_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Author
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Modify_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Author
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_View_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Author
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<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>
categories
</string>
</key>
<value>
<tuple>
<string>
group/template_test_group
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
corporate_name
</string>
</key>
<value>
<string>
Template Test Organisation For Slide View
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<string>
Test Organisation for template testing
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
template_test_organisation_for_slide_view
</string>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Organisation
</string>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Template Test Organisation For Slide View
</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>
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view/default_address.xml
0 → 100644
View file @
4922dd5b
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Address"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
city
</string>
</key>
<value>
<string>
Test City
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
default_address
</string>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Address
</string>
</value>
</item>
<item>
<key>
<string>
sid
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
street_address
</string>
</key>
<value>
<string>
Test Drive 123
</string>
</value>
</item>
<item>
<key>
<string>
zip_code
</string>
</key>
<value>
<string>
12345
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view/default_bank_account.xml
0 → 100644
View file @
4922dd5b
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Bank Account"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_Access_contents_information_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Author
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Add_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Author
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Modify_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Author
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_View_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Author
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_local_properties
</string>
</key>
<value>
<tuple>
<dictionary>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
comment
</string>
</value>
</item>
<item>
<key>
<string>
type
</string>
</key>
<value>
<string>
string
</string>
</value>
</item>
</dictionary>
</tuple>
</value>
</item>
<item>
<key>
<string>
bank_account_holder_name
</string>
</key>
<value>
<string>
Template Test
</string>
</value>
</item>
<item>
<key>
<string>
bank_account_key
</string>
</key>
<value>
<string>
Foo
</string>
</value>
</item>
<item>
<key>
<string>
bank_account_number
</string>
</key>
<value>
<string>
0190 123 456
</string>
</value>
</item>
<item>
<key>
<string>
bank_code
</string>
</key>
<value>
<string>
12345
</string>
</value>
</item>
<item>
<key>
<string>
bank_country_code
</string>
</key>
<value>
<string>
12
</string>
</value>
</item>
<item>
<key>
<string>
branch
</string>
</key>
<value>
<string>
67890
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string>
Template Test
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<string>
Template Test Bank Account
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
default_bank_account
</string>
</value>
</item>
<item>
<key>
<string>
overdraft_facility
</string>
</key>
<value>
<int>
0
</int>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Bank Account
</string>
</value>
</item>
<item>
<key>
<string>
start_date
</string>
</key>
<value>
<object>
<klass>
<global
id=
"1.1"
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
946684800.0
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
stop_date
</string>
</key>
<value>
<object>
<klass>
<reference
id=
"1.1"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
4102358400.0
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Template Test Bank Account
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view/default_email.xml
0 → 100644
View file @
4922dd5b
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Email"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
coordinate_text
</string>
</key>
<value>
<string>
info@test-organisation.eu
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
default_email
</string>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Email
</string>
</value>
</item>
<item>
<key>
<string>
sid
</string>
</key>
<value>
<none/>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view/default_image.xml
0 → 100644
View file @
4922dd5b
This diff is collapsed.
Click to expand it.
bt5/erp5_corporate_identity_test/PathTemplateItem/organisation_module/template_test_organisation_for_slide_view/default_telephone.xml
0 → 100644
View file @
4922dd5b
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Telephone"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
coordinate_text
</string>
</key>
<value>
<string>
+123 456 789 0
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
default_telephone
</string>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Telephone
</string>
</value>
</item>
<item>
<key>
<string>
sid
</string>
</key>
<value>
<none/>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_corporate_identity_test/PathTemplateItem/web_page_module/template_test_organisation_logo_in_slide_view.html
0 → 100644
View file @
4922dd5b
<section
class=
"master"
>
<h1>
TOC
</h1>
<ul>
<li>
A
</li>
<li>
B
</li>
<li>
C
</li>
</ul>
</section>
<section
class=
"chapter"
>
<h1>
A
</h1>
</section>
<section>
<h1>
Test PNG as PNG
</h1>
<img
src=
"Template.Test.Image.Map?format=png"
alt=
""
/>
<ul>
<li>
Content
</li>
<li>
Content
</li>
<li>
Content
<a
href=
""
>
with link
</a></li>
<li>
Content
</li>
<li>
Content
</li>
</ul>
<details
open=
"open"
>
This is a sample image in png format rendered as png.
</details>
</section>
<section>
<h1>
Test PNG as SVG
</h1>
<img
src=
"Template.Test.Illustration.Reach?format=svg"
type=
"image/svg+xml"
alt=
""
/>
<details
open=
"open"
>
This is a sample image in svg format, not converted.
</details>
</section>
<section>
<h1>
Test SVG as PNG
</h1>
<img
src=
"Template.Test.Illustration.Stack?format=png"
alt=
""
/>
<div
style=
"font-size:10px;margin-top:0;text-align:center;"
>
<span>
Photo by
<a
target=
"_blank"
href=
""
>
Someone
</a>
/
<a
target=
"_blank"
href=
""
>
Source
</a></span>
</div>
<details
open=
"open"
>
This is a sample image in svg format, rendered as png. With Attribution
</details>
</section>
<section>
<h1>
Test HTML
</h1>
<div
style=
"padding: 1em;margin-bottom:16px;background-size:cover;background-image: url(); background-color: #ffffff; background-position: center"
>
<div
style=
"padding:8px 8px 0 8px;"
>
<span
style=
"color:#fff;text-align:left;display: block;font-weight:bold;margin:4px;padding:4px 4px 4px 1.5em;background-color: #33A8A8"
>
A
</span>
</div>
<div
style=
"padding:0 8px 0 8px;"
>
<span
style=
"color:#fff;text-align:left;display: block;font-weight:bold;margin:4px;padding:4px 4px 4px 1.5em;background-color: #434371"
>
B
</span>
</div>
<div
style=
"padding:0 8px 0 8px;"
>
<span
style=
"color:#fff;text-align:left;display: block;font-weight:bold;margin:4px;padding:4px 4px 4px 1.5em;background-color: #1C76BB"
>
C
</span>
</div>
<div
style=
"padding:0 8px 0 8px;"
>
<span
style=
"color:#fff;text-align:left;display: block;font-weight:bold;margin:4px;padding:4px 4px 4px 1.5em;background-color: #267B87"
>
D
</span>
</div>
<div
style=
"padding:0 8px 0 8px;"
>
<span
style=
"color:#fff;text-align:left;display: block;font-weight:bold;margin:4px;padding:4px 4px 4px 1.5em;background-color: #90C3D4"
>
E
</span>
</div>
<div
style=
"padding:0 8px 0 8px;"
>
<span
style=
"color:#fff;text-align:left;display: block;font-weight:bold;margin:4px;padding:4px 4px 4px 1.5em;background-color: #A9BCC2"
>
F
</span>
</div>
<div
style=
"padding:0 8px 0 8px;"
>
<span
style=
"color:#fff;text-align:left;display: block;font-weight:bold;margin:4px;padding:4px 4px 4px 1.5em;background-color: #000000"
>
G
</span>
</div>
</div>
<ul>
<li>
Content
</li>
</ul>
<details
open=
"open"
>
This is a sample graphic generated in HTML.
</details>
</section>
<section
class=
"master"
>
<h1>
Test Side by Side and Multiple Details
</h1>
<div>
<img
src=
"Template.Test.Image.Office?format=png&display=medium"
type=
"image/png"
alt=
""
/>
</div>
<div>
<ul
style=
"list-style:none;display:block;"
>
<li>
Content
</li>
<li>
Content
</li>
<li>
Content
</li>
<li>
Content
</li>
</ul>
</div>
<details
open=
"open"
>
<p>
This is a side by side content slide with multiple details subslides.
</p>
</details>
<details>
This is the second detail subslide.
</details>
</section>
bt5/erp5_corporate_identity_test/PathTemplateItem/web_page_module/template_test_organisation_logo_in_slide_view.xml
0 → 100644
View file @
4922dd5b
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Web Page"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_Access_contents_information_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Add_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Change_local_roles_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Modify_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_View_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
categories
</string>
</key>
<value>
<tuple>
<string>
follow_up/organisation_module/template_test_organisation_for_slide_view
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
content_md5
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
content_type
</string>
</key>
<value>
<string>
text/html
</string>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
Template.Test.Organisation.Logo.In.Slide.View
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
template_test_organisation_logo_in_slide_view
</string>
</value>
</item>
<item>
<key>
<string>
language
</string>
</key>
<value>
<string>
en
</string>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Web Page
</string>
</value>
</item>
<item>
<key>
<string>
short_title
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Template Test Organisation Logo In Slide View
</string>
</value>
</item>
<item>
<key>
<string>
version
</string>
</key>
<value>
<string>
001
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_corporate_identity_test/TestTemplateItem/portal_components/test.erp5.testCorporateIdentityTemplateList.py
View file @
4922dd5b
...
@@ -252,7 +252,7 @@ class TestCorporateIdentityTemplateList(ERP5TypeTestCase):
...
@@ -252,7 +252,7 @@ class TestCorporateIdentityTemplateList(ERP5TypeTestCase):
getattr
(
test_page
,
kw
.
get
(
"test_method"
)),
getattr
(
test_page
,
kw
.
get
(
"test_method"
)),
**
kw
**
kw
)
)
self
.
login
()
image_source_pdf_doc
.
setData
(
pdf_data
)
image_source_pdf_doc
.
setData
(
pdf_data
)
_
,
bmp
=
image_source_pdf_doc
.
convert
(
"bmp"
,
frame
=
kw
.
get
(
"page_number"
))
_
,
bmp
=
image_source_pdf_doc
.
convert
(
"bmp"
,
frame
=
kw
.
get
(
"page_number"
))
...
@@ -402,6 +402,28 @@ class TestCorporateIdentityTemplateList(ERP5TypeTestCase):
...
@@ -402,6 +402,28 @@ class TestCorporateIdentityTemplateList(ERP5TypeTestCase):
)
)
@
changeSkin
(
'Slide'
)
@
changeSkin
(
'Slide'
)
def
test_pdfSlideShowForAnonymous
(
self
):
"""
Test for anonymous:
- Web Page as Slideshow
- without follow up
- without contributor
- export as pdf
"""
self
.
logout
()
self
.
tic
()
self
.
runPdfTestPattern
(
"template_test_organisation_logo_in_slide_view"
,
"template_test_slideshow_for_anonymous_en_bmp"
,
"template_test_image_source_pdf"
,
**
dict
(
page_number
=
0
,
use_skin
=
"Slide"
,
test_method
=
"WebPage_exportAsSlideshow"
,
format
=
"pdf"
)
)
@
changeSkin
(
'Slide'
)
def
test_pdfSlideshowNotes
(
self
):
def
test_pdfSlideshowNotes
(
self
):
"""
"""
Test:
Test:
...
...
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