Commit 278da17f authored by edwin's avatar edwin

update popup logic, and indent

parent 0d778427
...@@ -26,8 +26,14 @@ inputButton.onclick = function(element) { ...@@ -26,8 +26,14 @@ inputButton.onclick = function(element) {
toGoogle.onclick = function(element) { toGoogle.onclick = function(element) {
chrome.tabs.query({active: true, currentWindow: true}, function(tabs) { chrome.tabs.query({active: true, currentWindow: true}, function(tabs) {
const execute = chrome.tabs.executeScript(tabs[0].id, let url = "";
{code: `document.location.href = "https://digitallibrary-external.fastretailing.com/";`}); chrome.storage.local.get('idArray', function (items) {
var a = items.idArray.split(',');
url = "https://digitallibrary-external.fastretailing.com/asset?t=datacategory%2Fasset&w="+ a[0] + "&r=north";
chrome.tabs.executeScript(tabs[0].id,{
code: `document.location.href = "${url}";`
});
});
}); });
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment