<%# LuCI - Lua Configuration Interface Copyright 2008 Steven Barth Copyright 2008 Jo-Philipp Wich Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 $Id$ -%> <%+header%>

<%:system%>

<%:a_s_flash%>

<%:a_s_flash_upgrade1%>


<% if next(blocks) and not next(flash) then %>
<%:a_s_flash_fwimage%>:
<% for name, v in pairs(blocks) do %> <%=name%>:
<% end %>
<% if keep_avail then -%> <%:a_s_flash_keepcfg%> <% end -%>
<% elseif next(flash) then %>

<%:a_s_flash_received%>

<% reboot.exec = false for name, func in pairs(flash) do %> <%:a_s_flash_inprogress%> <%=name%>... <%=string.rep(" ", 2048)%> <% local stat, code = func() reboot.exec = reboot.exec or stat if stat and code then %> <%:a_s_flash_flashed%>
<% else %> <%:a_s_flash_flasherr%>! (<%:code%> <%=code%>)
<% end %> <% end %> <% else %>
<%:a_s_flash_notimplemented%>
<% end %> <%+footer%>