Teach the DB interface modules about the weight/length/... fields
[bse.git] / site / templates / admin / edit_product.tmpl
CommitLineData
58baa27b 1<:wrap admin/xbase.tmpl title => "Shop Administration", menuitem=>edit, showtitle=>1 :>
35c0719f 2<:ifMessage:>
27feb834
TC
3<p><b><:message:></b></p>
4<:or:><:eif:>
58baa27b 5<:include admin/product_menu.tmpl:>
759c295d
TC
6 <h2>Product Details</h2>
7<:ifNew:><:or:><:if Or [iadminuser_count] [iadmingroup_count]:>
abf5bbc6 8 <form action="/cgi-bin/admin/adminusers.pl">
12bcb7ac 9 <input type="hidden" name="id" value="<: article id:>" />
58baa27b 10 <table class="editform editformtiny">
abf5bbc6 11 <tr>
58baa27b
TC
12 <th>Manage access:</th>
13 <td>
12bcb7ac 14 <select name="adminid">
08123550 15<:iterator begin adminusers:>
12bcb7ac
TC
16<option value="<:iadminuser id:>">User <:iadminuser logon:>
17</option><:iterator end adminusers:>
08123550 18<:iterator begin admingroups:>
12bcb7ac
TC
19<option value="<:iadmingroup id:>">Group <:iadmingroup name:>
20</option><:iterator end admingroups:>
abf5bbc6 21 </select>
12bcb7ac 22 <input type="submit" name="a_showobjectart" value="Manage" />
abf5bbc6 23 </td>
58baa27b 24 <td class="help"><:help access manage:>
abf5bbc6
TC
25 </td>
26 </tr>
27 </table>
abf5bbc6
TC
28 </form>
29<br>
759c295d 30<:or Or:><:eif Or:><:eif:>
12b42a0b
TC
31<form action="<:script:>" enctype="multipart/form-data" method="post">
32 <input type="hidden" name="lastModified" value="<: old lastModified article lastModified :>" />
33 <input type="hidden" name="type" value="Product" />
34 <input type="hidden" name="id" value="<:product id:>" />
58baa27b 35 <table class="editform">
759c295d 36 <tr>
58baa27b
TC
37 <th>Catalog:</th>
38 <td>
abf5bbc6 39<:ifFieldPerm parentid:><select name="parentid"><:list:></select><:or:><:parent title:> (<:parent id:>)<:eif:></td>
12bcb7ac 40 <td nowrap="nowrap" bgcolor="#FFFFFF"><:help product catalog:> <:error_img
429e9103 41 parentid:></td>
759c295d
TC
42 </tr>
43 <tr>
58baa27b
TC
44 <th>Title:</th>
45 <td><:ifFieldPerm title:><input type="text" name="title" value="<:old title default title:>" size="60"><:or:><:product title:><:eif:> </td>
46 <td class="help"><:help product title:> <:error_img title:></td>
5bc24704 47 </tr>
37726cc9 48 <:if Cfg "title alias" [concatenate level [article level]]:><tr>
58baa27b
TC
49 <th>Alias:</th>
50 <td>
37726cc9
AO
51 <:if FieldPerm titleAlias:><input type="text" name="titleAlias" maxlength="<:cfg fields alias_size 60:>" size="60" value="<:old titleAlias article titleAlias:>" /><:or FieldPerm:><:article titleAlias:><:eif FieldPerm:>
52 </td>
58baa27b 53 <td class="help"><:help edit titleAlias:> <:error_img titleAlias:></td>
37726cc9 54 </tr><:or Cfg:><:eif Cfg:>
ca9aa2bf 55 <tr>
58baa27b
TC
56 <th>Summary:</th>
57 <td><:ifFieldPerm summary:><input type="text" name="summary" value="<:old summary default summary:>" size=60><:or:><:product summary:><:eif:> </td>
58 <td class="edit"><:help product summary:> <:error_img
759c295d 59 summary:></td>
ca9aa2bf 60 </tr>
74b21f6d 61 <tr>
58baa27b
TC
62 <th>Description:</th>
63 <td><:ifFieldPerm description:><input type="text" name="description" value="<:old description default description:>" size=60><:or:><:product description:><:eif:> </td>
64 <td class="help"><:help product description:> <:error_img
74b21f6d
TC
65 description:></td>
66 </tr>
67 <tr>
58baa27b
TC
68 <th>Product Code:</th>
69 <td><:ifFieldPerm product_code:><input type="text" name="product_code" value="<:old product_code default product_code:>" size=60><:or:><:product product_code:><:eif:> </td>
70 <td class="help"><:help product product_code:> <:error_img
74b21f6d
TC
71 product_code:></td>
72 </tr>
27feb834 73 <tr>
58baa27b
TC
74 <th> Body:</th>
75 <td>
12bcb7ac 76 <:ifFieldPerm body:><textarea name="body" rows="15" cols="60" wrap="virtual"><:old body default body:></textarea><:or:><:bodytext product body:><:eif:>
5bc24704 77 </td>
58baa27b 78 <td class="help"><:help body body:> <:error_img
429e9103 79 body:></td>
759c295d 80 </tr>
0a66f55c 81 <:if Cfgsection [concatenate level [article level] " menus"]:><tr>
58baa27b
TC
82 <th>Menu:</th>
83 <td>
aef5bada 84 <:if FieldPerm menu:><select name="menu" id="menu">
0a66f55c
AO
85 <:iterator begin cfgsection [concatenate level [article level] " menus"] sort=key:><option value="<:cfgentry key:>"<:if Eq [old menu] [cfgentry key]:> selected="selected"<:or Eq:><:eif Eq:>><:cfgentry value:></option><:iterator separator cfgsection:>
86 <:iterator end cfgsection:>
aef5bada 87 </select><:or FieldPerm:><:article menu:><:eif FieldPerm:>
0a66f55c 88 </td>
58baa27b 89 <td class="help"><:help article menu:> <:error_img menu:></td>
0a66f55c 90 </tr><:or Cfgsection:><:eif Cfgsection:>
759c295d 91 <tr>
58baa27b
TC
92 <th>Template:</th>
93 <td><:ifFieldPerm template:><:templates:><:or:><:product template:><:eif:></td>
94 <td class="help"><:help product template:> <:error_img
429e9103 95 template:></td>
759c295d
TC
96 </tr>
97 <tr>
58baa27b
TC
98 <th>List article:</th>
99 <td> <:if FieldPerm listed:><:list listed:><:or FieldPerm:><:if Article listed:><:ifEq [article listed] "1":>Yes<:or:>In Sections, but not menu<:eif:><:or Article:>No<:eif Article:><:eif FieldPerm:> </td>
100 <td class="help"><:help edit listed:> <:error_img listed:></td>
c76e86ea
TC
101 </tr>
102 <tr>
58baa27b
TC
103 <th>Link alias:</th>
104 <td>
c76e86ea
TC
105 <:ifFieldPerm linkAlias:><input type="text" name="linkAlias" maxlength="<:cfg fields linkAlias_size 255:>" size="40" value="<: old linkAlias article linkAlias :>">
106 <:or:><:default linkAlias:><:eif:></td>
58baa27b 107 <td class="help"><:help edit linkAlias:> <:error_img linkAlias:></td>
759c295d 108 </tr>
429e9103 109 <tr>
58baa27b
TC
110 <th>Flags:</th>
111 <td><:iterator begin flags:><:if FieldPerm flags:>
12bcb7ac
TC
112 <input type="checkbox" name="flags" value="<:flag id:>" <:ifFlagSet [flag id]:>checked<:or:>
113 <:eif:> /><:or FieldPerm:><:ifFlagSet [flag id]:>Yes<:or:>No<:eif:>
cc9019d1 114 <:eif FieldPerm:><:flag desc:><:iterator separator flags:><br /><:iterator end flags:></td>
58baa27b 115 <td class="help"><:help edit flags:> <:error_img flags:></td>
5bc24704 116 </tr>
9604a90c 117 <tr>
58baa27b
TC
118 <th>Page title:</th>
119 <td>
12bcb7ac 120 <:ifFieldPerm pageTitle:><input type="text" name="pageTitle" value='<:old pageTitle article pageTitle:>' size="60" maxlength="255" /> (alternate title)<:or:><:article pageTitle:><:eif:>
9604a90c 121 </td>
58baa27b 122 <td class="help"><:help edit pageTitle:> <:error_img pageTitle:></td>
9604a90c 123 </tr>
12bcb7ac 124 <tr>
58baa27b
TC
125 <th>Meta description:</th>
126 <td>
12bcb7ac
TC
127 <:ifFieldPerm metaDescription:><input type="text" name="metaDescription" value='<:old metaDescription article metaDescription:>' size="60" maxlength="255" /><:or:><:article metaDescription:><:eif:>
128 </td>
58baa27b 129 <td class="help"><:help edit metaDescription:> <:error_img metaDescription:></td>
12bcb7ac
TC
130 </tr>
131 <tr>
58baa27b
TC
132 <th>Meta keywords:</th>
133 <td>
12bcb7ac
TC
134 <:ifFieldPerm metaKeywords:><input type="text" name="metaKeywords" value='<:old metaKeywords article metaKeywords:>' size="60" maxlength="255" /> (comma separated)<:or:><:article metaKeywords:><:eif:>
135 </td>
58baa27b 136 <td class="help"><:help edit metaKeywords:> <:error_img metaKeywords:></td>
12bcb7ac 137 </tr>
9604a90c 138 <tr>
58baa27b
TC
139 <th>Author name:</th>
140 <td>
12bcb7ac 141 <:if FieldPerm author:><input type="text" name="author" value='<:ifCfg editor auto_author:><:old author adminuser name:><:or:><:old author:><:eif:>' size="40" maxlength="255" /><:or FieldPerm:><:article author:><:eif FieldPerm:>
9604a90c 142 </td>
58baa27b 143 <td class="help"><:help edit author:> <:error_img author:></td>
9604a90c 144 </tr>
5bc24704 145 <tr>
58baa27b
TC
146 <th>Lead time:</th>
147 <td>
759c295d 148 <:ifFieldPerm leadTime:>
12bcb7ac 149 <input type="text" name="leadTime" value="<:old leadTime default leadTime:>" size="5" /><:or:><:product leadTime:><:eif:>
5bc24704 150 days</td>
58baa27b 151 <td class="help"><:help product leadtime:> <:error_img leadTime:></td>
5bc24704
TC
152 </tr>
153 <tr>
58baa27b
TC
154 <th><:cfg "product fields" retailPrice "Retail price":>:</th>
155 <td>$
12bcb7ac 156 <:ifFieldPerm retailPrice:><input type="text" name="retailPrice" value="<:old retailPrice money default retailPrice:>" size="7" />
759c295d 157 (0.00)<:or:><:money product retailPrice:><:eif:> </td>
58baa27b 158 <td class="help"><:help product retail:> <:error_img retailPrice:></td>
5bc24704
TC
159 </tr>
160 <tr>
58baa27b
TC
161 <th>Wholesale price:</th>
162 <td>$
12bcb7ac 163 <:ifFieldPerm wholesalePrice:><input type="text" name="wholesalePrice" value="<:old wholesalePrice money default wholesalePrice:>" size="7" />
abf5bbc6 164 (0.00)<:or:><:money product wholesalePrice:><:eif:></td>
58baa27b 165 <td class="help"><:help product wholesale:> <:error_img wholesalePrice:></td>
5bc24704
TC
166 </tr>
167 <tr>
58baa27b
TC
168 <th>GST:</th>
169 <td>$
12bcb7ac 170 <:ifFieldPerm gst:><input type="text" name="gst" value="<:old gst money default gst:>" size="7" />
abf5bbc6 171 (0.00)<:or:><:money product gst:><:eif:></td>
58baa27b 172 <td class="help"><:help product gst:> <:error_img gst:></td>
5bc24704
TC
173 </tr>
174 <tr>
58baa27b
TC
175 <th>Release date:</th>
176 <td>
12bcb7ac 177 <:ifFieldPerm release:><input type="text" name="release" value="<:old release date "%d/%m/%Y" default release:>" size="11" />
abf5bbc6 178 (dd/mm/yyyy)<:or:><:date "%d/%m/%Y" product release:><:eif:></td>
58baa27b 179 <td class="help"><:help product release:> <:error_img
429e9103 180 release:></td>
5bc24704
TC
181 </tr>
182 <tr>
58baa27b
TC
183 <th>Expiry date:</th>
184 <td>
12bcb7ac 185 <:ifFieldPerm expire:><input type="text" name="expire" value="<:old expire date "%d/%m/%Y" default expire:>" size="11" />
abf5bbc6 186 (dd/mm/yyyy)<:or:><:date "%d/%m/%Y" product expire:><:eif:></td>
58baa27b 187 <td class="help"><:help product expire:> <:error_img
429e9103 188 expire:></td>
5bc24704 189 </tr>
26094672 190 <tr>
58baa27b
TC
191 <th>Summary length:</th>
192 <td>
12bcb7ac 193 <:ifFieldPerm summaryLength:><input type="text" name="summaryLength" size="10" maxlength="10" value="<:old summaryLength default summaryLength:>" /><:or:><:product summaryLength:><:eif:>
26094672 194 </td>
58baa27b 195 <td class="help"><:help product summary:> <:error_img summaryLength:></td>
26094672
TC
196 </tr>
197 <tr>
58baa27b
TC
198 <th>Display threshold:</th>
199 <td>
12bcb7ac 200 <:ifFieldPerm threshold:><input type="text" name="threshold" size="10" maxlength="10" value="<:old threshold default threshold:>" /><:or:><:product threshold:><:eif:>
35c0719f 201 </td>
58baa27b 202 <td class="help"><:help product threshold:> <:error_img threshold:></td>
26094672 203 </tr>
c2096d67 204 <tr>
58baa27b
TC
205 <th> Keywords: </th>
206 <td>
12bcb7ac 207 <:ifFieldPerm keyword:><input type="text" name="keyword" maxlength="255" size="60" value="<: old keyword default keyword :>" /><:or:><: article threshold :><:eif:>
c2096d67 208 (comma separated) </td>
58baa27b 209 <td class="help"><:help catalog keywords:> <:error_img keyword:></td>
c2096d67
TC
210 </tr>
211 <tr>
58baa27b
TC
212 <th>Always Dynamic:</th>
213 <td>
c2096d67
TC
214 <:ifFieldPerm force_dynamic:><input type="hidden" name="save_force_dynamic" value="1" /><input type="checkbox" name="force_dynamic" value="1" <:if Article force_dynamic :>checked="checked"<:or Article:><:eif Article:> />
215 <:or:><:ifArticle force_dynamic :>Yes<:or Article:>No<:eif Article:><:eif:></td>
58baa27b 216 <td class="help"><:help edit keywords:> <:error_img keyword:></td>
c2096d67 217 </tr>
a11a0d7c 218 <tr>
58baa27b
TC
219 <th>Options:</th>
220 <td>
12bcb7ac 221 <:ifFieldPerm options:><input type="text" name="options" value="<:old options default options:>" size="30" />
abf5bbc6 222 (<:alloptions:>)<:or:><:product options:><:eif:> </td>
58baa27b 223 <td class="help"><:help product options:> <:error_img options:></td>
a11a0d7c 224 </tr>
d64413ee 225<:include admin/product_custom.tmpl optional:>
27feb834 226 <tr>
58baa27b
TC
227 <th>Thumbnail image:</th>
228 <td>
12bcb7ac 229 <:ifFieldPerm thumbImage:><input type="file" name="thumbnail" /><:or:><:eif:>
35c0719f 230 <:ifProduct thumbImage:><img src="/images/<:product thumbImage:>">
12bcb7ac 231 <:if FieldPerm thumbImage:><input type="checkbox" name="remove_thumb" />
abf5bbc6 232 Remove<:or FieldPerm:><:eif FieldPerm:><:or:><:eif:> </td>
58baa27b 233 <td class="help"><:help product thumb:> <:error_img
429e9103 234 thumbImage:></td>
5bc24704 235 </tr>
759c295d 236 <:if Article id:>
27feb834 237 <tr>
58baa27b
TC
238 <th><a name="files"></a>Files:</th>
239 <td> <:if Files:>
240 <table class="editform editformsmall">
241 <tr>
27feb834
TC
242 <th>Filename</th>
243 <th>Size</th>
244 <th>Type</th>
35c0719f
TC
245 <th>D/l</th>
246 <th>Pay</th>
247 <th>User</th>
27feb834
TC
248 </tr>
249 <:iterator begin files:>
58baa27b 250 <tr>
27feb834 251 <td><:file displayName:></td>
35c0719f 252 <td align="center"><:kb file sizeInBytes:></td>
27feb834 253 <td><:file contentType:></td>
12bcb7ac
TC
254 <td align="center"><:ifFile download:>Yes<:or:>No<:eif:></td>
255 <td align="center"><:ifFile forSale:>Yes<:or:>No<:eif:></td>
256 <td align="center"><:ifFile requireUser:>Yes<:or:>No<:eif:></td>
27feb834
TC
257 </tr>
258 <:iterator end files:>
259 </table>
caa7299c
TC
260 <p><a href="<:script:>?filelist=1&id=<:article id:>"><b>Manage Files</b></a>
261 </p>
262 <:or Files:>
58baa27b 263 No files are attached to this article. <a href="<:script:>?filelist=1&id=<:article id:>"><b>Manage Files</b></a><:eif Files:>
edc5d096 264 </td>
58baa27b 265 <td class="help"><:help product
429e9103 266 files:> <:error_img files:></td>
edc5d096 267 </tr>
26094672 268 <tr>
58baa27b
TC
269 <th>Images:</th>
270 <td> <:if Images:> <:iterator begin
55753022 271 images:> <img src="/images/<: image image :>" alt="<:image alt :>" width=
26094672
TC
272 <:image width:> height=<:image height:>> <:iterator separator images:>
273 <hr noshade size="1">
15fb10f2
TC
274 <: iterator end images :>
275 <p align="left"><a href="<:script:>?id=<:article id:>&showimages=1"><b>Manage Images</b></a></p>
58baa27b 276 <:or Images:>No images are attached to this article. <a href="<:script:>?id=<:article id:>&showimages=1"><b>Manage Images</b></a>
55753022 277 <:eif Images:>
35c0719f 278 </td>
58baa27b 279 <td class="help"><:help product images:> <:error_img
429e9103 280 images:></td>
35c0719f 281 </tr>
759c295d 282 <:or Article:><:eif Article:>
d7538448 283 <tr>
58baa27b
TC
284 <th>Purchase subscribes to:</th>
285 <td>
0ec4ac8a
TC
286 <select name="subscription_id">
287 <option value="-1"<:ifEq [old subscription_id] "-1":> selected="selected"<:or:><:eif:>>(nothing)</option>
288<:iterator begin subscriptions:>
289 <option value="<:subscription subscription_id:>"<:ifEq [old subscription_id] [subscription subscription_id]:> selected="selected"<:or:><:eif:>><:subscription title:></option>
290<:iterator end subscriptions:>
d7538448 291 </select> for <input type="text" name="subscription_period" value="<:ifEq [old subscription_period] "":><:default subscription_period:><:or:><:old subscription_period:><:eif:>" size="3" /><:error_img subscription_period:> months.
0ec4ac8a 292 </td>
58baa27b 293 <td class="help"><:help product subscription_id:></td>
0ec4ac8a
TC
294 </tr>
295 <tr>
58baa27b
TC
296 <th>Can be used to:</th>
297 <td>
0ec4ac8a
TC
298 <select name="subscription_usage">
299 <option value="3"<:ifEq [old subscription_usage] "3":> selected="selected"<:or:><:eif:>>Start or renew a subscription</option>
300 <option value="1"<:ifEq [old subscription_usage] "1":> selected="selected"<:or:><:eif:>>Start a subscription only</option>
301 <option value="2"<:ifEq [old subscription_usage] "2":> selected="selected"<:or:><:eif:>>Renew a subscription only</option>
302 </select>
303 </td>
58baa27b 304 <td class="help"><:help product subscription_usage:></td>
0ec4ac8a
TC
305 </tr>
306 <tr>
58baa27b
TC
307 <th>User must be subscribed to:</th>
308 <td>
0ec4ac8a
TC
309 <select name="subscription_required">
310 <option value="-1"<:ifEq [old subscription_required] "-1":> selected="selected"<:or:><:eif:>>(nothing)</option>
311<:iterator begin subscriptions:>
312 <option value="<:subscription subscription_id:>"<:ifEq [old subscription_required] [subscription subscription_id]:> selected="selected"<:or:><:eif:>><:subscription title:></option>
313<:iterator end subscriptions:>
314 </select> to purchase this product
315 </td>
58baa27b 316 <td class="help"><:help product subscription_id:></td>
d7538448 317 </tr>
5bc24704 318 </table>
759c295d
TC
319 <p><font size="-1">*These fields cannot be modified once this product has been
320 included in an order.</font></p>
321 <:if UserCan edit_save:article:>
322 <p>
12bcb7ac 323 <:ifNew:><input type="submit" name="save" value="Add Product" /><:or:><input type="submit" name="save" value="Update Product" /><:eif:>
abf5bbc6 324 </p><:or UserCan:><:eif UserCan:>
5bc24704
TC
325</form>
326
7063727a 327<p><font size="-1">BSE Release <:release:></font></p>
5bc24704
TC
328</body>
329</html>