Skip to content

Commit 451cdd0

Browse files
committed
add arrow fn and fix ajax
1 parent 55254ce commit 451cdd0

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
block('pager')
22
.elem('item')
3-
.match(function() { return this.ctx.url !== true; })
4-
.replace()(function() {
3+
.match(node => { return node.ctx.url !== true; })
4+
.replace()(node => {
55
const type2caption = {
66
first: '<<',
77
prev: '<',
@@ -10,14 +10,14 @@ block('pager')
1010
last: '>>'
1111
};
1212

13-
const elemMods = this.elemMods;
13+
const elemMods = node.elemMods;
1414
const type = elemMods.type;
1515

1616
return {
1717
block: 'button',
1818
mods: { theme: 'islands', size: 'm', type: 'link', disabled: type === 'current' },
19-
mix: { block: this.block, elem: this.elem, elemMods },
20-
url: this.ctx.url,
21-
text: type2caption[type] || this.ctx.number
19+
mix: { block: node.block, elem: node.elem, elemMods },
20+
url: node.ctx.url,
21+
text: type2caption[type] || node.ctx.number
2222
};
2323
});

common.blocks/sidebar/__sorting/sidebar__sorting.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ modules.define(
2525
delete params.page;
2626

2727
Location.change({ params: params });
28-
window.location.reload();
2928
},
3029

3130
_getParams: function(sort, direction) {

0 commit comments

Comments
 (0)