Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Sara 5 posts 87 karma points notactivated
    May 18, 2017 @ 05:09
    Sara
    2

    Delete an Item from Key Value List

    If any item wants to be deleted from Key Value pairs , Always the last one will be deleted :

    So in App_Plugins -> KeyValueEditor -> "KeyValueEditorController.js" we should change the delete code as below:

    $scope.deleteKeyValue = function (item) {
        var index = $scope.model.value.indexOf(item);
        $scope.model.value.splice(index, 1);
    };
    

    at the moment ,it is

    $scope.deleteKeyValue = function (item) {
        $scope.model.value.pop(item); 
    };
    
  • Tom van Enckevort 107 posts 429 karma points
    Mar 26, 2019 @ 10:07
    Tom van Enckevort
    0

    Thanks Sara for sharing this fix!

    I came across this exact issue today and was able to fix it quickly using your suggested fix.

Please Sign in or register to post replies

Write your reply to:

Draft