Porattr.html
7.73 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
<%include '../../common/views/__ui/header'%>
<%include '../../common/views/__partail/ListHeader'%>
<div class="contentpanel">
<div class="row">
<div class="col-md-3">
<div class="panel panel-default noborder pattrscroll">
<div class="panel-body">
<div class="pannel-scroll">
<ul class="list-group">
<%if data%>
<%each data as item%>
<li class="list-group-item level<%item.sortLevel%> <%if item.child%>hidden<%/if%>" data-parent="<%item.parentId%>" data-val="<%item.id%>" data-status="close">
<span class="icon expand-icon glyphicon glyphicon-plus"></span>
<%item.sortName%>
</li>
<%/each%>
<%/if%>
</ul>
</div>
</div>
</div>
</div>
<div class="col-md-9">
<div class="panel panel-default">
<div class="panel-heading noborder">
<button class="btn btn-success model-attr-btn" disabled data-toggle="modal" id="add-attri" data-target="#addAttr">
<i class="fa fa-plus"></i> 添加属性
</button>
</div>
</div>
<div id="attr-table" class="table-responsive">
</div>
</div>
</div>
</div>
<script type="text/template" id="template">
<form id="add-attr-form" class="form-horizontal form-bordered" method="post" action="/product/attr/add" style="height: 400px;overflow: auto">
<div class="form-group">
<label class="col-md-3 control-label">
属性名称<i class="red">*</i>
</label>
<div class="col-md-6">
<input id="attributeName" value="{attributeName}" class="form-control width300" type="text" placeholder="属性名称" required="required">
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label">
销售类型<i class="red">*</i>
</label>
<div class="col-md-6">
<select id="saleType" class="attr-select width300" data-placeholder="销售类型" value="{saleType}" required="required">
<option value="">请选择</option>
<option value="1">销售属性</option>
<option value="2">非销售属性</option>
<option value="3">扩展属性</option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label">
输入类型<i class="red">*</i>
</label>
<div class="col-md-6">
<select id="inputType" class="attr-select width300" data-placeholder="输入类型" value="{inputType}" required="required">
<option value="">请选择</option>
<option value="radio">单选按钮</option>
<option value="checkbox">复选框</option>
<option value="select">下拉列表</option>
<option value="text">单行文本框</option>
<option value="textarea">多行文本框</option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label">
是否必选
</label>
<div class="col-md-6">
<select id="isMust" value="{isMust}" class="attr-select width300" data-placeholder="是否必选">
<option value="">请选择</option>
<option value="Y">是</option>
<option value="N">否</option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label">
启用搜索
</label>
<div class="col-md-6">
<select id="isSearch" value="{isSearch}" class="attr-select width300" data-placeholder="启用搜索">
<option value="0">请选择</option>
<option value="Y">是</option>
<option value="N">否</option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label">
最大输入值
</label>
<div class="col-md-6">
<input id="maxValueLen" class="form-control width300" value="{maxValueLen}" type="text" placeholder="最大输入值">
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label">
是否允许别名
</label>
<div class="col-md-6">
<select id="isAllowAlias" value="{isAllowAlias}" class="attr-select width300" data-placeholder="是否允许别名">
<option value="">请选择</option>
<option value="Y">是</option>
<option value="N">否</option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label">
排序
</label>
<div class="col-md-6">
<input id="orderBy" class="form-control width300" type="text" value="{orderBy}" placeholder="排序">
</div>
</div>
<div class="form-group" id="propValue">
<label class="col-md-3 control-label">
属性值<i class="red">*</i>
</label>
<div class="col-md-6" >
<input id="attributeValues" value="{attributeValues}" class="form-control width300" type="text" placeholder="属性值" required="required">
<div id="prop-value-table" class="table-responsive" >
</div>
</div>
</div>
<!--新增-->
<div class="form-group">
<label class="col-md-3 control-label">
展示位置
</label>
<div class="col-md-6">
<select id="displayPosition" value="{displayPosition}" class="attr-select width300" data-placeholder="展示位置">
<option value="">请选择</option>
<option value="1">基础商品-非销售属性</option>
<option value="2">网售信息-上架后补全信息</option>
<option value="3">网售信息-商品参数</option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label">
备注
</label>
<div class="col-md-6">
<textarea id="remark" value="{remark}" class="form-control width300" rows="2" name="remark"></textarea>
</div>
</div>
<div class="form-group hidden">
<label class="col-md-3 control-label">
ID<i>*</i>
</label>
<div class="col-md-6">
<input id="categoryId" class="form-control width300" value="" type="text" placeholder="ID">
</div>
</div>
<div class="form-group hidden">
<label class="col-md-3 control-label">
attributeId<i class="red">*</i>
</label>
<div class="col-md-6">
<input id="attributeId" class="form-control width300" value="" type="text" placeholder="attributeId">
</div>
</div>
</form>
</script>
<%include '../../common/views/__ui/footer'%>