123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128 |
- <?php /*a:2:{s:60:"/data/web/pl.valimart.net/app/admin/view/type/attr_edit.html";i:1657785098;s:59:"/data/web/pl.valimart.net/app/admin/view/public/header.html";i:1657785098;}*/ ?>
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="utf-8">
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
- <title><?php echo htmlentities((isset($html_title) && ($html_title !== '')?$html_title:config('ds_config.site_name'))); ?><?php echo htmlentities(lang('system_backend')); ?></title>
- <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
- <link rel="stylesheet" href="<?php echo htmlentities(ADMIN_SITE_ROOT); ?>/css/admin.css">
- <link rel="stylesheet" href="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/js/jquery-ui/jquery-ui.min.css">
- <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/jquery-2.1.4.min.js"></script>
- <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/jquery.validate.min.js"></script>
- <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/jquery.cookie.js"></script>
- <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/common.js"></script>
- <script src="<?php echo htmlentities(ADMIN_SITE_ROOT); ?>/js/admin.js"></script>
- <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/js/jquery-ui/jquery-ui.min.js"></script>
- <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/js/jquery-ui/jquery.ui.datepicker-zh-CN.js"></script>
- <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/perfect-scrollbar.min.js"></script>
- <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/layer/layer.js"></script>
- <script type="text/javascript">
- var BASESITEROOT = "<?php echo htmlentities(BASE_SITE_ROOT); ?>";
- var ADMINSITEROOT = "<?php echo htmlentities(ADMIN_SITE_ROOT); ?>";
- var BASESITEURL = "<?php echo htmlentities(BASE_SITE_URL); ?>";
- var HOMESITEURL = "<?php echo htmlentities(HOME_SITE_URL); ?>";
- var ADMINSITEURL = "<?php echo htmlentities(ADMIN_SITE_URL); ?>";
- </script>
- </head>
- <body>
- <div id="append_parent"></div>
- <div id="ajaxwaitid"></div>
- <div class="page">
- <form class="" method="post">
- <div class="ncap-form-default">
- <dl>
- <dt><?php echo htmlentities(lang('type_add_attr_name')); ?></dt>
- <dd>
- <input type="hidden" name="attr_id" value="<?php echo htmlentities($attribute['attr_id']); ?>" />
- <input type="hidden" name="type_id" value="<?php echo htmlentities($attribute['type_id']); ?>" />
- <input type="text" name="attr_name" id="attr_name" value="<?php echo htmlentities($attribute['attr_name']); ?>" />
- <span class="err"></span>
- <p class="notic"></p>
- </dd>
- </dl>
- <dl>
- <dt><?php echo htmlentities(lang('ds_sort')); ?></dt>
- <dd>
- <input type="text" name="attr_sort" id="attr_sort" value="<?php echo htmlentities($attribute['attr_sort']); ?>" />
- <span class="err"></span>
- <p class="notic"></p>
- </dd>
- </dl>
- <dl>
- <dt><?php echo htmlentities(lang('type_edit_type_attr_is_show')); ?></dt>
- <dd class="onoff">
- <label for="attr_show1" class="cb-enable <?php if($attribute['attr_show'] == '1'): ?>selected<?php endif; ?>" ><span><?php echo htmlentities(lang('ds_yes')); ?></span></label>
- <label for="attr_show2" class="cb-disable <?php if($attribute['attr_show'] == '0'): ?>selected<?php endif; ?>" ><span><?php echo htmlentities(lang('ds_no')); ?></span></label>
- <input id="attr_show1" name="attr_show" <?php if($attribute['attr_show'] == '1'): ?>checked="checked"<?php endif; ?> value="1" type="radio">
- <input id="attr_show2" name="attr_show" <?php if($attribute['attr_show'] == '0'): ?>checked="checked"<?php endif; ?> value="0" type="radio">
- </dd>
- </dl>
- </div>
- <table class="ds-default-table">
- <thead>
- <tr>
- <th width="200"><?php echo htmlentities(lang('ds_del')); ?></th>
- <th width="100"><?php echo htmlentities(lang('ds_sort')); ?></th>
- <th><?php echo htmlentities(lang('type_add_attr_value')); ?></th>
- <th width="100"><?php echo htmlentities(lang('ds_handle')); ?></th>
- </tr>
- </thead>
- <tbody id="tr_model">
- <tr></tr>
- <?php if($attributevalue_list): if(is_array($attributevalue_list) || $attributevalue_list instanceof \think\Collection || $attributevalue_list instanceof \think\Paginator): if( count($attributevalue_list)==0 ) : echo "" ;else: foreach($attributevalue_list as $key=>$val): ?>
- <tr>
- <td>
- <input type="hidden" name='attr_value[<?php echo htmlentities($val['attrvalue_id']); ?>][form_submit]' value='' />
- <input type="checkbox" name="attr_del[<?php echo htmlentities($val['attrvalue_id']); ?>]" value="<?php echo htmlentities($val['attrvalue_id']); ?>" />
- </td>
- <td><input type="text" class="form-control" name="attr_value[<?php echo htmlentities($val['attrvalue_id']); ?>][sort]" value="<?php echo htmlentities($val['attrvalue_sort']); ?>"/></td>
- <td><input type="text" class="form-control" name="attr_value[<?php echo htmlentities($val['attrvalue_id']); ?>][name]" value="<?php echo htmlentities($val['attrvalue_name']); ?>"/></td>
- <td></td>
- </tr>
- <?php endforeach; endif; else: echo "" ;endif; ?>
- <?php endif; ?>
- </tbody>
- <tbody>
- <tr>
- <td>
- <a id="add_type" class="btn-add-nofloat marginleft" href="JavaScript:void(0);"> <span><?php echo htmlentities(lang('type_add_attr_add_one')); ?></span> </a>
- </td>
- </tr>
- <tr>
- <td>
- <input class="btn" type="submit" value="<?php echo htmlentities(lang('ds_submit')); ?>"/>
- </td>
- </tr>
- </tbody>
- </table>
-
- </form>
- </div>
- <!--载入-->
- <script>
- $(function() {
- var i = 0;
- var tr_model = '<tr><td></td>' +
- '<td><input type="text" class="form-control" name="attr_value[key][sort]" value="0" /></td>' +
- '<td><input type="text" class="form-control" name="attr_value[key][name]" value="" /></td>' +
- '<td><a onclick="remove_tr($(this));" href="JavaScript:void(0);"><?php echo htmlentities(lang('ds_del')); ?></a></td>' +
- '</tr>';
- $("#add_type").click(function() {
- $('#tr_model > tr:last').after(tr_model.replace(/key/g, 's_' + i));
- i++;
- });
- });
- function remove_tr(o) {
- o.parents('tr:first').remove();
- }
- </script>
- </body>
|