function search_data(data, key, search) {

  let result = {};

  Object.keys(data).forEach(function(index) {

    let temp = data[index];

    if(temp[key].toLowerCase().indexOf(search.toLowerCase()) !== -1) {

      result[index] = temp;

    }

  });

  return {

    status: true,

    data: result

  };

}