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
Labels
Merge Requests
7
Merge Requests
7
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Jérome Perrin
erp5
Commits
a6f74a19
Commit
a6f74a19
authored
May 02, 2023
by
Xiaowu Zhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_base&erp5_core_test: fix can't delete embedded file
parent
4350a316
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
0 deletions
+25
-0
bt5/erp5_base/WorkflowTemplateItem/portal_workflow/embedded_workflow/state_embedded.xml
...Item/portal_workflow/embedded_workflow/state_embedded.xml
+15
-0
bt5/erp5_core_test/TestTemplateItem/portal_components/test.erp5.testERP5Base.py
...tTemplateItem/portal_components/test.erp5.testERP5Base.py
+10
-0
No files found.
bt5/erp5_base/WorkflowTemplateItem/portal_workflow/embedded_workflow/state_embedded.xml
View file @
a6f74a19
...
@@ -12,6 +12,21 @@
...
@@ -12,6 +12,21 @@
<tuple/>
<tuple/>
</value>
</value>
</item>
</item>
<item>
<key>
<string>
categories
</string>
</key>
<value>
<tuple>
<string>
destination/portal_workflow/embedded_workflow/transition_delete
</string>
<string>
destination/portal_workflow/embedded_workflow/transition_delete_action
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<item>
<key>
<string>
description
</string>
</key>
<key>
<string>
description
</string>
</key>
<value>
<string>
This document is embedded (i.e. acquire its security from container)
</string>
</value>
<value>
<string>
This document is embedded (i.e. acquire its security from container)
</string>
</value>
...
...
bt5/erp5_core_test/TestTemplateItem/portal_components/test.erp5.testERP5Base.py
View file @
a6f74a19
...
@@ -1533,6 +1533,16 @@ class TestERP5Base(ERP5TypeTestCase):
...
@@ -1533,6 +1533,16 @@ class TestERP5Base(ERP5TypeTestCase):
self
.
assertEqual
(
'text/xml'
,
embedded_file
.
getContentType
())
self
.
assertEqual
(
'text/xml'
,
embedded_file
.
getContentType
())
self
.
assertEqual
(
'text/xml'
,
embedded_file
.
getProperty
(
'content_type'
))
self
.
assertEqual
(
'text/xml'
,
embedded_file
.
getProperty
(
'content_type'
))
def
test_EmbeddedFile_workflow
(
self
):
embedded_file
=
self
.
portal
.
person_module
.
newContent
(
portal_type
=
'Person'
).
newContent
(
portal_type
=
'Embedded File'
)
self
.
assertEqual
(
'embedded'
,
embedded_file
.
getValidationState
())
self
.
portal
.
portal_workflow
.
doActionFor
(
embedded_file
,
'delete_action'
)
self
.
assertEqual
(
'deleted'
,
embedded_file
.
getValidationState
())
def
test_BankAccount_validateIBAN
(
self
):
def
test_BankAccount_validateIBAN
(
self
):
self
.
assertTrue
(
self
.
assertTrue
(
self
.
portal
.
BankAccount_validateIBAN
(
self
.
portal
.
BankAccount_validateIBAN
(
...
...
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