From: <m_h...@us...> - 2006-08-10 19:19:34
|
Revision: 303 Author: m_hildebrand Date: 2006-08-10 12:18:40 -0700 (Thu, 10 Aug 2006) ViewCVS: http://svn.sourceforge.net/tcdb/?rev=303&view=rev Log Message: ----------- Added lots of new graphics to the administration page Fixed some CSS problems Modified Paths: -------------- Website/App_Themes/Python/Images/product_add_48.png Website/App_Themes/Python/Images/product_edit_48.png Website/App_Themes/Python/Images/user_delete_48.png Website/App_Themes/Python/Images/user_edit_48.png Website/App_Themes/Python/Images/user_role_48.png Website/App_Themes/Python/Python.skin Website/App_Themes/Python/python.css Website/Includes/Administration.ascx Website/Includes/Administration.ascx.cs Website/TCDB.master Added Paths: ----------- Graphics/Python/Processed/ Graphics/Python/Processed/ArrowDown.gif Graphics/Python/Processed/ArrowUp.gif Graphics/Python/Processed/Header-Background.gif Graphics/Python/Processed/TCDB-2006-Logo-on-Blue.gif Graphics/Python/Processed/TCDB-2006-Logo-on-White.gif Graphics/Python/Processed/Thumbs.db Graphics/Python/Processed/important.png Graphics/Python/Processed/important_large.png Graphics/Python/Processed/product_add_48.png Graphics/Python/Processed/product_delete_48.png Graphics/Python/Processed/product_edit_48.png Graphics/Python/Processed/product_view_48.png Graphics/Python/Processed/reddot.gif Graphics/Python/Processed/role_add_48.png Graphics/Python/Processed/role_delete_48.png Graphics/Python/Processed/role_edit_48.png Graphics/Python/Processed/role_view_48.png Graphics/Python/Processed/toolbar_calendar_48.png Graphics/Python/Processed/user_add_48.png Graphics/Python/Processed/user_delete_48.png Graphics/Python/Processed/user_edit_48.png Graphics/Python/Processed/user_role_48.png Graphics/Python/Processed/user_view_48.png Graphics/Python/Raw PSD/ Graphics/Python/Raw PSD/Delete Overlay.psd Graphics/Python/Raw PSD/Edit Overlay.psd Graphics/Python/Raw PSD/New Overlay.psd Graphics/Python/Raw PSD/TCDB 2006 Logo.psd Graphics/Python/Raw PSD/product_add_48.psd Graphics/Python/Raw PSD/product_delete_48.psd Graphics/Python/Raw PSD/product_edit_48.psd Graphics/Python/Raw PSD/product_view_48.psd Graphics/Python/Raw PSD/role_add_48.psd Graphics/Python/Raw PSD/role_delete_48.psd Graphics/Python/Raw PSD/role_edit_48.psd Graphics/Python/Raw PSD/role_view_48.psd Graphics/Python/Raw PSD/user_add_48.psd Graphics/Python/Raw PSD/user_delete_48.psd Graphics/Python/Raw PSD/user_edit_48.psd Graphics/Python/Raw PSD/user_role_48.psd Graphics/Python/Raw PSD/user_view_48.psd Website/App_Themes/Python/Images/important.png Website/App_Themes/Python/Images/important_large.png Website/App_Themes/Python/Images/role_add_48.png Website/App_Themes/Python/Images/role_delete_48.png Website/App_Themes/Python/Images/role_edit_48.png Website/App_Themes/Python/Images/role_view_48.png Website/App_Themes/Python/style-ie.style Removed Paths: ------------- Graphics/Python/ArrowDown.gif Graphics/Python/ArrowUp.gif Graphics/Python/Header-Background.gif Graphics/Python/TCDB 2006 Logo.psd Graphics/Python/TCDB-2006-Logo-on-Blue.gif Graphics/Python/TCDB-2006-Logo-on-White.gif Graphics/Python/reddot.gif Website/App_Themes/Python/style-ie.css Deleted: Graphics/Python/ArrowDown.gif =================================================================== (Binary files differ) Deleted: Graphics/Python/ArrowUp.gif =================================================================== (Binary files differ) Deleted: Graphics/Python/Header-Background.gif =================================================================== (Binary files differ) Copied: Graphics/Python/Processed/ArrowDown.gif (from rev 299, Graphics/Python/ArrowDown.gif) =================================================================== (Binary files differ) Copied: Graphics/Python/Processed/ArrowUp.gif (from rev 299, Graphics/Python/ArrowUp.gif) =================================================================== (Binary files differ) Copied: Graphics/Python/Processed/Header-Background.gif (from rev 299, Graphics/Python/Header-Background.gif) =================================================================== (Binary files differ) Copied: Graphics/Python/Processed/TCDB-2006-Logo-on-Blue.gif (from rev 299, Graphics/Python/TCDB-2006-Logo-on-Blue.gif) =================================================================== (Binary files differ) Copied: Graphics/Python/Processed/TCDB-2006-Logo-on-White.gif (from rev 299, Graphics/Python/TCDB-2006-Logo-on-White.gif) =================================================================== (Binary files differ) Added: Graphics/Python/Processed/Thumbs.db =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/Thumbs.db ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/important.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/important.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/important_large.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/important_large.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/product_add_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/product_add_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/product_delete_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/product_delete_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/product_edit_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/product_edit_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/product_view_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/product_view_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Copied: Graphics/Python/Processed/reddot.gif (from rev 299, Graphics/Python/reddot.gif) =================================================================== (Binary files differ) Added: Graphics/Python/Processed/role_add_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/role_add_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/role_delete_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/role_delete_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/role_edit_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/role_edit_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/role_view_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/role_view_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/toolbar_calendar_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/toolbar_calendar_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/user_add_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/user_add_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/user_delete_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/user_delete_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/user_edit_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/user_edit_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/user_role_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/user_role_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Processed/user_view_48.png =================================================================== (Binary files differ) Property changes on: Graphics/Python/Processed/user_view_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/Delete Overlay.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/Delete Overlay.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/Edit Overlay.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/Edit Overlay.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/New Overlay.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/New Overlay.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Copied: Graphics/Python/Raw PSD/TCDB 2006 Logo.psd (from rev 299, Graphics/Python/TCDB 2006 Logo.psd) =================================================================== (Binary files differ) Added: Graphics/Python/Raw PSD/product_add_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/product_add_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/product_delete_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/product_delete_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/product_edit_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/product_edit_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/product_view_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/product_view_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/role_add_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/role_add_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/role_delete_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/role_delete_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/role_edit_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/role_edit_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/role_view_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/role_view_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/user_add_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/user_add_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/user_delete_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/user_delete_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/user_edit_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/user_edit_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/user_role_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/user_role_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Graphics/Python/Raw PSD/user_view_48.psd =================================================================== (Binary files differ) Property changes on: Graphics/Python/Raw PSD/user_view_48.psd ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Deleted: Graphics/Python/TCDB 2006 Logo.psd =================================================================== (Binary files differ) Deleted: Graphics/Python/TCDB-2006-Logo-on-Blue.gif =================================================================== (Binary files differ) Deleted: Graphics/Python/TCDB-2006-Logo-on-White.gif =================================================================== (Binary files differ) Deleted: Graphics/Python/reddot.gif =================================================================== (Binary files differ) Added: Website/App_Themes/Python/Images/important.png =================================================================== (Binary files differ) Property changes on: Website/App_Themes/Python/Images/important.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Website/App_Themes/Python/Images/important_large.png =================================================================== (Binary files differ) Property changes on: Website/App_Themes/Python/Images/important_large.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Modified: Website/App_Themes/Python/Images/product_add_48.png =================================================================== (Binary files differ) Modified: Website/App_Themes/Python/Images/product_edit_48.png =================================================================== (Binary files differ) Added: Website/App_Themes/Python/Images/role_add_48.png =================================================================== (Binary files differ) Property changes on: Website/App_Themes/Python/Images/role_add_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Website/App_Themes/Python/Images/role_delete_48.png =================================================================== (Binary files differ) Property changes on: Website/App_Themes/Python/Images/role_delete_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Website/App_Themes/Python/Images/role_edit_48.png =================================================================== (Binary files differ) Property changes on: Website/App_Themes/Python/Images/role_edit_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: Website/App_Themes/Python/Images/role_view_48.png =================================================================== (Binary files differ) Property changes on: Website/App_Themes/Python/Images/role_view_48.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Modified: Website/App_Themes/Python/Images/user_delete_48.png =================================================================== (Binary files differ) Modified: Website/App_Themes/Python/Images/user_edit_48.png =================================================================== (Binary files differ) Modified: Website/App_Themes/Python/Images/user_role_48.png =================================================================== (Binary files differ) Modified: Website/App_Themes/Python/Python.skin =================================================================== --- Website/App_Themes/Python/Python.skin 2006-08-10 18:58:26 UTC (rev 302) +++ Website/App_Themes/Python/Python.skin 2006-08-10 19:18:40 UTC (rev 303) @@ -25,7 +25,12 @@ <asp:Image runat="server" SkinId="viewUserImage" ImageUrl="Images/user_view_48.png" /> <asp:Image runat="server" SkinId="editUserImage" ImageUrl="Images/user_edit_48.png" /> <asp:Image runat="server" SkinId="deleteUserImage" ImageUrl="Images/user_delete_48.png" /> + <asp:Image runat="server" SkinId="userRoleImage" ImageUrl="Images/user_role_48.png" /> +<asp:Image runat="server" SkinId="newRoleImage" ImageUrl="Images/role_add_48.png" /> +<asp:Image runat="server" SkinId="viewRoleImage" ImageUrl="Images/role_view_48.png" /> +<asp:Image runat="server" SkinId="editRoleImage" ImageUrl="Images/role_edit_48.png" /> +<asp:Image runat="server" SkinId="deleteRoleImage" ImageUrl="Images/role_delete_48.png" /> <asp:Image runat="server" SkinId="newProductImage" ImageUrl="Images/product_add_48.png" /> <asp:Image runat="server" SkinId="editProductImage" ImageUrl="Images/product_edit_48.png" /> Modified: Website/App_Themes/Python/python.css =================================================================== --- Website/App_Themes/Python/python.css 2006-08-10 18:58:26 UTC (rev 302) +++ Website/App_Themes/Python/python.css 2006-08-10 19:18:40 UTC (rev 303) @@ -149,6 +149,13 @@ text-indent: -5em } +.clean +{ + margin: 0; + padding: 0; + border: none; +} + /********** END Global Classes **********/ /********** BEGIN Calendar Classes **********/ Deleted: Website/App_Themes/Python/style-ie.css =================================================================== --- Website/App_Themes/Python/style-ie.css 2006-08-10 18:58:26 UTC (rev 302) +++ Website/App_Themes/Python/style-ie.css 2006-08-10 19:18:40 UTC (rev 303) @@ -1,59 +0,0 @@ -.body -{ - background: red; -} - -.bottom -{ - position: static; - padding-top: 8px; -} - -.item .checkbox INPUT -{ - position: static; -} - -/* A CSS hack that only applied to IE -- forces the height of NonFooter - to be 100%, something that causes problems in Mozilla */ -#NonFooter -{ - height: 100%; -} - -/* A CSS hack that only applies to IE -- specifies a different height for the footer - and set the position to static so the background displays */ -/* TODO: Figure out a way to keep the footer in IE from overlaping page content */ -/* -#FooterContent -{ - position: static; - margin-top: -2.3em; -} -*/ - -.form .checkbox INPUT -{ - width: 15px; -} - -#fullname input -{ - width: 100px; -} - -.cb -{ - position: static; -} - -.cb .bottom -{ - position: relative; - top: 5px; -} - -.ct H2 -{ - font-size: 16px; -} \ No newline at end of file Copied: Website/App_Themes/Python/style-ie.style (from rev 301, Website/App_Themes/Python/style-ie.css) =================================================================== --- Website/App_Themes/Python/style-ie.style (rev 0) +++ Website/App_Themes/Python/style-ie.style 2006-08-10 19:18:40 UTC (rev 303) @@ -0,0 +1,71 @@ +.bottom +{ + position: static; + padding-top: 8px; +} + +.item .checkbox INPUT +{ + position: static; +} + +/* A CSS hack that only applied to IE -- forces the height of NonFooter + to be 100%, something that causes problems in Mozilla */ +#NonFooter +{ + height: 100%; +} + +/* A CSS hack that only applies to IE -- specifies a different height for the footer + and set the position to static so the background displays */ +/* TODO: Figure out a way to keep the footer in IE from overlaping page content */ +/* +#FooterContent +{ + position: static; + margin-top: -2.3em; +} +*/ + +.form .checkbox INPUT +{ + width: 15px; +} + +#fullname input +{ + width: 100px; +} + +.cb +{ + position: static; +} + +.cb .bottom +{ + position: relative; + top: 5px; +} + +.ct H2 +{ + font-size: 16px; +} + +#Administration .menu +{ + display: block; + margin: 15px; + float: left; + clear: left; + width: 550px; +} + +.button +{ + float: left; + position: relative; + z-index: 50; + margin: 5px 0 5px -10px; +} \ No newline at end of file Modified: Website/Includes/Administration.ascx =================================================================== --- Website/Includes/Administration.ascx 2006-08-10 18:58:26 UTC (rev 302) +++ Website/Includes/Administration.ascx 2006-08-10 19:18:40 UTC (rev 303) @@ -2,20 +2,72 @@ Inherits="TCDB.Administration" %> <!-- TODO: make these pull-downs dynamic --> <div id="Administration"> - <div class="menu"> + <asp:Panel runat="server" ID="ProductAdmin" CssClass="menu"> <label> Product Administration</label> - <div class="pictureMenu" id="ProductAdmin"> + <div class="pictureMenu"> <div class="xsnazzy"> <b class="xtop"><b class="xb1"></b><b class="xb2"></b><b class="xb3"></b><b class="xb4"> </b></b> <div class="xboxcontent"> + <!--<asp:Panel runat="server" ID="ProductAdminTop" CssClass="clean">--> + <div class="button"> + <asp:LinkButton ID="newProduct" runat="server" OnInit="newProduct_Init" CommandName="new" + OnCommand="Product_Command"> + <asp:Image ID="newProductIcon" runat="server" SkinID="newProductImage" AlternateText="New Product" />New + Product</asp:LinkButton></div> + <div class="end"> + </div> + <!-- </asp:Panel> + <asp:Panel runat="server" ID="ProductAdminHR" CssClass="clean">--> + <div class="hr"> + </div> + <!-- </asp:Panel>--> + <asp:Panel runat="server" ID="ProductAdminBottom" CssClass="clean"> + <div class="pulldown"> + <label> + For:</label> + <asp:DropDownList runat="server" ID="productList" AutoPostBack="True" OnInit="productList_Init" + OnSelectedIndexChanged="productList_SelectedIndexChanged"> + </asp:DropDownList> + </div> + <div class="button"> + <asp:LinkButton ID="viewProduct" runat="server" CommandName="view" OnCommand="Product_Command"> + <asp:Image ID="viewProductIcon" runat="server" SkinID="viewProductImage" AlternateText="View Product" />View + Product</asp:LinkButton> + </div> + <div class="button"> + <asp:LinkButton ID="editProduct" runat="server" CommandName="edit" OnCommand="Product_Command"> + <asp:Image ID="editProductIcon" runat="server" SkinID="editProductImage" AlternateText="Edit Product" />Edit + Product</asp:LinkButton> + </div> + <div class="button"> + <asp:LinkButton ID="deleteProduct" runat="server" CommandName="delete" OnCommand="Product_Command"> + <asp:Image ID="deleteProductIcon" runat="server" SkinID="deleteProductImage" AlternateText="Delete Product" />Delete + Product</asp:LinkButton> + </div> + <div class="end"> + </div> + </asp:Panel> + </div> + <b class="xbottom"><b class="xb4"></b><b class="xb3"></b><b class="xb2"></b><b class="xb1"> + </b></b> + </div> + </div> + </asp:Panel> + <div class="menu"> + <label> + User Administration</label> + <div class="pictureMenu" id="UserAdmin"> + <div class="xsnazzy"> + <b class="xtop"><b class="xb1"></b><b class="xb2"></b><b class="xb3"></b><b class="xb4"> + </b></b> + <div class="xboxcontent"> <div class="button"> - <asp:LinkButton ID="newProduct" runat="server" - OnInit="newProduct_Init" CommandName="new" OnCommand="Product_Command"> - <asp:Image ID="newProductIcon" runat="server" SkinID="newProductImage" AlternateText="New Product" />New - Product</asp:LinkButton> - </div> + <asp:LinkButton ID="newUser" runat="server" OnInit="newUser_Init" CommandName="new" + OnCommand="User_Command"> + <asp:Image ID="newUserIcon" runat="server" SkinID="newUserImage" AlternateText="New User" />New + User</asp:LinkButton></div> <div class="end"> </div> <div class="hr"> @@ -23,47 +75,46 @@ <div class="pulldown"> <label> For:</label> - <asp:DropDownList runat="server" ID="productList" AutoPostBack="True" OnInit="productList_Init" OnSelectedIndexChanged="productList_SelectedIndexChanged"> + <asp:DropDownList runat="server" ID="userList" AutoPostBack="True" OnInit="userList_Init" + OnSelectedIndexChanged="userList_SelectedIndexChanged"> </asp:DropDownList> </div> <div class="button"> - <asp:LinkButton ID="viewProduct" runat="server" CommandName="view" OnCommand="Product_Command"> - <asp:Image ID="viewProductIcon" runat="server" SkinID="viewProductImage" AlternateText="View Product" />View - Product</asp:LinkButton> - </div> + <asp:LinkButton ID="userView" runat="server" CommandName="view" OnCommand="User_Command"> + <asp:Image ID="userViewIcon" runat="server" SkinID="viewUserImage" AlternateText="View User" />View + User</asp:LinkButton></div> <div class="button"> - <asp:LinkButton ID="editProduct" runat="server" CommandName="edit" OnCommand="Product_Command"> - <asp:Image ID="editProductIcon" runat="server" SkinID="editProductImage" AlternateText="Edit Product" />Edit - Product</asp:LinkButton> - </div> + <asp:LinkButton ID="userEdit" runat="server" CommandName="edit" OnCommand="User_Command"> + <asp:Image ID="userEditIcon" runat="server" SkinID="editUserImage" AlternateText="Edit User" />Edit + User</asp:LinkButton></div> <div class="button"> - <asp:LinkButton ID="deleteProduct" runat="server" CommandName="delete" OnCommand="Product_Command"> - <asp:Image ID="deleteProductIcon" runat="server" SkinID="deleteProductImage" AlternateText="Delete Product" />Delete - Product</asp:LinkButton> - </div> + <asp:LinkButton ID="userDelete" runat="server" CommandName="delete" OnCommand="User_Command"> + <asp:Image ID="userDeleteIcon" runat="server" SkinID="deleteUserImage" AlternateText="Delete User" />Delete + User</asp:LinkButton></div> <div class="end"> </div> </div> - <b class="xbottom"><b class="xb4"></b><b class="xb3"></b><b class="xb2"></b></b> - <b class="xb1"></b> + <b class="xbottom"><b class="xb4"></b><b class="xb3"></b><b class="xb2"></b> + <b class="xb1"></b></b> </div> </div> </div> <div class="menu"> <label> - User Administration</label> - <div class="pictureMenu" id="UserAdmin"> + Role Administration</label> + <div class="pictureMenu" id="RoleAdmin"> <div class="xsnazzy"> <b class="xtop"><b class="xb1"></b><b class="xb2"></b><b class="xb3"></b><b class="xb4"> </b></b> <div class="xboxcontent"> <div class="button"> - <asp:LinkButton ID="newUser" runat="server" - OnInit="newUser_Init" CommandName="new" OnCommand="User_Command"> - <asp:Image ID="newUserIcon" runat="server" SkinID="newUserImage" AlternateText="New User" />New - User</asp:LinkButton></div> + <asp:LinkButton ID="newRole" runat="server" OnInit="newRole_Init" CommandName="new" + OnCommand="Role_Command"> + <asp:Image ID="newRoleIcon" runat="server" SkinID="newRoleImage" AlternateText="New User" />New + Role</asp:LinkButton></div> <div class="button"> - <asp:LinkButton ID="userRole" runat="server" OnInit="userRole_Init" CommandName="role" OnCommand="User_Command"> + <asp:LinkButton ID="userRole" runat="server" OnInit="userRole_Init" CommandName="role" + OnCommand="Role_Command"> <asp:Image ID="userRoleIcon" runat="server" SkinID="userRoleImage" AlternateText="User Roles" />User Roles</asp:LinkButton></div> <div class="end"> @@ -73,29 +124,27 @@ <div class="pulldown"> <label> For:</label> - <asp:DropDownList runat="server" ID="userList" AutoPostBack="True" OnInit="userList_Init" OnSelectedIndexChanged="userList_SelectedIndexChanged"> + <asp:DropDownList runat="server" ID="roleList" AutoPostBack="True" OnInit="roleList_Init" + OnSelectedIndexChanged="roleList_SelectedIndexChanged"> </asp:DropDownList> </div> <div class="button"> - <asp:LinkButton ID="userView" runat="server" - CommandName="view" OnCommand="User_Command"> - <asp:Image ID="userViewIcon" runat="server" SkinID="viewUserImage" AlternateText="View User" />View - User</asp:LinkButton></div> + <asp:LinkButton ID="roleView" runat="server" CommandName="view" OnCommand="Role_Command"> + <asp:Image ID="roleViewIcon" runat="server" SkinID="viewRoleImage" AlternateText="View Role" />View + Role</asp:LinkButton></div> <div class="button"> - <asp:LinkButton ID="userEdit" runat="server" - CommandName="edit" OnCommand="User_Command"> - <asp:Image ID="userEditIcon" runat="server" SkinID="editUserImage" AlternateText="Edit User" />Edit - User</asp:LinkButton></div> + <asp:LinkButton ID="roleEdit" runat="server" CommandName="edit" OnCommand="Role_Command"> + <asp:Image ID="roleEditIcon" runat="server" SkinID="editRoleImage" AlternateText="Edit Role" />Edit + Role</asp:LinkButton></div> <div class="button"> - <asp:LinkButton ID="userDelete" runat="server" - CommandName="delete" OnCommand="User_Command"> - <asp:Image ID="userDeleteIcon" runat="server" SkinID="deleteUserImage" AlternateText="Delete User" />Delete - User</asp:LinkButton></div> + <asp:LinkButton ID="roleDelete" runat="server" CommandName="delete" OnCommand="Role_Command"> + <asp:Image ID="roleDeleteIcon" runat="server" SkinID="deleteRoleImage" AlternateText="Delete Role" />Delete + Role</asp:LinkButton></div> <div class="end"> </div> </div> - <b class="xbottom"><b class="xb4"></b><b class="xb3"></b><b class="xb2"></b></b> - <b class="xb1"></b> + <b class="xbottom"><b class="xb4"></b><b class="xb3"></b><b class="xb2"></b> + <b class="xb1"></b></b> </div> </div> </div> Modified: Website/Includes/Administration.ascx.cs =================================================================== --- Website/Includes/Administration.ascx.cs 2006-08-10 18:58:26 UTC (rev 302) +++ Website/Includes/Administration.ascx.cs 2006-08-10 19:18:40 UTC (rev 303) @@ -32,12 +32,18 @@ if (!m_user.HasRight(Constants.RIGHTS_USER_CREATE, Constants.PRODUCT_ANYID)) newUser.Visible = false; } + protected void newRole_Init(object sender, EventArgs e) + { + if (!m_user.HasRight(Constants.RIGHTS_ROLE_CREATE, Constants.PRODUCT_ANYID)) + newRole.Visible = false; + } protected void userRole_Init(object sender, EventArgs e) { if (!m_user.HasRight(Constants.RIGHTS_ROLE_VIEW_MY, Constants.PRODUCT_ANYID) && !m_user.HasRight(Constants.RIGHTS_ROLE_VIEW_OTHER, Constants.PRODUCT_ANYID)) userRole.Visible = false; } + protected void productList_Init(object sender, EventArgs e) { @@ -58,20 +64,25 @@ } protected void productList_SelectedIndexChanged(object sender, EventArgs e) { - int productID = Convert.ToInt32(productList.SelectedValue); + try + { + int productID = Convert.ToInt32(productList.SelectedValue); if (!m_user.HasRight(Constants.RIGHTS_PRODUCT_VIEW, productID)) - viewProduct.Visible = false; - else - viewProduct.Visible = true; + viewProduct.Visible = false; + else + viewProduct.Visible = true; if (!m_user.HasRight(Constants.RIGHTS_PRODUCT_EDIT, productID)) - editProduct.Visible = false; - else - editProduct.Visible = true; + editProduct.Visible = false; + else + editProduct.Visible = true; if (!m_user.HasRight(Constants.RIGHTS_PRODUCT_DELETE, productID)) - deleteProduct.Visible = false; - else - deleteProduct.Visible = true; + deleteProduct.Visible = false; + else + deleteProduct.Visible = true; + } + catch { } + } protected void userList_Init(object sender, EventArgs e) @@ -102,7 +113,81 @@ } protected void userList_SelectedIndexChanged(object sender, EventArgs e) { + try + { + List<Product> products = ProductDB.GetProductList(active); + User user = UserDB.GetUserInfo(Convert.ToInt32(userList.SelectedValue)); + + if (user.ID == m_user.ID) + { + userView.Visible = false; + userEdit.Visible = false; + userDelete.Visible = false; + foreach (Product product in products) + { + if (!userView.Visible && m_user.HasRight(Constants.RIGHTS_USER_VIEW_MY, product.ID)) + userView.Visible = true; + if (!userEdit.Visible && m_user.HasRight(Constants.RIGHTS_USER_EDIT_MY, product.ID)) + userEdit.Visible = true; + } + } + else + { + userView.Visible = false; + userEdit.Visible = false; + userDelete.Visible = true; + foreach (Product product in products) + { + if (!userView.Visible && m_user.HasRight(Constants.RIGHTS_USER_VIEW_OTHER, user, product.ID)) + userView.Visible = true; + if (!userEdit.Visible && m_user.HasRight(Constants.RIGHTS_USER_EDIT_OTHER, user, product.ID)) + userEdit.Visible = true; + if (product.ID != Constants.PRODUCT_SITEID && user.HasRights(product.ID)) + { + if (userDelete.Visible && !m_user.HasRight(Constants.RIGHTS_USER_DELETE, product.ID)) + userDelete.Visible = false; + } + } + } + } + catch { } + } + + protected void roleList_Init(object sender, EventArgs e) + { + //TODO: Turn this into stuff for roles! + + /* List<Product> products = ProductDB.GetProductList(active); + List<User> users = UserDB.TCDB_GetUserList(); + + foreach (User user in users) + { + foreach (Product product in products) + { + if (!(m_user.HasRight("view_other_settings")) && + !(user.ID == m_user.ID && m_user.HasRight("view_my_settings", product.ID)) && + !(m_user.HasRight("view_other_settings", user, product.ID))) + continue; + + ListItem item = new ListItem(user.FULLNAME, user.ID.ToString()); + //if (!user.ACTIVE) + //item.Attributes.CssStyle.Add("text-decoration", "line-through"); + + userList.Items.Add(item); + break; + } + } + if (!IsPostBack) + userList_SelectedIndexChanged(sender, e); + */ + } + protected void roleList_SelectedIndexChanged(object sender, EventArgs e) + { + //TODO: Turn this into stuff for roles! + + /* + List<Product> products = ProductDB.GetProductList(active); User user = UserDB.GetUserInfo(Convert.ToInt32(userList.SelectedValue)); if (user.ID == m_user.ID) @@ -112,9 +197,9 @@ userDelete.Visible = false; foreach (Product product in products) { - if (!userView.Visible && m_user.HasRight(Constants.RIGHTS_USER_VIEW_MY, product.ID)) + if (!userView.Visible && m_user.HasRight("view_my_settings", product.ID)) userView.Visible = true; - if (!userEdit.Visible && m_user.HasRight(Constants.RIGHTS_USER_EDIT_MY, product.ID)) + if (!userEdit.Visible && m_user.HasRight("edit_my_settings", product.ID)) userEdit.Visible = true; } } @@ -125,18 +210,20 @@ userDelete.Visible = true; foreach (Product product in products) { - if (!userView.Visible && m_user.HasRight(Constants.RIGHTS_USER_VIEW_OTHER, user, product.ID)) + if (!userView.Visible && m_user.HasRight("view_other_settings", user, product.ID)) userView.Visible = true; - if (!userEdit.Visible && m_user.HasRight(Constants.RIGHTS_USER_EDIT_OTHER, user, product.ID)) + if (!userEdit.Visible && m_user.HasRight("edit_other_settings", user, product.ID)) userEdit.Visible = true; if (product.ID != Constants.PRODUCT_SITEID && user.HasRights(product.ID)) { - if (userDelete.Visible && !m_user.HasRight(Constants.RIGHTS_USER_DELETE, product.ID)) + if (userDelete.Visible && !m_user.HasRight("delete_user", product.ID)) userDelete.Visible = false; } } } + */ } + protected void Product_Command(object sender, CommandEventArgs e) { int productID = Convert.ToInt32(productList.SelectedValue); @@ -180,7 +267,19 @@ case "new": Response.Redirect("~/UserSettings.aspx?" + Constants.CODE_MODE + "=new"); break; - case "role": + default: + m_logg.Error("Invalid Command: " + e.CommandName); + break; + } + } + protected void Role_Command(object sender, CommandEventArgs e) + { + int roleID = Convert.ToInt32(roleList.SelectedValue); + + // TODO: Flush this out completely + switch (e.CommandName) + { + case "new": Response.Redirect("~/AdminRole.aspx"); break; default: @@ -189,4 +288,4 @@ } } } -} \ No newline at end of file +} Modified: Website/TCDB.master =================================================================== --- Website/TCDB.master 2006-08-10 18:58:26 UTC (rev 302) +++ Website/TCDB.master 2006-08-10 19:18:40 UTC (rev 303) @@ -14,10 +14,10 @@ <head runat="server"> <title>TCDB: Test Case DataBase 2006</title> </head> +<body> <!--[if IE]> - <link href="App_Themes/<%= Page.StyleSheetTheme %>/style-ie.css" type="text/css" rel="stylesheet" /> + <link href="App_Themes/<%= Page.StyleSheetTheme %>/style-ie.style" type="text/css" rel="stylesheet" /> <![endif]--> -<body> <!--<div id="NonFooter" style="border: solid thin red;">--> <% if (ConfigDB.GetConfigString("tcdb_version").Equals(Constants.TCDB_VERSION)) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |