Jelajahi Sumber

代码上传

zhangqiOMG 3 tahun lalu
induk
melakukan
de471345d5

+ 48 - 5
src/Form/QuotedPrice/edit.vue

@@ -41,7 +41,7 @@
                       @keyup.enter.native="projectList(projectParam.content.pageNumber = 1)">
                     <i slot="prefix" class="el-icon-search" @click="projectList(projectParam.content.pageNumber = 1)"></i>
                   </el-input>
-                  <el-table :data="project.projectData" @row-click="projectData" height="396px" :header-cell-style="{background:'#EEEEEE',color:'#333'}" size="mini">
+                  <el-table :data="project.projectData" @row-click="projectOpen" height="396px" :header-cell-style="{background:'#EEEEEE',color:'#333'}" size="mini">
                     <el-table-column
                         label="项目编号"
                         width="180">
@@ -273,8 +273,8 @@ export default {
         "id": 20221020143502,
         "content": {
           "pageNumber": 1,
-          "pageSize": 5,
-          "type":0, //  1:我负责的;2:我参与的;3:我下属负责的;4:我下属参与的
+          "pageSize": 10,
+          "type":1, //  1:我负责的;2:我参与的;3:我下属负责的;4:我下属参与的
           "where": {
             "condition": "",
             "startdate": "",
@@ -295,7 +295,7 @@ export default {
         "id": 20220920083901,
         "content": {
           "pageNumber": 1,
-          "pageSize": 5,
+          "pageSize": 10,
           "where": {
             "condition": "",
             "type":4,
@@ -310,7 +310,6 @@ export default {
       },
       contactsParam:{
         "id": "20221022165503",
-        "version": 1,
         "content": {
           "sys_enterpriseid":"",
           "where": {
@@ -332,6 +331,7 @@ export default {
       drawer:false,
       isQuotedPrice:false,
       date:[],
+      clearData:[],
       form:{
         quotedpricetype:'',
         totalPrice:0,
@@ -517,6 +517,49 @@ export default {
       this.form.contactsphonenumber = ''
       this.projectShow = false
     },
+    /*更改项目前提示*/
+    projectOpen(val) {
+      this.$confirm('修改项目后将清空产品配置, 是否继续?', '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning'
+      }).then(() => {
+        this.productList()
+        this.projectData(val)
+      }).catch(() => {
+        this.$message({
+          type: 'info',
+          message: '已取消'
+        });
+      });
+    },
+    /*获取产品明细*/
+    async productList(){
+      const res = await this.$api.requested({
+        "id": 20221021095503,
+        "content": {
+          "sa_quotedpriceid":this.form.sa_quotedpriceid     //sat_notice_classid<=0时 为新增
+        }
+      })
+      console.log(res,"产品明细")
+      this.clearData = []
+      res.data.forEach((item,index)=>{
+        console.log(item)
+        this.clearData[index] = item.sa_quotedprice_itemsid
+      })
+      console.log(this.clearData,"需要删除的产品明细")
+      this.productClear()
+    },
+    /*清空产品明细*/
+    async productClear(){
+      const res = await this.$api.requested({
+        "id": 20221021095603,
+        "content": {
+          "sa_quotedprice_itemsids":this.clearData     //sat_notice_classid<=0时 为新增
+        }
+      })
+      this.$refs.quoterPrice.productData()
+    },
     /*客户选择信息*/
     customerData(val){
       this.form.sys_enterpriseid = val.sys_enterpriseid

+ 51 - 7
src/Form/QuotedPrice/editCopy.vue

@@ -34,7 +34,7 @@
                     @keyup.enter.native="projectList(projectParam.content.pageNumber = 1)">
                   <i slot="prefix" class="el-icon-search" @click="projectList(projectParam.content.pageNumber = 1)"></i>
                 </el-input>
-                <el-table :data="project.projectData">
+                <el-table :data="project.projectData" @row-click="projectOpen" height="396px" :header-cell-style="{background:'#EEEEEE',color:'#333'}" size="mini">
                   <el-table-column
                       label="项目编号"
                       width="180">
@@ -96,7 +96,7 @@
                     @keyup.enter.native="customerList(customerParam.content.pageNumber = 1)">
                   <i slot="prefix" class="el-icon-search" @click="customerList(customerParam.content.pageNumber = 1)"></i>
                 </el-input>
-                <el-table :data="customer.customerData">
+                <el-table :data="customer.customerData" @row-click="customerData" height="396px" :header-cell-style="{background:'#EEEEEE',color:'#333'}" size="mini">
                   <el-table-column
                       label="客户编号"
                       width="180">
@@ -179,7 +179,7 @@
                     @keyup.enter.native="contactsList(contactsParam.content.pageNumber = 1)">
                   <i slot="prefix" class="el-icon-search" @click="contactsList(contactsParam.content.pageNumber = 1)"></i>
                 </el-input>
-                <el-table :data="contacts.contactsData">
+                <el-table :data="contacts.contactsData" @row-click="contactsData" height="396px" :header-cell-style="{background:'#EEEEEE',color:'#333'}" size="mini">
                   <el-table-column
                       label="姓名"
                       width="180">
@@ -264,7 +264,7 @@ export default {
         "id": 20221020143502,
         "content": {
           "pageNumber": 1,
-          "pageSize": 5,
+          "pageSize": 10,
           "type":0, //  1:我负责的;2:我参与的;3:我下属负责的;4:我下属参与的
           "where": {
             "condition": "",
@@ -286,7 +286,7 @@ export default {
         "id": 20220920083901,
         "content": {
           "pageNumber": 1,
-          "pageSize": 5,
+          "pageSize": 10,
           "where": {
             "condition": "",
             "type":4,
@@ -323,6 +323,7 @@ export default {
       drawer:true,
       isQuotedPrice:false,
       date:[],
+      clearData:[],
       form:{
         quotedpricetype:'',
         totalPrice:0,
@@ -490,16 +491,59 @@ export default {
       this.form.projectnum = val.projectnum
       this.form.sys_enterpriseid = ''
       this.form.enterprisename = ''
-      this.form.contactsid = ''
+      this.form.contactsid = 0
       this.form.contactsname = ''
       this.form.contactsphonenumber = ''
       this.projectShow = false
     },
+    /*更改项目前提示*/
+    projectOpen(val) {
+      this.$confirm('修改项目后将清空产品配置, 是否继续?', '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning'
+      }).then(() => {
+        this.productList()
+        this.projectData(val)
+      }).catch(() => {
+        this.$message({
+          type: 'info',
+          message: '已取消'
+        });
+      });
+    },
+    /*获取产品明细*/
+    async productList(){
+      const res = await this.$api.requested({
+        "id": 20221021095503,
+        "content": {
+          "sa_quotedpriceid":this.form.sa_quotedpriceid     //sat_notice_classid<=0时 为新增
+        }
+      })
+      console.log(res,"产品明细")
+      this.clearData = []
+      res.data.forEach((item,index)=>{
+        console.log(item)
+        this.clearData[index] = item.sa_quotedprice_itemsid
+      })
+      console.log(this.clearData,"需要删除的产品明细")
+      this.productClear()
+    },
+    /*清空产品明细*/
+    async productClear(){
+      const res = await this.$api.requested({
+        "id": 20221021095603,
+        "content": {
+          "sa_quotedprice_itemsids":this.clearData     //sat_notice_classid<=0时 为新增
+        }
+      })
+      this.$refs.quoterPrice.productData()
+    },
     /*客户选择信息*/
     customerData(val){
       this.form.sys_enterpriseid = val.sys_enterpriseid
       this.form.enterprisename = val.enterprisename
-      this.form.contactsid = ''
+      this.form.contactsid = 0
       this.form.contactsname = ''
       this.form.contactsphonenumber = ''
       this.customerShow = false

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

@@ -44,8 +44,6 @@ import { log } from '@antv/g2plot/lib/utils'
 export default {
   components:{
   },
-  computed: {
-  },
   data () {
     return {
       drawer:false,

+ 26 - 25
src/HDrpManagement/competitor/detail/modules/addressManage/list.vue

@@ -1,31 +1,32 @@
 <template>
   <div>
-    <div class="normal-margin">
-      <add v-if="tool.checkAuth($route.name,'addressManage')" :data="data" @insertSuccess="onSuccess" style="float: left;"></add>
-      <div style="width: 20%">
-        <el-input
-            placeholder="请输入内容"
-            v-model="search"
-            clearable
-            @clear="clearData()"
-            size="small"
-            @keyup.enter.native="queryClick()">
-          <i slot="prefix" class="el-icon-search" @click="queryClick()"></i>
-        </el-input>
-      </div>
+    <div >
+      <add v-if="tool.checkAuth($route.name,'addressManage')" class="inline-16" :data="data" @insertSuccess="onSuccess" ></add>
+      <el-input
+          placeholder="请输入内容"
+          v-model="search"
+          clearable
+          style="width:200px"
+          @clear="clearData()"
+          size="small"
+          @keyup.enter.native="queryClick()">
+        <i slot="prefix" class="el-icon-search" @click="queryClick()"></i>
+      </el-input>
+    </div>
+    <div style="margin-top: 15px">
+      <tableLayout :layout="tablecols" :data="list" :opwidth="200" :custom="true"  :height="tableHieght" >
+        <template v-slot:customcol="scope">
+          <div v-if="scope.column.columnname === 'province'">
+            <p>{{ scope.column.data.province + scope.column.data.city + scope.column.data.county}}</p>
+          </div>
+          <p v-else>{{scope.column.data[scope.column.columnname]}}</p>
+        </template>
+        <template v-slot:opreation="scope">
+          <edit v-if="tool.checkAuth($route.name,'addressManage')" :data="scope.data" @updateSuccess="onSuccess"></edit>
+          <toVoid v-if="tool.checkAuth($route.name,'addressManage')" :data="scope.data" @toVoidSuccess="onSuccess"></toVoid>
+        </template>
+      </tableLayout>
     </div>
-    <tableLayout :layout="tablecols" :data="list" :opwidth="200" :custom="true"  :height="tableHieght" >
-      <template v-slot:customcol="scope">
-        <div v-if="scope.column.columnname === 'province'">
-          <p>{{ scope.column.data.province + scope.column.data.city + scope.column.data.county}}</p>
-        </div>
-        <p v-else>{{scope.column.data[scope.column.columnname]}}</p>
-      </template>
-      <template v-slot:opreation="scope">
-        <edit v-if="tool.checkAuth($route.name,'addressManage')" :data="scope.data" @updateSuccess="onSuccess"></edit>
-        <toVoid v-if="tool.checkAuth($route.name,'addressManage')" :data="scope.data" @toVoidSuccess="onSuccess"></toVoid>
-      </template>
-    </tableLayout>
     <div style="margin-top:16px;text-align:right">
       <el-pagination
           background

+ 23 - 23
src/HDrpManagement/competitor/detail/modules/contacts/list.vue

@@ -1,28 +1,29 @@
 <template>
   <div>
-    <div class="normal-margin">
-      <add v-if="tool.checkAuth($route.name,'contactsManage')" :data="data"  @insertSuccess="onSuccess" style="float: left;"></add>
-      <div style="width: 20%">
-        <el-input
-            placeholder="请输入内容"
-            v-model="search"
-            clearable
-            @clear="clearData()"
-            size="small"
-            @keyup.enter.native="queryClick()">
-          <i slot="prefix" class="el-icon-search" @click="queryClick()"></i>
-        </el-input>
-      </div>
+    <div>
+      <add v-if="tool.checkAuth($route.name,'contactsManage')" class="inline-16" :data="data"  @insertSuccess="onSuccess" ></add>
+      <el-input
+          placeholder="请输入内容"
+          v-model="search"
+          style="width:200px"
+          clearable
+          @clear="clearData()"
+          size="small"
+          @keyup.enter.native="queryClick()">
+        <i slot="prefix" class="el-icon-search" @click="queryClick()"></i>
+      </el-input>
+    </div>
+    <div style="margin-top: 15px">
+      <tableLayout :layout="tablecols" :data="list" :opwidth="200" :custom="true"  :height="tableHieght" fixedName="operation">
+        <template v-slot:customcol="scope">
+          <p>{{scope.column.data[scope.column.columnname]}}</p>
+        </template>
+        <template v-slot:opreation="scope">
+          <edit v-if="tool.checkAuth($route.name,'contactsManage')" :data="scope.data" @updateSuccess="onSuccess"></edit>
+          <toVoid v-if="tool.checkAuth($route.name,'contactsManage')" :data="scope.data" @toVoidSuccess="onSuccess"></toVoid>
+        </template>
+      </tableLayout>
     </div>
-    <tableLayout :layout="tablecols" :data="list" :opwidth="200" :custom="true"  :height="tableHieght" >
-      <template v-slot:customcol="scope">
-        <p>{{scope.column.data[scope.column.columnname]}}</p>
-      </template>
-      <template v-slot:opreation="scope">
-        <edit v-if="tool.checkAuth($route.name,'contactsManage')" :data="scope.data" @updateSuccess="onSuccess"></edit>
-        <toVoid v-if="tool.checkAuth($route.name,'contactsManage')" :data="scope.data" @toVoidSuccess="onSuccess"></toVoid>
-      </template>
-    </tableLayout>
     <div style="margin-top:16px;text-align:right">
       <el-pagination
           background
@@ -124,5 +125,4 @@ export default {
   display: flex;
   align-items: center;
 }
-
 </style>

+ 52 - 1
src/HDrpManagement/contractManage/components/addContract.vue

@@ -359,7 +359,6 @@
 
 <script>
 import {mapGetters} from 'vuex'
-
 import selectPople from './selectSaler'
 import selectAgent from './selectAgent'
 import seleteProject from './seleteProject'
@@ -519,6 +518,32 @@ export default {
     }
   },
   created () {
+    this.form = {
+      "sa_contractid": 0,
+      "sys_enterpriseid": "",
+      "projectname":'',
+      "begdate": "",
+      "enddate": "",
+      "sa_projectid": "", //可选
+      "type": "", //可选
+      "discountrate": '', //可选
+      "saler_hrid": JSON.parse(window.sessionStorage.getItem('active_account')).hrid, //可选
+      "signdate": "", //可选
+      "signby": "", //可选
+      "remarks": "", //可选
+      "title": "",
+      "signamount":'',
+      "salername":JSON.parse(window.sessionStorage.getItem('active_account')).name,
+      "enterprisename":'',
+      "sys_printmodelid": '',//可选
+      "typemx":"",//可选
+      "modelname":"",
+      "calculatemodel":'1',
+      "productdiscount":'',
+      "orderratio":'',
+      "ascription_title":'',
+      'ascription_contractid':''
+    }
   },
   methods: {
     async onSubmit () {
@@ -599,6 +624,32 @@ export default {
     },
     onCancel () {
       this.$store.dispatch('DrawerShowChange',false)
+      this.form = {
+        "sa_contractid": 0,
+        "sys_enterpriseid": "",
+        "projectname":'',
+        "begdate": "",
+        "enddate": "",
+        "sa_projectid": "", //可选
+        "type": "", //可选
+        "discountrate": '', //可选
+        "saler_hrid": JSON.parse(window.sessionStorage.getItem('active_account')).hrid, //可选
+        "signdate": "", //可选
+        "signby": "", //可选
+        "remarks": "", //可选
+        "title": "",
+        "signamount":'',
+        "salername":JSON.parse(window.sessionStorage.getItem('active_account')).name,
+        "enterprisename":'',
+        "sys_printmodelid": '',//可选
+        "typemx":"",//可选
+        "modelname":"",
+        "calculatemodel":'1',
+        "productdiscount":'',
+        "orderratio":'',
+        "ascription_title":'',
+        'ascription_contractid':''
+      }
     },
     showChange (key) {
       this.agentVisible = false

+ 2 - 1
src/HDrpManagement/contractManage/components/selectAgent.vue

@@ -33,7 +33,7 @@
 	</div>
   <el-empty v-if="tableData.length === 0" description="暂无数据" :image-size="40"></el-empty>
   <el-button size="mini" type="text" style="margin-top:16px;float:right" @click="onCancel">取 消</el-button>
-	<el-button size="mini" type="primary" style="margin-top:16px;float:right;margin-right:10px" @click="onSelect">确 定</el-button>
+<!--	<el-button size="mini" type="primary" style="margin-top:16px;float:right;margin-right:10px" @click="onSelect">确 定</el-button>-->
  	<div style="margin-top:16px;text-align:left">
     <el-pagination
     background
@@ -96,6 +96,7 @@ export default {
 					return e.sys_enterpriseid !== item.sys_enterpriseid
 				})
 			}
+      this.onSelect()
 		},
 		showSelelctIcon (item) {
 			let _isSame = this.selected.some(m=>item.sys_enterpriseid === m.sys_enterpriseid)

+ 45 - 16
src/HDrpManagement/contractManage/index.vue

@@ -10,31 +10,32 @@
       :options="options"
       :detailPath="{
         path:'/contractDetail',
+        param:{tabIndex:tabIndex}
       }"
       @listData="listdata"
       @listCreate="list">
-      <div slot="custom" style="display:flex">
-        <div class="label_center">
+      <template #custom>
+        <div class="mt-10">
           <p class="search__label">范围:</p>
           <el-select
-            class="inline-16"
+            class="inline-24"
             size="small"
             v-model="area"
             placeholder="请选择范围"
-            @change="$refs.list.param.content.pageNumber=1;$refs.list.param.content.type=area;$refs.list.listData()"
+            @change="areaChange"
           >
             <el-option
               v-for="item in areaList"
-              :key="item.remarks"
-              :label="item.value"
-              :value="item.remarks"
+              :key="item.index"
+              :label="item.title"
+              :value="item.name"
             ></el-option>
           </el-select>
         </div>
-        <div class="label_center">
+        <div class="mt-10">
           <p class="search__label">合同类型:</p>
           <el-select
-            class="inline-16"
+            class="inline-24"
             size="small"
             v-model="type"
             placeholder="请选择合同类型"
@@ -49,10 +50,10 @@
             ></el-option>
           </el-select>
         </div>
-        <div class="label_center">
+        <div class="mt-10">
           <p class="search__label">合同状态:</p>
           <el-select
-            class="inline-16"
+            class="inline-24"
             size="small"
             v-model="status"
             placeholder="请选择合同状态"
@@ -65,7 +66,7 @@
             <el-option label="已终止" value="已终止" ></el-option>
           </el-select>
         </div>
-      </div>
+      </template>
 
       <template v-slot:tbList="scope">
         <div v-if="scope.data.column.columnname == 'status'">
@@ -98,9 +99,31 @@ export default {
   data () {
     return {
       options:[],
-      areaList:[],
+      areaList:[
+        {
+          title: '我负责的',
+          name: "1",
+        },
+        {
+          title: '我参与的',
+          name: "2",
+        },
+        {
+          title: '我创建的',
+          name: "5",
+        },
+        {
+          title: '我下属负责的',
+          name: "3",
+        },
+        {
+          title: '我下属参与的',
+          name: "4",
+        }
+      ],
       typeList:[],
-      area:'0',
+      area:'1',
+      tabIndex:"1",
       type:'',
       condition:'',
       status:''
@@ -113,9 +136,9 @@ export default {
   },
   methods:{
     async getSystemList () {
-      const res = await this.$store.dispatch('optiontypeselect','dataarea')
+      /*const res = await this.$store.dispatch('optiontypeselect','dataarea')
       this.areaList = res.data
-      console.log(this.areaList);
+      console.log(this.areaList);*/
       
       const res2 = await this.$store.dispatch('optiontypeselect','contracttype')
       this.typeList = res2.data
@@ -156,6 +179,12 @@ export default {
     listdata(data) {
       console.log(data);
       
+    },
+    areaChange(){
+      this.tabIndex = this.area
+      this.$refs.list.param.content.pageNumber=1;
+      this.$refs.list.param.content.type=this.area;
+      this.$refs.list.listData()
     }
   }
 }

+ 1 - 0
src/HDrpManagement/contractManage/modules/detail.vue

@@ -202,6 +202,7 @@ export default {
         }
       })
       this.mainData = res.data
+      this.$refs.details.param.content.type = this.$route.query.tabIndex
       console.log(this.mainData);
       
       this.mainData.type == '项目' 

+ 1 - 1
src/HDrpManagement/projectChange/modules/modules/andEnterprise/index.vue

@@ -1,7 +1,7 @@
 <template>
   <div>
     <div>
-      <add class="inline-16" v-if="tool.checkAuth($route.name,'andEnterpriseManage')" :data="rowData" @addSuccess="onSuccess"></add>
+      <add class="inline-16" v-if="tool.checkAuth($route.name,'andEnterpriseManage')"  :data="rowData" @addSuccess="onSuccess"></add>
       <el-input
           placeholder="请输入搜索内容"
           suffix-icon="el-icon-search"

+ 47 - 19
src/HManagement/clueManage/m_activity/index.vue

@@ -11,30 +11,30 @@
       idName="sat_campaignid" 
       :apiId="{query:20221101095102,del:''}" 
       :options="options"
-      :detailPath="{path:'/marketing_activityDetails'}"
+      :detailPath="{path:'/marketing_activityDetails',param:{tabIndex:tabIndex}}"
       @listCreate="list"
     >
-     <div slot="custom" style="display:flex">
-       <div class="label_center">
+     <template #custom >
+       <div class="mt-10">
         <p class="search__label">范围:</p>
         <el-select
-          class="inline-16"
+          class="inline-24"
           size="small"
           v-model="area"
           placeholder="请选择范围"
-          @change="$refs.basicLayout.param.content.pageNumber=1;$refs.basicLayout.param.content.type=area;$refs.basicLayout.listData()"
+          @change="areaChange"
         >
           <el-option
             v-for="item in areaList2"
-            :key="item.remarks"
-            :label="item.value"
-            :value="item.remarks"
+            :key="item.index"
+            :label="item.title"
+            :value="item.name"
           ></el-option>
         </el-select>
       </div>
-       <div class="label_center">
+       <div class="mt-10">
         <p class="search__label">活动类型:</p>
-        <el-select v-model="search.type" style="margin-right:10px" size="small" placeholder="请选择活动类型" @change="campaigntypeChange" clearable>
+        <el-select v-model="search.type" class="inline-24" size="small" placeholder="请选择活动类型" @change="campaigntypeChange" clearable>
           <el-option
             v-for="item in campaigntypeList"
             :key="item.index"
@@ -43,9 +43,9 @@
           </el-option>
         </el-select>
       </div>
-      <div class="label_center">
+      <div class="mt-10">
         <p class="search__label">活动状态:</p>
-        <el-select v-model="search.status" style="margin-right:10px" size="small" placeholder="请选择活动状态" @change="statusChange" clearable>
+        <el-select v-model="search.status" class="inline-24" size="small" placeholder="请选择活动状态" @change="statusChange" clearable>
           <el-option label="新建" value="新建">
           </el-option>
           <el-option label="发布" value="发布">
@@ -54,8 +54,7 @@
           </el-option>
         </el-select>
       </div>
-        
-     </div>
+     </template>
       <div slot="titleRight" style="display:flex;margin-left:10px">
       </div>
       <template v-slot:tbList="scope">
@@ -86,9 +85,30 @@ export default {
       options:[],
       search:{},
       campaigntypeList:'',
-      areaList2:[],
-      area:'全部'
-
+      areaList2:[
+        {
+          title: '我负责的',
+          name: "1",
+        },
+        {
+          title: '我参与的',
+          name: "2",
+        },
+        {
+          title: '我创建的',
+          name: "5",
+        },
+        {
+          title: '我下属负责的',
+          name: "3",
+        },
+        {
+          title: '我下属参与的',
+          name: "4",
+        }
+      ],
+      area:'1',
+      tabIndex:"1",
     }
   },
   provide () {
@@ -100,6 +120,7 @@ export default {
     list (param) {
       param.content.isAll = 0
       param.content.nocache = true
+      param.content.type = 1
     },
     async campaigntype () {
       const res = await this.$api.requested({
@@ -120,12 +141,19 @@ export default {
       this.$refs.basicLayout.param.content.where.status = this.search.status
       this.$refs.basicLayout.listData()
     },
+    areaChange(){
+      this.tabIndex = this.area
+      this.$refs.basicLayout.param.content.pageNumber=1;
+      this.$refs.basicLayout.param.content.type=this.area;
+      this.$refs.basicLayout.listData()
+    }
   },
-  async created () {
+  created () {
     this.campaigntype()
 
-    const res = await this.$store.dispatch('optiontypeselect','dataarea')
+   /* const res = await this.$store.dispatch('optiontypeselect','dataarea')
     this.areaList2 = res.data
+    console.log(this.areaList2)*/
   }
 }
 

+ 4 - 2
src/HManagement/clueManage/m_activity/modules/details.vue

@@ -76,6 +76,7 @@ export default {
         }
       })
       this.mainData = res.data
+      this.$refs.details.param.content.type = this.$route.query.tabIndex
       this.changeDataStructure()
       console.log(this.mainData);
       
@@ -182,9 +183,10 @@ export default {
       param.content.isAll = 0
     },
     // 监听切换数据,上一页,下一页
-    pageChange (id,rowindex) {
+    pageChange (id,rowindex,tabIndex) {
       this.flag = false
-      this.$router.replace({path:'/marketing_activityDetails',query:{id:id,rowindex:rowindex}})
+      tabIndex = this.$route.query.tabIndex
+      this.$router.replace({path:'/marketing_activityDetails',query:{id:id,rowindex:rowindex,tabIndex:tabIndex}})
       this.queryMainData(id)
     }
   },

+ 1 - 0
src/SDrpManagement/QuotedPrice/components/edit/productTable.vue

@@ -7,6 +7,7 @@
         append-to-body
         size="80%"
         direction="rtl"
+        :show-close="false"
         @close="onColes">
       <div class="drawer__panel">
         <div class="flex-align-center flex-between ">

+ 1 - 0
src/SDrpManagement/QuotedPrice/components/edit/productTableProject.vue

@@ -7,6 +7,7 @@
         append-to-body
         size="80%"
         direction="rtl"
+        :show-close="false"
         @close="onColes">
       <div class="drawer__panel">
         <div class="flex-align-center flex-between ">

+ 1 - 0
src/SDrpManagement/QuotedPrice/components/productTable.vue

@@ -7,6 +7,7 @@
         append-to-body
         size="80%"
         direction="rtl"
+        :show-close="false"
         @close="onColes">
       <div class="drawer__panel">
         <div class="flex-align-center flex-between ">

+ 1 - 0
src/SDrpManagement/QuotedPrice/components/productTableProject.vue

@@ -6,6 +6,7 @@
         :visible.sync="dialogProductVisible"
         append-to-body
         size="80%"
+        :show-close="false"
         direction="rtl"
         @close="onColes">
       <div class="drawer__panel">

+ 1 - 0
src/SDrpManagement/QuotedPrice/components/projectTable.vue

@@ -5,6 +5,7 @@
         :visible.sync="dialogProjectVisible"
         append-to-body
         width="900px"
+        :show-close="false"
         @close="onColes">
       <div class="panel_Target">
         <el-input style="width:200px;margin-top: 10px;margin-bottom: 15px" placeholder="请输入搜索内容" suffix-icon="el-icon-search" @input="selectChange" v-model="param.content.where.condition" @keyup.native.enter="projectList(param.content.pageNumber = 1)" @clear="projectList(param.content.pageNumber = 1)" size="small" class="input-with-select inline-16 layout_search__panel" clearable>

+ 44 - 15
src/SManagement/orderclue/index.vue

@@ -11,36 +11,36 @@
       idName="sat_orderclueid" 
       :apiId="{query:20221101094502,del:''}" 
       :options="options"
-      :detailPath="{path:'/orderclue_detail'}"
+      :detailPath="{path:'/orderclue_detail',param:{tabIndex:tabIndex}}"
       @listCreate="list"
       @listData="list2"
     >
-    <div slot="custom" style="display:flex">
-      <div class="label_center">
+    <template #custom>
+      <div class="mt-10">
         <p class="search__label">范围:</p>
         <el-select
-          class="inline-16"
+          class="inline-24"
           size="small"
           v-model="area"
           placeholder="请选择范围"
-          @change="$refs.list.param.content.pageNumber=1;$refs.list.param.content.type=area;$refs.list.listData()"
+          @change="areaChange"
         >
           <el-option
             v-for="item in areaList2"
-            :key="item.remarks"
-            :label="item.value"
-            :value="item.remarks"
+            :key="item.index"
+            :label="item.title"
+            :value="item.name"
           ></el-option>
         </el-select>
       </div>
-      <div class="label_center">
+      <div class="mt-10">
         <p class="search__label">跟进状态:</p>
-        <el-select v-model="status" clearable style="margin-right:10px" size="small" placeholder="请选择线索状态" @change="$refs.list.param.content.pageNumber=1;$refs.list.param.content.where.status = status;$refs.list.listData()">
+        <el-select v-model="status" clearable class="inline-24" size="small" placeholder="请选择线索状态" @change="$refs.list.param.content.pageNumber=1;$refs.list.param.content.where.status = status;$refs.list.listData()">
           <el-option v-for="item in statusList" :label="item.value" :key="item.rowindex" :value="item.remarks">
           </el-option>
         </el-select>
       </div>
-    </div>
+    </template>
       <template v-slot:tbList="scope">
         <div v-if="scope.data.column.columnname == 'status'">
           <span style="color:#999999" v-if="scope.data.column.data[[scope.data.column.columnname]] == '已过期'">{{scope.data.column.data[[scope.data.column.columnname]]}}</span>
@@ -74,8 +74,30 @@ export default {
       options:[],
       arealist:[],
       teamList:[],
-      areaList2:[],
-      area:'0',
+      areaList2:[
+        {
+          title: '我负责的',
+          name: "1",
+        },
+        {
+          title: '我参与的',
+          name: "2",
+        },
+        {
+          title: '我创建的',
+          name: "5",
+        },
+        {
+          title: '我下属负责的',
+          name: "3",
+        },
+        {
+          title: '我下属参与的',
+          name: "4",
+        }
+      ],
+      area:'1',
+      tabIndex:"1",
       status:'',
       statusList:[]
     }
@@ -91,8 +113,8 @@ export default {
     this.query_arealist()
     this.queryUserInfo()
 
-    const res = await this.$store.dispatch('optiontypeselect','dataarea')
-    this.areaList2 = res.data
+   /* const res = await this.$store.dispatch('optiontypeselect','dataarea')
+    this.areaList2 = res.data*/
 
     const res2 = await this.$store.dispatch('optiontypeselect','datafollowuptype')
     this.statusList = res2.data
@@ -124,6 +146,12 @@ export default {
       
       this.arealist = this.tool.createMenu(res.data)
     },
+    areaChange(){
+      this.tabIndex = this.area
+      this.$refs.list.param.content.pageNumber=1;
+      this.$refs.list.param.content.type=this.area;
+      this.$refs.list.listData()
+    },
     async queryUserInfo() {
       let res = await this.$api.requested({
         "classname": "common.usercenter.usercenter",
@@ -144,6 +172,7 @@ export default {
     },
     list (param) {
       param.content.isAll = 0
+      param.content.type = 1
     },
     list2 (data) {
       console.log(data);

+ 4 - 2
src/SManagement/orderclue_detail/index.vue

@@ -107,6 +107,7 @@ export default {
         }
       })
       this.mainData = res.data
+      this.$refs.details.param.content.type = this.$route.query.tabIndex
       console.log(this.mainData,"销售线索手机号数据");
       
       this.changeDataStructure()
@@ -301,9 +302,10 @@ export default {
       })
     },
     // 监听切换数据,上一页,下一页
-    pageChange (id,rowindex) {
+    pageChange (id,rowindex,tabIndex) {
       this.flag = false
-      this.$router.replace({path:'/orderclue_detail',query:{id:id,rowindex:rowindex}})
+      tabIndex = this.$route.query.tabIndex
+      this.$router.replace({path:'/orderclue_detail',query:{id:id,rowindex:rowindex,tabIndex:tabIndex}})
       this.queryMainData(id)
     },
     onChangeCustomer(){

+ 2 - 1
src/SManagement/project_target/modules/detailInfo.vue

@@ -274,6 +274,7 @@ export default {
       this.$confirm('只能填写目标年度的月份!', '提示', {
         confirmButtonText: '确定',
         showCancelButton:false,
+        closeOnClickModal:false,
         type: 'warning'
       }).then(() => {
         this.$message({
@@ -283,7 +284,7 @@ export default {
       }).catch(() => {
         this.$message({
           type: 'info',
-          message: '已取消删除'
+          message: '已取消'
         });
       });
     }

+ 194 - 104
src/template/salesForecastUseProject/addProduct.vue

@@ -6,110 +6,142 @@
       :visible.sync="drawer"
       append-to-body
       direction="rtl"
+      :show-close="false"
       size="80%">
       <div class="drawer__panel">
-        <el-table
-          ref="multipleTable"
-          :data="list"
-          style="width: 100%"
-          :header-cell-style="{height:'50px',color:'#606266',fontWeight:'400'}"
-          :cell-style="{height:'50px',color:'#666666',fontWeight:'400'}">
-        <el-table-column
-            align="center"
-            label="产品图"
-            width="80">
-          <template slot-scope="scope">
-            <div v-if="scope.row.attinfos[0]">
-              <previewImage style="height:38px;width:38px" :image="scope.row.attinfos[0]" :list="scope.row.attinfos" :deletebtn="false"></previewImage>
+        <div class="flex-align-center flex-between " style="margin-top:-10px;margin-bottom: 10px">
+          <div class="flex-align-center">
+            <el-input size="small"  suffix-icon="el-icon-search" v-model="param.content.where.condition" placeholder="产品名称,编号" @keyup.enter.native="listData(param.content.pageNumber = 1)" @clear="listData(param.content.pageNumber = 1)" clearable></el-input>&nbsp;
+          </div>
+          <div style="float: right">
+            <el-button style="float: right" type="primary" size="mini" @click="onSubmit"  :disabled="tableSelectData.length === 0 ">批量添加</el-button>
+          </div>
+        </div>
+        <div class="produtMag-panel" style="margin-top: 10px">
+          <el-table
+              ref="multipleTable"
+              :data="list"
+              style="width: 100%"
+              :header-cell-style="{height:'50px',color:'#606266',fontWeight:'400'}"
+              :cell-style="{height:'50px',color:'#666666',fontWeight:'400'}"
+              @selection-change="selectionChange">
+            <el-table-column
+                type="selection"
+                width="55">
+            </el-table-column>
+            <el-table-column
+                align="center"
+                label="产品图"
+                width="80">
+              <template slot-scope="scope">
+                <div v-if="scope.row.attinfos[0]">
+                  <previewImage style="height:38px;width:38px" :image="scope.row.attinfos[0]" :list="scope.row.attinfos" :deletebtn="false"></previewImage>
+                </div>
+              </template>
+            </el-table-column>
+            <el-table-column
+                prop="itemno"
+                label="产品编号"
+                width="180">
+            </el-table-column>
+            <el-table-column
+                prop="itemname"
+                label="产品名称"
+                width="180">
+            </el-table-column>
+            <el-table-column
+                label="型号/规格">
+              <template slot-scope="scope">
+                <p><span>{{scope.row.model}}</span>&nbsp;/&nbsp;<span>{{scope.row.spec}}</span></p>
+              </template>
+            </el-table-column>
+            <el-table-column
+                prop="caliber"
+                label="口径"
+                width="180">
+            </el-table-column>
+            <el-table-column
+                prop="pressure"
+                label="压力"
+                width="180">
+            </el-table-column>
+            <el-table-column
+                prop="material"
+                label="材质"
+                width="180">
+            </el-table-column>
+            <el-table-column
+                prop="brand"
+                label="品牌"
+                width="180">
+              <template slot-scope="scope">
+                <p v-for="(item,index) in scope.row.brand" :key="index">
+                  <span style="float: left" v-if="index === scope.row.brand.length -1">{{item?item.brandname+'':'--'}}</span>
+                  <span style="float: left" v-else>{{item?item.brandname+',':'--'}}</span>
+                </p>
+              </template>
+            </el-table-column>
+            <el-table-column
+                prop="itemclass"
+                label="类别"
+                width="180">
+              <template slot-scope="scope">
+                <p v-for="(item,index) in scope.row.itemclass" :key="index">
+                  <span style="float: left" v-if="index === scope.row.itemclass.length -1">{{item?item.itemclassname+'':'--'}}</span>
+                  <span style="float: left" v-else>{{item?item.itemclassname+',':'--'}}</span>
+                </p>
+              </template>
+            </el-table-column>
+            <el-table-column
+                prop="unitid"
+                label="计量单位"
+                width="100">
+              <template slot-scope="scope">
+                <el-tag size="mini" type="info" effect="plain">{{scope.row.unitname}}/{{scope.row.axunitname}}</el-tag>
+              </template>
+            </el-table-column>
+            <el-table-column
+                prop="marketprice"
+                label="牌价"
+                width="100">
+            </el-table-column>
+            <el-table-column
+                label="操作"
+                width="90"
+                fixed="right">
+              <template slot-scope="scope">
+                <el-button type="text" size="small" @click="addProduct(scope.row)">添加</el-button>
+              </template>
+            </el-table-column>
+          </el-table>
+<!--          <div class="container normal-panel" style="text-align:right">
+            <el-pagination
+                background
+                @size-change="handleSizeChange"
+                @current-change="handleCurrentChange"
+                :current-page="currentPage"
+                :page-sizes="[20, 50, 100, 200]"
+                layout="total,sizes, prev, pager, next, jumper"
+                :total="total">
+            </el-pagination>
+          </div>-->
+          <div>
+            <div style="float: left">已选:{{selectTotal}}个商品</div>
+            <div style="margin-top:16px;text-align:right">
+              <el-pagination
+                  background
+                  small
+                  @size-change="handleSizeChange"
+                  @current-change="handleCurrentChange"
+                  :current-page="currentPage"
+                  :page-sizes="[20, 50, 100, 200]"
+                  layout="total, prev, pager, next, jumper"
+                  :total="total">
+              </el-pagination>
             </div>
-          </template>
-        </el-table-column>
-        <el-table-column
-            prop="itemno"
-            label="产品编号"
-            width="180">
-        </el-table-column>
-        <el-table-column
-            prop="itemname"
-            label="产品名称"
-            width="180">
-        </el-table-column>
-        <el-table-column
-            label="型号/规格">
-          <template slot-scope="scope">
-            <p><span>{{scope.row.model}}</span>&nbsp;/&nbsp;<span>{{scope.row.spec}}</span></p>
-          </template>
-        </el-table-column>
-        <el-table-column
-            prop="caliber"
-            label="口径"
-            width="180">
-        </el-table-column>
-        <el-table-column
-            prop="pressure"
-            label="压力"
-            width="180">
-        </el-table-column>
-        <el-table-column
-            prop="material"
-            label="材质"
-            width="180">
-        </el-table-column>
-        <el-table-column
-            prop="brand"
-            label="品牌"
-            width="180">
-          <template slot-scope="scope">
-            <p v-for="(item,index) in scope.row.brand" :key="index">
-              <span style="float: left" v-if="index === scope.row.brand.length -1">{{item?item.brandname+'':'--'}}</span>
-              <span style="float: left" v-else>{{item?item.brandname+',':'--'}}</span>
-            </p>
-          </template>
-        </el-table-column>
-        <el-table-column
-            prop="itemclass"
-            label="类别"
-            width="180">
-          <template slot-scope="scope">
-            <p v-for="(item,index) in scope.row.itemclass" :key="index">
-              <span style="float: left" v-if="index === scope.row.itemclass.length -1">{{item?item.itemclassname+'':'--'}}</span>
-              <span style="float: left" v-else>{{item?item.itemclassname+',':'--'}}</span>
-            </p>
-          </template>
-        </el-table-column>
-        <el-table-column
-            prop="unitid"
-            label="计量单位"
-            width="100">
-          <template slot-scope="scope">
-            <el-tag size="mini" type="info" effect="plain">{{scope.row.unitname}}/{{scope.row.axunitname}}</el-tag>
-          </template>
-        </el-table-column>
-        <el-table-column
-            prop="marketprice"
-            label="牌价"
-            width="100">
-        </el-table-column>
-        <el-table-column
-            label="操作"
-            width="90"
-            fixed="right">
-          <template slot-scope="scope">
-            <el-button type="text" size="small" @click="addProduct(scope.row)">添加</el-button>
-          </template>
-        </el-table-column>
-        </el-table>
-        <div class="container normal-panel" style="text-align:right">
-          <el-pagination
-            background
-            @size-change="handleSizeChange"
-            @current-change="handleCurrentChange"
-            :current-page="currentPage"
-            :page-sizes="[20, 50, 100, 200]"
-            layout="total,sizes, prev, pager, next, jumper"
-            :total="total">
-          </el-pagination>
+          </div>
         </div>
+
       </div>
     </el-drawer>
   </div>
@@ -127,14 +159,19 @@ export default {
       drawer:false,
       param:{
         "id": 20221208105403,
-        "version":1,
         "content": {
-          "sa_projectid":this.id
+          "sa_projectid":this.id,
+          "where": {
+            "condition": ""
+          }
         }
       },
       list:[],
       currentPage:0,
-      total:0
+      selectTotal:0,
+      total:0,
+      tableSelectData:[],
+      selectData:[]
     }
   },
   methods:{
@@ -158,13 +195,13 @@ export default {
     onShow () {
       console.log(this.mainData)
       this.listData()
+      this.selectListData()
     },
     async addProduct (row) {
       console.log(row,"添加商品")
       row.sa_salesforecastid = 0
       const res = await this.$api.requested({
         "id": 20220906155003,
-        "version":1,
         "content": {
             "sa_salesforecastmodelid":this.mainData.sa_salesforecastmodelid,
             "sa_salesforecastbillid":this.$route.query.id,
@@ -185,7 +222,60 @@ export default {
       this.tool.showMessage(res,()=>{
         this.$emit('onSuccess')
         this.listData()
+        this.selectListData()
+      })
+    },
+    /*选择要添加的数据*/
+    selectionChange(val){
+      console.log(val)
+      this.tableSelectData = []
+      this.tableSelectData = val
+      let obj = this.tableSelectData.map(e=>{
+        return {
+          "sa_salesforecastid":0,
+          "itemid":e.itemid,
+          "itemclassnum":'',
+          "orderqty": 1,
+          "orderamount": e.marketprice,
+          "invoiceqty": 1,
+          "invoiceamount": e.marketprice,
+          "outqty": 1,
+          "outamount": e.marketprice
+        }
+      })
+      this.selectData = obj
+      console.log(this.selectData)
+    },
+    /*批量添加产品*/
+    async onSubmit(){
+      const res = await this.$api.requested({
+        "id": 20220906155003,
+        "content": {
+          "sa_salesforecastmodelid":this.mainData.sa_salesforecastmodelid,
+          "sa_salesforecastbillid":this.$route.query.id,
+          "sa_projectid":this.id,
+          "itemclassinfos": this.selectData
+        }
+      })
+      this.tool.showMessage(res,()=>{
+        this.$emit('onSuccess')
+        this.listData()
+        this.selectListData()
+      })
+    },
+    /*已选产品*/
+    async selectListData(){
+      const res = await this.$api.requested({
+        "id": 20220906154703,
+        "content": {
+          "sa_salesforecastbillid":this.$route.query.id,
+          "where":{
+            "sa_projectid":'',
+            "condition":""
+          }
+        }
       })
+      this.selectTotal = res.total
     }
   },
   mounted () {