blob: 1287751aee3bf034b89ff255fad40c2278796764 (
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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
|
{strip}
<div class="floaticon">{bithelp}</div>
<div class="edit newsletters">
<div class="header">
<h1>{tr}Newsletter Settings{/tr}</h1>
</div>
<div class="body">
{if !$newsletters || $gContent->isValid() || $smarty.request.new}
{form legend="Create / Edit Newsletters"}
{if $individual eq 'y'}
<a href="{$smarty.const.KERNEL_PKG_URL}object_permissions.php?objectName=newsletter%20{$gContent->mInfo.name}&object_type=newsletter&permType=newsletters&object_id={$gContent->mInfo.nl_id}">{tr}There are individual permissions set for this newsletter{/tr}</a><br /><br />
{/if}
<input type="hidden" name="nl_id" value="{$gContent->mNewsletterId}" />
<div class="row">
{formlabel label="Title" for="title"}
{forminput}
<input type="text" name="title" id="title" value="{$gContent->mInfo.title|escape}" />
{formhelp note="Title of the newsletter."}
{/forminput}
</div>
<div class="row">
{formlabel label="Description" for="description"}
{forminput}
<textarea name="edit" rows="4" cols="40" id="description">{$gContent->mInfo.data|escape}</textarea>
{formhelp note="Description of the newsletter, that users know what they are getting themselves into."}
{/forminput}
</div>
<div class="row">
{formlabel label="Users can Subscribe" for="allow_user_sub"}
{forminput}
<input type="checkbox" name="allow_user_sub" id="allow_user_sub" {if $gContent->mInfo.allow_user_sub eq 'y'}checked="checked"{/if} />
{formhelp note="Users can subscribe to this list. Disabling this options means that you have to manually add users to the list."}
{/forminput}
</div>
<div class="row">
{formlabel label="Any e-mail Address" for="allow_any_sub"}
{forminput}
<input type="checkbox" name="allow_any_sub" id="allow_any_sub" {if $gContent->mInfo.allow_any_sub eq 'y'}checked="checked"{/if} />
{formhelp note="Users may subscribe using any email address."}
{/forminput}
</div>
<div class="row">
{formlabel label="Append Un/Subscribe Instructions" for="unsub_msg"}
{forminput}
<input type="checkbox" name="unsub_msg" id="unsub_msg" {if $gContent->mInfo.unsub_msg eq 'y'}checked="checked"{/if} />
{formhelp note="Append instructions on how to subscribe / unsubscribe to ever outgoing newsletter. This is only useful when users can un / subscribe to the list themselves."}
{/forminput}
</div>
<div class="row">
{formlabel label="Validate e-mail Addresses" for="validate_addr"}
{forminput}
<input type="checkbox" name="validate_addr" id="validate_addr" {if $gContent->mInfo.validate_addr eq 'y'}checked="checked"{/if} />
{formhelp note="Validate all email addresses before they are added to the list. This might result in members not being added despite working email addresses."}
{/forminput}
</div>
<div class="row submit">
<input type="submit" name="cancel" value="{tr}Cancel{/tr}" />
<input type="submit" name="save" value="{tr}Save{/tr}" />
</div>
{/form}
{else}
{minifind}
<table class="data">
<caption>{tr}Newsletters{/tr}</caption>
<tr>
<th>{smartlink ititle="Name" isort=name offset=$offset}</th>
<th>{smartlink ititle="Description" isort=description offset=$offset}</th>
<th>{smartlink ititle="Created" isort=last_sent offset=$offset}</th>
<th>{smartlink ititle="Last Sent" isort=created offset=$offset}</th>
<th>{smartlink ititle="Unsubscribed" isort=users offset=$offset}</th>
<th>{tr}Action{/tr}</th>
</tr>
{foreach key=nlId from=$newsletters item=nl}
<tr class="{cycle values='odd,even'}">
<td><a href="{$smarty.const.NEWSLETTERS_PKG_URL}index.php?nl_id={$nlId}">{$nl.title}</a></td>
<td>{$nl.data}</td>
<td>{$nl.created|bit_short_date}</td>
<td>{$nl.last_sent|bit_short_date}</td>
<td><a href="{$smarty.const.NEWSLETTERS_PKG_URL}admin/admin_newsletter_subscriptions.php?nl_id={$nl.nl_id}"> {$nl.unsub_count|default:0}</a></td>
<td style="text-align:right;">
<a href="{$smarty.const.NEWSLETTERS_PKG_URL}edition_edit.php?nl_id={$nl.nl_id}">{biticon ipackage=liberty iname=new iexplain="New Edition"}</a>
<a href="{$smarty.const.NEWSLETTERS_PKG_URL}newsletters.php?remove=1&nl_id={$nl.nl_id}">{biticon ipackage=liberty iname=delete iexplain=Remove}</a>
<a href="{$smarty.const.NEWSLETTERS_PKG_URL}newsletters.php?&nl_id={$nl.nl_id}">{biticon ipackage=liberty iname=edit iexplain=Edit}</a>
{if $channels[user].individual eq 'y'}({/if}<a href="{$smarty.const.KERNEL_PKG_URL}object_permissions.php?objectName=newsletter%20{$nl.title}&object_type={$smarty.const.BITNEWSLETTER_CONTENT_TYPE_GUID}&permType=newsletters&object_id={$nlId}">{biticon ipackage=liberty iname=permissions iexplain=Permissions}</a>{if $nl.individual eq 'y'}){/if}
</td>
</tr>
{foreachelse}
<tr class="norecords">
<td colspan="7">{tr}No Records Found{/tr}</td>
</tr>
{/foreach}
</table>
{if $gBitUser->hasPermission('bit_p_create_newsletters')}
<a href="{$smarty.server.php_self}?new=1">Create new newsletter</a>
{/if}
{pagination}
{/if}
</div><!-- end .body -->
</div><!-- end .___ -->
{/strip}
|