Show one row

Show one row

Coder102Coder102 Posts: 78Questions: 2Answers: 0
edited November 2020 in Free community support
 var datos= {
        a: json.data.a,
        b: json.data.b,
        c: json.data.c,
        d: json.data.d,
        e: json.data.e,
      };

      var dog= json.data.animals.questions;
      var animals = questions.map(function (a) {
        return {
          name: a.name,
        };
      });
 table = $("#table").DataTable({
        searching: false,
        info: false,
        paging: false,
        ordering: false,
        data: animals,
        columns: [
          {
            title: "Datos",
            data: null,
            render: function (data, type, row) {
              return "a: "+datos.a+ "<br>"+
              "b: "+datos.b+ "<br>"+
              "c: "+datos.c+ "<br>"+
              "d: "+datos.d+ "<br>"+
              "e: "+datos.e+ "<br>";
            },
          }, 
        ],
      });

Hello, I want to show the data row in table only once, it is shown to me many times by the animal map.
If I put animals in data it doesn't work for me

Replies

  • colincolin Posts: 15,240Questions: 1Answers: 2,599

    We're happy to take a look, but as per the forum rules, please link to a test case - a test case that replicates the issue will ensure you'll get a quick and accurate response. Information on how to create a test case (if you aren't able to link to the page you are working on) is available here.

    Cheers,

    Colin

This discussion has been closed.