Browse Source

Merge remote-tracking branch 'origin/mergeBranch' into mergeBranch

qymljy 3 years ago
parent
commit
4a23a95db5

+ 2 - 2
src/App.vue

@@ -24,7 +24,7 @@
     watch: {
       $route(val) {
         this.system = JSON.parse(sessionStorage.getItem('module_info'))
-        this.system.forEach(sys => {
+        this.system?this.system.forEach(sys => {
           sys.modules.forEach(md=>{
             md.apps.forEach(app=>{
               if (val.name == app.name) {
@@ -34,7 +34,7 @@
               }
             })
           })
-        });
+        }):"";
       }
     }
   }

+ 1 - 1
src/Form/QuotedPrice/add.vue

@@ -46,7 +46,7 @@
 </template>
 
 <script>
-import projec_quotation_add from '@/SDrpManagement/QuotedPrice/modules/ProjectQuotationAdd'
+import projec_quotation_add from '@/SDrpManagement/QuotedPrice/modules/ProjectQuotationAdd.vue'
 export default {
   name: "add",
   data(){

+ 0 - 1
src/Form/contractManage/add.vue

@@ -39,7 +39,6 @@
 
 <script>
 import {mapGetters} from 'vuex'
-import { log } from '@antv/g2plot/lib/utils'
 
 export default {
   components:{

+ 10 - 10
src/HDrpManagement/contractManage/components/addContract.vue

@@ -191,7 +191,7 @@
                   trigger="manual"
                   v-model="accountVisible"
                   width="500">
-                  <selectAgent type="7" ref="member" typemx="直销项目协议" :param="agentListPrams" :radio="true" @onSelect="accountChange" @onCancel="accountVisible = false"></selectAgent>
+                  <selectAgent type="6" ref="member" typemx="直销项目协议" :param="agentListPrams" :radio="true" @onSelect="accountChange" @onCancel="accountVisible = false"></selectAgent>
                   <el-input readonly type="text" slot="reference" size="small" @focus="showChange('accountVisible')" v-model="form.enterprisename"></el-input>
                 </el-popover>
               </el-form-item>
@@ -306,14 +306,14 @@
                   v-model="accountVisible"
                   width="600">
 <!--                  <selectAgent type="2" ref="member" typemx="工具使用(借用)协议" :param="agentListPrams" :radio="true" @onSelect="accountChange" @onCancel="accountVisible = false"></selectAgent>-->
-                  <el-tabs v-model="activeName"  type="border-card" @tab-click="tabClick">
-                    <el-tab-pane label="客户" name="客户">
-                      <selectAgent ref="member" type="7" typemx="工具使用(借用)协议" :param="agentListPrams" :radio="true" @onSelect="accountChange" @onCancel="accountVisible = false"></selectAgent>
+                  <!-- <el-tabs v-model="activeName" @tab-click="tabClick">
+                    <el-tab-pane label="企业" name="企业">
                     </el-tab-pane>
                     <el-tab-pane label="经销商" name="经销商">
                       <selectAgent ref="member" type="5" typemx="工具使用(借用)协议" :param="agentListPrams" :radio="true" @onSelect="accountChange" @onCancel="accountVisible = false"></selectAgent>
                     </el-tab-pane>
-                  </el-tabs>
+                  </el-tabs> -->
+                  <selectAgent ref="member" type="10" typemx="工具使用(借用)协议" :param="agentListPrams" :radio="true" @onSelect="accountChange" @onCancel="accountVisible = false"></selectAgent>
                   <el-input readonly type="text" slot="reference" size="small" @focus="showChange('accountVisible')" v-model="form.enterprisename"></el-input>
                 </el-popover>
               </el-form-item>
@@ -464,7 +464,7 @@
 <script>
 import {mapGetters} from 'vuex'
 import selectPople from './selectSaler'
-import selectAgent from './selectAgent'
+import selectAgent from './selectAgent.vue'
 import seleteProject from './seleteProject'
 import seleteProjectContract from './seleteProjectContract'
 import TimeSelect from './TimeSelect'
@@ -501,7 +501,7 @@ export default {
       }
     }
     return {
-      activeName: '客户',
+      activeName: '企业',
       agentVisible:false,
       salerVisible:false,
       projectVisible:false,
@@ -613,9 +613,9 @@ export default {
           "pageNumber": 1,
           "pageSize": 20,
           "where": {
-              "condition": "",
-              "type":'',
-              "typemx":"",
+            "condition": "",
+            "type":5,
+            "typemx":"",
           }
         }
       },

+ 21 - 2
src/HDrpManagement/orderManage/details/tabs/productlist.vue

@@ -6,6 +6,7 @@
         <el-button style="margin:0 0 10px 10px" size="small" type="primary" :disabled="data.status !== '新建'" v-if="type !== 'confirmdate'" @click="drawer = true">{{setcol === 24?'添 加':'取 消'}}</el-button>
         <excel style="margin:0 0 10px 10px" :tablecols="columnTitle" :param="param" :total="total" :excelTitle="excelTitle"></excel>
       </div>
+      <p class="normal-margin" style="font-size: 13px !important;color:red;font-weight: normal">{{data.amount > freefreightamount?'当前订单免运费':`订单满${tool.formatAmount(freefreightamount,2)}元免运费,当前还差${tool.formatAmount(freefreightamount - data.amount,2)}元`}}</p>
       <el-table
         ref="multipleTable"
         :data="tableData"
@@ -349,6 +350,7 @@ export default {
   },
   data () {
     return {
+      freefreightamount:null,
       drawer:false,
       dataRefresh:true,
       setcol:24,
@@ -396,6 +398,7 @@ export default {
           this.$refs.multipleTable.doLayout()
         });
       }, 300);
+      this.queryBasicInfo()
     },
     handleSizeChange(val) {
       // console.log(`每页 ${val} 条`);
@@ -464,8 +467,16 @@ export default {
         "id": 20221109093602,
         "content": val
       })
-      this.$emit('onSuccess')
-      this.listData()
+       if (res.code == 1) {
+        this.$emit('onSuccess')
+        this.listData()
+      } else {
+        this.$message({
+          message:res.data + ':' + res.msg,
+          type:'error'
+        })
+      }
+     
     },
     async dateChangeNeed(val){
       const res = await this.$api.requested({
@@ -554,6 +565,14 @@ export default {
 
       })
       this.stockOptions = res.data
+    },
+    async queryBasicInfo () {
+      const res = await this.$api.requested({
+        "id":20220920084001,"content":{
+          sys_enterpriseid:this.data.sys_enterpriseid
+        },
+      })
+      this.freefreightamount = res.data.freefreightamount?res.data.freefreightamount:0
     }
   },
   mounted () {

+ 2 - 4
src/HDrpManagement/orderManage/modules/edit.vue

@@ -13,7 +13,7 @@
         <p><span style="font-size:14px">订单合计:</span><span style="color:red;font-size:16px;"><b>¥&nbsp;{{tool.formatAmount(data.defaultamount,2)}}</b></span></p>
       </div>
         <div class="flex-align-center">
-        <p v-if="freefreightamount" style="font-size: 13px !important;color: #8888;font-weight: normal">{{data.amount > freefreightamount?'当前订单免运费':`订单满${tool.formatAmount(freefreightamount,2)}元免运费,当前还差${tool.formatAmount(freefreightamount - data.amount,2)}元`}}</p>
+        <p v-if="freefreightamount" style="font-size: 13px !important;color: #8888;font-weight: normal">{{data.amount >= freefreightamount?'当前订单免运费':`订单满${tool.formatAmount(freefreightamount,2)}元免运费,当前还差${tool.formatAmount(freefreightamount - data.amount,2)}元`}}</p>
       </div>
     </div>
     <div class="drawer__panel">
@@ -213,7 +213,7 @@
         <el-input size="mini" class="order__note__input" type="textarea" v-model="data.projectnote" :autosize="{minRows:5}" placeholder="请输入项目备注"></el-input>
       </div>
       <div class="mt-10">
-        <p class="normal-title inline-16">寄付方式</p>
+        <p class="normal-title inline-16">运费方式</p>
       </div>
       <div class="mt-10 flex-align-center">
         <div :style="defaultData.freightstatus === '到付'?{background:'#d9ecff'}:{background:'#fff'}" class="reveive__panel normal-margin inline-16" @click="defaultData.freightstatus = '到付'">
@@ -333,8 +333,6 @@ export default {
         },
       })
       this.freefreightamount = res.data.freefreightamount
-      console.log(res.data);
-      
     },
     async rebateUsedChange(){
       console.log(this.data)

+ 3 - 1
src/HManagement/accountManage/modules/teamInformation/add.vue

@@ -86,6 +86,7 @@
 
 <script>
 export default {
+  props:['data'],
   name: "add",
   data(){
     return {
@@ -127,7 +128,8 @@ export default {
         "id":"20230302174301",
         "content":{
           "editable":1,
-          "userid":row.userid
+          "userid":row.userid,
+          "leaderuserid":this.$route.query.id
         }
       })
       this.tool.showMessage(res,()=>{

+ 3 - 1
src/HManagement/accountManage/modules/teamInformation/index.vue

@@ -111,6 +111,7 @@ export default {
   methods:{
     /*我负责的*/
     async leaderData(){
+      this.leader.params.content.leaderuserid = this.$route.query.id
       const res = await this.$api.requested(this.leader.params)
       this.leader.list = res.data
     },
@@ -172,7 +173,8 @@ export default {
       const res = await this.$api.requested({
         "id":"20230302174401",
         "content":{
-          "userid":row.userid
+          "userid":row.userid,
+          "leaderuserid":this.$route.query.id
         }
       })
       this.tool.showMessage(res,()=>{

+ 1 - 1
src/HManagement/clueManage/clue_private/modules/add.vue

@@ -117,7 +117,7 @@
 </template>
 
 <script>
-import selectActivity from '@/SManagement/orderclue/components/selectActivity/selectActivity'
+import selectActivity from '@/SManagement/orderclue/components/selectActivity/selectActivity.vue'
 import businessMessage from "@/components/businessMessage";
 export default {
   components: {selectActivity,businessMessage},

+ 1 - 1
src/SDrpManagement/QuotedPrice/modules/ProjectQuotationAdd.vue

@@ -315,7 +315,7 @@ export default {
         "content": {
           "pageNumber": 1,
           "pageSize": 10,
-          "type":0, //  1:我负责的;2:我参与的;3:我下属负责的;4:我下属参与的
+          "type":1, //  1:我负责的;2:我参与的;3:我下属负责的;4:我下属参与的
           "where": {
             "condition": "",
             "startdate": "",

+ 1 - 1
src/SDrpManagement/agentOrder/modules/edit.vue

@@ -1,7 +1,7 @@
 <template>
   <div>
     <!-- <el-button :disabled="data.status !=='新建'" type="primary" size="mini" @click="onShow(drawer = true)">编 辑</el-button> -->
-    <el-button type="primary" size="mini" @click="onShow(drawer = true)">编 辑</el-button>
+    <el-button type="primary" :disabled="data.type === '特殊订单'" size="mini" @click="onShow(drawer = true)">编 辑</el-button>
     <el-drawer
     :visible.sync="drawer"
     direction="rtl"

+ 21 - 2
src/SDrpManagement/agentOrder/modules/productlist.vue

@@ -3,9 +3,10 @@
   <el-col :span="setcol">
     <div  class="flex-align-center normal-margin">
       <slot name="operation"></slot>
-      <el-button v-if="data.status === '新建'" class="inline-16" size="small" type="primary"  @click="drawer = true">{{setcol === 24?'添 加':'取 消'}}</el-button>
+      <el-button v-if="data.status === '新建'" class="inline-16" :disabled="data.type === '特殊订单'" size="small" type="primary"  @click="drawer = true">{{setcol === 24?'添 加':'取 消'}}</el-button>
       <excel class="inline-16" :tablecols="columnTitle" :param="param" :total="total" :excelTitle="excelTitle"></excel>
     </div>
+    <p class="normal-margin" style="font-size: 13px !important;color:red;font-weight: normal">{{data.amount >= freefreightamount?'当前订单免运费':`订单满${tool.formatAmount(freefreightamount,2)}元免运费,当前还差${tool.formatAmount(freefreightamount - data.amount,2)}元`}}</p>
     <el-table
       ref="multipleTable"
       :data="tableData"
@@ -240,6 +241,7 @@ export default {
   props:['data','type'],
   data () {
     return {
+      freefreightamount:null,
       drawer:false,
       setcol:24,
       dataRefresh:true,
@@ -281,6 +283,7 @@ export default {
       this.tableData = res.data
       this.total = res.total
       this.currentPage = res.pageNumber
+      this.queryBasicInfo()
     },
     handleSizeChange(val) {
       // console.log(`每页 ${val} 条`);
@@ -362,7 +365,15 @@ export default {
         "id": 20221109093602,
         "content": val
       })
-      this.$emit('onSuccess')
+      if (res.code == 1) {
+        this.$emit('onSuccess')
+      } else {
+        this.$message({
+          message:res.data + ':' + res.msg,
+          type:'error'
+        })
+        this.listData()
+      }
     },
     setPickerOptions (val) {
       var startDate = val.deliverydate
@@ -399,6 +410,14 @@ export default {
         this.$emit('onSuccess')
       })
     },
+    async queryBasicInfo () {
+      const res = await this.$api.requested({
+        "id":20220920084001,"content":{
+          sys_enterpriseid:this.data.sys_enterpriseid
+        },
+      })
+      this.freefreightamount = res.data.freefreightamount?res.data.freefreightamount:0
+    }
   },
   mounted () {
     this.listData()

+ 1 - 1
src/SDrpManagement/myaccountclass/index.vue

@@ -8,7 +8,7 @@
             <el-col v-for="(item,index) in acountlist" :key="index" :span="6" class="mt-10" @click.native="handleClick(index)">
               <div class="acccounet__panel" :style="activeName == index?{border:'1px solid #d8dde8'}:''">
                 <p class="normal-margin">{{item.accountname}}</p>
-                <p class="normal-title" style="font-size:1.825rem" :style="activeName == index?{color:'#3874f6'}:''"><small>¥</small>&nbsp;{{tool.formatAmount(item.balance)}}</p>
+                <p class="normal-title" style="font-size:1.825rem" :style="activeName == index?{color:'#3874f6'}:''"><small>¥</small>&nbsp;{{tool.formatAmount(item.balance,2)}}</p>
                 <div class="score">
                   <p style="margin-top:16px">信用额度:{{item.creditquota}}</p>
                 </div>

+ 1 - 1
src/SDrpManagement/salerOrder/modules/edit.vue

@@ -1,7 +1,7 @@
 <template>
   <div>
     <!-- <el-button :disabled="data.status !=='新建'" type="primary" size="mini" @click="onShow(drawer = true)">编 辑</el-button> -->
-    <el-button type="primary" size="mini" @click="onShow(drawer = true)">编 辑</el-button>
+    <el-button type="primary" :disabled="data.type === '特殊订单'" size="mini" @click="onShow(drawer = true)">编 辑</el-button>
     <el-drawer
     :visible.sync="drawer"
     direction="rtl"

+ 34 - 32
src/SDrpManagement/salerOrder/modules/productlist.vue

@@ -3,9 +3,10 @@
   <el-col :span="setcol">
     <div  class="flex-align-center normal-margin">
       <slot name="operation"></slot>
-      <el-button class="inline-16" size="small" type="primary" @click="drawer = true">{{setcol === 24?'添 加':'取 消'}}</el-button>
+      <el-button :disabled="data.type === '特殊订单'"  v-if="data.status === '新建'" class="inline-16" size="small" type="primary" @click="drawer = true">{{setcol === 24?'添 加':'取 消'}}</el-button>
       <excel class="inline-16" :tablecols="columnTitle" :param="param" :total="total" :excelTitle="excelTitle"></excel>
     </div>
+    <p class="normal-margin" style="font-size: 13px !important;color:red;font-weight: normal">{{data.amount >= freefreightamount?'当前订单免运费':`订单满${tool.formatAmount(freefreightamount,2)}元免运费,当前还差${tool.formatAmount(freefreightamount - data.amount,2)}元`}}</p>
     <el-table
       ref="multipleTable"
       :data="tableData"
@@ -256,6 +257,7 @@ export default {
   props:['data','type'],
   data () {
     return {
+      freefreightamount:null,
       drawer:false,
       setcol:24,
       dataRefresh:true,
@@ -286,8 +288,8 @@ export default {
   },
   computed:{
     canUseInput () {
-      if (this.data.saler.length === 0) return false
-      let salerIsEditPrice = this.data.saler[0].iseditprice
+      if (this.data.saler && this.data.saler.length === 0) return false
+      let salerIsEditPrice = this.data.saler?this.data.saler[0].iseditprice:0
       if (this.data.type === '标准订单' && salerIsEditPrice && this.data.status === '新建') {
         return true
       } else {
@@ -306,6 +308,7 @@ export default {
       this.tableData = res.data
       this.total = res.total
       this.currentPage = res.pageNumber
+      this.queryBasicInfo()
     },
     handleSizeChange(val) {
       // console.log(`每页 ${val} 条`);
@@ -381,12 +384,21 @@ export default {
         },
       })
     },
-    async updateOrder (val) {
+    async updateOrder (val,fn) {
       const res  = await this.$api.requested({
         "id": 20221109093602,
         "content": val
       })
-      this.$emit('onSuccess')
+      if (res.code == 1) {
+        this.$emit('onSuccess')
+        fn?fn():''
+      } else {
+        this.$message({
+          type:'error',
+          message:res.data + ':' + res.msg
+        })
+        this.listData()
+      }
     },
     setPickerOptions (val) {
       var startDate = val.deliverydate
@@ -424,33 +436,23 @@ export default {
       })
     },
     inputChange (row,index) {
-      console.log(row.defaultprice,Number(row.contractprice))
-      if (row.defaultprice < Number(row.contractprice)) {
-        this.$message({
-          message:'价格不能低于原价!',
-          type:'error'
-        }) 
-        row.defaultprice = row.contractprice
-        this.updateOrder({
-          "sa_orderid": this.data.sa_orderid, //订单ID
-          "sys_enterpriseid": this.data.sys_enterpriseid, //企业ID
-          "sa_contractid": this.data.contacts.contactsid, //合同ID
-          "type": this.data.type, //订单类型
-          "items": this.tableData
-        })
-      } else {
-        // row.defaultprice = row.contractprice
-        this.$set(this.tableData,index,row)
-        this.updateOrder({
-          "sa_orderid": this.data.sa_orderid, //订单ID
-          "sys_enterpriseid": this.data.sys_enterpriseid, //企业ID
-          "sa_contractid": this.data.contacts.contactsid, //合同ID
-          "type": this.data.type, //订单类型
-          "items": this.tableData
-        })
-        
-      }
-      
+      this.updateOrder({
+        "sa_orderid": this.data.sa_orderid, //订单ID
+        "sys_enterpriseid": this.data.sys_enterpriseid, //企业ID
+        "sa_contractid": this.data.contacts.contactsid, //合同ID
+        "type": this.data.type, //订单类型
+        "items": this.tableData
+      },()=>{
+         this.$set(this.tableData,index,row)
+      })
+    },
+    async queryBasicInfo () {
+      const res = await this.$api.requested({
+        "id":20220920084001,"content":{
+          sys_enterpriseid:this.data.sys_enterpriseid
+        },
+      })
+      this.freefreightamount = res.data.freefreightamount?res.data.freefreightamount:0
     }
   },
   mounted () {

+ 1 - 0
src/SManagement/orderclue/components/selectActivity/selectActivity.vue

@@ -66,6 +66,7 @@ export default {
           "pageNumber":1,
           "pageSize":20,
           "where": {
+            "unend":1,
             'condition':''
           }
         }

+ 2 - 2
src/components/normal-basic-layout/index.vue

@@ -18,9 +18,9 @@
                 <cpAdd v-if="tool.checkAuth($route.name,'insert')" :formPath="formPath" :oldFormPath="oldFormPath" @onAddSuccess="listData(param.content.pageNumber = 1)"></cpAdd>
               </div>
               <slot name="titleLight"></slot>
-              <el-button-group v-if="tool.checkAuth($route.name,'delete')" class="inline-16">
+              <!-- <el-button-group v-if="tool.checkAuth($route.name,'delete')" class="inline-16">
                 <el-button :type="selection.length === 0?'':'primary'" :disabled="selection.length === 0" size="small" @click="deleteData">删 除</el-button>
-              </el-button-group>
+              </el-button-group> -->
               <!-- <el-button class="inline-16" size="small" type="primary" plain>导 入</el-button> -->
               <excel :tablecols="layout" :param="param" :total="total" :specialKey="specialKey" :excelTitle="routerName"></excel>
             </div>

+ 1 - 0
src/components/uploadBindMediaStock/modules/list.vue

@@ -81,6 +81,7 @@ export default {
           "pageNumber": 1,
           "pageSize": 20,
           "where": {
+            "isonlycollect":1,
             "condition":"",
             "parentid":''
           }