small-package/luci-app-bypass/luasrc/view/bypass/subscribe.htm

19 lines
800 B
HTML
Raw Normal View History

2022-12-08 23:37:04 +08:00
<%+cbi/valueheader%>
<script type="text/javascript">//<![CDATA[
function subscribe(btn,dataname){
btn.disabled=true;
btn.value='<%:Refresh...%>';
murl=dataname;
XHR.get('<%=luci.dispatcher.build_url("admin","services","bypass","subscribe")%>',{set:murl},function(x,rv){
// 先简单刷新后期如果重构会考虑下如何组织lua shell JavaScript之间的代码逻辑和各自的调用逻辑
window.location.reload()
// btn.disabled = false;
// btn.value = '<%:Refresh Data %>';
});
return false;
}
//]]></script>
<input type="button" class="cbi-button cbi-input-apply" value="<%:Update All Subscribe Severs%> " onclick="return subscribe(this,'<%=self.option%>')" />
<!-- <span id="<%=self.option%>-status"><em><%=self.value%></em></span> -->
<%+cbi/valuefooter%>