Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ayush Tiwari
erp5
Commits
9cae9286
Commit
9cae9286
authored
Sep 05, 2018
by
Ayush Tiwari
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_core] Add link for checking the current value for large text contents
parent
03192ae8
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
317 additions
and
5 deletions
+317
-5
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_getCurrentValueUrl.py
...ateItem/portal_skins/erp5_core/Base_getCurrentValueUrl.py
+20
-0
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_getCurrentValueUrl.xml
...teItem/portal_skins/erp5_core/Base_getCurrentValueUrl.xml
+62
-0
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_getWorkflowHistoryItemList.py
...portal_skins/erp5_core/Base_getWorkflowHistoryItemList.py
+4
-4
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_viewCurrentValueForLargeText.xml
...tal_skins/erp5_core/Base_viewCurrentValueForLargeText.xml
+109
-0
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_viewCurrentValueForLargeText/my_current_value.xml
...re/Base_viewCurrentValueForLargeText/my_current_value.xml
+121
-0
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_viewHistoricalComparisonDiffLinkList/listbox.xml
...ore/Base_viewHistoricalComparisonDiffLinkList/listbox.xml
+1
-1
No files found.
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_getCurrentValueUrl.py
0 → 100644
View file @
9cae9286
"""
This URL script returns the URL for current value for the
properties in the Historical Comparison Diff.
"""
if
brain
is
None
:
brain
=
context
# Get the name of property from the brain and send it as
# parameter to the next view
path
=
brain
.
getProperty
(
'path'
)
property_name
=
path
.
split
(
'/'
)[
2
]
if
url_dict
:
return
{
'command'
:
'raw'
,
'options'
:
{
'url'
:
'google.com'
}
}
return
'Base_viewCurrentValueForLargeText?property_name=%s'
%
property_name
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_getCurrentValueUrl.xml
0 → 100644
View file @
9cae9286
<?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>
url_dict=False, brain=None, selection=None, selection_name=None, **kw
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
Base_getCurrentValueUrl
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_getWorkflowHistoryItemList.py
View file @
9cae9286
...
@@ -33,7 +33,7 @@ def getActorName(actor):
...
@@ -33,7 +33,7 @@ def getActorName(actor):
# Get history
# Get history
# XXX Compatibility
# XXX Compatibility
for
history_name
in
[
'history'
,
'building_history'
,
'installation_history'
]:
for
history_name
in
[
'history'
,
'building_history'
,
'installation_history'
]:
workflow_item_list
=
portal_workflow
.
getInfoFor
(
ob
=
context
,
workflow_item_list
=
portal_workflow
.
getInfoFor
(
ob
=
context
,
name
=
'history'
,
wf_id
=
workflow_id
)
name
=
'history'
,
wf_id
=
workflow_id
)
if
workflow_item_list
!=
[]:
if
workflow_item_list
!=
[]:
break
break
...
@@ -56,7 +56,7 @@ for workflow_item in workflow_item_list:
...
@@ -56,7 +56,7 @@ for workflow_item in workflow_item_list:
if
key
.
startswith
(
compatibility_name
):
if
key
.
startswith
(
compatibility_name
):
# Display the workflow state in the state columns
# Display the workflow state in the state columns
key
=
key
[
len
(
compatibility_name
):]
key
=
key
[
len
(
compatibility_name
):]
if
key
==
wf_state_var
:
if
key
==
wf_state_var
:
# Store locally the id of state, usefull for merging action and transition
# Store locally the id of state, usefull for merging action and transition
state_id
=
wf_states
.
get
(
value
,
marker
)
and
wf_states
[
value
].
id
state_id
=
wf_states
.
get
(
value
,
marker
)
and
wf_states
[
value
].
id
o
.
setProperty
(
'state_id'
,
state_id
)
o
.
setProperty
(
'state_id'
,
state_id
)
...
@@ -78,7 +78,7 @@ for workflow_item in workflow_item_list:
...
@@ -78,7 +78,7 @@ for workflow_item in workflow_item_list:
value
=
wf_transitions
.
get
(
value
,
marker
)
and
(
wf_transitions
[
value
].
id
or
wf_transitions
[
value
].
actbox_name
)
or
value
value
=
wf_transitions
.
get
(
value
,
marker
)
and
(
wf_transitions
[
value
].
id
or
wf_transitions
[
value
].
actbox_name
)
or
value
if
display
:
if
display
:
if
key
==
'error_message'
and
same_type
(
value
,
''
):
if
key
==
'error_message'
and
same_type
(
value
,
''
):
value
=
context
.
Localizer
.
erp5_ui
.
gettext
(
value
)
value
=
context
.
Localizer
.
erp5_ui
.
gettext
(
value
)
elif
key
==
'error_message'
and
same_type
(
value
,
[]):
elif
key
==
'error_message'
and
same_type
(
value
,
[]):
value
=
'. '
.
join
([
'%s'
%
x
for
x
in
value
])
value
=
'. '
.
join
([
'%s'
%
x
for
x
in
value
])
elif
key
==
'error_message'
:
elif
key
==
'error_message'
:
...
@@ -92,7 +92,7 @@ for workflow_item in workflow_item_list:
...
@@ -92,7 +92,7 @@ for workflow_item in workflow_item_list:
if
value
is
marker
:
if
value
is
marker
:
value
=
'Does not exist'
value
=
'Does not exist'
o
.
setProperty
(
key
,
value
)
o
.
setProperty
(
key
,
value
)
# record current serial as "next serial" for the previous revision
# record current serial as "next serial" for the previous revision
if
next_serial
is
not
None
and
can_view_history
:
if
next_serial
is
not
None
and
can_view_history
:
previous_obj
.
setProperty
(
'next_serial'
,
o
.
serial
)
previous_obj
.
setProperty
(
'next_serial'
,
o
.
serial
)
...
...
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_viewCurrentValueForLargeText.xml
0 → 100644
View file @
9cae9286
<?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>
_objects
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string></string>
</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>
<string>
my_current_value
</string>
</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>
Base_viewCurrentValueForLargeText
</string>
</value>
</item>
<item>
<key>
<string>
method
</string>
</key>
<value>
<string>
POST
</string>
</value>
</item>
<item>
<key>
<string>
name
</string>
</key>
<value>
<string>
Base_viewCurrentValueForLargeText
</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></string>
</value>
</item>
<item>
<key>
<string>
unicode_mode
</string>
</key>
<value>
<int>
0
</int>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_viewCurrentValueForLargeText/my_current_value.xml
0 → 100644
View file @
9cae9286
<?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>
default
</string>
<string>
editable
</string>
<string>
title
</string>
</list>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
my_current_value
</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>
</dictionary>
</value>
</item>
<item>
<key>
<string>
tales
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
default
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
editable
</string>
</key>
<value>
<string></string>
</value>
</item>
<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>
title
</string>
</key>
<value>
<string></string>
</value>
</item>
</dictionary>
</value>
</item>
<item>
<key>
<string>
values
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
default
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
editable
</string>
</key>
<value>
<int>
0
</int>
</value>
</item>
<item>
<key>
<string>
field_id
</string>
</key>
<value>
<string>
my_text_content
</string>
</value>
</item>
<item>
<key>
<string>
form_id
</string>
</key>
<value>
<string>
Base_viewWebFieldLibrary
</string>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Current Value
</string>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"TALESMethod"
module=
"Products.Formulator.TALESField"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_text
</string>
</key>
<value>
<string>
python: context.getProperty(context.REQUEST.get(\'property_name\', None))
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_viewHistoricalComparisonDiffLinkList/listbox.xml
View file @
9cae9286
...
@@ -132,7 +132,7 @@
...
@@ -132,7 +132,7 @@
</tuple>
</tuple>
<tuple>
<tuple>
<string>
current_value
</string>
<string>
current_value
</string>
<string></string>
<string>
Base_getCurrentValueUrl
</string>
</tuple>
</tuple>
</list>
</list>
</value>
</value>
...
...
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