BVB Source Codes

WSTShop v1.1.0 B2C revenue system Show edit.html Source code

Return Download WSTShop v1.1.0 B2C revenue system: download edit.html Source code - Download WSTShop v1.1.0 B2C revenue system Source code - Type:.html
  1. {extend name="base" /}
  2. {block name="css"}
  3. <link rel="stylesheet" type="text/css" href="__STATIC__/plugins/webuploader/webuploader.css?v={$v}" />
  4. <style>
  5. .goodsCat{display:inline-block;width:150px}
  6. </style>
  7. {/block}
  8. {block name="js"}
  9. <script src="__STATIC__/plugins/webuploader/webuploader.js?v={$v}" type="text/javascript" ></script>
  10. <script src="__STATIC__/plugins//kindeditor/kindeditor.js?v={$v}" type="text/javascript" ></script>
  11. <script src="__ADMIN__/brands/brands.js?v={$v}" type="text/javascript"></script>
  12. <script>
  13. $(function () {
  14.            {if condition="$object['brandId'] !=0 "}
  15.                 WST.setValues({$object});
  16.            {/if}
  17.                 $('#brandForm').validator({
  18.                     fields: {
  19.                         brandName: {
  20.                                 tip: "请输入品牌名称",
  21.                                 rule: '品牌名称:required;length[~16];'
  22.                         },
  23.                         catId: {
  24.                                 tip: "请选择分类",
  25.                                 rule: 'checked(1~);length[~16];'
  26.                         },
  27.                         brandDesc: {
  28.                                 tip: "请输入品牌介绍",
  29.                                 rule: '品牌介绍:required;'
  30.                         }
  31.                     },
  32.                     valid: function(form){
  33.                         var brandId = $('#brandId').val();
  34.                         toEdits(brandId);
  35.                     }
  36.                 })
  37. });
  38. </script>
  39. {/block}
  40. {block name="main"}
  41. <input type='hidden' id='brandId' value='{$object["brandId"]}'/>
  42. <div class="l-loading" style="display: block" id="wst-loading"></div>
  43. <form id="brandForm" autocomplete="off">
  44. <table class='wst-form wst-box-top'>
  45.   <tr>
  46.      <th width='150'>品牌名称<font color='red'>*</font></th>
  47.      <td><input type="text" id='brandName' name='brandName' maxLength='20' style='width:300px;' class='ipt'/></td>
  48.   </tr>
  49.    <tr>
  50.      <th width='150' align='right'>所属分类<font color='red'>*</font></th>
  51.      <td>
  52.      {volist name="gcatList" id="vo"}
  53.              <label class='goodsCat'>
  54.              <input type='checkbox' id='catId' name='catId' class="ipt" value='{$vo["catId"]}'
  55.       {if condition="$object['brandId'] !=0 "}
  56.       {if in_array($vo["catId"],$object['catIds'])==1}checked{/if}
  57.       {/if}
  58.       >&nbsp;{$vo["catName"]}&nbsp;
  59.              </label>
  60.          {/volist}
  61.      </td>
  62.    </tr>
  63.    <tr width='150'>
  64.      <th align='right'>品牌图标<font color='red'>*</font></th>
  65.      <td>
  66.         <div>
  67.         <div id="filePicker" style='margin-left:0px;float:left; width: 100px'>上传图片</div>
  68.             <div style='margin-left:5px;float:left'>图片大小:400 x 200 (px),格式为 gif, jpg, jpeg,bmp, png</div>
  69.             <input id="brandImg" name="brandImg" class="text ipt" autocomplete="off" type="hidden" value="{$object.brandImg}"/>
  70.             <div style="clear:both;"></div>
  71.         </div>
  72.      </td>
  73.    </tr>
  74.    <tr >
  75.      <th align='right' height='152'>预览图:</th>
  76.      <td >
  77.         <div id="preview" >
  78.         {if $object['brandId']!=0}
  79.         <img src="/{$object['brandImg']}" class="ipt" height='152'/>
  80.         {/if}
  81.         </div>
  82.      </td>
  83.    </tr>
  84.    <tr>
  85.        <th width='150'>品牌介绍<font color='red'>*</font></th>
  86.        <td>
  87.         <textarea id='brandDesc' name='brandDesc' class="form-control ipt" style='width:80%;height:400px'></textarea>
  88.        </td>
  89.     </tr>
  90.      <tr>
  91.        <td colspan='2' align='center'>
  92.            <button type="submit" class="btn btn-blue">&nbsp;</button>
  93.            <button type="button" class="btn" onclick="javascript:history.go(-1)">&nbsp;</button>
  94.        </td>
  95.      </tr>
  96. </table>
  97.  </form>
  98.  <script>
  99. $(function(){
  100.   //文件上传
  101.         WST.upload({
  102.           pick:'#filePicker',
  103.           formData: {dir:'brands',mWidth:500,mHeight:250},
  104.           accept: {extensions: 'gif,jpg,jpeg,bmp,png',mimeTypes: 'image/*'},
  105.           callback:function(f){
  106.                   var json = WST.toAdminJson(f);
  107.                   if(json.status==1){
  108.                 $('#preview').html('<img src="'+WST.conf.ROOT+"/"+json.savePath+json.thumb+'" height="200" />');
  109.                 $('#brandImg').val(json.savePath+json.thumb);
  110.                   }
  111.           }
  112.     });
  113.   //编辑器
  114.     KindEditor.ready(function(K) {
  115.                 editor1 = K.create('textarea[name="brandDesc"]', {
  116.                         height:'350px',
  117.                         uploadJson : WST.conf.ROOT+'/admin/brands/editorUpload',
  118.                         allowFileManager : false,
  119.                         allowImageUpload : true,
  120.                         items:[
  121.                                 'source', '|', 'undo', 'redo', '|', 'preview', 'print', 'template', 'code', 'cut', 'copy', 'paste',
  122.                                 'plainpaste', 'wordpaste', '|', 'justifyleft', 'justifycenter', 'justifyright',
  123.                                 'justifyfull', 'insertorderedlist', 'insertunorderedlist', 'indent', 'outdent', 'subscript',
  124.                                 'superscript', 'clearhtml', 'quickformat', 'selectall', '|', 'fullscreen', '/',
  125.                                 'formatblock', 'fontname', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold',
  126.                                 'italic', 'underline', 'strikethrough', 'lineheight', 'removeformat', '|','image','table', 'hr', 'emoticons', 'baidumap', 'pagebreak',
  127.                                 'anchor', 'link', 'unlink', '|', 'about'
  128.                         ],
  129.                         afterBlur: function(){ this.sync(); }
  130.                 });
  131.         });
  132. });
  133. </script>
  134. {/block}
downloadedit.html Source code - Download WSTShop v1.1.0 B2C revenue system Source code
Related Source Codes/Software:
HTML 5 black reactive booth design dream weaving dedecms site template (adaptive) v1.0 - HTML5 black-response design dream dedecms template... 2017-05-06
DolpinPHP v1.0.0 rapid development framework - DophinPHP (Dolphin PHP) is an open source rapid de... 2017-05-06
HTML 5 responsive weave template v1.0 dream relaxed and blog posts - HTML5 response-refreshing blog dream template is a... 2017-05-06
Responsive precision chemical chemical class dreams to template (adaptive equipment) v1.0 - Response precision chemical chemical dream templat... 2017-05-06
HTML 5 high-end dedecms decorate construction company enterprise template - Dedecms latest kernel source code, this source cod... 2017-05-06
Blue air conditioning refrigeration electronic enterprise website dream weaving template v1.0 - Blue air conditioning and refrigeration electronic... 2017-05-06
Dream weaving white large entrepreneurial wealth information class site template v1.0 - Dream white large entrepreneurial wealth of inform... 2017-05-06
bash-guide - A guide to learn bash 2017-06-05
N-blog - Learn the Node together. J 2017-06-05
Become-A-Full-Stack-Web-Developer - Free resources for learning Full Stack Web Develop... 2017-06-05
compromise - Natural language processing in javascript ... 2017-06-05
stack-on-a-budget - A collection of services with great free tiers for... 2017-06-05
packer - Packer is a tool for creating identical machine im... 2017-06-05
pkg - Package your Node.js project into an executable ... 2017-06-05
Dapper - Dapper - a simple object mapper for .Net 2017-06-05
python-fire - Python Fire is a library for automatically generat... 2017-06-04
kaminari - A Scope & Engine based, clean, powerful, custo... 2017-06-04

 Back to top