m7vm7v

Experience

68,250

3 Best Reply Awards

  • Member Since 1 Year Ago
  • 643 Lessons Completed
  • 11 Favorites

13th August, 2017

m7vm7v left a reply on A Clean Way For Users To Opt Out Of Emails • 1 week ago

If I get this right. You can make a collection of the users - you should recieve a collection now anyway of the users you want to notify

so then

$collection->where('the_flag', true)->each(function ($item, $key) { Notification::send(...); });

m7vm7v left a reply on Get UserID From Database And Compare With Logged-in User • 1 week ago

You can try:

$host = DB::table('hosts')->where('id', $id)->first();

if($host->user_id == auth()->user()->id){
    //They are matching
}

//No match

I will recommend you to make a Model for the hosts

So then the logic will stay there:

static function theLoggedUserIsAuthenticated(Host $host){

return auth()->user()->id == $host->user_id;

}

then in your controller:

if(Host::theLoggedUserIsAuthenticated($id)){
    //They are matching
}

//No match

m7vm7v left a reply on Route::resource Problem • 1 week ago

When you are using a resource then IF you have the store method in your controller then it will be executed when you have a POST request to that route.

I would recommend you to use

public function store(Request $request, $id) {
       
/**
/*   DO NOT FORGET TO VALIDATE

        $task = Task::create([
        'task_name' => $request->input('name'),
        'body' => $request->input('body'),
        ...
    ]);

    }

m7vm7v left a reply on Multiple Methods In Web Routes • 1 week ago

Give us please some more information what exactly are you trying to accomplish.

m7vm7v left a reply on Help On A Complex Query • 1 week ago

Both the events should be now a collections. So now you can simply combine them


$combined = $collection1->combine($collection1);

$combined->all();

m7vm7v left a reply on Refresh A DIV In Laravel Every 5 Seconds • 1 week ago

I would recommend you to use VueJS and Laravel Echo and the broadcasting that isaackearl proposed. It is very simple when you bind the needed information with VueJS and make a live listener with Laravel Echo.... No need of ajax call then. I would recommend you to watch https://laracasts.com/lessons/introducing-laravel-echo

8th August, 2017

m7vm7v left a reply on Phpinfo() Is Showing A Wrong Information Running On Valet • 2 weeks ago

Thank you both for the answers.

I believe that @danmatthews is having the right answer.

What I did to fix it was 'valet install' and it started working fine after.

Thanks for the help again

7th August, 2017

m7vm7v started a new conversation Phpinfo() Is Showing A Wrong Information Running On Valet • 2 weeks ago

In a Laravel application I am returning phpinfo() in my route and it shows me 'PHP Version 7.0.20'

But when I run php --version in the terminal I have 'PHP 7.1.7 (cli)'.

I did 'brew unlink php70', 'brew link php71', 'brew services start php71'.

I have uninstalled php70 and all the dependencies with brew and did run valet restart.

I am running on mac machine with Laravel 5.2 with Valet and php 7.1.

Do you know how to link my php7.1 instead 7.0? Would that be a problem related with Valet or brew or php itself?

Thanks for your time

23rd July, 2017

m7vm7v left a reply on Packagist From Custom Newly Created Console Command • 4 weeks ago

That one might be helpful to you https://laracasts.com/series/russian-doll-caching-in-laravel

There are a few (2-3) videos in the link I have given you that would give you the idea what you should do.

7th May, 2017

m7vm7v left a reply on Database [localhost] Not Configured. • 3 months ago

When you use {{ $menu }} there is NO need of {{ $var }} means

29th April, 2017

m7vm7v left a reply on Can't Pass Data From Blade To Vue Through A Prop • 3 months ago

try

props: ['dictionary'],

computed: {
    theDictionary: function(){
        return JSON.parse(this.dictionary);
    }   
}

mounted() {
    console.log(this.theDictionary);
}

m7vm7v left a reply on Laravel And MariaDB JSON Columns Issue • 3 months ago

Can you give us the Schema that you are using for the migrations.

7th April, 2017

m7vm7v left a reply on How To Destroy Child Component In VueJS • 4 months ago

hi @WebKenth , thanks for replying.

I am getting all the data without paginating from the database, and then I am rendering the datatable so after that the datatable is responsible for all the work and the pagination. So when I am going to the second page there are not any request to the server. So far I am adding the new row to the DOM and mainly that is affecting it. It is working all I want to be except that when I am creating the new row I am adding it to the DOM and if I do not remove it before the $('#dataTable').on( 'page.dt', function () {} event, it complains. But if I am able to remove it by this.toggleNewItem = false; it will all work.

m7vm7v started a new conversation How To Destroy Child Component In VueJS • 4 months ago

Hi,

I am using VueJS and Datatables.

When I click a button it adds a new row in the table.

<button type="button" @click="toggleNewItem = !toggleNewItem">Add row</button>

If i click it for a second time it disappears as expected. But if I click on the button and click after to go on the second page from the datatable it disappears and it is no longer working on the other generated page. But if I click on the button to add new row it works and after if i click it again it disappears and then if i click for the next page it all works fine and i can generate it again as expected.

That is why I have created

    $('#dataTable').on( 'page.dt', function () {
                this.toggleNewItem = false;
            } );

The event is triggered every time i change the page but the toggleNewItem remains true. How can I change the toggleNewItem to false. Or if there is another way to destroy the child component because the button triggers a child component to appear so if that is destroyed it will all works fine.

Help me to make toggleNewItem false OR destroy the child.

Thanks for helping.

21st March, 2017

m7vm7v left a reply on How To Get A Property From Object In VueJS 2 • 5 months ago

Thanks for your help @Abi but it needs to be more dynamic. Meaby I do not see it but all I see now is that this creates a new object with the 3 values a need but on the same level...

At the beggining I have the object item consisting: id, question_id, answer_id, created_at, updated_at and two objects: question and answer.

And array itemBlueprint that has: id, question.data, qnswer.data

Lets say that I have the item and I know that there is something in this object but have no idea what is inside, but the itemBlueprint knows what to look inside the item....

So I have uknown item and itemBlueprint that is having the information what to look for in the object.

In this example I have unknown 'item' but in itemBlueprint[0]=id sais that the item has the property id .... so if I type item[itemBlueprint[0]] that will give me the property from the unknown item.... and I know that itemBlueprint[1]=question.data so item[itemBlueprint[1]] looks like it will give me the the property item.question.data but it is not working.

All the information I have is the unknown object item and the itemBlueprint array that reveals what to look inside the item object.

Thanks for helping.

m7vm7v left a reply on How To Get A Property From Object In VueJS 2 • 5 months ago

Thanks mate, but I want to make it more flexible. Lets say that I have the item and the itemBlueprint from the props but I do not know what is inside the item. But the itemBlueprint knows what is inside the item.

So if I want to take the property from the known information it should look something like 'item.itemBlueprint[1]' but obviously this is not working.

m7vm7v started a new conversation How To Get A Property From Object In VueJS 2 • 5 months ago

Hi, I need to take the property from object.

My object, loaded from Laravel with eager loding with hasOne relationships for question and answer:

id  1
    question_id 1
    answer_id   1
    created_at  "2017-03-21 13:52:50"
    updated_at  "2017-03-21 13:52:50"
    question
        id          1
        data            "Culpa sit facilis voluptate sit."
        created_at  "2017-03-21 13:52:49"
        updated_at  "2017-03-21 13:52:49"
    answer  
        id          1
        data            "sequi"
        created_at  "2017-03-21 13:52:49"
        updated_at  "2017-03-21 13:52:49"

In my Vuejs I have:

props : ['item', 'itemBlueprint'],

The item consist the object, and the itemBlueprint is an array with

['id', 'question[data]', 'answer.data']

I want to make it flexible so in this example if I want to take the id I can do

this.item.id  / this.item[itemBlueprint[0]]      //= '1'

And it is working with id but whe I try with the question or answer it is not working

this.item[itemBlueprint[1]]      //for  question[data]
this.item[itemBlueprint[2]]     //for  answer.data

I got nothing. // this.item.question.data is working but not needed

How can I make it more flexible so if I know that I have item and I have the itemBlueprint and combine them to get the property I need.

Thanks

6th March, 2017

m7vm7v left a reply on How To Make A Relationship On Negative ID In Laravel 5.3 • 5 months ago

I am sorry guys. You are completely 100% right. I love laravel and how it works and I do respect any of the choices that have been taken when the framework has been made. I do understand that there are unconventional approaches and 'workarounds' that should be reconcidered before using them.

I am not offended for any of the comments. And specially I am thankfull for your time that you have spend in this discussion.

I know for the most of you this was more likely to be considered as a bad practice but I incorrige you to think more 'out of the box'. That was even for me more than 'out of the box' but with the mistakes we are taking we are mostly like to learn because that is expirience.

Thanks again and be blessed, Martin

5th March, 2017

m7vm7v left a reply on How To Make A Relationship On Negative ID In Laravel 5.3 • 5 months ago

Thanks all.

I know it might be the worst approach but still we should have access and the flexability to do this. If not it is fair enought and understandable. I was just asking. And most of it here was hate how bad would that be. I know that would not be nesseary if I just create a new columb or a new table. But you do not understant that the most not complicated approach would be the simpliest. If there are a thousonds of regular records and just a few that needs to be absolutelly the same, only that they need to be some kind of 'flagged', that does not mean that I need to create the new columb for them called flagged. I have decided to show them as a flagged with the negative id.

Have you heard how microsoft decided a years ago(i think now that they reconcidered this but....) to build their included drivers. The decided to put as a date to be June 21, 2006 and that is not because they do not update them. It is all because it was the easiest approach for them to make the flexability for the external drivers to be installed with newer date. And even if that was a "bizzare", and most thinks that "one day they will see the light", at the time they decided to make it like this for the simplicity and that it is not such a 'big' problem to work around.

I have asked you is it possible but not to judge me is that the worst way for this job. I have decided that would be suitable for me at that time.

Thanks anyway for the time for writing and reading. Many thanks for @primordial and @jekinney because thay have actually tryed to help me.

4th March, 2017

m7vm7v left a reply on How To Make A Relationship On Negative ID In Laravel 5.3 • 5 months ago

Thanks for all the help.

@jekinney thank you but that did not work. Or it might but I am prety sure it is not on the right place abs('user_from').

I know that there are much better solutions but for this small think I'd rather stay with the wrong uproach coz If I have to recreate this I need to tuch a lot other code side.

Thanks anyway to all of you.

3rd March, 2017

m7vm7v left a reply on How To Make A Relationship On Negative ID In Laravel 5.3 • 5 months ago

that is the way I wan it to work. Because the normal way is used for one operation and with the negative is for something else.

m7vm7v left a reply on How To Make A Relationship On Negative ID In Laravel 5.3 • 5 months ago

Yep but the relationship_id is negative but the model that interacts with is positive. That is why I need to connect them with hasOne() to take the oposite to the id I am giving it.

$this->hasOne('App\User', 2, -2); 

So I need to make something like -(-2).

m7vm7v left a reply on How To Make A Relationship On Negative ID In Laravel 5.3 • 5 months ago

Because I need to work like this.

m7vm7v started a new conversation How To Make A Relationship On Negative ID In Laravel 5.3 • 5 months ago

I have the relationship that works fine with positive numbers, But I need to work with negative:

$this->hasOne('App\User','id', 'user_from');

in users table the IDs are positive but the relationship need to point to the negative I mean that in messages table the user_from are negative -1, -2 but they are pointing to real 1, 2 id in the users table

I have tryed this but does not work:

$this->hasOne('App\User','id','-' . 'user_from');

Thanks for helping

2nd March, 2017

m7vm7v left a reply on How To Fire A New Option In Select2 With VueJS • 5 months ago

I see that the 'change' event is triggered but .val(new) is not....

m7vm7v started a new conversation How To Fire A New Option In Select2 With VueJS • 5 months ago

I need to add a new option and to be selected after I click a button with select2 and VueJS2.

I have a parent vue holding:

<template>
    <div>
        <question-selection :selected="answer" v-if="editable" :options="$parent.$data.answers[0]"  :questionID="questionID">
        <button @click="buttonClicked"></button>
    </div>
</template>
<script>

    export default {
    data: function() {
            return {
                questionID: 25,
            }
        },
    mounted(){
            vm.$on('input' + this.questionID, (selected) => {
                this.answer = selected;
            });
    },
    methods: {
        buttonClicked(){
            vm.$emit('button' + this.questionID, 'new button');
        }
    }

     }

In my Child component I have:

<template>
        <div>
                <select ref='select'>
                        <slot></slot>
                </select>
        </div>
</template>

<script>
    export default {
        props: ['options', 'questionID'],

        mounted: function () {
            $(this.$refs.select).select2();

            vm.$on('button' + this.questionID, (new) => {
                $(this.$refs.select).val(new).trigger('change.select2');
                $(this.$refs.select).val(new).trigger("change");
                $(this.$refs.select).val(new).change();
                $(this.$refs.select).val(new');
            });
        }
    }

</script>

I have tryed with all but none is working:

    $(this.$refs.select).val(new).trigger('change.select2');
            $(this.$refs.select).val(new).trigger("change");
            $(this.$refs.select).val(new).change();
            $(this.$refs.select).val(new');

Thanks for helping

1st March, 2017

m7vm7v left a reply on How To Bind The Value From Select In VueJS With Select2 • 5 months ago

I have created a new component:

'

export default { props: ['options', 'value'],
    mounted: function () {
        var vm = this;
        $(this.$refs.select)
            .select2({
                data: this.options,
                tags: true,
                createTag: function (params) {
                    return {
                        id: params.term,
                        text: params.term,
                        newOption: true
                    }
                },
                templateResult: function (data) {
                    var $result = $("<span></span>");
                    $result.text(data.text);
                    if (data.newOption) {
                        $result.append(" <em>(new)</em>");
                    }
                    return $result;
                }
            })
            .on('change', function (ev, args) {
                if (!(args && "ignore" in args)) {
                    vm.$emit('input', $(this).val());
                }
            });

        Vue.nextTick(() => {
            $(this.$refs.select)
                .val(this.value)
                .trigger('change', { ignore: true })
        });
    },
    watch: {
        value: function (value, oldValue) {
            // update value
            $(this.$refs.select)
                .val(this.value)
                .trigger('change', { ignore: true });
        },
        options: function (options) {
            // update options
            $(this.$refs.select).select2({ data: options })
        }
    },
    destroyed: function () {
        $(this.$refs.select).off().select2('destroy')
    }
}
.select2-container--default { min-width: 300px; max-width: 500px; }

'

And I am calling it in the parent.

My question is where am I listening for the event? here I am firing an event but if I am listening for it in the parent this event will fire all the parent listeners.

I have a page with 5 selects. So I am rendering them all in the page and then they all are having the same listener and when one of the select fires that it holds a value all of them are trggired. So if I select in the first one the first value then all the select would have the same value.

How can I properly need to listen for the event that I am firing in the component.

Thanks

m7vm7v started a new conversation How To Bind The Value From Select In VueJS With Select2 • 5 months ago

Hi, I am using select2 with VueJS and when I try to bind the value nothing is happening In my vue I have :

<select v-model="selected" class="answer">
            <option v-for="answer in answers">{{ answer }}</option>
        </select>

in mounted() have:

$(".answer").select2({
            width: '100%',
        });

So when I select a value in my "selected" remains empty but if I delete the class="answer" the value is binded to 'selected' or if I remove the .select2 entirelly it works again. But I need to apply select2 and to bind the selected to 'select'.

Thank you.

26th February, 2017

m7vm7v started a new conversation How Can The Administrator Be Logged In As A Different User In Laravel 5.3? • 5 months ago

Hi

I need to make the administrator to login as a different user and when he is finished with his work the admin would be logged again in his account with a button for example.

The admin has access to:

Route::get('/users/{id}/login-as-me', function ($id){
    auth()->loginUsingId($id);

    return redirect('/');
})->middleware('administrator');

So for example the admin need to be logged in as a user with id 5, then he visits '/users/5/login-as-me' and he is logged as should. How can I make a button that will login me as admin again.

I have tryed

Route::get('/users/{id}/login-as-me', function ($id){
    auth()->onceUsingId($id);

    return view('home');
})->middleware('administrator');

But it works only for 1 request. I need the administrator to be logged as the user with id 5 in all the requests he needs to and when he is finished to undo the auth()->loginUsingId($id); and go back logged as admin.

Thanks for the help

25th February, 2017

m7vm7v started a new conversation How Can I Access Children Data From The Parent In VueJS2? • 5 months ago

How can I take the data from a chid component in VueJS2.

If I want to access some method in the parent from the child I would do :

this.$parent.$options.methods.someParentMethod(data);

But I do want to do the reverce. I need access to the data in the child component from the parent. Specifically I need to delete the child data "form". Should look something like :

this.$child.$options.data.form

But I do not have the access like this.

Thanks for your help

22nd February, 2017

m7vm7v started a new conversation How To Rearrange The Model Data Output • 6 months ago

Hi I need to take out the Model data in json but not the traditional way.

When I get the data from the Model

self::orderBy('created_at', 'desc')->get();

and return it, I get something like:

[{id: 1, prop: 'Value'},{id: 2, prop: 'Value2'}]

I need to rearrange the output to look like:

{"data" : [['1', 'Value'], ['2', 'Value2']]}

So far I have created in the Model public $data = []; and I am filling $final = new self; with:

foreach ($models as $model){
        array_push($final->data, [$model->id, $model->prop]);
    }

and if I return $final->data I have

[['1', 'Value'], ['2', 'Value2']]

But if I try to return $final I got only []

Thanks for helping

21st February, 2017

m7vm7v left a reply on How I Can Send Email With 'from()' In Laravel 5.3 • 6 months ago

Thanks mate. That worked

m7vm7v started a new conversation How I Can Send Email With 'from()' In Laravel 5.3 • 6 months ago

Hello, so far in my email build I have:

return $this->from(['address' => [email protected]', 'name' => 'The name'])
    ->subject('Register')
        ->view('emails.login')
        ->with([
            'token' => $this->token,
        ]);

When I receive the email it looks like:

from -> [email protected] with subject of the meil "Register"

But I would like to look:

from -> The name with subject of the meil "Register"

Like in the example: https://ibb.co/fxbkDv I need to look like the second email, but now it looks like the first

Thanks

14th February, 2017

m7vm7v started a new conversation The Series Information Is Not Updating Here In Laracast! • 6 months ago

Hi, I do not know is this a problem that appears only on my side but It is a bit annoying.

When I start watching some of the series here In Laracast the percentage is growing as expected until it reaches COMPLETED but after when a new lesson is added the COMPLETED sign still appears. Am I thinking wrong or it should goes again to percentage because it is not completed and when I visit it all the lessons appears green as watched but the last are grey... It is all good but some of us relay on this COMPLETED sign and so many times I have seen it without checking is there something new only because I trusted the COMPLETED sign. Can you prove that my logic is not right and why? I do not see that is the way it should be. What do you thing?

Thanks

6th February, 2017

m7vm7v left a reply on Eloquent Join Statement • 6 months ago

You could create a Model for the Worlds

php artisan make:model World

So in the User model you can have this method:

public function worlds()
    {
        return $this->hasMany('App\World');
    }

So after you can collect all the worlds that the user is assosiated with like so:

$user = auth()->user()->with('worlds');

2nd February, 2017

m7vm7v left a reply on Vue.js:525 [Vue Warn]: Property Or Method "refresh" Is Not Defined On The Instance But Referenced During Render. Make Sure To Declare Reactive Data Properties In The Data Option After Update To Vue 2.0 • 6 months ago

I have recrated your project on my Laravel 5.3 project and it is working fine. Are you useng laravel. If so there is better way of creating the project. Let me know if this is Laravel project so I can give you one more try.

30th January, 2017

m7vm7v left a reply on SQLSTATE[42000]: Syntax Error Or Access Violation: 1064 • 6 months ago

Or you can try:

$messages  = DB::table('message')
        ->where('message.msg_emetteurid', $id)
        ->orWhere('message.msg_recepteurid', $id)
    ->join('users as u1', 'message.msg_emetteurid', '=', 'u1.id')
    ->join('users as u1', 'message.msg_recepteurid', '=', 'u2.id')
        ->select('u1.firstName as sender','u2.firstName as receiver','message.message')
        ->get();

29th January, 2017

m7vm7v left a reply on SQLSTATE[42000]: Syntax Error Or Access Violation: 1064 • 6 months ago

Have you concidered using relationships: https://laravel.com/docs/5.4/eloquent-relationships

For example in your Message controller you can have:

public function emetUser()
   {
       return $this->belongsTo('App\User', 'msg_emetteurid');
    }

public function recepUser()
    {
        return $this->belongsTo('App\User', 'msg_recepteurid');
    }

And then you query would look like:

$messages  = Message::where('message.msg_emetteurid', $id)
            ->orWhere('message.msg_recepteurid', $id)
            ->select('u1.firstName as sender','u2.firstName as  receiver','message.message')
->with('emetUser', 'recepUser')
            ->get();

28th January, 2017

m7vm7v left a reply on Vue.js:525 [Vue Warn]: Property Or Method "refresh" Is Not Defined On The Instance But Referenced During Render. Make Sure To Declare Reactive Data Properties In The Data Option After Update To Vue 2.0 • 6 months ago

Try:

methods: {

        loadData() {
            let self = this;

             this.$http.get('/api/games')
            .then(function (response) {
            

                        response.json()
                    .then(function (games) {
                                self.games = games;
                                console.log(games);
                    });

                });
        },

        refresh() {
                this.loadData();
                setInterval(function () {
                    this.loadData();
            }.bind(this), 30000);
        }
  
    },


    mounted() {
        this.$nextTick(function () {

                this.refresh();
        })
    }

27th January, 2017

m7vm7v left a reply on Override Artisan Commands? • 6 months ago

So what is the problem of runing

 php artisan make:command MineMigration

go to app/Console/Commands/MineMigration.php

protected $signature = 'migration2';

in public function handle(){} you can place all the methods you would like to go trought. When you are ready you can run:

php artisan migration2

then you can create alias php artisan migrate2='mig' So even running mig will run your way.

m7vm7v left a reply on Why V-if It Is Not Dynamic In VueJS2 • 6 months ago

As I said the event is triggered. I have created a bus that renames the emit and on to fire and listen. So that is working fine. If a put alert it shows when it is triggered. So it is not from the event.

Thanks

m7vm7v left a reply on Why V-if It Is Not Dynamic In VueJS2 • 6 months ago

I have tried it mate but it is still the same.

m7vm7v left a reply on Why V-if It Is Not Dynamic In VueJS2 • 6 months ago

I am using the data() from a component. So then I need to use it like this. Only in the root we can use your way. Correct me if I am wrong.

Thanks @DarkRoast

m7vm7v started a new conversation Why V-if It Is Not Dynamic In VueJS2 • 6 months ago

Hi, In my case v-if and else are not reactive in VueJS.

I have:

<div v-if="logged">
    logged
</div>
<div v-else>
    not logged
</div>


data: () => {
        return {
            logged: false,
        }
    },

mounted: () => {

        Event.listen('userHasLoggedIn', () =>{
            this.logged = true;
        });
    },

When the event userHasLoggedIn has been fired the reactivity of the if-else does not work. At first we are not logged and it shows 'not logged', but when I log in the event userHasLoggedIn is fired so the value for this.logged is true.... So after the page should show 'logged' but it still shows 'not logged'. If the value is changed it should affect the rendered page but for if-else that is not working. Can you give me some ideas what to do here.

Thanks for your time.

m7vm7v left a reply on Override Artisan Commands? • 6 months ago

Why do not just leave it like it is and create your own command:

https://laravel.com/docs/5.3/artisan

m7vm7v left a reply on Vue Component Is Not Refreshing After Running Gulp • 6 months ago

Yes mate. Or kind of. I have a work around that is working perfect so far.

Just add

    .version('public/js/app.js');

in the end and in the view file do not include the app.js but the verion file like so:

<script src="{{ elixir('js/app.js') }}"></script>

It works great here. I hope would work for you too. Let me know if so.

Cheers.

25th January, 2017

m7vm7v started a new conversation How To Verify The Domain With MailGun • 6 months ago

Hi, I have created a new domain in MailGun, and setup all in .env and config/services.php And now when I send a message it is all working but in mailgun it sais that the domain is not verified and when I click on 'Verify DNS Records Now' the current value remins empty.

What should I do to verify my domain. Thanks for your time

18th January, 2017

m7vm7v left a reply on How To Remove An Item From A List With Given ID In VueJS • 7 months ago

Thanks @pittaya That is the right one with only one difference. No need of 'bla' just '1'. Thanks alot.

m7vm7v left a reply on How To Remove An Item From A List With Given ID In VueJS • 7 months ago

I have tryed with

delete list[bla];

and

this.list.remove(bla);

But still no success.

m7vm7v left a reply on How To Remove An Item From A List With Given ID In VueJS • 7 months ago

$remove seems to be depricated in VueJS 2

I have tryed:

let bla = list.find( (stack) => {
                return stack.id === itemID;
            });

So when I

console.log(bla); I got the object 

But when I

this.list.splice( bla, 1);

It removes allways the first element in the list, not the selected one.

Edit Your Profile
Update

Want to change your profile photo? We pull from gravatar.com.