From: pho Date: Thu, 7 Aug 2008 12:28:09 +0000 (+0900) Subject: Indentation X-Git-Url: https://git.cielonegro.org/gitweb.cgi?a=commitdiff_plain;h=34ef5e26ef818d2ef74d5bc2a6c0f2bdac97614f;p=Rakka.git Indentation darcs-hash:20080807122809-62b54-02fcbca7d8c71dfd7805efc81ea7950beb2e47de.gz --- diff --git a/js/systemConfig.js b/js/systemConfig.js index 64f6a39..7b8192a 100644 --- a/js/systemConfig.js +++ b/js/systemConfig.js @@ -293,85 +293,85 @@ }; var appendUsersPanel = function ($area) { - $area.append($.H2({}, "Users")); - $area.append($.H3({}, "Existing Users")); - - var tbody = $.TBODY(); - - var usersPanel - = $.TABLE({className: "pageEditor"}, - $.THEAD({}, - $.TR({}, - $.TH({}, "User ID"), - $.TH({}, "Change Password"), - $.TH({}, "Delete User") - ) - ), - tbody - ); - - var updateUserList = function () { - var users = Rakka.getUserList(); - - $(tbody).empty(); - - for (var i = 0; i < users.length; i++) { - var pass1 = $.INPUT({type: "password"}); - var pass2 = $.INPUT({type: "password"}); - var change = $.INPUT({type: "button", value: "Change"}); - - var chpass = $.TABLE({className: "pageEditor"}, - $.TR({}, - $.TD({}, pass1), - $.TD({rowSpan: 2}, change)), - $.TR({}, - $.TD({}, pass2))); - - var delUser = $.INPUT({type: "button", value: "Delete"}); - - $.each(users, function () { - var id = users[i]; - var tr = $.TR({}, - $.TD({}, id), - $.TD({}, chpass), - $.TD({}, delUser) - ); - tbody.appendChild(tr); - }); - } - }; - updateUserList(); - - $area.append(usersPanel); - - $area.append($.H3({}, "Add new user")); - - var userID = $.INPUT({type: "text"}); - var pass1 = $.INPUT({type: "password"}); - var pass2 = $.INPUT({type: "password"}); - var addUser = $.INPUT({type: "button", value: "Add"}); - var addUserPanel = $.TABLE({className: "pageEditor"}, - $.TR({}, - $.TH({}, "User ID"), - $.TD({}, userID)), - $.TR({}, - $.TH({}, "Password"), - $.TD({}, pass1)), - $.TR({}, - $.TH({}, "Password (retype)"), - $.TD({}, pass2)), - $.TR({}, - $.TH({}), - $.TD({}, addUser))); - - $area.append(addUserPanel); + $area.append($.H2({}, "Users")); + $area.append($.H3({}, "Existing Users")); + + var tbody = $.TBODY(); + + var usersPanel + = $.TABLE({className: "pageEditor"}, + $.THEAD({}, + $.TR({}, + $.TH({}, "User ID"), + $.TH({}, "Change Password"), + $.TH({}, "Delete User") + ) + ), + tbody + ); + + var updateUserList = function () { + var users = Rakka.getUserList(); + + $(tbody).empty(); + + for (var i = 0; i < users.length; i++) { + var pass1 = $.INPUT({type: "password"}); + var pass2 = $.INPUT({type: "password"}); + var change = $.INPUT({type: "button", value: "Change"}); + + var chpass = $.TABLE({className: "pageEditor"}, + $.TR({}, + $.TD({}, pass1), + $.TD({rowSpan: 2}, change)), + $.TR({}, + $.TD({}, pass2))); + + var delUser = $.INPUT({type: "button", value: "Delete"}); + + $.each(users, function () { + var id = users[i]; + var tr = $.TR({}, + $.TD({}, id), + $.TD({}, chpass), + $.TD({}, delUser) + ); + tbody.appendChild(tr); + }); + } + }; + updateUserList(); + + $area.append(usersPanel); + + $area.append($.H3({}, "Add new user")); + + var userID = $.INPUT({type: "text"}); + var pass1 = $.INPUT({type: "password"}); + var pass2 = $.INPUT({type: "password"}); + var addUser = $.INPUT({type: "button", value: "Add"}); + var addUserPanel = $.TABLE({className: "pageEditor"}, + $.TR({}, + $.TH({}, "User ID"), + $.TD({}, userID)), + $.TR({}, + $.TH({}, "Password"), + $.TD({}, pass1)), + $.TR({}, + $.TH({}, "Password (retype)"), + $.TD({}, pass2)), + $.TR({}, + $.TH({}), + $.TD({}, addUser))); + + $area.append(addUserPanel); }; Rakka.showConfigPanel = function () { - var $area = Rakka.switchScreen(); + var $area = Rakka.switchScreen(); - appendConfigPanel($area); - appendUsersPanel($area); + appendConfigPanel($area); + appendUsersPanel($area); }; $(document).ready(function () {