guhongwei 4 years ago
parent
commit
f63b6c4387
1 changed files with 2 additions and 3 deletions
  1. 2 3
      src/views/userCenter/productInfo/index.vue

+ 2 - 3
src/views/userCenter/productInfo/index.vue

@@ -103,8 +103,6 @@ export default {
     },
     // 保存草稿
     async draftBtn({ data }) {
-      data.userid = this.user.uid;
-      data.patent = this.addpatent;
       if (data.id) {
         let res = await this.productUpdate(data);
         if (this.$checkRes(res)) {
@@ -117,7 +115,8 @@ export default {
           this.$message.error('草稿保存失败');
         }
       } else {
-        console.log(data);
+        data.patent = this.addpatent;
+        data.userid = this.user.uid;
         let res = await this.productCreate(data);
         if (this.$checkRes(res)) {
           this.$message({