Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5_fork
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
Eteri
erp5_fork
Commits
11e8ee75
Commit
11e8ee75
authored
May 27, 2020
by
Arnaud Fontaine
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ZODB Components: erp5_inotify: Migrate InotifyTool from filesystem.
parent
a2b4c035
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
114 additions
and
6 deletions
+114
-6
bt5/erp5_inotify/TestTemplateItem/portal_components/test.erp5.testInotifyTool.py
...mplateItem/portal_components/test.erp5.testInotifyTool.py
+1
-1
bt5/erp5_inotify/ToolComponentTemplateItem/portal_components/tool.erp5.InotifyTool.py
...ntTemplateItem/portal_components/tool.erp5.InotifyTool.py
+1
-3
bt5/erp5_inotify/ToolComponentTemplateItem/portal_components/tool.erp5.InotifyTool.xml
...tTemplateItem/portal_components/tool.erp5.InotifyTool.xml
+110
-0
bt5/erp5_inotify/bt/template_tool_component_id_list
bt5/erp5_inotify/bt/template_tool_component_id_list
+1
-0
product/ERP5/__init__.py
product/ERP5/__init__.py
+1
-2
No files found.
bt5/erp5_inotify/TestTemplateItem/portal_components/test.erp5.testInotifyTool.py
View file @
11e8ee75
...
...
@@ -33,7 +33,7 @@ from Products.ERP5.ERP5Site import addERP5Tool
class
TestInotifyTool
(
ERP5TypeTestCase
):
def
test_inotify
(
self
):
from
Products.ERP5.T
ool.InotifyTool
import
IN_CREATE
,
IN_MODIFY
,
IN_DELETE
from
erp5.component.t
ool.InotifyTool
import
IN_CREATE
,
IN_MODIFY
,
IN_DELETE
addERP5Tool
(
self
.
portal
,
'portal_inotify'
,
'Inotify Tool'
)
inotify_tool
=
self
.
portal
.
portal_inotify
for
inotify
in
inotify_tool
.
objectValues
():
...
...
product/ERP5/Tool/
InotifyTool.py
→
bt5/erp5_inotify/ToolComponentTemplateItem/portal_components/tool.erp5.
InotifyTool.py
View file @
11e8ee75
...
...
@@ -27,11 +27,9 @@
##############################################################################
import
errno
,
glob
,
os
,
threading
from
AccessControl
import
ClassSecurityInfo
from
Acquisition
import
aq_base
from
Products.ERP5Type.Tool.BaseTool
import
BaseTool
from
Products.ERP5Type.TransactionalVariable
import
TransactionalResource
from
Products.ERP5Type
import
Permissions
from
Products.ERP5.mixin.timer_service
import
TimerServiceMixin
from
AccessControl.SecurityManagement
import
newSecurityManager
,
\
getSecurityManager
,
setSecurityManager
...
...
@@ -61,7 +59,7 @@ class InotifyTool(TimerServiceMixin, BaseTool):
except
AttributeError
:
pass
def
process_timer
(
self
,
tick
,
interval
,
prev
=
""
,
next
=
""
):
def
process_timer
(
self
,
tick
,
interval
,
prev
=
""
,
next
=
""
):
# pylint: disable=redefined-builtin
if
timerservice_lock
.
acquire
(
0
):
try
:
try
:
...
...
bt5/erp5_inotify/ToolComponentTemplateItem/portal_components/tool.erp5.InotifyTool.xml
0 → 100644
View file @
11e8ee75
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Tool Component"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
InotifyTool
</string>
</value>
</item>
<item>
<key>
<string>
default_source_reference
</string>
</key>
<value>
<string>
Products.ERP5.Tool.InotifyTool
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
tool.erp5.InotifyTool
</string>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Tool Component
</string>
</value>
</item>
<item>
<key>
<string>
sid
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
text_content_error_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<key>
<string>
version
</string>
</key>
<value>
<string>
erp5
</string>
</value>
</item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAM=
</string>
</persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
validate
</string>
</value>
</item>
<item>
<key>
<string>
validation_state
</string>
</key>
<value>
<string>
validated
</string>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_inotify/bt/template_tool_component_id_list
0 → 100644
View file @
11e8ee75
tool.erp5.InotifyTool
\ No newline at end of file
product/ERP5/__init__.py
View file @
11e8ee75
...
...
@@ -47,7 +47,7 @@ from Tool import CategoryTool, IdTool, TemplateTool,\
GadgetTool
,
ContributionRegistryTool
,
IntrospectionTool
,
\
AcknowledgementTool
,
SolverTool
,
\
UrlRegistryTool
,
\
CertificateAuthorityTool
,
InotifyTool
CertificateAuthorityTool
import
ERP5Site
from
Document
import
PythonScript
,
SQLMethod
object_classes
=
(
ERP5Site
.
ERP5Site
,
...
...
@@ -71,7 +71,6 @@ portal_tools = ( CategoryTool.CategoryTool,
SolverTool
.
SolverTool
,
UrlRegistryTool
.
UrlRegistryTool
,
CertificateAuthorityTool
.
CertificateAuthorityTool
,
InotifyTool
.
InotifyTool
,
)
content_classes
=
()
content_constructors
=
()
...
...
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