how can i show from database in modal bootsrap which is data type is json

how can i show from database in modal bootsrap which is data type is json

Hi, i don't know how to pass value from database if check box or radio button put it in and also images, i'm trying to make variable which is save the data for checkbox but still no t works even errors please see line 14-21 i make comment so you gusy can guide me, but for all input type text already success
so here is my script, please review , thanks millions time

  1. //edit data product
  2. $('.edit_button').on("click", function(e) {
  3.     var id = $(this).data('id');  
  4.      $.ajax({
  5.         url: base_url + "product/edit/"+id,
  6.         type: "GET",
  7.         dataType: "JSON",
  8.         success: function(data)
  9.         {
  10.           
  11.  var a= data.product_status;

  12.             if (a!='') {
  13.                 console.log('status has value');
  14.                 $('#status').prop('checked', true);
  15.              } else{
  16.                 console.log('status has no value');
  17.                 $('#status').prop('checked', false);
  18.             }
  19.             
  20.             $('[name="id_brand"]').val(data.id_brand);
  21.             $('[name="merk"]').val(data.name_brand);
  22.             $('[name="id_tipe"]').val(data.id_tipe);
  23.             $('[name="tipe"]').val(data.name_tipe);
  24.             $('[name="product_toko"]').val(data.product_toko);
  25.             $('[name="product_harga"]').val(data.product_harga);
  26.             $('[name="product_keterangan"]').val(data.product_keterangan);
  27.             
  28.             $('#modal_form').modal('show'); // show bootstrap modal when complete loaded
  29.             $('.modal-title').text('Edit Product'); // Set title to Bootstrap modal title
  30.  
  31.         },
  32.         error: function (jqXHR, textStatus, errorThrown)
  33.         {
  34.             alert('Error get data from ajax');
  35.         }
  36.  });
  37.       });
edit i have success check box then how can i show image in modal, is it same like checkbox way 

  1. save data in json with variable 
  2. then use jquery to put images with keyword goolging src !
am i right to handle images in modal bootsrap ? thanks