summaryrefslogtreecommitdiff
path: root/demos/blog-tutorial/samples/day3/blog/protected/pages/users/AdminUser.page
blob: af03b858e99570c6fd4ff677f2415af41ead7357 (plain)
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
<%@ Title="My Blog - Manage User Accounts" %>

<com:TContent ID="Main">
 
<h1>Manage User Accounts</h1>

<a href="<%= $this->Service->constructUrl('users.NewUser')%>">Create New User</a>
<br/>

<com:TDataGrid ID="UserGrid"
    DataKeyField="username"
    AutoGenerateColumns="false"
    OnDeleteCommand="deleteButtonClicked">

    <com:THyperLinkColumn
        HeaderText="Username"
        DataTextField="username"
        DataNavigateUrlField="username">
        <prop:DataNavigateUrlFormatString>#
          $this->Service->constructUrl('users.EditUser',array('username'=>{0}))
        </prop:DataNavigateUrlFormatString>
    </com:THyperLinkColumn>

    <com:TBoundColumn
        HeaderText="Email"
        DataField="email" />
    
    <com:TCheckBoxColumn
        HeaderText="Administrator"
        DataField="role" />
    
    <com:TButtonColumn
        HeaderText="Command"
        Text="Delete" 
        ButtonType="PushButton"
        CommandName="delete" />

</com:TDataGrid>

</com:TContent>