Add.html
7.9 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
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
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
<%include '../../common/__ui/header'%>
<%include '../../common/__partail/ListHeader'%>
<div class="contentpanel">
<div class="row">
<div class="col-md-12">
<div id="basicForm" class="form-horizontal form-bordered">
</div>
</div>
</div>
</div>
<script type="text/template" id="couponListAdd-template">
<div class="panel panel-default">
<div class="panel-heading">
<h4 class="panel-title">添加活动</h4>
</div>
<div class="panel-body">
<div class="row">
<div class="form-group">
<label class="col-sm-2 control-label">活动名称 <span class="red">*</span></label>
<div class="col-sm-8">
<input type="text" placeholder="活动名称" prompt="活动名称" class="form-control observe"
data-field="actName" required maxlength="30" value="[[actName]]">
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">活动类型 </label>
<div class="col-sm-8">
<select id="filter-activityType" tabindex="-1" class="select2-offscreen brandBtn-group observe"
value="[[activityType]]" data-field="activityType" >
<option value="-1">活动类型</option>
<option value="1">普通活动</option>
<option value="2">APP活动</option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">活动地址</label>
<div class="col-sm-8">
<input type="text" placeholder="活动地址" class="form-control observe number" data-field="actUrl"
value="[[actUrl]]">
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">活动时间</label>
<div class="col-sm-6">
<div class="col-sm-6">
<input type="text" class="form-control observe" data-field="startTime" id="startTime"
placeholder="开始时间" value="[[startTime]]" readonly >
</div>
<div class="col-sm-6">
<input type="text" class="form-control observe" data-field="endTime" id="endTime"
placeholder="结束时间" value="[[endTime]]" readonly >
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">背景图片</label>
<div class="col-sm-8">
<input type="file" bucket="couponBgImg" placeholder="背景图片" class="form-control"
data-field="bgImageUrl" value="[[bgImageUrl]]" name="couponBgImg">
<p>图片不是必选项 ,活动类型为APP活动时添加</p>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">分享标题</label>
<div class="col-sm-8">
<input type="text" placeholder="分享标题" prompt="名称" class="form-control observe"
data-field="shareTitle" maxlength="30" value="[[shareTitle]]">
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">分享描述</label>
<div class="col-sm-8">
<textarea class="form-control observe" prompt="分享描述" data-field="shareDescribe" maxlength="100"
placeholder="分享描述" style="resize: none">[[shareDescribe]]</textarea>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">分享图片</label>
<div class="col-sm-8">
<input type="file" bucket="couponImage" class="form-control"
data-field="sharePic" value="[[sharePic]]" name="couponImage">
<p>支持jpg/png/gif,建议尺寸:640 x 1038,图片不是必选项</p>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">分享地址</label>
<div class="col-sm-8">
<input type="text" placeholder="分享地址" class="form-control observe number" data-field="shareUrl"
value="[[shareUrl]]">
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">是否授权</label>
<div class="col-sm-8">
<label style="cursor: pointer;"><input type="radio" name="isVerify" value="Y" class="observe" data-field="isVerify">是</label>
<label style="cursor: pointer;"><input type="radio" name="isVerify" value="N" class="observe" data-field="isVerify">否</label>
</div>
<input type="hidden" id="isVerify" value="[[isVerify]]" for="radio" data-field="isVerify">
</div>
<div class="form-group">
<label class="col-sm-2 control-label">活动说明</label>
<div class="col-sm-8">
<textarea class="form-control observe" prompt="分享描述" data-field="instructions" maxlength="100"
placeholder="分享描述" style="resize: none">[[instructions]]</textarea>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">限制新老客户</label>
<div class="col-sm-8">
<label style="cursor: pointer;"><input type="radio" name="isNewUser" value="0" class="observe" data-field="isNewUser">不限制</label>
<label style="cursor: pointer;"><input type="radio" name="isNewUser" value="1" class="observe" data-field="isNewUser">限制新用户</label>
</div>
<input type="hidden" id="isNewUser" value="[[isNewUser]]" for="radio" data-field="isNewUser">
</div>
[[each couponIds as item index]]
<div class="form-group">
<label class="col-sm-2 control-label">优惠券</label>
<div class="col-sm-2">
<input type="text" id="couponId" class="form-control observe" value="[[item.id]]"
placeholder="ID" data-field="couponIds.[[index]].id">
</div>
<div class="col-sm-2">
<a class="col-sm-4 btn btn-primary addBtn" data-index="[[index]]">+</a>
<a class="col-sm-4 col-sm-offset-2 btn btn-danger delBtn" data-index="[[index]]">-</a>
</div>
</div>
[[/each]]
</div>
</div>
<div class="panel-footer">
<div class="row">
<div class="col-sm-8 col-sm-offset-2">
<a href="javascript:;" onclick="history.go(-1);" class="btn btn-default">取消</a>
<button id="save_brand" type="button" data-loading-text="保存中..." class="btn btn-primary">保存</button>
</div>
</div>
</div>
</div>
</script>