简体   繁体   English

chrome扩展程序重定向到带有刷新内容的列表页面

[英]chrome extension redirect to listing page with refreshed content

I have created reminder app which allows user to create , edit and delete reminder but i am facing one problem here , when i click on add button after that i want to redirect it into listing page , just like we do in normal website how can i resolve it ? 我已经创建了提醒应用程序,该应用程序允许用户创建,编辑和删除提醒,但是在这里我遇到了一个问题,当我单击添加按钮之后,我想将其重定向到列表页面,就像我们在普通网站中一样解决吗? i have created following page for my chrome extension 我已经为我的chrome扩展程序创建了以下页面

  1. Listing page 列表页面
  2. Add Page 添加页面
  3. Edit Page 编辑页面

i have tried following code to redirect page but it opens 2 window. 我曾尝试按照以下代码重定向页面,但它会打开2个窗口。 so it is not feasible for me. 所以对我来说不可行。 acknowledge me as soon as possible. 尽快确认我。

function redirect(){
  chrome.app.window.create('window.html', {
  'bounds': {
 'width': 600,
  'height': 550
},
"resizable": true
 });
}

and i have also tried to call ShowAllEvents(); 我也曾尝试调用ShowAllEvents(); function which lists all reminders but it doesn't list currently added reminder. 该功能列出所有提醒,但不列出当前添加的提醒。

i have called following function on storage event changed and now its coming with refreshed content 我在存储事件更改时调用了以下函数,现在它带有刷新的内容

  chrome.storage.onChanged.addListener(function(changes,areaName)
  {
   var event = document.getElementById('event_show');
   event.click();
  });

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM