X-Git-Url: https://git.auder.net/?p=vchess.git;a=blobdiff_plain;f=public%2Fjavascripts%2Fcomponents%2Fproblems.js;h=68830a4f7f9af93c281455eb43b8521f9a41aaf5;hp=dbd8340c96236d023f1d88b27ef2b38676ae7e9e;hb=c794dbb87592782913af0a09784ed25e019e4d10;hpb=7931e479adf93c87771ded1892a0873af72ae46d
diff --git a/public/javascripts/components/problems.js b/public/javascripts/components/problems.js
index dbd8340c..68830a4f 100644
--- a/public/javascripts/components/problems.js
+++ b/public/javascripts/components/problems.js
@@ -9,7 +9,7 @@ Vue.component('my-problems', {
-
@@ -45,7 +45,6 @@ Vue.component('my-problems', {
`,
computed: {
sortedProblems: function() {
- console.log("call");
// Newest problem first
return this.problems.sort((p1,p2) => { return p2.added - p1.added; });
},
@@ -54,6 +53,10 @@ Vue.component('my-problems', {
},
},
methods: {
+ // Propagate "show problem" event to parent component (my-variant)
+ bubbleUp: function(problem) {
+ this.$emit('show-problem', JSON.stringify(problem));
+ },
fetchProblems: function(direction) {
return; //TODO: re-activate after server side is implemented (see routes/all.js)
if (this.problems.length == 0)