summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-minidlna/luasrc/view/minidlna_status.htm
diff options
context:
space:
mode:
Diffstat (limited to 'applications/luci-app-minidlna/luasrc/view/minidlna_status.htm')
-rw-r--r--applications/luci-app-minidlna/luasrc/view/minidlna_status.htm29
1 files changed, 29 insertions, 0 deletions
diff --git a/applications/luci-app-minidlna/luasrc/view/minidlna_status.htm b/applications/luci-app-minidlna/luasrc/view/minidlna_status.htm
new file mode 100644
index 000000000..098a72a07
--- /dev/null
+++ b/applications/luci-app-minidlna/luasrc/view/minidlna_status.htm
@@ -0,0 +1,29 @@
+<script type="text/javascript">//<![CDATA[
+ XHR.poll(5, '<%=luci.dispatcher.build_url("admin/services/minidlna_status")%>', null,
+ function(x, st)
+ {
+ var tb = document.getElementById('minidlna_status');
+ if (st && tb)
+ {
+ if (st.running)
+ {
+ tb.innerHTML = String.format(
+ '<%:The miniDLNA service is active, serving %d audio, %d video and %d image files.%>',
+ st.audio, st.video, st.image
+ );
+ }
+ else
+ {
+ tb.innerHTML = '<em><%:The miniDLNA service is not running.%></em>';
+ }
+ }
+ }
+ );
+//]]></script>
+
+<fieldset class="cbi-section">
+ <legend><%:miniDLNA Status%></legend>
+ <p id="minidlna_status">
+ <em><%:Collecting data...%></em>
+ </p>
+</fieldset>