title: Add remove tr td row without click open 4 field and after click one by one open?
body: <p>I  need to add remove tr td row without click onload 4 tr td row open after click one by one open tr td row all need script not need static. please help..</p>
  <p><strong>html code</strong></p>
  <pre><code>&lt;html&gt;
  &lt;head&gt;
  &lt;script src=&quot;https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js&quot;&gt;&lt;/script&gt;
  &lt;/head&gt;
     &lt;table id=&quot;table-details&quot;&gt;&lt;/table&gt;
     &lt;button class=&quot;btn-add-more&quot;&gt;Add Rows&lt;/button&gt;
  &lt;/html&gt;
  </code></pre>
  <p><strong>Script</strong></p>
  <pre><code>$(&quot;body&quot;).on('click', '.btn-add-more', function (e) {
    e.preventDefault();
    var rows = $(&quot;.jdr1&quot;).length;
    var limit = 1;
    // In the first click append 3 rows, then 1 row per click
    if (rows &lt; 3) limit = 3;
     for (let i=0; i&lt;limit; i++) {
        var $sr = ($(&quot;.jdr1&quot;).length + 1);
        var rowid = Math.random();
        var $html = '&lt;tr class=&quot;jdr1&quot; id=&quot;' + rowid + '&quot;&gt;' +
             '&lt;td&gt;&lt;span class=&quot;btn btn-sm btn-default&quot;&gt;' + $sr + '&lt;/span&gt;&lt;input type=&quot;hidden&quot; name=&quot;count[]&quot; value=&quot;'+Math.floor((Math.random() * 10000) + 1)+'&quot;&gt;&lt;/td&gt;' +
             '&lt;td&gt;&lt;input type=&quot;text&quot; required=&quot;&quot; class=&quot;form-control input-sm title&quot; placeholder=&quot;Medicine&quot; name=&quot;medicine[]&quot;&gt;&lt;/td&gt;' +
             '&lt;td&gt;&lt;input type=&quot;text&quot; name=&quot;medicine_qty[]&quot; placeholder=&quot;Potency&quot; class=&quot;form-control input-sm&quot;&gt;&lt;/td&gt;' +
             '&lt;td&gt;&lt;input type=&quot;text&quot; name=&quot;medicine_time[]&quot; placeholder=&quot;Description&quot; class=&quot;form-control input-sm&quot;&gt;&lt;/td&gt;' +
             '&lt;td&gt;&lt;input type=&quot;text&quot; name=&quot;remark[]&quot; placeholder=&quot;Add/Note&quot; class=&quot;form-control input-sm&quot;&gt;&lt;/td&gt;' + '&lt;td&gt;&lt;button class=&quot;btn btn-sm btn-warning btn-remove-detail-row&quot;&gt;&lt;i class=&quot;glyphicon glyphicon-remove&quot;&gt;Remove&lt;/i&gt;&lt;/button&gt;    &lt;/td&gt;'+
             '&lt;/tr&gt;';
     
     $(&quot;#table-details&quot;).append($html);
     }
  })
  </code></pre>