Browse Source

fix:修改看店Bug

xzh 4 years ago
parent
commit
0e52ab4ec8
34 changed files with 513 additions and 489 deletions
  1. 1 1
      admins/fd-mall-backstage/WEB-INF/page/shop/adminuser.html
  2. 1 1
      admins/fd-mall-backstage/WEB-INF/page/shop/brand.html
  3. 5 5
      admins/fd-mall-backstage/WEB-INF/page/shop/broadcast.html
  4. 405 402
      admins/fd-mall-backstage/js/common.js
  5. 1 1
      admins/fd-mall-backstage/js/shop/adminuser.js
  6. 1 1
      admins/fd-mall-backstage/js/shop/brand.js
  7. 1 1
      admins/fd-mall-backstage/js/shop/broadcast.js
  8. 1 1
      admins/fd-mall-backstage/js/shop/carousel.js
  9. 1 1
      admins/fd-mall-backstage/js/shop/coupon.js
  10. 1 1
      admins/fd-mall-backstage/js/shop/coupondetail.js
  11. 1 1
      admins/fd-mall-backstage/js/shop/goods.js
  12. 1 1
      admins/fd-mall-backstage/js/shop/goodshotspot.js
  13. 1 1
      admins/fd-mall-backstage/js/shop/order.js
  14. 1 1
      admins/fd-mall-backstage/js/sys/schedule_log.js
  15. 1 1
      admins/zl-mall-backstage/js/shop/adminuser.js
  16. 1 1
      admins/zl-mall-backstage/js/shop/brand.js
  17. 1 1
      admins/zl-mall-backstage/js/shop/broadcast.js
  18. 1 1
      admins/zl-mall-backstage/js/shop/carousel.js
  19. 1 1
      admins/zl-mall-backstage/js/shop/coupon.js
  20. 1 1
      admins/zl-mall-backstage/js/shop/coupondetail.js
  21. 1 1
      admins/zl-mall-backstage/js/shop/goods.js
  22. 1 1
      admins/zl-mall-backstage/js/shop/goodshotspot.js
  23. 1 1
      admins/zl-mall-backstage/js/shop/order.js
  24. 1 1
      admins/zl-mall-backstage/js/sys/schedule_log.js
  25. 2 2
      js/shop/adminuser.js
  26. 45 43
      js/shop/brand.js
  27. 16 5
      js/shop/broadcast.js
  28. 3 3
      js/shop/carousel.js
  29. 5 2
      js/shop/coupon.js
  30. 2 1
      js/shop/coupondetail.js
  31. 2 2
      js/shop/goods.js
  32. 2 1
      js/shop/goodshotspot.js
  33. 2 1
      js/shop/order.js
  34. 2 0
      js/sys/schedule_log.js

+ 1 - 1
admins/fd-mall-backstage/WEB-INF/page/shop/adminuser.html

@@ -11,7 +11,7 @@
             <div class="search-group">
                 <i-col span="8">
                     <div style="display: inline-block;">
-                        <i-input v-model="q.username" @on-enter="query" placeholder="请输入微信名称或用户名称"/>
+                        <i-input v-model="q.nickname" @on-enter="query" placeholder="请输入微信名称或用户名称"/>
                     </div>
                     <div style="display: inline-block;">
                         <i-button @click="query">查询</i-button>

+ 1 - 1
admins/fd-mall-backstage/WEB-INF/page/shop/brand.html

@@ -227,7 +227,7 @@
     </Card>
 
     <div id="loginLayer" style="display: none;height: 100%;">
-        <iframe id="loginfdkk" src="https://test.4dkankan.com/mall_login/login.html" style="height: 100%;width:100%" frameborder="0"></iframe>
+        <iframe id="loginfdkk" src="https://www.4dkankan.com/mall_login/login.html" style="height: 100%;width:100%" frameborder="0"></iframe>
     </div>
 </div>
 <script src="https://webapi.amap.com/maps?v=1.4.10&key=e661b00bdf2c44cccf71ef6070ef41b8"></script>

+ 5 - 5
admins/fd-mall-backstage/WEB-INF/page/shop/broadcast.html

@@ -47,7 +47,7 @@
                 <Form-item label="直播类型" prop="title">
                     <div class="c-winput" >
                         <Radio-group v-model="broadcast.type">
-                            <Radio label="1">
+                            <Radio :label="0">
                                 <span>手机直播</span>
                             </Radio>
                         </Radio-group>
@@ -170,10 +170,10 @@
                 <Form-item label="回放">
                     <div class="c-winput">
                         <Radio-group v-model="broadcast.closeReplay">
-                            <Radio label="0">
+                            <Radio :label="0">
                                 <span>是</span>
                             </Radio>
-                            <Radio label="1">
+                            <Radio :label="1">
                                 <span>否</span>
                             </Radio>
                         </Radio-group>
@@ -183,10 +183,10 @@
                 <Form-item label="客服">
                     <div class="c-winput">
                         <Radio-group v-model="broadcast.closeKf">
-                            <Radio label="0">
+                            <Radio :label="0">
                                 <span>是</span>
                             </Radio>
-                            <Radio label="1">
+                            <Radio :label="1">
                                 <span>否</span>
                             </Radio>
                         </Radio-group>

+ 405 - 402
admins/fd-mall-backstage/js/common.js

@@ -1,502 +1,505 @@
 //iframe自适应
 $(window).on('resize', function () {
-  var $content = $('#mainApp');
-  $content.height($(this).height());
-  $content.find('iframe').each(function () {
-      $(this).height($content.height() - 150);
-  });
-  var $rrapp = $('#rrapp').parent();
-  $rrapp.height($(this).height());
-  $(this).height($content.height());
+    var $content = $('#mainApp');
+    $content.height($(this).height());
+    $content.find('iframe').each(function () {
+        $(this).height($content.height() - 150);
+    });
+    var $rrapp = $('#rrapp').parent();
+    $rrapp.height($(this).height());
+    $(this).height($content.height());
 }).resize();
 
 $.ajaxSetup({
-  dataType: "json",
-  cache: false
+    dataType: "json",
+    cache: false
 });
 
+window.commonVue = new Vue()
+
 //重写alert
 window.alert = function (msg, callback) {
-  // parent.layer.alert 弹出在iframe外的页面。
-  layer.alert(msg, function (index) {
-      layer.close(index);
-      if (typeof(callback) === "function") {
-          callback("ok");
-      }
-  });
+    // parent.layer.alert 弹出在iframe外的页面。
+    layer.alert(msg, function (index) {
+        layer.close(index);
+        if (typeof(callback) === "function") {
+            callback("ok");
+        }
+    });
 };
 
 //重写confirm式样框
 window.confirm = function (msg, callback) {
-  //如果没有定义回调函数,直接返回true
-  if (!callback) {
-      return true;
-  }
-  layer.confirm(msg, {
-          skin: 'layui-layer-molv', btn: ['确定', '取消']
-      },
-      function () {//确定事件
-          if (typeof(callback) === "function") {
-              callback("ok");
-          }
-      });
+    //如果没有定义回调函数,直接返回true
+    if (!callback) {
+        return true;
+    }
+    layer.confirm(msg, {
+            skin: 'layui-layer-molv', btn: ['确定', '取消']
+        },
+        function () {//确定事件
+            if (typeof(callback) === "function") {
+                callback("ok");
+            }
+        });
 };
 
 /**
-*
-* @param options
-*/
+ *
+ * @param options
+ */
 window.openWindow = function (options) {
-  let globalParams = {
-      skin: 'layui-layer-molv',//皮肤
-      title: '标题',//标题
-      type: 1,//打开窗口的类型 1:html里的div内容 2:iframe方式,页面的路径
-      closeBtn: 1, //关闭按钮的形状 0、1
-      anim: -1,
-      isOutAnim: false,
-      shadeClose: false,
-      area: ['90%', '95%'],
-      content: '',
-      end:'',
-      btn: false, //按钮
-      top: false //窗口弹出是否在iframe上层
-  };
-  globalParams = $.extend(globalParams, options);
-  if (globalParams.top) {
-      parent.layer.open(globalParams);
-  } else {
-      layer.open(globalParams);
-  }
+    let globalParams = {
+        skin: 'layui-layer-molv',//皮肤
+        title: '标题',//标题
+        type: 1,//打开窗口的类型 1:html里的div内容 2:iframe方式,页面的路径
+        closeBtn: 1, //关闭按钮的形状 0、1
+        anim: -1,
+        isOutAnim: false,
+        shadeClose: false,
+        area: ['90%', '95%'],
+        content: '',
+        end:'',
+        btn: false, //按钮
+        top: false //窗口弹出是否在iframe上层
+    };
+    globalParams = $.extend(globalParams, options);
+    if (globalParams.top) {
+        parent.layer.open(globalParams);
+    } else {
+        layer.open(globalParams);
+    }
 };
 
 window.formClose = function(){
-  var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
-  console.log(index)
-  //layer.msg(index);
-  parent.layer.close(index); //再执行关闭   
+    var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
+    console.log(index)
+    //layer.msg(index);
+    parent.layer.close(index); //再执行关闭   
 }
 
 //获取选中的数据
 function getSelectedRowData(gridId) {
-  var id = getSelectedRow(gridId);
-  return $(gridId).jqGrid('getRowData', id);
+    var id = getSelectedRow(gridId);
+    return $(gridId).jqGrid('getRowData', id);
 }
 
 //选择一条记录
 function getSelectedRow(gridId) {
-  var grid = $(gridId);
-  var rowKey = grid.getGridParam("selrow");
-  if (!rowKey) {
-      // iview.Message.error("请选择一条记录");
-      alert("请选择一条记录");
-      return;
-  }
-
-  var selectedIDs = grid.getGridParam("selarrrow");
-  if (selectedIDs.length > 1) {
-      alert("只能选择一条记录");
-
-      return;
-  }
-
-  return selectedIDs[0];
+    var grid = $(gridId);
+    var rowKey = grid.getGridParam("selrow");
+    if (!rowKey) {
+        // iview.Message.error("请选择一条记录");
+        alert("请选择一条记录");
+        return;
+    }
+
+    var selectedIDs = grid.getGridParam("selarrrow");
+    if (selectedIDs.length > 1) {
+        alert("只能选择一条记录");
+
+        return;
+    }
+
+    return selectedIDs[0];
 };
 
 //选择多条记录
 function getSelectedRows(gridId) {
-  var grid = $(gridId);
-  var rowKey = grid.getGridParam("selrow");
-  if (!rowKey) {
-      alert("请选择一条记录");
-      return;
-  }
-  return grid.getGridParam("selarrrow");
+    var grid = $(gridId);
+    var rowKey = grid.getGridParam("selrow");
+    if (!rowKey) {
+        alert("请选择一条记录");
+        return;
+    }
+    return grid.getGridParam("selarrrow");
 };
 
 /**
-* 预览图片
-* @param url
-*/
+ * 预览图片
+ * @param url
+ */
 function eyeImage(url) {
-  if (!url) {
-      iview.Message.error('请先上传图片');
-      return;
-  }
-  layer.photos({
-      photos: {
-          "title": "预览", //相册标题
-          "start": 0, //初始显示的图片序号,默认0
-          "data": [   //相册包含的图片,数组格式
-              {
-                  "src": url //原图地址
-              }
-          ]
-      }, anim: 5 //0-6的选择,指定弹出图片动画类型,默认随机
-  });
+    if (!url) {
+        iview.Message.error('请先上传图片');
+        return;
+    }
+    layer.photos({
+        photos: {
+            "title": "预览", //相册标题
+            "start": 0, //初始显示的图片序号,默认0
+            "data": [   //相册包含的图片,数组格式
+                {
+                    "src": url //原图地址
+                }
+            ]
+        }, anim: 5 //0-6的选择,指定弹出图片动画类型,默认随机
+    });
 };
 
 /**
-* 预览图片
-* @param data
-*/
+ * 预览图片
+ * @param data
+ */
 function eyeImages(data) {
-  layer.photos({
-      photos: {
-          "title": "预览", //相册标题
-          "start": 0, //初始显示的图片序号,默认0
-          "data": data
-      }, anim: 5 //0-6的选择,指定弹出图片动画类型,默认随机
-  });
+    layer.photos({
+        photos: {
+            "title": "预览", //相册标题
+            "start": 0, //初始显示的图片序号,默认0
+            "data": data
+        }, anim: 5 //0-6的选择,指定弹出图片动画类型,默认随机
+    });
 };
 
 /**
-* 重置验证
-* @param vue vue对象
-* @param name
-*/
+ * 重置验证
+ * @param vue vue对象
+ * @param name
+ */
 function handleResetForm(vue, name) {
-  vue.$refs[name].resetFields();
+    vue.$refs[name].resetFields();
 };
 
 /**
-* 表单验证
-* @param vue vue对象
-* @param name 验证规则
-* @param callback 验证通过回调函数
-*/
+ * 表单验证
+ * @param vue vue对象
+ * @param name 验证规则
+ * @param callback 验证通过回调函数
+ */
 function handleSubmitValidate(vue, name, callback) {
-  vue.$refs[name].validate(function (valid) {
-      if (valid) {
-          callback();
-      } else {
-          iview.Message.error('请填写完整信息!');
-          return false;
-      }
-  })
+    vue.$refs[name].validate(function (valid) {
+        if (valid) {
+            callback();
+        } else {
+            iview.Message.error('请填写完整信息!');
+            return false;
+        }
+    })
 };
 
 /**
-* 翻译日期
-* @param date
-* @param fmt
-* @returns {*}
-*/
+ * 翻译日期
+ * @param date
+ * @param fmt
+ * @returns {*}
+ */
 function transDate(date, fmt) {
-  if (date) {
-      if (typeof date == 'number') {
-          return new Date(date).dateFormat(fmt);
-      } else {
-          try {
-              return new Date(date.replace('-', '/').replace('-', '/')).dateFormat(fmt);
-          } catch (e) {
-              return '-';
-          }
-      }
-  } else {
-      return '-';
-  }
+    if (date) {
+        if (typeof date == 'number') {
+            return new Date(date).dateFormat(fmt);
+        } else {
+            try {
+                return new Date(date.replace('-', '/').replace('-', '/')).dateFormat(fmt);
+            } catch (e) {
+                return '-';
+            }
+        }
+    } else {
+        return '-';
+    }
 };
 
 /**
-* 翻译图片
-* @param url
-* @returns {*}
-*/
+ * 翻译图片
+ * @param url
+ * @returns {*}
+ */
 function transImg(url,width,height) {
 
-  if (url) {
-      return '<img width="'+(width||50)+'px" height="'+(height||50)+'px" src="' + url + '">';
-  } else {
-      return '-';
-  }
+    if (url) {
+        return '<img width="'+(width||50)+'px" height="'+(height||50)+'px" src="' + url + '">';
+    } else {
+        return '-';
+    }
 };
 
 /**
-* 翻译媒体文件
-* @param url
-* @returns {*}
-*/
+ * 翻译媒体文件
+ * @param url
+ * @returns {*}
+ */
 function transMedia(url,width,height) {
-  let video=['mp4','rmvb','rm','avi']
-  let audio=['mp3','wav','flac','ape']
-  let img = ['png','bmp','gif','jpg','jpeg']
-
-  if (url) {
-      let hz = url.split('.').pop().toLowerCase();
-      let type = '-'
-      console.log(hz)
-
-      video.forEach(function (v){
-          if (v===hz.toLowerCase()) {
-              type='<img width="60px" height="60px" src="http://4d-tjw.oss-cn-shenzhen.aliyuncs.com/wxmall/images/video-logo.png">'
-          }
-      })
-
-      audio.forEach(function (a){
-          if (a===hz.toLowerCase()) {
-              type='<span>'+url+'</span>'
-          }
-      })
-
-      img.forEach(function (i){
-          if (i===hz.toLowerCase()) {
-              type='<img width="'+(width||50)+'px" height="'+(height||50)+'px" src="' + url + '">';
-          }
-      })
-
-      return type;
-  } else {
-      return '-';
-  }
+    let video=['mp4','rmvb','rm','avi']
+    let audio=['mp3','wav','flac','ape']
+    let img = ['png','bmp','gif','jpg','jpeg']
+
+    if (url) {
+        let hz = url.split('.').pop().toLowerCase();
+        let type = '-'
+        console.log(hz)
+
+        video.forEach(function (v){
+            if (v===hz.toLowerCase()) {
+                type='<img width="60px" height="60px" src="http://4d-tjw.oss-cn-shenzhen.aliyuncs.com/wxmall/images/video-logo.png">'
+            }
+        })
+
+        audio.forEach(function (a){
+            if (a===hz.toLowerCase()) {
+                type='<span>'+url+'</span>'
+            }
+        })
+
+        img.forEach(function (i){
+            if (i===hz.toLowerCase()) {
+                type='<img width="'+(width||50)+'px" height="'+(height||50)+'px" src="' + url + '">';
+            }
+        })
+
+        return type;
+    } else {
+        return '-';
+    }
 };
 
 
 /**
-* 翻译性别
-* @param gender
-* @returns {*}
-*/
+ * 翻译性别
+ * @param gender
+ * @returns {*}
+ */
 function transGender(gender) {
-  if (gender == 1) {
-      return '男';
-  }
-  if (gender == 2) {
-      return '女';
-  }
-  return '未知';
+    if (gender == 1) {
+        return '男';
+    }
+    if (gender == 2) {
+        return '女';
+    }
+    return '未知';
 };
 
 function transIsNot(value) {
-  if (value == 1) {
-      return '<span class="label label-success">是</span>';
-  }
-  return '<span class="label label-danger">否</span>';
+    if (value == 1) {
+        return '<span class="label label-success">是</span>';
+    }
+    return '<span class="label label-danger">否</span>';
 };
 
 function transStatus(value) {
-  if (value == 1) {
-      return '<span class="label label-success">有效</span>';
-  }
-  return '<span class="label label-danger">无效</span>';
+    if (value == 1) {
+        return '<span class="label label-success">有效</span>';
+    }
+    return '<span class="label label-danger">无效</span>';
 };
 
 function toUrl(href) {
-  window.location.href = href;
+    window.location.href = href;
 }
 
 function dialogLoading(flag) {
-  if (flag) {
-      top.layer.load(0, {
-          shade: [0.5, '#fff'],
-          time: 5000,
-          content: '处理中...'
-      });
-  } else {
-      top.layer.closeAll('loading');
-  }
+    if (flag) {
+        top.layer.load(0, {
+            shade: [0.5, '#fff'],
+            time: 5000,
+            content: '处理中...'
+        });
+    } else {
+        top.layer.closeAll('loading');
+    }
 }
 
 /**
-* 用JS获取地址栏参数的方法
-* 使用示例 location.href = http://localhost:8080/index.html?id=123
-*          getQueryString('id') --> 123;
-* @param name
-* @returns {null}
-* @constructor
-*/
+ * 用JS获取地址栏参数的方法
+ * 使用示例 location.href = http://localhost:8080/index.html?id=123
+ *          getQueryString('id') --> 123;
+ * @param name
+ * @returns {null}
+ * @constructor
+ */
 function getQueryString(name) {
-  var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
-  var r = window.location.search.substr(1).match(reg);
-  if (r != null) {
-      return unescape(r[2]);
-  }
-  return null;
+    var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
+    var r = window.location.search.substr(1).match(reg);
+    if (r != null) return decodeURI(r[2]); return null;
 }
 
 /**
-* 主要功能:导出功能公共方法
-*
-* @param formId 表单ID,带'#'号,如'#formId'
-* @param url 请求后台地址
-* @param extraObj 往后台请求额外参数,对象格式,如:{'aaa': 111}
-*/
+ * 主要功能:导出功能公共方法
+ *
+ * @param formId 表单ID,带'#'号,如'#formId'
+ * @param url 请求后台地址
+ * @param extraObj 往后台请求额外参数,对象格式,如:{'aaa': 111}
+ */
 function exportFile(formId, url, extraObj) {
-  var form = $('<form>'); //定义一个form表单
-  form.attr('style', 'display: none');
-  form.attr('target', '');
-  form.attr('method', 'post');
-  form.attr('action', url);
-
-  var json = getJson(formId);
-  if (typeof extraObj != 'undefined') {
-      json = $.extend(json, extraObj);
-  }
-
-  $('body').append(form);//将表单放置在web中
-  for (var i in json) {
-      var input = $('<input>');
-      input.attr('type', 'hidden');
-      input.attr('name', i);
-      input.attr('value', json[i]);
-      form.append(input);
-  }
-
-  form.submit();//表单提交
+    var form = $('<form>'); //定义一个form表单
+    form.attr('style', 'display: none');
+    form.attr('target', '');
+    form.attr('method', 'post');
+    form.attr('action', url);
+
+    var json = getJson(formId);
+    if (typeof extraObj != 'undefined') {
+        json = $.extend(json, extraObj);
+    }
+
+    $('body').append(form);//将表单放置在web中
+    for (var i in json) {
+        var input = $('<input>');
+        input.attr('type', 'hidden');
+        input.attr('name', i);
+        input.attr('value', json[i]);
+        form.append(input);
+    }
+
+    form.submit();//表单提交
 }
 
 /**
-* 将form转化为json
-* @param form 传入 form表单的dom $("#baseFm")
-* @returns {___anonymous49_50}  序列化的键值对 {key:value,key2:value2,....}
-*/
+ * 将form转化为json
+ * @param form 传入 form表单的dom $("#baseFm")
+ * @returns {___anonymous49_50}  序列化的键值对 {key:value,key2:value2,....}
+ */
 function getJson(form) {
-  var o = {};
-  var $form = $(form).find('input,textarea,select');
-  $.each($form, function (i, item) {
-      var $this = $(item);
-
-      if ($this.attr("type") == 'radio') {
-          o[$this.attr("name")] = $("input[name='" + $this.attr("name") + "']:checked").val();
-          return true;
-      }
-      o[$this.attr("name")] = $this.val();
-  })
-  return o;
+    var o = {};
+    var $form = $(form).find('input,textarea,select');
+    $.each($form, function (i, item) {
+        var $this = $(item);
+
+        if ($this.attr("type") == 'radio') {
+            o[$this.attr("name")] = $("input[name='" + $this.attr("name") + "']:checked").val();
+            return true;
+        }
+        o[$this.attr("name")] = $this.val();
+    })
+    return o;
 }
 
 /**
-*
-Ajax.request({
-      url: '', //访问路径
-      dataType: 'json', //访问类型 'json','html'等
-      params: getJson(form),
-      resultMsg: true, false, //是否需要提示信息
-      type: 'GET',//,'get','post'
-      beforeSubmit: function (data) {},//提交前处理
-      successCallback: function (data) {} //提交后处理
-  });
-*/
+ *
+ Ajax.request({
+        url: '', //访问路径
+        dataType: 'json', //访问类型 'json','html'等
+        params: getJson(form),
+        resultMsg: true, false, //是否需要提示信息
+        type: 'GET',//,'get','post'
+        beforeSubmit: function (data) {},//提交前处理
+        successCallback: function (data) {} //提交后处理
+    });
+ */
 Ajax = function () {
 
-  //var opt = { type:'GET',dataType:'json',resultMsg:true };
-  function request(opt) {
-
-      //添加遮罩层
-      dialogLoading(true);
-
-      if (typeof opt.cache == 'undefined') {
-          opt.cache = false;
-      }
-
-      if (typeof opt == 'undefined') {
-          return;
-      }
-      //opt = $.extend(opt, p);
-      if (typeof(opt.type) == 'undefined') {
-          opt.type = 'GET'
-      }
-      if (typeof(opt.async) == 'undefined') {
-          opt.async = false;
-      }
-      if (typeof(opt.dataType) == 'undefined') {
-          opt.dataType = 'json'
-      }
-      if (typeof(opt.contentType) == 'undefined') {
-          opt.contentType = 'application/x-www-form-urlencoded;chartset=UTF-8'
-      }
-      if (typeof(opt.params) == 'undefined' || opt.params == null) {
-          opt.params = {};
-      }
-      opt.params.date = new Date();
-      if (typeof(opt.beforeSubmit) != 'undefined') {
-          var flag = opt.beforeSubmit(opt);
-          if (!flag) {
-              return;
-          }
-      }
-
-      if (typeof(opt.resultMsg) == 'undefined') {
-          opt.resultMsg = true;
-      }
-
-      $.ajax({
-          async: opt.async,
-          url: opt.url,
-          dataType: opt.dataType,
-          contentType: opt.contentType,
-          data: opt.params,
-          crossDomain: opt.crossDomain || false,
-          type: opt.type,
-          cache: opt.cache,
-          success: function (data) {
-              //关闭遮罩
-              dialogLoading(false);
-
-              if (typeof data == 'string' && data.indexOf("exception") > 0 || typeof data.code != 'undefined' && data.code != '0') {
-                  var result = {code: null};
-                  if (typeof data == 'string') {
-                      result = eval('(' + data + ')')
-                  } else if (typeof data == 'object') {
-                      result = data;
-                  }
-
-                  if (opt.resultMsg && result.msg) {
-                      layer.alert(result.msg, {icon: 5});
-                  }
-                  return;
-              }
-              if (opt.resultMsg && data.msg) {
-                  layer.alert(data.msg, {icon: 6}, function () {
-                      if (typeof(opt.successCallback) != 'undefined') {
-                          opt.successCallback(data);
-                      }
-                  });
-                  return;
-              }
-
-              if (typeof(opt.successCallback) != 'undefined') {
-                  opt.successCallback(data);
-              }
-          },
-          error: function (data) {
-              //关闭遮罩
-              dialogLoading(false);
-              layer.alert(data.msg, {icon: 5});
-          }
-      });
-  }
-
-  return {
-      /**
-       * Ajax调用request
-       */
-      request: request
-  };
+    //var opt = { type:'GET',dataType:'json',resultMsg:true };
+    function request(opt) {
+
+        //添加遮罩层
+        dialogLoading(true);
+
+        if (typeof opt.cache == 'undefined') {
+            opt.cache = false;
+        }
+
+        if (typeof opt == 'undefined') {
+            return;
+        }
+        //opt = $.extend(opt, p);
+        if (typeof(opt.type) == 'undefined') {
+            opt.type = 'GET'
+        }
+        if (typeof(opt.async) == 'undefined') {
+            opt.async = false;
+        }
+        if (typeof(opt.dataType) == 'undefined') {
+            opt.dataType = 'json'
+        }
+        if (typeof(opt.contentType) == 'undefined') {
+            opt.contentType = 'application/x-www-form-urlencoded;chartset=UTF-8'
+        }
+        if (typeof(opt.params) == 'undefined' || opt.params == null) {
+            opt.params = {};
+        }
+        opt.params.date = new Date();
+        if (typeof(opt.beforeSubmit) != 'undefined') {
+            var flag = opt.beforeSubmit(opt);
+            if (!flag) {
+                return;
+            }
+        }
+
+        if (typeof(opt.resultMsg) == 'undefined') {
+            opt.resultMsg = true;
+        }
+
+        $.ajax({
+            async: opt.async,
+            url: opt.url,
+            dataType: opt.dataType,
+            contentType: opt.contentType,
+            data: opt.params,
+            crossDomain: opt.crossDomain || false,
+            type: opt.type,
+            cache: opt.cache,
+            success: function (data) {
+                //关闭遮罩
+                dialogLoading(false);
+
+                if(data.code === 500){
+                    layer.alert(data.msg, {icon: 5});
+                    return;
+                }
+                if (typeof data == 'string' && data.indexOf("exception") > 0 || typeof data.code != 'undefined' && data.code != '0') {
+                    var result = {code: null};
+                    if (typeof data == 'string') {
+                        result = eval('(' + data + ')')
+                    } else if (typeof data == 'object') {
+                        result = data;
+                    }
+
+                    if (opt.resultMsg && result.msg) {
+                        layer.alert(result.msg, {icon: 5});
+                    }
+                    return;
+                }
+                if (opt.resultMsg && data.msg) {
+                    layer.alert(data.msg, {icon: 6}, function () {
+                        if (typeof(opt.successCallback) != 'undefined') {
+                            opt.successCallback(data);
+                        }
+                    });
+                    return;
+                }
+
+                if (typeof(opt.successCallback) != 'undefined') {
+                    opt.successCallback(data);
+                }
+            },
+            error: function (data) {
+                //关闭遮罩
+                dialogLoading(false);
+                layer.alert(data.msg, {icon: 5});
+            }
+        });
+    }
+
+    return {
+        /**
+         * Ajax调用request
+         */
+        request: request
+    };
 }();
 
 /**
-* 缓存字典数据
-* 使用方法:字典 调用方式为在table的列或者columns 的列中 formatter:function(value){ return Dict.getDictValue(groupCode,value);}
-* 其中value为类型code  返回值为类型名称
-*/
+ * 缓存字典数据
+ * 使用方法:字典 调用方式为在table的列或者columns 的列中 formatter:function(value){ return Dict.getDictValue(groupCode,value);}
+ * 其中value为类型code  返回值为类型名称
+ */
 Dict = function () {
-  return {
-      getDictValue: function (groupCode, dictKey) {
-          var dictValue = '-';
-          Ajax.request({
-              url: '/sys/dict/getDictValue',
-              dataType: 'json',
-              params: {
-                  groupCode: groupCode, dictKey: dictKey
-              },
-              cache: true,
-              async: false,
-              type: 'GET',
-              successCallback: function (data) {
-                  dictValue = data.dictValue;
-              }
-          });
-          return dictValue;
-      }
-  };
+    return {
+        getDictValue: function (groupCode, dictKey) {
+            var dictValue = '-';
+            Ajax.request({
+                url: '/sys/dict/getDictValue',
+                dataType: 'json',
+                params: {
+                    groupCode: groupCode, dictKey: dictKey
+                },
+                cache: true,
+                async: false,
+                type: 'GET',
+                successCallback: function (data) {
+                    dictValue = data.dictValue;
+                }
+            });
+            return dictValue;
+        }
+    };
 }();

File diff suppressed because it is too large
+ 1 - 1
admins/fd-mall-backstage/js/shop/adminuser.js


File diff suppressed because it is too large
+ 1 - 1
admins/fd-mall-backstage/js/shop/brand.js


File diff suppressed because it is too large
+ 1 - 1
admins/fd-mall-backstage/js/shop/broadcast.js


File diff suppressed because it is too large
+ 1 - 1
admins/fd-mall-backstage/js/shop/carousel.js


File diff suppressed because it is too large
+ 1 - 1
admins/fd-mall-backstage/js/shop/coupon.js


File diff suppressed because it is too large
+ 1 - 1
admins/fd-mall-backstage/js/shop/coupondetail.js


File diff suppressed because it is too large
+ 1 - 1
admins/fd-mall-backstage/js/shop/goods.js


File diff suppressed because it is too large
+ 1 - 1
admins/fd-mall-backstage/js/shop/goodshotspot.js


File diff suppressed because it is too large
+ 1 - 1
admins/fd-mall-backstage/js/shop/order.js


File diff suppressed because it is too large
+ 1 - 1
admins/fd-mall-backstage/js/sys/schedule_log.js


File diff suppressed because it is too large
+ 1 - 1
admins/zl-mall-backstage/js/shop/adminuser.js


File diff suppressed because it is too large
+ 1 - 1
admins/zl-mall-backstage/js/shop/brand.js


File diff suppressed because it is too large
+ 1 - 1
admins/zl-mall-backstage/js/shop/broadcast.js


File diff suppressed because it is too large
+ 1 - 1
admins/zl-mall-backstage/js/shop/carousel.js


File diff suppressed because it is too large
+ 1 - 1
admins/zl-mall-backstage/js/shop/coupon.js


File diff suppressed because it is too large
+ 1 - 1
admins/zl-mall-backstage/js/shop/coupondetail.js


File diff suppressed because it is too large
+ 1 - 1
admins/zl-mall-backstage/js/shop/goods.js


File diff suppressed because it is too large
+ 1 - 1
admins/zl-mall-backstage/js/shop/goodshotspot.js


File diff suppressed because it is too large
+ 1 - 1
admins/zl-mall-backstage/js/shop/order.js


File diff suppressed because it is too large
+ 1 - 1
admins/zl-mall-backstage/js/sys/schedule_log.js


+ 2 - 2
js/shop/adminuser.js

@@ -7,7 +7,7 @@ $(function () {
             {label: '会员名称', name: 'nickname', index: "nickname", key: true},
             {label: '微信名称', name: 'username', index: 'username', width: 75},
             {label: '手机号', name: 'mobile', index: 'mobile', width: 100},
-            {label: '已绑定的店铺', name: 'brandName',index: 'brand_name', width: 100,sortable:false}]
+            {label: '已绑定的店铺', name: 'bindBrandName',index: 'brand_name', width: 100,sortable:false}]
     });
 });
 
@@ -252,7 +252,7 @@ var vm = new Vue({
             vm.showList = true;
             var page = $("#jqGrid").jqGrid('getGridParam', 'page');
             $("#jqGrid").jqGrid('setGridParam', {
-                postData: {'username': vm.q.username},
+                postData: {'nickname': vm.q.nickname},
                 page: page
             }).trigger("reloadGrid");
             vm.handleReset('formValidate');

+ 45 - 43
js/shop/brand.js

@@ -1,9 +1,9 @@
 $(function () {
     var types = {
      0:'服饰',
-     1:'家',
+     1:'家',
      2:'数码',
-     3:'娱乐',
+     3:'美妆',
      4:'其他',
     }
      
@@ -4946,41 +4946,7 @@ $(function () {
             this.map.setFitView(this.marker);
         },
         areapath(newVal){
-            let getArr = (arr)=>{
-                let idArr = ['', '', '']
-                let address = ''
-                if (arr) {
-                    let tempArr = arr.split(' ')[0].split(',')
-                    address = arr.split(' ')[1]
-                    let [p, c, d] = tempArr
-                    idArr = (() => {
-                        let tmp = []
-                        citylist.forEach((item, index) => {
-                        if (item.p === p) {
-                            tmp.push(index)
-                            item.c.forEach((t2, i2) => {
-                            if (t2.n === c) {
-                                tmp.push(i2)
-                                t2.a.forEach((t3, i3) => {
-                                if (t3.s === d) {
-                                    tmp.push(i3)
-                                }
-                                })
-                            }
-                            })
-                        }
-                        })
-                        return tmp || ['', '', '']
-                    })()
-                }
-                return {idArr,address}
-            }
-            let idArr = getArr(newVal).idArr
-            let address = getArr(newVal).address
-            this.currentPID=idArr[0] !== '' ? idArr[0] : 18
-            this.currentCID= idArr[1] !== '' ? idArr[1] : 3
-            this.currentSID= idArr[2] !== '' ? idArr[2] : 2
-            this.address = address
+          this.handleAreaPathChange(newVal)
         }
     },
     methods: {
@@ -5007,14 +4973,51 @@ $(function () {
                     let city = prov.c[this.currentCID]
                     let dist = city.a[this.currentSID]
                     this.currentVal = [
-                        prov.p, city.n, dist.s
-                      ]
+                      prov.p, city.n, dist.s
+                    ]
                 });
+        },
+        handleAreaPathChange (newVal) {
+          let getArr = (arr)=>{
+            let idArr = ['', '', '']
+            let address = ''
+            if (arr) {
+                let tempArr = arr.split(' ')[0].split(',')
+                address = arr.split(' ')[1]
+                let [p, c, d] = tempArr
+                idArr = (() => {
+                    let tmp = []
+                    citylist.forEach((item, index) => {
+                    if (item.p === p) {
+                        tmp.push(index)
+                        item.c.forEach((t2, i2) => {
+                        if (t2.n === c) {
+                            tmp.push(i2)
+                            t2.a.forEach((t3, i3) => {
+                            if (t3.s === d) {
+                                tmp.push(i3)
+                            }
+                            })
+                        }
+                        })
+                    }
+                    })
+                    return tmp || ['', '', '']
+                })()
+            }
+            return {idArr,address}
+        }
+        let idArr = getArr(newVal).idArr
+        let address = getArr(newVal).address
+        this.currentPID=idArr[0] !== '' ? idArr[0] : 18
+        this.currentCID= idArr[1] !== '' ? idArr[1] : 3
+        this.currentSID= idArr[2] !== '' ? idArr[2] : 2
+        this.address = address
         }
     },
     mounted () {
         this.handleChange()
-       
+       this.handleAreaPathChange(this.areapath)
         this.map = new AMap.Map("container", {
             resizeEnable: true,
             zoom:12,
@@ -5088,7 +5091,7 @@ $(function () {
              },
              {
                  id:1,
-                 name:'家'
+                 name:'家'
              },
              {
                  id:2,
@@ -5096,7 +5099,7 @@ $(function () {
              },
              {
                  id:3,
-                 name:'娱乐'
+                 name:'美妆'
              },
              {
                 id:4,
@@ -5244,7 +5247,6 @@ $(function () {
              this.loading = false
               file.url = res.url;
               file.name =  res.url;
-              console.log(this.$refs.upload.fileList)
               this.brand.picList = this.$refs.upload.fileList
         },
         handleSuccessVideoUrl:function (res, file) {

+ 16 - 5
js/shop/broadcast.js

@@ -1,11 +1,20 @@
 let cacheData = {
 }
+let broadcastMap = {
+    101: '直播中',
+    102: '未开始',
+    103: '已结束',
+    104: '禁播',
+    105: '暂停',
+    106: '异常',
+    107: '已过期'
+}
 $(function () {
     var types = {
      0:'服饰',
-     1:'家具',
+     1:'家',
      2:'数码',
-     3:'娱乐',
+     3:'美妆',
      4:'其他',
     }
      
@@ -39,7 +48,9 @@ $(function () {
             label: '主播', name: 'anchorName', index: 'anchorName', width: 80
         },
         {
-            label: '直播状态', name: 'liveStatus', index: 'liveStatus', width: 80
+            label: '直播状态', name: 'liveStatus', index: 'liveStatus', width: 80, formatter (value) {
+                return broadcastMap[value] || value
+            }
         }
      ]
      });
@@ -73,7 +84,7 @@ $(function () {
         loading:false,
          showList: true,
          title: null,
-         broadcast: {name: '',coverImg:'',startTime:'',endTime:'',anchorName:'',anchorWechat:'', shareImg: '',feedsImg: '',screenType:0,isFeedsPublic: 0,type: 1,closeLike:0, closeGoods: 0,closeKf:0, closeComment: 0,closeReplay: 0,closeShare: 0},
+         broadcast: {name: '',coverImg:'',startTime:'',endTime:'',anchorName:'',anchorWechat:'', shareImg: '',feedsImg: '',screenType:0,isFeedsPublic: 0,type: 0,closeLike:1, closeGoods: 1,closeKf:0, closeComment: 1,closeReplay: 0,closeShare: 1},
          func:['closeComment','closeGoods'],
          ruleValidate: {
             name: [
@@ -122,7 +133,7 @@ $(function () {
          add: function () {
              vm.showList = false;
              vm.title = "新增";
-             vm.broadcast =   {name: '',coverImg:'',startTime:'',endTime:'',anchorName:'',anchorWechat:'', shareImg: '',feedsImg: '',screenType:0,isFeedsPublic: 0,type: 1,closeLike:0, closeGoods: 0,closeKf:0, closeComment: 0,closeReplay: 0,closeShare: 0}
+             vm.broadcast =   {name: '',coverImg:'',startTime:'',endTime:'',anchorName:'',anchorWechat:'', shareImg: '',feedsImg: '',screenType:0,isFeedsPublic: 0,type: 0,closeLike:1, closeGoods: 1,closeKf:0, closeComment: 1,closeReplay: 0,closeShare: 1}
          },
          share: function (event) {
              eyeImage('https://res.wx.qq.com/op_res/BbVNeczA1XudfjVqCVoKgfuWe7e3aUhokktRVOqf_F0IqS6kYR--atCpVNUUC3zr');

+ 3 - 3
js/shop/carousel.js

@@ -16,9 +16,9 @@ function request (url, data) {
 $(function () {
     var types = {
      0:'服饰',
-     1:'家',
+     1:'家',
      2:'数码',
-     3:'娱乐',
+     3:'美妆',
      4:'其他',
     }
      
@@ -61,7 +61,7 @@ $(function () {
         }, 
         {
             label: '更新时间', name: 'updateTime', index: 'update_time', width: 80, formatter: function (value) {
-                return transDate(value, 'yyyy-MM-dd');
+                return value
             }
         },
          {

+ 5 - 2
js/shop/coupon.js

@@ -79,8 +79,9 @@ $(function () {
             }]
     });
 });
+var vm = ''
 
-var vm = new Vue({
+vm = new Vue({
     el: '#rrapp',
     data(){
         const validateBrandIdCheck =function (rule, value, callback)  {
@@ -412,4 +413,6 @@ var vm = new Vue({
     mounted:function() {
         this.getBrands()
     }
-});
+});
+
+window.vm = vm

+ 2 - 1
js/shop/coupondetail.js

@@ -181,4 +181,5 @@ var vm = new Vue({
             }).trigger("reloadGrid");
         }
     }
-});
+});
+window.vm = vm

+ 2 - 2
js/shop/goods.js

@@ -487,8 +487,8 @@ var vm = new Vue({
                 isLimited: 0,
                 isHot: 0,
                 goodsNumber:1,
-                retailPrice:1,
-                marketPrice:1,
+                retailPrice: '',
+                marketPrice: '',
                 categoryName: ''
             };
             $('#goodsDesc').editable('setHTML', '');

+ 2 - 1
js/shop/goodshotspot.js

@@ -429,4 +429,5 @@ var vm = new Vue({
     mounted:function() {
         this.uploadList = this.$refs.upload.fileList;
     }
-});
+});
+window.vm = vm

+ 2 - 1
js/shop/order.js

@@ -295,4 +295,5 @@ let vm = new Vue({
             }
         });
     }
-});
+});
+window.vm = vm

+ 2 - 0
js/sys/schedule_log.js

@@ -71,4 +71,6 @@ var vm = new Vue({
         }
     }
 });
+window.vm = vm
+