bannerEdit.html
11 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
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
<%include '../../common/__ui/header'%>
<%include '../../common/__partail/ListHeader'%>
<div class="contentpanel">
<div class="row">
<div class="col-md-12">
<form id="basicForm" role="form" class="form-horizontal form-bordered" method="post" action="<%action%>" novalidate="novalidate">
<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-1 control-label">名称</label>
<div class="col-sm-8">
<input type="text" id="caption" name="caption" class="form-control" placeholder="名称" required value="<%data.caption%>" maxlength="200"/>
<input type="hidden" id="id" name="id" value="<%data.id%>"/>
<input type="hidden" id="createTime" name="createTime" value="<%data.createTime%>"/>
</div>
</div>
<div class="form-group">
<label class="col-sm-1 control-label">位置</label>
<div class="col-sm-4">
<select id="positionId" class="form-control" required placeholder="位置" name="positionId">
<option value="<%data.positionId%>"><%data.positionName%></option>
</select>
</div>
<label class="col-sm-1 control-label">样式</label>
<div class="col-sm-2">
<select id="templetId" class="form-control" required placeholder="样式" name="templetId">
<option value="<%data.templetId%>"><%data.templetName%></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-1 control-label">分类</label>
<div class="col-sm-4">
<div id="sortTree" style="width: 100%"></div>
</div>
<label class="col-sm-1 control-label">性别</label>
<div class="col-sm-2">
<label class="radio-inline">
<input type="radio" name="gender" value="1">男</label>
<label class="radio-inline">
<input type="radio" name="gender" value="2">女</label>
<label class="radio-inline">
<input type="radio" name="gender" value="3">通用</label>
<input type="hidden" id="gender" name="gender" value="<%data.gender%>" for="radio" required placeholder="性别"/>
</div>
</div>
<div class="form-group title_div">
<label class="col-sm-1 control-label">标题</label>
<div class="col-sm-8">
<input type="text" id="data_title" name="data_title" class="form-control" value="<%data.bannerData.title%>" placeholder="标题" value="" maxlength="200"/>
</div>
</div>
<div class="form-group subtitle_div">
<label class="col-sm-1 control-label">副标题</label>
<div class="col-sm-8">
<input type="text" id="data_subtitle" name="data_subtitle" class="form-control" placeholder="副标题" value="<%data.bannerData.subtitle%>" maxlength="200"/>
</div>
</div>
<div class="form-group intro_div">
<label class="col-sm-1 control-label">内容</label>
<div class="col-sm-8">
<textarea id="data_intro" name="data_intro" class="form-control" rows="10" value="<%data.bannerData.intro%>"><%data.bannerData.intro%></textarea>
</div>
</div>
<div class="form-group" id="keywordDiv"> </div>
<div class="form-group logo_div">
<label class="col-sm-1 control-label">图片</label>
<div class="col-sm-8">
<input type="file" id="logo" name="logo" value="<%data.bannerData.logo%>" />
</div>
</div>
<div class="form-group url_div">
<label class="col-sm-1 control-label">URL</label>
<div class="col-sm-8">
<input id="data_url" name="data_url" class="form-control" value="<%data.bannerData.url%>" placeholder="URL(请加上http://)"/>
</div>
</div>
</div>
</div>
</div>
<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-1 control-label">价格</label>
<div class="col-sm-2">
<input type="text" id="price" name="price" class="form-control" placeholder="价格" value="<%data.price%>" maxlength="10"/>
</div>
<label class="col-sm-3 control-label">尺码</label>
<div class="col-sm-3">
<select id="sizeId" class="form-control" placeholder="尺码" name="sizeId">
<option value="<%data.sizeId%>"><%data.sizeName%></option>
</select>
</div>
</div>
<div class="form-group" id="styleDiv"> </div>
<div class="form-group" id="colorDiv"> </div>
<div class="form-group" id="brandDiv"> </div>
</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_banner" type="submit" data-loading-text="保存中..." class="btn delay-btn btn-success">保存</button>
</div>
</div>
</div>
</div>
</form>
</div>
</div>
</div>
<script type="text/template" id="templateStyle">
<label class="col-sm-1 control-label">风格</label>
<div class="col-sm-8">
[[each data as item index ]]
<label class="radio-inline">
<input type="checkbox" name="style" data-index="[[index]]" class="attr_checkobx_class" value="[[item.id]]">[[item.text]]</label>
[[/each]]
<input type="hidden" id="style" value="[[selectStyle||'']]" for="checkbox" />
</div>
</script>
<script type="text/template" id="templateColor">
<label class="col-sm-1 control-label">颜色</label>
<div class="col-sm-8">
[[each list as item index ]]
<label class="radio-inline">
<input type="radio" name="color" value="[[item.id]]">[[item.colorName]]</label>
[[/each]]
<input type="hidden" id="color" value="<%data.color%>" for="radio" name="color"/>
</div>
</script>
<script type="text/template" id="templateKeyword">
<label class="col-sm-1 control-label"><button class="btn delay-btn btn-addKeyword" style="background-color: #5cb85c">增加关键字</button></label>
<div class="col-sm-8" id="keywordListId">
<table style="width: 100%" id="templateKeywordTable">
[[each keyword as item index ]]
<tr style="width: 100%;">
<td style="padding-bottom: 5px">
<label class="col-sm-1 control-label" style="width: 20%">关键字</label>
<div class="col-sm-2" style="width: 80%">
<input type="text" name="word" value="[[item.word]]" class="form-control" placeholder="关键字"/>
</div>
</td>
<td style="padding-bottom: 5px">
<label class="col-sm-1 control-label" style="width: 20%">关键字URL</label>
<div class="col-sm-6" style="width: 80%">
<input type="text" name="url" value="[[item.url]]" class="form-control" placeholder="关键字URL"/>
</div>
</td>
</tr>
[[/each]]
</table>
</div>
</script>
<script type="text/template" id="templateKeywordItem">
<tr style="width: 100%;">
<td style="padding-bottom: 5px">
<label class="col-sm-1 control-label" style="width: 20%">关键字</label>
<div class="col-sm-2" style="width: 80%">
<input type="text" name="word" value="" class="form-control" placeholder="关键字"/>
</div>
</td>
<td style="padding-bottom: 5px">
<label class="col-sm-1 control-label" style="width: 20%">关键字URL</label>
<div class="col-sm-6" style="width: 80%">
<input type="text" name="url" value="" class="form-control" placeholder="关键字URL(请加上http://)"/>
</div>
</td>
</tr>
</script>
<script type="text/template" id="templateBrandItem">
<div class="form-group">
<label class="col-sm-1 control-label">品牌</label>
<div class="col-sm-4">
<select id="brand" size="20" class="form-control" multiple="multiple">
[[each data as item index ]]
[[if item.text]]
<option value="[[item.id]]">[[item.text]]</option>
[[/if]]
[[/each]]
</select>
</div>
</div>
</script>
<%include '../../common/__ui/footer'%>