Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Guillaume Hervier
slapos.core
Commits
476cbf81
Commit
476cbf81
authored
Mar 05, 2018
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_jio: Reopen ticket if a new message is posted.
parent
7c2eef57
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
99 additions
and
5 deletions
+99
-5
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_add_related_event_js.js
..._module/rjs_gadget_erp5_page_slap_add_related_event_js.js
+11
-3
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_add_related_event_js.xml
...module/rjs_gadget_erp5_page_slap_add_related_event_js.xml
+2
-2
master/bt5/slapos_jio/SkinTemplateItem/portal_skins/slapos_hal_json_style/WebMessage_stop.py
...tem/portal_skins/slapos_hal_json_style/WebMessage_stop.py
+16
-0
master/bt5/slapos_jio/SkinTemplateItem/portal_skins/slapos_hal_json_style/WebMessage_stop.xml
...em/portal_skins/slapos_hal_json_style/WebMessage_stop.xml
+70
-0
No files found.
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_add_related_event_js.js
View file @
476cbf81
...
...
@@ -12,6 +12,7 @@
.
declareAcquiredMethod
(
"
getUrlFor
"
,
"
getUrlFor
"
)
.
declareAcquiredMethod
(
"
redirect
"
,
"
redirect
"
)
.
declareAcquiredMethod
(
"
jio_post
"
,
"
jio_post
"
)
.
declareAcquiredMethod
(
"
jio_putAttachment
"
,
"
jio_putAttachment
"
)
.
declareAcquiredMethod
(
"
jio_get
"
,
"
jio_get
"
)
...
...
@@ -31,10 +32,17 @@
.
push
(
function
(
doc
)
{
return
gadget
.
jio_post
(
doc
);
})
.
push
(
function
()
{
return
gadget
.
redirect
({
"
command
"
:
"
change
"
,
.
push
(
function
(
key
)
{
return
gadget
.
getSetting
(
'
hateoas_url
'
)
.
push
(
function
(
hateoas_url
)
{
return
gadget
.
jio_putAttachment
(
key
,
hateoas_url
+
key
+
"
/WebMessage_stop
"
,
{});
})
.
push
(
function
()
{
return
gadget
.
redirect
({
"
command
"
:
"
change
"
,
"
options
"
:
{
"
jio_key
"
:
gadget
.
state
.
jio_key
,
"
page
"
:
"
slap_controller
"
}});
});
});
})
...
...
@@ -166,7 +174,7 @@
})
.
push
(
function
()
{
return
gadget
.
updateHeader
({
page_title
:
"
New
Ticket
"
,
page_title
:
"
New
Message
"
,
submit_action
:
true
});
});
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_add_related_event_js.xml
View file @
476cbf81
...
...
@@ -273,7 +273,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
96
3.3640.49595.9984
</string>
</value>
<value>
<string>
96
5.59722.26989.42052
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -291,7 +291,7 @@
</tuple>
<state>
<tuple>
<float>
15
09323928.0
1
</float>
<float>
15
20009407.2
1
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
master/bt5/slapos_jio/SkinTemplateItem/portal_skins/slapos_hal_json_style/WebMessage_stop.py
0 → 100644
View file @
476cbf81
from
zExceptions
import
Unauthorized
portal
=
context
.
getPortalObject
()
person
=
portal
.
ERP5Site_getAuthenticatedMemberPersonValue
()
# XXX Proxy role is Manager so user to open ticket which is closed.
# We check permissions
if
not
person
:
raise
Unauthorized
(
"You need to be logged in before modify this object!"
)
ticket
=
context
.
getFollowUpValue
()
if
ticket
.
getDestinationDecision
()
!=
person
.
getRelativeUrl
():
raise
Unauthorized
context
.
stop
(
comment
=
"Submitted from the renderjs app"
)
if
portal
.
portal_workflow
.
isTransitionPossible
(
ticket
,
"validate"
):
ticket
.
validate
(
comment
=
"See %s"
%
context
.
getRelativeUrl
())
master/bt5/slapos_jio/SkinTemplateItem/portal_skins/slapos_hal_json_style/WebMessage_stop.xml
0 → 100644
View file @
476cbf81
<?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>
*args, **kwargs
</string>
</value>
</item>
<item>
<key>
<string>
_proxy_roles
</string>
</key>
<value>
<tuple>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
WebMessage_stop
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
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