// 投融资限制
import router from "@/router/index";
// 跳转SDN清单
export const goToSDNList = () => {
  const param = {
    sanTypeId: 2,
  }
  const jsonStr = JSON.stringify(param);
  const base64 = btoa(encodeURIComponent(jsonStr));
  const route = router.resolve({
    path: "/finance/sdnlistoverview",
    query: {
      data: base64
    }
  });
  window.open(route.href, "_blank");
}

// 跳转SDN清单事件
export const goToSingleSDNEvent = (id, tabName, date) => {
  window.sessionStorage.setItem("curTabName", tabName);
  const param = {
    id: id,
    sanTypeId: 2,
    date: date
  }
  const jsonStr = JSON.stringify(param);
  const base64 = btoa(encodeURIComponent(jsonStr));
  const route = router.resolve({
    path: "/finance/singleSanction",
    query: {
      data: base64
    }
  });
  window.open(route.href, "_blank");
}