Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
ecommerce-ui
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
ecommerce-ui
Commits
72011fb6
Commit
72011fb6
authored
Jul 31, 2013
by
Sven Franck
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Gadgets/RenderJs: renamed callback and mockup to "after" and "before" (append)
parent
9eecb911
Changes
27
Hide whitespace changes
Inline
Side-by-side
Showing
27 changed files
with
47 additions
and
45 deletions
+47
-45
js/plugins/renderjs/renderjs.js
js/plugins/renderjs/renderjs.js
+12
-12
modules/ui/address/address.js
modules/ui/address/address.js
+1
-1
modules/ui/basket/basket.js
modules/ui/basket/basket.js
+1
-1
modules/ui/browser/browser.js
modules/ui/browser/browser.js
+2
-2
modules/ui/confirm/confirm.js
modules/ui/confirm/confirm.js
+1
-1
modules/ui/description/description.js
modules/ui/description/description.js
+1
-1
modules/ui/details/details.js
modules/ui/details/details.js
+6
-4
modules/ui/footer/footer.js
modules/ui/footer/footer.js
+1
-1
modules/ui/gallery/gallery.js
modules/ui/gallery/gallery.js
+2
-2
modules/ui/header/header.js
modules/ui/header/header.js
+1
-1
modules/ui/index/index.js
modules/ui/index/index.js
+1
-1
modules/ui/item/item.js
modules/ui/item/item.js
+2
-2
modules/ui/items/items.js
modules/ui/items/items.js
+2
-2
modules/ui/login/login.js
modules/ui/login/login.js
+1
-1
modules/ui/media/media.js
modules/ui/media/media.js
+1
-1
modules/ui/payment/payment.js
modules/ui/payment/payment.js
+1
-1
modules/ui/products/products.js
modules/ui/products/products.js
+1
-1
modules/ui/refine/refine.js
modules/ui/refine/refine.js
+1
-1
modules/ui/register/register.js
modules/ui/register/register.js
+1
-1
modules/ui/searchbar/searchbar.js
modules/ui/searchbar/searchbar.js
+1
-1
modules/ui/seo/seo.js
modules/ui/seo/seo.js
+1
-1
modules/ui/shipment/shipment.js
modules/ui/shipment/shipment.js
+1
-1
modules/ui/sorting/sorting.js
modules/ui/sorting/sorting.js
+1
-1
modules/ui/summary/summary.js
modules/ui/summary/summary.js
+1
-1
modules/ui/teaser/teaser.js
modules/ui/teaser/teaser.js
+1
-1
modules/ui/terms/terms.js
modules/ui/terms/terms.js
+1
-1
modules/ui/translate/translate.js
modules/ui/translate/translate.js
+1
-1
No files found.
js/plugins/renderjs/renderjs.js
View file @
72011fb6
...
...
@@ -104,7 +104,7 @@ var RenderJs = (function () {
});
},
setGadgetAndRecurse
:
function
(
gadget
,
data
,
callback
,
async
)
{
setGadgetAndRecurse
:
function
(
gadget
,
data
,
after
,
before
)
{
/*
* Set gadget data and recursively load it in case it holds another
* gadgets.
...
...
@@ -112,18 +112,18 @@ var RenderJs = (function () {
// set current gadget as being loaded so gadget instance itself knows which gadget it is
var
self
=
RenderJs
.
GadgetIndex
.
getGadgetById
(
gadget
.
attr
(
"
id
"
));
setSelfGadget
(
self
);
// a
sync
if
(
async
)
{
async
(
data
,
function
(
markup
){
// a
llow to generate content and enhance before appending!
if
(
before
)
{
before
(
data
,
function
(
markup
){
gadget
.
empty
().
append
(
markup
);
if
(
callback
)
{
callback
(
self
);
if
(
after
)
{
after
(
self
);
}
});
}
else
{
gadget
.
empty
().
append
(
data
);
if
(
callback
)
{
callback
(
self
);
if
(
after
)
{
after
(
self
);
}
}
...
...
@@ -200,8 +200,8 @@ var RenderJs = (function () {
RenderJs
.
setGadgetAndRecurse
(
gadget
,
response
.
data
,
response
.
callback
,
response
.
mockup
response
.
after
,
response
.
before
);
RenderJs
.
checkAndTriggerReady
();
RenderJs
.
updateGadgetData
(
gadget
);
...
...
@@ -260,8 +260,8 @@ var RenderJs = (function () {
RenderJs
.
setGadgetAndRecurse
(
gadget
,
response
.
data
,
response
.
callback
,
response
.
mockup
response
.
after
,
response
.
before
);
RenderJs
.
checkAndTriggerReady
();
RenderJs
.
updateGadgetData
(
gadget
);
...
...
modules/ui/address/address.js
View file @
72011fb6
...
...
@@ -8,7 +8,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/basket/basket.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/browser/browser.js
View file @
72011fb6
...
...
@@ -120,7 +120,7 @@ define([
};
that
.
data
=
source
;
that
.
mockup
=
function
(
source
,
callback_mockup
)
{
that
.
before
=
function
(
source
,
callback_mockup
)
{
var
spec
=
{};
spec
.
gadget
=
RenderJs
.
getSelfGadget
();
...
...
@@ -148,7 +148,7 @@ define([
}
};
that
.
callback
=
function
(
self
)
{
that
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/confirm/confirm.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/description/description.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/details/details.js
View file @
72011fb6
...
...
@@ -4,10 +4,12 @@ define([
,
'
css!details
'
],
function
(
App
,
source
)
{
var
response
=
{};
var
that
=
{};
var
priv
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
that
.
data
=
source
;
that
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
@@ -25,6 +27,6 @@ define([
};
// return response object
return
response
;
return
that
;
}
);
modules/ui/footer/footer.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/gallery/gallery.js
View file @
72011fb6
...
...
@@ -188,7 +188,7 @@ define([
// response object
that
.
data
=
source
;
that
.
mockup
=
function
(
source
,
callback_mockup
)
{
that
.
before
=
function
(
source
,
callback_mockup
)
{
var
spec
=
{};
spec
.
gadget
=
RenderJs
.
getSelfGadget
();
...
...
@@ -227,7 +227,7 @@ define([
}
};
that
.
callback
=
function
(
self
)
{
that
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/header/header.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{},
def
;
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
// TODO: this should be inside renderJs, although its application-specific
// but the problem with using async-render-require will be everything
// being loaded at the same time, so the user should have the opportunity
...
...
modules/ui/index/index.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{},
def
;
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/item/item.js
View file @
72011fb6
...
...
@@ -170,7 +170,7 @@ define([
// response object
that
.
data
=
source
;
that
.
mockup
=
function
(
source
,
callback_mockup
)
{
that
.
before
=
function
(
source
,
callback_mockup
)
{
var
spec
=
{};
spec
.
gadget
=
RenderJs
.
getSelfGadget
();
...
...
@@ -209,7 +209,7 @@ define([
}
};
that
.
callback
=
function
(
self
)
{
that
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/items/items.js
View file @
72011fb6
...
...
@@ -96,7 +96,7 @@ define([
// response object
that
.
data
=
source
;
that
.
mockup
=
function
(
source
,
callback_mockup
)
{
that
.
before
=
function
(
source
,
callback_mockup
)
{
var
spec
=
{};
spec
.
gadget
=
RenderJs
.
getSelfGadget
();
...
...
@@ -124,7 +124,7 @@ define([
}
};
that
.
callback
=
function
(
self
)
{
that
.
after
=
function
(
self
)
{
// set binding for opening a detailed view
// TODO: this should also be a link-method call
self
.
dom
.
find
(
"
ul
"
).
on
(
"
click
"
,
"
a
"
,
function
(
e
)
{
...
...
modules/ui/login/login.js
View file @
72011fb6
...
...
@@ -8,7 +8,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/media/media.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/payment/payment.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/products/products.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/refine/refine.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/register/register.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/searchbar/searchbar.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
var
filter
=
self
.
dom
.
find
(
"
.searchbar_filter
"
),
value
,
runSearch
;
...
...
modules/ui/seo/seo.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/shipment/shipment.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/sorting/sorting.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/summary/summary.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/teaser/teaser.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/terms/terms.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
if
(
App
===
undefined
)
{
def
=
new
$
.
Deferred
;
...
...
modules/ui/translate/translate.js
View file @
72011fb6
...
...
@@ -7,7 +7,7 @@ define([
var
response
=
{};
response
.
data
=
source
;
response
.
callback
=
function
(
self
)
{
response
.
after
=
function
(
self
)
{
var
that
=
{};
var
priv
=
{};
...
...
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