Uncaught (in promise) Error: Unexpected token ‘S’, “System.Inv”… is not a valid JSON [closed]

Me pasaron un API para poder cuadrar algunas cosas con un bot que tengo, el problema esta en que cuando ejecuto el API y doy click en BUSCAR todo bien pero si marco la casilla de INCLUIR CASTE DE PASO me saltan los errores que están en la foto, revise el archivo de ASP.NETCORE que tengo para ver si algún modelo estaba mal y lo corregí pero aun así tengo el mismo error.

[enter image description here](https://i.stack.imgur.com/yYLIO.jpg)

Estas son las fotos de la APP y los errores que aparecen.

Este es mi código de Tollbooths.js

enter image description here

How to Slow Down Axios Get Rate in React App?

I’m currently facing an issue where I’m making too many requests to a third-party API too quickly, exceeding the API’s request limit rate and resulting in a 409 error status code. My goal is to repeatedly make requests to the API every 5 seconds (the API’s rate limit is 1 request per second) but right now it seems that my program is repeatedly making nonstop requests without break.

I’ve tried wrapping the function that makes the Axios.get call (getCoordinates()) in a setInterval() method with a 5s interval length but it seems to have absolutely no effect; I’m still nonstop requesting without break and ending up with 409 every time. Am I placing things in the wrong spot?

Error
Code

How to make material in three.js change between two colours?

So I made snow but i didnt want it to just be white i wanted random snow flakes to be light blue too, I used an array to create it and randomised the positions but its really just the material colour, please can someone help me with this.

materialSnowFlakes.push (new THREE.MeshPhongMaterial({color: 0xFFFFFF0); // wanna add the blue here

Thank you!!

react-tracked re-rendering components that aren’t updated

I’m trying to learn how to use react-tracked for a project and I have a simple sandbox here. The problem I’m having is clicking on one of the components to increment it is causing both to re-render according to React Devtools.

Clicking one component causes both to highlight when I enable “Highlight updates when components render”. The profiler shows both components under “What caused this update?”, but only shows one component rendering in the flamegraph. I don’t know if it’s a bug with react-tracked or React Devtools, or maybe I’m misunderstanding how to use either of them?

How using javascript (no jquery) to retrieve all markup between two tags into a string

Assuming a screen element has been selected using something like const foo = document.getElementById(“#foo”) I’d like to retrieve all markup between that elements tags <div id="foo">...</div>

The issue I find is it only returns me one level in the dom tree. Is there a way to retrieve all markup? ie. for <div id="foo"> <ul><li>item1</li><li>item2</li></ul></div>

React component rendered with createPortal with state controlled by parents will not rerender on state change

My issue is explained on this live example : https://stackblitz.com/edit/stackblitz-starters-qcvjsz?file=src%2FApp.tsx

Basically I’m passing a list of options to a radio button list, with the state and setter to a child component rendered with createPortal, however when the options are clicked in the child the parent component updates it’s state, but not the child, so the radio never have the checked status.

main_script.js:51 ‘NoneType’ object has no attribute ‘get’ [closed]

I have an app that runs locally, but not on Python Anywhere. My current error is

main_script.js:51 ‘NoneType’ object has no attribute ‘get’
updateOverlay @main_script.js:51
setInterval (async)
(anonymous) @main_script.js:80

From main_script.js

async function updateOverlay()
{
    if (animation_id != 0)
        return;
    const response = await fetch(`/api/character-hp/${CHARACTER_ID}`);
    if (!response.ok)
        return;
    const data = await response.json();
    if (data.error) {
        console.error(data.error);
        return;
    }

    const prev_hp_percent = Math.floor(100 * character_info.current_hp / character_info.max_hp);

    character_info.max_hp = data.max;
    character_info.temp_hp = data.temp;
    character_info.current_hp = data.current;
    character_info.char_url = data.image;
    character_info.char_id = data.character_id;

    const hp_percent = Math.floor(100 * character_info.current_hp / character_info.max_hp);
    const hp_bar = document.getElementById("hp-bar");

    //feeds portrait "char-url" by calling "char_url"
    const char_url = character_info.char_url;
    document.getElementById("char-url").src = character_info.char_url;

    // const char_id = CHARACTER_ID;
    // var myOtherUrl = "https://www.dndbeyond.com/characters/" + (char_id);

    if (prev_hp_percent != hp_percent) {
        current_animation_frame = 1;
        animation_id = setInterval(() => {animateHPBar(hp_bar, prev_hp_percent, hp_percent, 50)}, 12);
    }
}
    // const char_id = CHARACTER_ID;
    // var myOtherUrl = "https://www.dndbeyond.com/characters/" + (110222058);
 const id = setInterval(updateOverlay, 5000);```



I'm stuck.  I don't know what to do.

I am getting a Invalid parameter error, need help 😴 [closed]

I am writing code for mobile number verification in wix using twilio. But I am getting an un accepted error whenever I click on confirm button. Error on line no 25

Here is the code Invalid parameter error To

import { getSecret } from 'wix-secrets-backend';

export const sendverificationcode = async (phoneNumber) => {
    const accountSid = await getSecret('Twilio_Account_SID');
    const authToken = await getSecret('Twilio_Auth_Token');
    const serviceId = "xxxxxxxxxxxx";
    const client = require('twilio')(accountSid, authToken);
    const verification = await client.verify.v2.services(serviceId)
        .verifications
        .create({ to: phoneNumber, channel: 'sms' })
        // .then(verification => console.log(verification.status));
        return verification.status;
}

export const checkverificationcode = async (phoneNumber, code) => {
    const accountSid = await getSecret('Twilio_Account_SID');
    const authToken = await getSecret('Twilio_Auth_Token');
    const serviceId = "xxxxxxxxxxxxx";
    const client = require('twilio')(accountSid, authToken);
    const verificationCheck = await client.verify.v2.services(serviceId)
        .verificationChecks
        .create({ To: phoneNumber, code})
        // .then(verification_check => console.log(verification_check.status));
          return verificationCheck.status;

}

I have looked the code, it’s my first time implementing in wix

Need help your text

Append to (update) JSON file in a local directory using JavaScript on a locally hosted web server [closed]

How can I go about updating a local JSON file for a website I am running locally?

This JSON file is the same directory as the html and javascript files, and is first fetched and used to populate a table on the website. Scanning a custom QR code (with url parameters decoded), adds an item into this table. I want to then convert that table back into a json object and append it to the local JSON file.

How to modify/change data loaded in the frontmatter in Astro?

I am using Astro to build a basic application where I am loading a JSON Array from a file using import syntax in frontmatter. Now I want to split data in half on every click depending which side of the half you have clicked. I have made a demo in codepen please check.

I just need to understand how do I load a data in frontMatter from API or local file and modify it. I was using script tag to write my methods to do the operations but I cant seem to access the data in script and also I can’t access data from script tag into my markup.

---
import Layout from '../layouts/Layout.astro';
import Card from "../components/Card.astro";
import messages from '../content/messages_arr.json'; /* <-- frontmatter */
---

<script>
  export let data_A =  "Data A"
  let data_B =  "Data B"
  
  export let methodA = () =>{ console.log(A)}
  let methodB = () =>{ console.log(B)}
  
</script>

<Layout> /* <-- markup */
<div>
  {message}
  {data_A}
  {data_B}
  <button onclick={methodA}>METHOD A</button>
  <button onclick={methodB}>METHOD B</button>
</div>
</Layout>

Google Sheet AppScript Dynamic Notes

So I’m trying to create a spreadsheet with dynamic tooltips using setNote() in AppScript. The user makes a selection from a dropdown and depending on the selection, it will display differing tooltips. Some of them works just fine… The others do not! And I cannot figure it out! Below are the ones that do not work…

function onEdit() {
  var ss = SpreadsheetApp.getActiveSpreadsheet();
  var sheet = ss.getSheets()[0];
  var asheet = ss.getActiveSheet();
  var aname = asheet.getName();
  var arange = ss.getActiveRange().getA1Notation();

  var space = sheet.getRange("Database!$A$1").getDisplayValue();

  var disc = sheet.getRange("Sheet!$CK$121:$CK$124");
  var tilt = sheet.getRange("Sheet!$BC$184:$BC$188");

  // Discipline Notes
  var discdesc1 = sheet.getRange("Database!$BZ$6").getDisplayValue();
  var discby1 = sheet.getRange("Database!$CA$6").getDisplayValue();
  var disc1 = "Used By: " + discby1 + space + discdesc1;

  var discdesc2 = sheet.getRange("Database!$BZ$7").getDisplayValue();
  var discby2 = sheet.getRange("Database!$CA$7").getDisplayValue();
  var disc2 = "Used By: " + discby2 + space + discdesc2;

  const discnotes = [
    [disc1],
    [""],
    [""],
    [disc2]
  ];

  var tiltdesc1 = sheet.getRange("Database!$CO$6").getDisplayValue();
  var tiltpg1 = sheet.getRange("Database!$CP$6").getDisplayValue();
  var tilt1 = tiltdesc1 + space + tiltpg1;

  var tiltdesc2 = sheet.getRange("Database!$CO$7").getDisplayValue();
  var tiltpg2 = sheet.getRange("Database!$CP$7").getDisplayValue();
  var tilt2 = tiltdesc2 + space + tiltpg2;

  var tiltdesc3 = sheet.getRange("Database!$CO$8").getDisplayValue();
  var tiltpg3 = sheet.getRange("Database!$CP$8").getDisplayValue();
  var tilt3 = tiltdesc3 + space + tiltpg3;

  const tiltnotes = [
    [tilt1],
    [""],
    [tilt2],
    [""],
    [tilt3],
    [""]
  ];

  if (aname == 'Sheet' && (arange == 'BC121' || 'BC124')){

    disc.setNotes(discnotes);

  };

  if (aname == 'Sheet' && (arange == 'BC184' || 'BC186' || 'BC188')){

    tilt.setNotes(tiltnotes);

  };
}

I tried this:

  if (aname == 'Sheet' && (arange == 'BC121' || 'BC124')){

    disc.setNotes(discnotes);

  } else if (aname == 'Sheet' && (arange == 'BC184' || 'BC186' || 'BC188')){

    tilt.setNotes(tiltnotes);

  };

Also tried this:

  if (aname == 'Sheet' && (arange == 'BC121' || arange == 'BC124')){

    disc.setNotes(discnotes);

  } else if (aname == 'Sheet' && (arange == 'BC184' || arange == 'BC186' || arange == 'BC188')){

    tilt.setNotes(tiltnotes);

  };

And even tried this!

  if (aname == 'Sheet'){
    if (arange == 'BC121'){

      var disc = sheet.getRange("Sheet!$CK$121");
      var discdesc1 = sheet.getRange("Database!$BZ$6").getDisplayValue();
      var discby1 = sheet.getRange("Database!$CA$6").getDisplayValue();
      var discnotes = "Used By: " + discby1 + space + discdesc1;

      disc.setNote(discnotes);

    } else if (arange == 'BA124'){

      var disc = sheet.getRange("Sheet!$CK$124");
      var discdesc2 = sheet.getRange("Database!$BZ$7").getDisplayValue();
      var discby2 = sheet.getRange("Database!$CA$7").getDisplayValue();
      var discnotes = "Used By: " + discby2 + space + discdesc2;

      disc.setNote(discnotes);

    }
  }

};

I am expecting The “desc” and “by” to get pulled from the Database sheet, which will then join together in discnotes like:

Used By: (by’s answer)

(desc’s answer)

And that will post as a Note into the range CK121 and CK124. Same goes for tiltnotes. But they’re just not happening. Either the notes don’t update or they disappear altogether. And as I’ve said above, the others work just fine and are copies of the first example I posted. Only difference with those are that they’re not arrays, which is why I tried the 3rd attempt. Did not work.

PS: The reason I’m not using onEdit(e) is because I cannot for the life of me, figure out how to use the event objects…

Python webscraping with Chromium browser cannot load Javascript but Chrome can

I’m trying to webscrape a particular url using requests-html module which uses Chromium browser. However Chromium couldn’t load what seem to be the Javascript portion and triggers timeout error. I thought html.render() would have rendered any Javascript code. I tested another python script using Selenium (with Google Chrome webdriver) and it ran perfectly.

So I tried to launch Chromium.exe manually (from %localappdata%pyppeteerpyppeteerlocal-chromium) and browse the url directly, it takes forever to load the Javascript portion. My Chromium version is [71.0.3542.0 (Developer Build) (64-bit)] and it was installed the first time I ran my python script below. What should I do to make Chromium support Javascript?

from requests_html import HTMLSession

webURL = "https://mphonline.com/collections/architecture-landscaping"
session = HTMLSession(pyppeteer_kwargs = {'handleSIGINT' : False,
                               'handleSIGTERM': False,
                               'handleSIGHUP': False,
                               'headless': False,
                               }
                           )

root = session.get(webURL)
root.html.render(timeout= 30, keep_page=True)    # default timeout is 8sec

titlesxpath = "//div[contains(@class, 'boost-sd__product-title')]"
titles = root.html.xpath(titlesxpath)  # find title element
for title in titles:
    print(title.text)

session.close()

How to calc CheckSum8 Modulo 256

i need to calc checksum like this site
https://www.scadacore.com/tools/programming-calculators/online-checksum-calculator/

for hex 313233343536373839 the site calc DD

with my function i get 168, how exactly to do it?

function calculateChecksum8Modulo256(data) {
  let checksum = 0;
  for (let i = 0; i < data.length; i++) {
    checksum = (checksum + data.charCodeAt(i)) % 256;
  }
  return checksum;
}

let res = calculateChecksum8Modulo256('313233343536373839')

How to use JavaScript to prevent the click events on child elements and inhibit changes to the mouse cursor style

I hope that only the click events within the areas of .box1 and .box2 will be prevented, and the mouse cursor style will not change. My current code is as follows, where I check the value of e.target, but this also prevents click events within the .boxs area. Additionally, I’ve set pointer-events to none, but the mouse cursor style still changes. I noticed that there’s a similar question, but there isn’t a better answer for my issue.
56886001

const wrap = document.querySelector('.wrap');

wrap.addEventListener('click', (event) => {
  if (event.target === wrap) {
    console.log('wrap');
  }
});
.wrap {
  width: 500px;
  height: 500px;
  background-color: lightcyan;
  cursor: pointer;
}

.boxs {
  width: 300px;
  border: 2px solid black;
}

.box1 {
  width: 250px;
  height: 250px;
  background-color: bisque;
  pointer-events: none;
}

.box2 {
  width: 250px;
  height: 250px;
  background-color: azure;
  pointer-events: none;
}
<div class="wrap">
  <div class="boxs">
    <div class="box1"></div>
    <div class="box2"></div>
  </div>
</div>

How to store dynamic HTML table to localStorage in javascript

New coder here. I have a dynamic html table with details by the user input and the time they input the details. But I need to store the data that even if I refresh or close the browser, it will retain..

Here is the html code:

<!DOCTYPE html>
<html lang="en">
<head>

    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width,initial-scale=1.0">
    <title>Down Logsheet</title>

    <!-- css file link -->
    <link rel="stylesheet" href="index.css">
</head>   
<body>
    <div class="parent">
        <div class="add-logsheet">           
        </div>   
        <div class="logsheet-table">
            <h3 class="title">エラー履歴システム</h3>
            
            <p1 id="title">入力情報</p1>
            <div class="sub-box">
                
                <div class="operatorside"style="width:50%; float:left">
                <label id="operator">依頼者</label>

                <input type="text"
                id="lotid"
                name="lotid"
                value=""
                style="width:20%"
                placeholder="ロットNo。">

                <input type="text"
                id="employeeid"
                name="employeeid"
                value=""
                style="width:20%"
                placeholder="依頼者名を入力">

                <!--Enter Error instead of selection-->
                <!--<input type="text"
                id="errorid"
                name="errorid"
                value=""
                placeholder="入力エラー内容">-->
                <!--<div id="div1"></div>-->
                
                <select style="width:20%" name="errorid" id="errorid" type="text" onchange="showfield(this.options[this.selectedIndex].value)">
                    <option value="noinput" disabled selected>エラーを選択</option>
                    <option value="電極スクラッチ">電極スクラッチ</option>
                    <option value="フィーダNG">フィーダNG</option>
                    <option value="電極崩壊">電極崩壊</option>
                    <option value="突出誤差">突出誤差</option>
                    <option value="障害">障害</option> 
                    <option value="Other">その他</option>
                      
                </select>

                <!--<a href=A>--><button id="submit-button2" class="btn"onclick="firstinput()">提出する</button><!--</a>-->
                <div id="div1"></div>
                </div>

                <div class="maintenanceside" style="width:50%; float:right">
                <label id="maintenance">KP</label>
                <input type="text"
                id="maintenanceid"
                name="maintenanceid"
                value=""
                style="width:20%"  
                placeholder="KPを入力"
                disabled>
                        
                <input type="text"
                id="actiondone"
                name="actiondone"
                style="width:20%"  
                placeholder="是正措置"
                disabled>

                <select style="width:20%" disabled name="ackid" id="ackid" type="text">
                    <option value="" disabled selected>謝辞</option>
                    <option value="NOT OK">NOT OK</option>
                    <option value="OK">OK</option>
                </select>
                <!--<a href=a>--><button disabled id="submit-button1" class="btn" onclick="addToTable()">提出する</button><!--</a><br>-->               
                
                </div>
            </div>
            <div class="table-body2">
                <!--<label for="StatusTable" style="text-align: center;" style="width:100%">STATUS</label>-->
                <!--<p style="text-align: center;">STATUS</p>-->
                
                <table id="StatusTable" style="width=100%" border="2">
                    <caption class="captionstatus">情報</caption>
                    <thead>
                        <tr>
                            <!--<th style="width:5%">No.</th>-->
                            <th style="width:20%">ロットNo。</th> 
                            <th style="width:20%">発生日時</th>
                            <th style="width:20%">依頼者</th>
                            <th style="width:40%">エラー内容</th>  
                            <!--<th style="width:10%">KP</th>-->            
                        </tr>

                    </thead>
                    <tbody id="status">
                    </tbody>
                </table>
            </div>
            <div class="table-body">               
                <!--<label for="myTable" style="text-align: left">機器No. SW 39</label>-->
                <table id="myTable" style="width=100%" border ="2">
                    <caption class="mainstatus">機器No.<input type="text" id="machineid" value="" style="width:5%"> </caption>
                    <thead>
                        <tr>
                            <th style="width:5%">番号No.</th>
                            <th style="width:5%">機器No.</th>
                            <th style="width:5%">ロットNo。</th> 
                            <th style="width:10%">依頼者</th>
                            <th style="width:15%">エラー内容</th>
                            <th style="width:10%">KP</th>
                            <th style="width:15%">是正措置</th>
                            <th style="width:10%">操作可能</th>
                            <th style="width:10%">発生日時</th>
                            <th style="width:10%">終了日時</th> 
                            <th style="width:10%">合計時間 (分)</th> 
                        </tr>
                    </thead>
                    <tbody id="main">

                    </tbody>
                </table>

                <h3 class="maintablefooter" id="no-data">機器のダウンタイム監視(No Data Available)</h3>
                <div class="footer">
                    
                <button id="exportToExcel" onclick="exportTableToExcel('myTable')">エクスポートデータ(.xls)</button>
                <!--<button id="button5" class="btn"onclick="TestLang()">try</button>-->
                <p1 type="text" value="datenow" id="datenow"></p1>
                  
                <!-- <button id="submit-button3" class="btn"onclick="save_data()">SAVE</button> -->
                <!-- <button id="submit-button4" class="btn"onclick="load_data()">LOAD</button> -->
                
                </div>
            </div>      
        </div> 
    </div>
    
</body> 


<!--java script source file-->

   <!--script-->
<script type="text/javascript" src="index.js"></script>
   </html>
<script type="text/javascript" src="tabletoexcel.js"></script>
</html>
<script type="text/javascript" src="datetime.js"></script>
</html>
<script type="text/javascript" src="tableborder.js"></script>
</html>

The table that I want to retain is the ‘myTable’ with a tbody ‘main’

Here is the javascript:

var employeeid= [];
var errorid= [];
var machineid=[];
var index= [];
var maintenanceid= [];
var ackid= [];
var c= 1;
var g= 1;
var time1= [];
var time2= [];
var actiondone= [];
var employeeid2=[];
var errorid2=[];
var index1= [];
var lotid= [];
var lotid2= [];
var time1st= [];
var totaltime =[];
var endTime=[];
var starT=[];
var time3=[];
var errorencountered=[];
var tr4=[];
var trial=[];

function firstinput(){
   
    var sub11= document.getElementById('employeeid').value;    
    let errorencountered=document.getElementById('errorid').value;
    if (errorencountered==='Other'){
      var sub22=document.getElementById('others123').value;
    }
    else {
      var sub22=document.getElementById('errorid').value;
    }
   
    var sub33= document.getElementById('lotid').value;
    const sub55= new Date();  
    starT=new Date().getTime();
    var sub69=document.getElementById('machineid').value;

    if(sub11&&sub22&&sub69 !=='')
    {

      employeeid= [...employeeid,sub11];
      errorid= [...errorid,sub22];
      time1= [...time1,sub55];
      index1= [...index1,g];  
      lotid= [...lotid,sub33];
  
    displayTable1();

    }
    else
        alert("入力不完全(Input Incomplete)");
}



document.getElementById('status').appendChild(tr4);
}

function displayTable1(){  
  const length= employeeid.length;
  tr4=document.createElement('tr');

  for(var i=0;i<length;i++)
  {
        tr4.innerHTML='';
      
        var ad33=document.createElement('td');
        ad33.innerHTML= lotid[i];
        tr4.appendChild(ad33);

        var ad5=document.createElement('td');
        ad5.innerHTML= time1[i];
        tr4.appendChild(ad5);
           
        var ad2=document.createElement('td');
        ad2.innerHTML= employeeid[i];
        tr4.appendChild(ad2);

        var ad3=document.createElement('td');
        ad3.style.backgroundColor = "red";
        ad3.style.color= "black";
        ad3.innerHTML= errorid[i];
        tr4.appendChild(ad3);

        document.getElementById('status').appendChild(tr4);  
  }
  g++;

  document.getElementById("submit-button2").disabled = true;
  document.getElementById("submit-button1").disabled = false;
  document.getElementById("employeeid").disabled = true;
  document.getElementById("errorid").disabled = true;
  document.getElementById("lotid").disabled = true;
  document.getElementById("maintenanceid").disabled = false;
  document.getElementById("ackid").disabled = false;
  document.getElementById("actiondone").disabled = false;

}

function addToTable(){
   
  document.getElementById('no-data').style.display="none";
  var sub1= document.getElementById('employeeid').value;

  let errorencountered=document.getElementById('errorid').value;
  if (errorencountered==='Other'){
    var sub2=document.getElementById('others123').value;
  }
  else {
    var sub2=document.getElementById('errorid').value;
  }

  var sub3= document.getElementById('maintenanceid').value;
  var sub4= document.getElementById('ackid').value;
  var sub7= document.getElementById('actiondone').value;
  var sub33 =document.getElementById('lotid').value;
  var sub69 =document.getElementById('machineid').value;

  const sub6= new Date().getTime();
  const sub68= new Date();
  var sub77 = ((sub6-starT)/1000)/60;
  sub77 = sub77.toFixed(2);  
 
  if(sub1&&sub2&&sub3&&sub4 !=='')

  {
  machineid= [...machineid,sub69];
  employeeid2= [...employeeid2,sub1];
  errorid2= [...errorid2,sub2];
  maintenanceid= [...maintenanceid,sub3];
  actiondone= [...actiondone,sub7];
  lotid2= [...lotid2,sub33];
  ackid= [...ackid,sub4];
  time3= [...time3,sub68];
  index= [...index,c];
  totaltime=[...totaltime,sub77]; 
  
  myDeleteFunction();
  displayTable();
  
  }

  else 
      alert("入力不完全(Input Incomplete)");
  
}

function displayTable(){

    const length= employeeid2.length;
    var tr=document.createElement('tr');

    for(var i=0;i<length;i++)
    {
        tr.innerHTML='';
        var td1=document.createElement('td');
        td1.innerHTML= index[i];
        tr.appendChild(td1);

        var td89=document.createElement('td');
        td89.innerHTML= machineid[i];
        tr.appendChild(td89);

        var td33=document.createElement('td');
        td33.innerHTML= lotid2[i];
        tr.appendChild(td33);

        var td2=document.createElement('td');
        td2.innerHTML= employeeid2[i];
        tr.appendChild(td2);

        var td3=document.createElement('td');
        td3.innerHTML= errorid2[i];
        tr.appendChild(td3);
       
        var td4=document.createElement('td');
        td4.innerHTML= maintenanceid[i];
        tr.appendChild(td4);

        var td5=document.createElement('td');
        td5.innerHTML= actiondone[i];
        tr.appendChild(td5);

        var td6=document.createElement('td');
        td6.innerHTML= ackid[i];
        tr.appendChild(td6);

        var td7=document.createElement('td');
        td7.innerHTML= time1[i];
        tr.appendChild(td7);

        var td8=document.createElement('td');
        td8.innerHTML= time3[i];
        tr.appendChild(td8);

        var td9=document.createElement('td');
        td9.innerHTML=totaltime[i];
        tr.appendChild(td9);

        document.getElementById('main').appendChild(tr);
    }
    c++;

    document.getElementById('employeeid').value='';
    document.getElementById('errorid').value='';
    document.getElementById('maintenanceid').value='';
    document.getElementById('ackid').value='';
    document.getElementById('actiondone').value='';
    document.getElementById('lotid').value='';
    document.getElementById('div1').innerHTML='';

    document.getElementById("submit-button2").disabled = false;
    document.getElementById("submit-button1").disabled = true;
    document.getElementById("employeeid").disabled = false;
    document.getElementById("errorid").disabled = false;
    document.getElementById("lotid").disabled = false;
    document.getElementById("maintenanceid").disabled = true;
    document.getElementById("ackid").disabled = true;
    document.getElementById("actiondone").disabled = true;
}

function myDeleteFunction() {
  document.getElementById("StatusTable").deleteRow(1);
}

function showfield(name){
  if(name=='Other')document.getElementById('div1').innerHTML='その他: <input type="text" name="other" value="" id="others123" placeholder="ご指定ください" >';
  else document.getElementById('div1').innerHTML='';
}


I expect that the ‘myTable’ with a tbody of ‘main’ will retain.. I am new to javascript and not yet familiar with localStorage, and I can’t seem to find a guide on localStorage regarding with the sequence that I’ve made in javascript.