记一次删批量数据

 let array= ["    1125906379509517"
      ,
      "    1125906532625950"
      ,
      "    1125906532855603"
      ,
      "    1125906533034925"
      ,
      "    1125906532988205"
      ,
    ]


    console.log(array.length);

    var nn = 90
    let timer = setInterval(() => {
      let item = array[nn] ? array[nn].trim() : ""
      name(item)
      if (nn < array.length) {
        ++nn;
        console.log(nn);
      } else {
        clearInterval(timer)
      }

    }, 1000);

  }
//element 为批量数据的ID
  function name(element, i) {
    console.log(element);
    let url = "https://aaa.bbb.ccc:8881//order_deleteOaoDe.action?gorderId=" + element
    var popup = window.open('', '');
    popup.location.href = url;
    setTimeout(function () { popup.close(); }, 500);

  }

 

posted on 2021-01-29 17:47  含蓄的龅牙妹  阅读(54)  评论(0编辑  收藏  举报

导航