Browse Source

fix:留资程序publish_id字段只在三级页传

tsz 3 years ago
parent
commit
97e58b252d
1 changed files with 2 additions and 1 deletions
  1. 2 1
      src/web/staticres/js/pc-collect-user-info.js

+ 2 - 1
src/web/staticres/js/pc-collect-user-info.js

@@ -672,6 +672,7 @@ var vm = new Vue({
     // 表单提交请求
     formAjax: function(source, info) {
       var infoid = window.location.pathname.split("/")[3].split(".html")[0]
+      var isProDetail = window.location.pathname.indexOf('/article/content')
       var params = {
         source: source,
         name: this.form.name,
@@ -690,7 +691,7 @@ var vm = new Vue({
         // agree: this.form.agreeChecked,
         branch: this.form.branch.indexOf('总裁') > -1 || this.form.branch.indexOf('总经理') > -1 ?  '' : this.form.branch
       }
-      if (infoid != ""){
+      if (infoid != "" && isProDetail != -1){
         params.publish_id = infoid
       }
       if (info) {