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
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
Klaus Wölfel
erp5
Commits
1d41abc9
Commit
1d41abc9
authored
Dec 14, 2021
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp_xhtml_style/erp5_web_renderjs_ui: update rsvp
parent
4975d150
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
34 additions
and
34 deletions
+34
-34
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_RSVP_js.js
...nderjs_ui/PathTemplateItem/web_page_module/rjs_RSVP_js.js
+16
-16
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_RSVP_js.xml
...derjs_ui/PathTemplateItem/web_page_module/rjs_RSVP_js.xml
+2
-2
product/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/rsvp.js.js
...SkinTemplateItem/portal_skins/erp5_xhtml_style/rsvp.js.js
+16
-16
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_RSVP_js.js
View file @
1d41abc9
...
@@ -48,14 +48,14 @@ define("rsvp/all",
...
@@ -48,14 +48,14 @@ define("rsvp/all",
throw
new
TypeError
(
'
You must pass an array to all.
'
);
throw
new
TypeError
(
'
You must pass an array to all.
'
);
}
}
function
canceller
()
{
function
canceller
(
msg
)
{
var
promise
;
var
promise
;
for
(
var
i
=
0
;
i
<
promises
.
length
;
i
++
)
{
for
(
var
i
=
0
;
i
<
promises
.
length
;
i
++
)
{
promise
=
promises
[
i
];
promise
=
promises
[
i
];
if
(
promise
&&
typeof
promise
.
then
===
'
function
'
&&
if
(
promise
&&
typeof
promise
.
then
===
'
function
'
&&
typeof
promise
.
cancel
===
'
function
'
)
{
typeof
promise
.
cancel
===
'
function
'
)
{
promise
.
cancel
();
promise
.
cancel
(
msg
);
}
}
}
}
}
}
...
@@ -396,7 +396,7 @@ define("rsvp/hash",
...
@@ -396,7 +396,7 @@ define("rsvp/hash",
function
hash
(
promises
)
{
function
hash
(
promises
)
{
function
canceller
()
{
function
canceller
(
msg
)
{
var
promise
,
var
promise
,
key
;
key
;
for
(
key
in
promises
)
{
for
(
key
in
promises
)
{
...
@@ -405,7 +405,7 @@ define("rsvp/hash",
...
@@ -405,7 +405,7 @@ define("rsvp/hash",
if
(
promise
&&
typeof
promise
.
then
===
'
function
'
&&
if
(
promise
&&
typeof
promise
.
then
===
'
function
'
&&
typeof
promise
.
cancel
===
'
function
'
)
{
typeof
promise
.
cancel
===
'
function
'
)
{
promise
.
cancel
();
promise
.
cancel
(
msg
);
}
}
}
}
}
}
...
@@ -552,21 +552,21 @@ define("rsvp/promise",
...
@@ -552,21 +552,21 @@ define("rsvp/promise",
this
.
on
(
'
error
'
,
onerror
);
this
.
on
(
'
error
'
,
onerror
);
this
.
cancel
=
function
()
{
this
.
cancel
=
function
(
msg
)
{
// For now, simply reject the promise and does not propagate the cancel
// For now, simply reject the promise and does not propagate the cancel
// to parent or children
// to parent or children
if
(
resolved
)
{
return
;
}
if
(
resolved
)
{
return
;
}
promise
.
isCancelled
=
true
;
promise
.
isCancelled
=
true
;
if
(
canceller
!==
undefined
)
{
if
(
canceller
!==
undefined
)
{
try
{
try
{
canceller
();
canceller
(
msg
);
}
catch
(
e
)
{
}
catch
(
e
)
{
rejectPromise
(
e
);
rejectPromise
(
e
);
return
;
return
;
}
}
}
}
// Trigger cancel?
// Trigger cancel?
rejectPromise
(
new
CancellationError
());
rejectPromise
(
new
CancellationError
(
msg
));
};
};
try
{
try
{
...
@@ -629,8 +629,8 @@ define("rsvp/promise",
...
@@ -629,8 +629,8 @@ define("rsvp/promise",
this
.
off
(
'
error
'
,
onerror
);
this
.
off
(
'
error
'
,
onerror
);
var
thenPromise
=
new
this
.
constructor
(
function
()
{},
var
thenPromise
=
new
this
.
constructor
(
function
()
{},
function
()
{
function
(
msg
)
{
thenPromise
.
trigger
(
'
promise:cancelled
'
,
{});
thenPromise
.
trigger
(
'
promise:cancelled
'
,
{
msg
:
msg
});
});
});
if
(
this
.
isFulfilled
)
{
if
(
this
.
isFulfilled
)
{
...
@@ -690,7 +690,7 @@ define("rsvp/promise",
...
@@ -690,7 +690,7 @@ define("rsvp/promise",
if
(
isFunction
(
then
))
{
if
(
isFunction
(
then
))
{
promise
.
on
(
'
promise:cancelled
'
,
function
(
event
)
{
promise
.
on
(
'
promise:cancelled
'
,
function
(
event
)
{
if
(
isFunction
(
value
.
cancel
))
{
if
(
isFunction
(
value
.
cancel
))
{
value
.
cancel
();
value
.
cancel
(
event
.
msg
);
}
}
});
});
then
.
call
(
value
,
function
(
val
)
{
then
.
call
(
value
,
function
(
val
)
{
...
@@ -773,9 +773,9 @@ define("rsvp/queue",
...
@@ -773,9 +773,9 @@ define("rsvp/queue",
return
new
Queue
(
thenable
);
return
new
Queue
(
thenable
);
}
}
function
canceller
()
{
function
canceller
(
msg
)
{
for
(
var
i
=
promise_list
.
length
;
i
>
0
;
i
--
)
{
for
(
var
i
=
promise_list
.
length
;
i
>
0
;
i
--
)
{
promise_list
[
i
-
1
].
cancel
();
promise_list
[
i
-
1
].
cancel
(
msg
);
}
}
}
}
...
@@ -818,10 +818,10 @@ define("rsvp/queue",
...
@@ -818,10 +818,10 @@ define("rsvp/queue",
checkPromise
(
resolve
(
thenable
));
checkPromise
(
resolve
(
thenable
));
queue
.
cancel
=
function
()
{
queue
.
cancel
=
function
(
msg
)
{
if
(
resolved
)
{
return
;}
if
(
resolved
)
{
return
;}
resolved
=
true
;
resolved
=
true
;
promise
.
cancel
();
promise
.
cancel
(
msg
);
promise
.
fail
(
function
(
rejectedReason
)
{
promise
.
fail
(
function
(
rejectedReason
)
{
queue
.
isRejected
=
true
;
queue
.
isRejected
=
true
;
queue
.
rejectedReason
=
rejectedReason
;
queue
.
rejectedReason
=
rejectedReason
;
...
@@ -884,9 +884,9 @@ define("rsvp/resolve",
...
@@ -884,9 +884,9 @@ define("rsvp/resolve",
}
}
}
}
return
resolve
(
thenable
);
return
resolve
(
thenable
);
},
function
()
{
},
function
(
msg
)
{
if
((
thenable
!==
undefined
)
&&
(
thenable
.
cancel
!==
undefined
))
{
if
((
thenable
!==
undefined
)
&&
(
thenable
.
cancel
!==
undefined
))
{
thenable
.
cancel
();
thenable
.
cancel
(
msg
);
}
}
});
});
}
}
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_RSVP_js.xml
View file @
1d41abc9
...
@@ -234,7 +234,7 @@
...
@@ -234,7 +234,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
9
89.27523.29749.43383
</string>
</value>
<value>
<string>
9
96.53961.44875.63385
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -252,7 +252,7 @@
...
@@ -252,7 +252,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
16
11827376.22
</float>
<float>
16
39486665.59
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
product/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/rsvp.js.js
View file @
1d41abc9
...
@@ -48,14 +48,14 @@ define("rsvp/all",
...
@@ -48,14 +48,14 @@ define("rsvp/all",
throw
new
TypeError
(
'
You must pass an array to all.
'
);
throw
new
TypeError
(
'
You must pass an array to all.
'
);
}
}
function
canceller
()
{
function
canceller
(
msg
)
{
var
promise
;
var
promise
;
for
(
var
i
=
0
;
i
<
promises
.
length
;
i
++
)
{
for
(
var
i
=
0
;
i
<
promises
.
length
;
i
++
)
{
promise
=
promises
[
i
];
promise
=
promises
[
i
];
if
(
promise
&&
typeof
promise
.
then
===
'
function
'
&&
if
(
promise
&&
typeof
promise
.
then
===
'
function
'
&&
typeof
promise
.
cancel
===
'
function
'
)
{
typeof
promise
.
cancel
===
'
function
'
)
{
promise
.
cancel
();
promise
.
cancel
(
msg
);
}
}
}
}
}
}
...
@@ -396,7 +396,7 @@ define("rsvp/hash",
...
@@ -396,7 +396,7 @@ define("rsvp/hash",
function
hash
(
promises
)
{
function
hash
(
promises
)
{
function
canceller
()
{
function
canceller
(
msg
)
{
var
promise
,
var
promise
,
key
;
key
;
for
(
key
in
promises
)
{
for
(
key
in
promises
)
{
...
@@ -405,7 +405,7 @@ define("rsvp/hash",
...
@@ -405,7 +405,7 @@ define("rsvp/hash",
if
(
promise
&&
typeof
promise
.
then
===
'
function
'
&&
if
(
promise
&&
typeof
promise
.
then
===
'
function
'
&&
typeof
promise
.
cancel
===
'
function
'
)
{
typeof
promise
.
cancel
===
'
function
'
)
{
promise
.
cancel
();
promise
.
cancel
(
msg
);
}
}
}
}
}
}
...
@@ -552,21 +552,21 @@ define("rsvp/promise",
...
@@ -552,21 +552,21 @@ define("rsvp/promise",
this
.
on
(
'
error
'
,
onerror
);
this
.
on
(
'
error
'
,
onerror
);
this
.
cancel
=
function
()
{
this
.
cancel
=
function
(
msg
)
{
// For now, simply reject the promise and does not propagate the cancel
// For now, simply reject the promise and does not propagate the cancel
// to parent or children
// to parent or children
if
(
resolved
)
{
return
;
}
if
(
resolved
)
{
return
;
}
promise
.
isCancelled
=
true
;
promise
.
isCancelled
=
true
;
if
(
canceller
!==
undefined
)
{
if
(
canceller
!==
undefined
)
{
try
{
try
{
canceller
();
canceller
(
msg
);
}
catch
(
e
)
{
}
catch
(
e
)
{
rejectPromise
(
e
);
rejectPromise
(
e
);
return
;
return
;
}
}
}
}
// Trigger cancel?
// Trigger cancel?
rejectPromise
(
new
CancellationError
());
rejectPromise
(
new
CancellationError
(
msg
));
};
};
try
{
try
{
...
@@ -629,8 +629,8 @@ define("rsvp/promise",
...
@@ -629,8 +629,8 @@ define("rsvp/promise",
this
.
off
(
'
error
'
,
onerror
);
this
.
off
(
'
error
'
,
onerror
);
var
thenPromise
=
new
this
.
constructor
(
function
()
{},
var
thenPromise
=
new
this
.
constructor
(
function
()
{},
function
()
{
function
(
msg
)
{
thenPromise
.
trigger
(
'
promise:cancelled
'
,
{});
thenPromise
.
trigger
(
'
promise:cancelled
'
,
{
msg
:
msg
});
});
});
if
(
this
.
isFulfilled
)
{
if
(
this
.
isFulfilled
)
{
...
@@ -690,7 +690,7 @@ define("rsvp/promise",
...
@@ -690,7 +690,7 @@ define("rsvp/promise",
if
(
isFunction
(
then
))
{
if
(
isFunction
(
then
))
{
promise
.
on
(
'
promise:cancelled
'
,
function
(
event
)
{
promise
.
on
(
'
promise:cancelled
'
,
function
(
event
)
{
if
(
isFunction
(
value
.
cancel
))
{
if
(
isFunction
(
value
.
cancel
))
{
value
.
cancel
();
value
.
cancel
(
event
.
msg
);
}
}
});
});
then
.
call
(
value
,
function
(
val
)
{
then
.
call
(
value
,
function
(
val
)
{
...
@@ -773,9 +773,9 @@ define("rsvp/queue",
...
@@ -773,9 +773,9 @@ define("rsvp/queue",
return
new
Queue
(
thenable
);
return
new
Queue
(
thenable
);
}
}
function
canceller
()
{
function
canceller
(
msg
)
{
for
(
var
i
=
promise_list
.
length
;
i
>
0
;
i
--
)
{
for
(
var
i
=
promise_list
.
length
;
i
>
0
;
i
--
)
{
promise_list
[
i
-
1
].
cancel
();
promise_list
[
i
-
1
].
cancel
(
msg
);
}
}
}
}
...
@@ -818,10 +818,10 @@ define("rsvp/queue",
...
@@ -818,10 +818,10 @@ define("rsvp/queue",
checkPromise
(
resolve
(
thenable
));
checkPromise
(
resolve
(
thenable
));
queue
.
cancel
=
function
()
{
queue
.
cancel
=
function
(
msg
)
{
if
(
resolved
)
{
return
;}
if
(
resolved
)
{
return
;}
resolved
=
true
;
resolved
=
true
;
promise
.
cancel
();
promise
.
cancel
(
msg
);
promise
.
fail
(
function
(
rejectedReason
)
{
promise
.
fail
(
function
(
rejectedReason
)
{
queue
.
isRejected
=
true
;
queue
.
isRejected
=
true
;
queue
.
rejectedReason
=
rejectedReason
;
queue
.
rejectedReason
=
rejectedReason
;
...
@@ -884,9 +884,9 @@ define("rsvp/resolve",
...
@@ -884,9 +884,9 @@ define("rsvp/resolve",
}
}
}
}
return
resolve
(
thenable
);
return
resolve
(
thenable
);
},
function
()
{
},
function
(
msg
)
{
if
((
thenable
!==
undefined
)
&&
(
thenable
.
cancel
!==
undefined
))
{
if
((
thenable
!==
undefined
)
&&
(
thenable
.
cancel
!==
undefined
))
{
thenable
.
cancel
();
thenable
.
cancel
(
msg
);
}
}
});
});
}
}
...
...
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