Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: b44a821501
Fetching contributors…

Cannot retrieve contributors at this time

file 77 lines (61 sloc) 2.14 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77
<%@ Page language="C#"%>
<!--
Copyright 2002-2011 Corey Trager
Distributed under the terms of the GNU General Public License
-->
<!-- #include file = "inc.aspx" -->

<script language="C#" runat="server">

DataSet ds;

Security security;

void Page_Load(Object sender, EventArgs e)
{

Util.do_not_cache(Response);

security = new Security();
security.check_security( HttpContext.Current, Security.MUST_BE_ADMIN);

titl.InnerText = Util.get_setting("AppTitle","BugTracker.NET") + " - "
+ "projects";

ds = btnet.DbUtil.get_dataset(
@"select
pj_id [id],
'<a href=edit_project.aspx?&id=' + convert(varchar,pj_id) + '>edit</a>' [$no_sort_edit],
'<a href=edit_user_permissions2.aspx?projects=y&id=' + convert(varchar,pj_id) + '>permissions</a>' [$no_sort_per user<br>permissions],
'<a href=delete_project.aspx?id=' + convert(varchar,pj_id) + '>delete</a>' [$no_sort_delete],
pj_name [project],
case when pj_active = 1 then 'Y' else 'N' end [active],
us_username [default user],
case when isnull(pj_auto_assign_default_user,0) = 1 then 'Y' else 'N' end [auto assign<br>default user],
case when isnull(pj_auto_subscribe_default_user,0) = 1 then 'Y' else 'N' end [auto subscribe<br>default user],
case when isnull(pj_enable_pop3,0) = 1 then 'Y' else 'N' end [receive items<br>via pop3],
pj_pop3_username [pop3 username],
pj_pop3_email_from [from email addressl],
case when pj_default = 1 then 'Y' else 'N' end [default]
from projects
left outer join users on us_id = pj_default_user
order by pj_name");

}


</script>

<html>
<head>
<title id="titl" runat="server">btnet projects</title>
<link rel="StyleSheet" href="btnet.css" type="text/css">
<script type="text/javascript" language="JavaScript" src="sortable.js"></script>
</head>

<body>
<% security.write_menu(Response, "admin"); %>

<div class=align>
<a href=edit_project.aspx>add new project</a>
</p>
<%

if (ds.Tables[0].Rows.Count > 0)
{
SortableHtmlTable.create_from_dataset(
Response, ds, "", "", false);

}
else
{
Response.Write ("No projects in the database.");
}
%>
</div>
<% Response.Write(Application["custom_footer"]); %></body>
</html>
Something went wrong with that request. Please try again.