summaryrefslogtreecommitdiff
path: root/app/frontend/controls/CalendarScaffold.tpl
blob: 6a22bc2aa9ece86dc2c2452a6f0094d812f9fed8 (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
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
78
79
80
81
<com:TPanel
    CssClass="calendarScaffold">
  <com:TActiveDataGrid ID="Calendars"
                       DataKeyField="UID"
                       AutoGenerateColumns="false"
                       OnEditCommand="editRow"
                       OnCancelCommand="cancelRowEdit"
                       OnUpdateCommand="saveRow">
    <com:TActiveBoundColumn ID="Name"
                            ReadOnly="true"
                            DataField="Name">
      <prop:HeaderText><%[ Calendar ]%></prop:HeaderText>
    </com:TActiveBoundColumn>
    <com:TActiveHyperLinkColumn ID="Website"
                                Target="_blank"
                                DataNavigateUrlField="Website">
      <prop:HeaderText><%[ WWW ]%></prop:HeaderText>
      <prop:Text><%[ [www] ]%></prop:Text>
    </com:TActiveHyperLinkColumn>
    <com:TActiveHyperLinkColumn ID="Url"
                                Target="_blank"
                                DataNavigateUrlField="Url">
      <prop:HeaderText><%[ ICS ]%></prop:HeaderText>
      <prop:Text><%[ [ics] ]%></prop:Text>
    </com:TActiveHyperLinkColumn>
    <com:TActiveDropDownListColumn ID="Category"
                                   DataTextField="Category.Name"
                                   DataValueField="CategoryID"
                                   ListValueField="ID"
                                   ListTextField="Name">
      <prop:HeaderText><%[ Category ]%></prop:HeaderText>
    </com:TActiveDropDownListColumn>
    <com:TActiveTemplateColumn ID="Visible">
      <prop:HeaderText><%[ Default ]%></prop:HeaderText>
      <prop:ItemTemplate>
        <com:TActiveCheckBox
           OnCheckedChanged="SourceTemplateControl.toggleDefaultState"
           CssClass="visibilityToggle">
          <prop:Checked><%# $this->Parent->Data->Visible %></prop:Checked>
          <prop:CustomData><%# $this->Parent->Data->UID %></prop:CustomData>
        </com:TActiveCheckBox>
      </prop:ItemTemplate>
      <prop:EditItemTemplate>
        <com:TCheckBox ID="CheckBox">
          <prop:Checked><%# $this->Parent->Data->Visible %></prop:Checked>
        </com:TCheckBox>
      </prop:EditItemTemplate>
    </com:TActiveTemplateColumn>
    <com:TActiveBoundColumn ID="CustomName"
                            DataField="CustomName">
      <prop:HeaderText><%[ Custom name ]%></prop:HeaderText>
    </com:TActiveBoundColumn>
    <com:TActiveBoundColumn ID="CustomUrl"
                            DataField="CustomUrl">
      <prop:HeaderText><%[ URL ]%></prop:HeaderText>
    </com:TActiveBoundColumn>
    <com:TActiveTemplateColumn ID="CustomImage">
      <prop:HeaderText><%[ Image ]%></prop:HeaderText>
      <prop:ItemTemplate>
        <com:TImage>
          <prop:ImageUrl><%# $this->Parent->Data->CustomImageUrl %></prop:ImageUrl>
        </com:TImage>
      </prop:ItemTemplate>
      <prop:EditItemTemplate>
        <com:TActiveTextBox ID="Value">
          <prop:Text><%# $this->Parent->Data->CustomImage %></prop:Text>
        </com:TActiveTextBox><br />
        <com:SafeActiveFileUpload
            OnFileUpload="SourceTemplateControl.uploadRowFile">
          <prop:CustomData><%# $this->Parent->Data->UID %></prop:CustomData>
        </com:SafeActiveFileUpload>
      </prop:EditItemTemplate>
    </com:TActiveTemplateColumn>
    <com:TActiveEditCommandColumn
        HeaderText="">
        <prop:EditText><%[ Edit ]%></prop:EditText>
        <prop:UpdateText><%[ Save ]%></prop:UpdateText>
        <prop:CancelText><%[ Cancel ]%></prop:CancelText>
    </com:TActiveEditCommandColumn>
  </com:TActiveDataGrid>
</com:TPanel>