Browse Source

Merge branch 'greenUrgent' into mergeBranch

qymljy 8 months ago
parent
commit
8fde341e6d

+ 2 - 2
src/HDrpManagement/collectionRule/modules/table.vue

@@ -89,7 +89,7 @@
             <template slot-scope="scope">
               <div v-if="scope.row.accountingnodes">
                 <div v-if="scope.row.accountingnodes.logisticscheck">
-                  <indexNew :data="scope.row.accountingnodes.logisticscheck"></indexNew>
+                  <indexNew :data="scope.row.accountingnodes.logisticscheck" name="isused"></indexNew>
                 </div>
                 <div v-else>--</div>
               </div>
@@ -150,7 +150,7 @@
             <template slot-scope="scope">
               <div v-if="scope.row.accountingnodes">
                 <div v-if="scope.row.accountingnodes.invoiceapplycheck">
-                  <indexNew :data="scope.row.accountingnodes.invoiceapplycheck"></indexNew>
+                  <indexNew :data="scope.row.accountingnodes.invoiceapplycheck" name="isused"></indexNew>
                 </div>
                 <div v-else>--</div>
               </div>

+ 263 - 0
src/HDrpManagement/contractManage/components/contactList/addContact.vue

@@ -0,0 +1,263 @@
+<template>
+  <div>
+    <el-button size="small" type="primary" @click="addBtn(drawerFormVisible = true)">添加</el-button>
+    <el-drawer
+        title="添加联系人"
+        :visible.sync="drawerFormVisible"
+        size="600px"
+        direction="rtl"
+        :show-close="false"
+        append-to-body
+        @close="onClose">
+      <div class="drawer__panel">
+        <el-row :gutter="20">
+          <el-form :model="form" :rules="rules"  ref="form"  size="mini" label-position="right" label-width="90px">
+            <el-col :span="24">
+              <el-form-item  label="姓名:" prop="name">
+                <contactsNewTemplate ref="contactRef" ownertable="sys_enterprise" :isParam="true" :newParam="param" @contactData="contactData" ></contactsNewTemplate>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item >
+                <el-radio v-model="form.isTelephone" label="0" disabled>手机号</el-radio>
+                <el-radio v-model="form.isTelephone" label="1" disabled>座机电话</el-radio>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24" v-if="form.isTelephone == '1'">
+              <el-form-item label="联系方式:" prop="telephone" >
+                <el-input v-model="form.areaCode" style="width: 25%" autocomplete="on" placeholder="请填写区号" disabled></el-input>
+                <span style="color: #999999">——</span>
+                <el-input v-model="form.telephone" style="width: 68%" autocomplete="on" placeholder="请填写座机电话" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24"  >
+              <el-form-item v-if="form.isTelephone == '0'" label="联系方式:" prop="phonenumber" :rules="[
+              { required: true, message: '手机号码不能为空'},
+              { pattern:/^1[3-9][0-9]\d{8}$/, message: '请输入正确手机号码',trigger: 'change' }
+            ]">
+                <el-input v-model="form.phonenumber" autocomplete="on" placeholder="请填写手机号码" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item  label="微信:" prop="wechatnum" >
+                <el-input  autosize v-model="form.wechatnum" placeholder="请输入微信" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item   label="邮箱:" :rules="[
+              { pattern:/^[A-Za-z0-9\u4e00-\u9fa5]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/, message: '请输入有效的邮箱',trigger: 'change' }
+            ]">
+                <el-input   autosize v-model="form.email" placeholder="请输入邮箱" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item  label="传真:" >
+                <el-input  autosize v-model="form.fax" placeholder="请输入传真" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item  label="关联企业:" >
+                <el-input  autosize v-model="form.enterprisename" placeholder="请输入关联企业" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item  label="部门:" prop="depname" >
+                <el-input  autosize v-model="form.depname" placeholder="请输入部门" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item  label="职位:" prop="position">
+                <el-input  autosize v-model="form.position" placeholder="请输入职位" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item  label="性别:" >
+                <el-radio v-model="form.sex" label="男" disabled>男</el-radio>
+                <el-radio v-model="form.sex" label="女" disabled>女</el-radio>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item  label="生日:" >
+                <el-date-picker
+                    disabled
+                    v-model="form.birthday"
+                    value-format="yyyy-MM-dd"
+                    type="date"
+                    placeholder="选择日期"
+                    style="width: 100%"
+                >
+                </el-date-picker>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item  label="家庭住址:" >
+                <el-input type="textarea" rows="5" v-model="form.address" placeholder="请输入家庭住址" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item label="偏好" prop="preference" >
+                <el-input v-model="form.preference" autocomplete="on" placeholder="请填写偏好" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item label="爱好" prop="hobby" >
+                <el-input v-model="form.hobby" autocomplete="on" placeholder="请填写爱好" disabled></el-input>
+              </el-form-item>
+            </el-col>
+            <el-col :span="24">
+              <el-form-item  label="备注:" >
+                <el-input type="textarea"  rows="5" v-model="form.remarks" placeholder="请输入备注" disabled></el-input>
+              </el-form-item>
+            </el-col>
+          </el-form>
+        </el-row>
+      </div>
+      <div class="fixed__btn__panel">
+        <el-button size="small" @click="onClose" class="normal-btn-width" :disabled="loading">取 消</el-button>
+        <el-button size="small" type="primary" :loading="loading"  @click="onSubmit" class="normal-btn-width">确 定</el-button>
+      </div>
+    </el-drawer>
+  </div>
+</template>
+
+<script>
+import contactsNewTemplate from '@/template/contactsNewTemplate/index'
+export default {
+  name: "addContact",
+  components:{contactsNewTemplate},
+  props:['data'],
+  data(){
+    var validateMobilePhone = (rule, value, callback) => {
+      if (value === '') {
+        callback(new Error('手机号不可为空'));
+      } else {
+        if (value !== '') {
+          var reg=/^1[3456789]\d{9}$/;
+          if(!reg.test(value)){
+            callback(new Error('请输入有效的手机号码'));
+          }
+        }
+        callback();
+      }
+    };
+    var telephone = (rule,value,callback) =>{
+      if (this.form.areaCode === '' && this.form.telephone === ''){
+        callback(new Error('座机电话不能为空'))
+      } else  {
+        var reg=/^0\d{2,3}-\d{7,8}$/
+        let telephone = this.form.areaCode + '-' + this.form.telephone
+        if (!reg.test(telephone)){
+          callback(new Error('请输入正确座机电话'))
+        } else {
+          callback();
+        }
+      }
+
+    }
+    return {
+      drawerFormVisible:false,
+      loading:false,
+      form:{
+        contactsid: 0,
+        sys_enterpriseid: "",
+        name: "",
+        sex: "",
+        depname: "",
+        position: "",
+        birthday: "",
+        phonenumber: "",
+        email: "",
+        address: "",
+        remarks: "",
+        enterprisename:'',
+        province: "",
+        city: "",
+        county: "",
+        workaddress: 0,
+        isdefault: 1,
+        isprimary: 1,
+        sys_phonebookid:'',
+        telephone:'',
+        fax:'',
+        ownerid: this.$route.query.id,
+        ownertable: "sa_customers",
+        isTelephone:'0',
+        areaCode:'',
+        company:''
+      },
+      rules:{
+        name: [
+          { required: true, message: '姓名不能为空', trigger: 'change' },
+        ],
+        telephone:[
+          { required: true, validator: telephone, trigger: 'change' }
+        ],
+        depname: [
+          { required: true, message: '部门不能为空', trigger: 'blur' },
+        ],
+        position: [
+          { required: true, message: '职位不能为空', trigger: 'blur' },
+        ],
+      },
+      param:{
+        "id": 20240923153304,
+        "content": {
+          "sa_contractid": this.$route.query.id,
+          "pageNumber": 1,
+          "pageSize": 20,
+          "where": {
+            "condition": ""
+          }
+        }
+      }
+    }
+  },
+  methods:{
+    addBtn(){
+      this.$refs.form.clearValidate()
+    },
+    onSubmit(){
+      this.$refs.form.validate(async(valid)=>{
+        if (!valid) return false
+        this.loading = true
+        const res = await this.$api.requested({
+          "id": 20240923153004,
+          "content": {
+            "sa_contractid": this.$route.query.id,
+            "sys_phonebookid": this.form.sys_phonebookid
+          }
+        })
+        this.loading = false
+        this.tool.showMessage(res,()=>{
+          this.$emit('addSuccess')
+          this.onClose()
+        })
+      })
+    },
+    onClose(){
+      this.drawerFormVisible = false
+      this.form = {}
+      this.$refs.contactRef.nameValue = ''
+    },
+    contactData(val){
+      this.form = Object.assign({},this.form,val)
+      this.form.name = val.name
+      if (val.phonenumber.indexOf('-') != '-1'){
+        this.form.isTelephone = '1'
+        this.form.areaCode = val.phonenumber.substring(0,val.phonenumber.indexOf('-'))
+        this.form.telephone = val.phonenumber.substring(this.form.areaCode.length+1)
+        this.form.phonenumber = ''
+      }else {
+        this.form.isTelephone = '0'
+        this.form.phonenumber = val.phonenumber
+        this.form.areaCode = ''
+        this.form.telephone = ''
+      }
+    },
+  }
+}
+</script>
+
+<style scoped>
+
+</style>

+ 118 - 0
src/HDrpManagement/contractManage/components/contactList/index.vue

@@ -0,0 +1,118 @@
+<template>
+  <div>
+    <addContact class="inline-16" @addSuccess="listData(param.content.pageNumber = 1)"></addContact>
+    <el-input style="width:200px;" placeholder="输入搜索内容" :suffix-icon="param.content.where.condition?param.content.where.condition.length > 0?'':'':'el-icon-search'" v-model="param.content.where.condition" @keyup.native.enter="listData(param.content.pageNumber = 1)" @clear="listData(param.content.pageNumber = 1)" size="small" class="mt-10 input-with-select inline-16 layout_search__panel" clearable>
+    </el-input>
+    <table-detail  :layout="tablecols" :data="list" :custom="true" :width="true" :height="tableHieght" minHeight="200px" fixedName="operation">
+      <template v-slot:customcol="scope">
+        <div v-if="scope.column.columnname === 'tag'">
+          <div v-if="scope.column.data.tag.length > 0">
+            <el-tag v-for="item in scope.column.data.tag" :key="item.index" color="#FA8C16" size="mini" type="warning" effect="dark" style="margin-right: 5px">
+              <span>{{item}}</span>
+            </el-tag>
+          </div>
+          <div v-else>--</div>
+        </div>
+        <div v-else>
+          {{ scope.column.data[[scope.column.columnname]] || scope.column.columnname === 'operation' ? scope.column.data[[scope.column.columnname]] : '--' }}
+        </div>
+      </template>
+      <template v-slot:opreation="scope">
+        <el-button type="text" @click="delClick(scope.data)" size="mini">删除</el-button>
+      </template>
+    </table-detail>
+    <div  class="container normal-panel" style="text-align:right;padding-bottom: 0!important;">
+      <el-pagination
+          background
+          @size-change="handleSizeChange"
+          @current-change="handleCurrentChange"
+          :current-page="currentPage"
+          :page-sizes="[50, 100, 150, 200]"
+          :page-size="50"
+          layout="total,sizes, prev, pager, next, jumper"
+          :total="total">
+      </el-pagination>
+    </div>
+  </div>
+</template>
+
+<script>
+import addContact from './addContact'
+export default {
+  name: "index",
+  components:{addContact},
+  props:['data'],
+  data(){
+    return {
+      tableHieght:'calc(100vh - 380px)',
+      tablecols:[],
+      list:[],
+      currentPage:0,
+      total:0,
+      param:{
+        "id": 20240923153204,
+        "content": {
+          "sa_contractid": "",
+          "pageNumber": 1,
+          "pageSize": 50,
+          "where": {
+            "condition": ""
+          }
+        }
+      }
+    }
+  },
+  methods:{
+    async listData(){
+      this.param.content.sa_contractid = this.$route.query.id
+      const res = await this.$api.requested(this.param)
+      this.list = res.data
+      this.total = res.total
+      this.currentPage = res.pageNumber
+    },
+    handleSizeChange(val) {
+      // console.log(`每页 ${val} 条`);
+      this.param.content.pageSize = val
+      this.listData()
+    },
+    handleCurrentChange(val) {
+      // console.log(`当前页: ${val}`);
+      this.param.content.pageNumber = val
+      this.listData()
+    },
+    delClick(data){
+      this.$confirm('确定删除该联系人吗?', '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning'
+      }).then(async() => {
+        const res = await this.$api.requested({
+          "id": 20240923153104,
+          "content": {
+            "sa_contractid": this.$route.query.id,
+            "sys_phonebookid": data.sys_phonebookid
+          }
+        })
+        this.tool.showMessage(res,()=>{
+          this.listData()
+        })
+      }).catch(() => {
+        this.$message({
+          type: 'info',
+          message: '已取消删除'
+        });
+      });
+    }
+  },
+  mounted() {
+    this.listData()
+  },
+  created() {
+    this.tablecols = this.tool.tabelCol(this.$route.name).contactsTable.tablecols
+  }
+}
+</script>
+
+<style scoped>
+
+</style>

+ 57 - 31
src/HDrpManagement/contractManage/components/priceDifference/addPriceDiff.vue

@@ -27,7 +27,7 @@
                   <selectAgentNew ref="member" type="22" :param="agentListPrams" :radio="true" @onSelect="centerChange" @onCancel="agentVisible = false" ></selectAgentNew>
                   <el-input readonly type="text" slot="reference" size="small" @focus="showChange('agentVisible')" v-model="ascription.enterprisename" placeholder="请选择居间商" >
                     <template slot="append">
-                      <el-button size="small" @click="agentVisible = false;ascription.enterprisename = '';agentListPrams.content.where.condition = '';$refs.member.selected = []" style="width:100%" type="primary">清空</el-button>
+                      <el-button size="small" @click="agentVisible = false;ascription.enterprisename = '';agentListPrams.content.where.condition = '';$refs.member.selected = [];form.sys_enterpriseid = ''" style="width:100%" type="primary">清空</el-button>
                     </template>
                   </el-input>
                 </el-popover>
@@ -97,7 +97,7 @@
         <span style="margin-left: 20px">调整后提成:<span style="color: red;margin-left: 10px">{{totaladjustrewardamount == 0?'¥ '+tool.formatAmount(0,2):'¥ '+tool.formatAmount(totaladjustrewardamount,2)}}</span></span>
         <span style="margin-left: 20px">差额:<span style="color: red;margin-left: 10px">{{totalsubamount == 0?'¥ '+tool.formatAmount(0,2):'¥ '+tool.formatAmount(totalsubamount,2)}}</span></span>
       </div>
-      <table-detail :layout="adjustTable" :data="adjustList" :custom="true" :width="true" :height="tableHieght">
+      <table-detail :layout="adjustTable" :data="adjustList" :custom="true" :width="true" :height="tableHieght" min-height="200px">
         <template v-slot:customcol="scope" >
           <div v-if="scope.column.columnname == 'rewardamount'">
             {{scope.column.data[[scope.column.columnname]]?tool.formatAmount(scope.column.data[[scope.column.columnname]],2):scope.column.data[[scope.column.columnname]] == 0?'0.00':'--'}}
@@ -115,7 +115,7 @@
       </table-detail>
       <span slot="footer" class="dialog-footer">
         <el-button @click="adjustCancel" class="normal-btn-width" size="small" :disabled="adjustLoading" >取消</el-button>
-        <el-button type="primary" @click="adjustClick" class="normal-btn-width" size="small" :loading="adjustLoading">确定调整</el-button>
+        <el-button type="primary" @click="adjustClick" class="normal-btn-width" size="small" :loading="adjustLoading">{{checkTitle?checkTitle:'确定调整'}}</el-button>
       </span>
     </el-dialog>
   </div>
@@ -125,7 +125,7 @@
 import selectAgentNew from '../selectAgentNew.vue'
 export default {
   name: "addPriceDiff",
-  props:["data"],
+  props:["data",'isCheck','checkTitle'],
   components:{selectAgentNew},
   data(){
     return {
@@ -185,7 +185,7 @@ export default {
         "content": {
           "sa_contractid": "0",
           "orderratio": "",
-          "isadd": true, //新建时请求确认列表传true
+          "type": 0, //新建时请求确认列表传true
           "ascription_contractid": "",// 来源合同id
           "pageNumber": 1,
           "pageSize": 20,
@@ -206,7 +206,8 @@ export default {
   },
   methods:{
     addBtn(){
-      this.form.title = this.data.enterprisename + '/' + this.data.title + '_居间费'
+      this.title = '新建居间协议'
+      this.form.title = this.$route.query.type == '经销项目' || this.$route.query.type == '直销项目'?this.data.projectname + '_居间费': this.data.enterprisename + '_居间费'
       this.form.ascription_contractid = this.data.sa_contractid
       this.form.sa_projectid = this.data.sa_projectid
       this.form.saler_hrid = this.data.saler_hrid
@@ -234,6 +235,7 @@ export default {
       this.form.begdate = this.data.begdate
       this.form.enddate = this.data.enddate
       this.form.signdate = this.data.signdate
+      this.form.remarks = data.remarks
       this.ascription = {
         "ascription_title":this.data.title,
         "enterprisename":data.sys_enterpriseid == -1  ? '':data.enterprisename,
@@ -246,27 +248,37 @@ export default {
     },
     onSubmit(){
       this.$refs.form.validate(async (valid)=>{
-        this.loading = true
         if (!valid) return false
-        this.form.orderratio = (this.form.orderratio / 100).toFixed(4)
-        let res = await this.$api.requested({
-          "id": 20221121185302,
-          "content": this.form
-        })
-        if (res.code == 0){
-          this.form.orderratio = this.form.orderratio * 100
+        if (this.title == '编辑居间协议'){
           this.loading = false
-        }else {
           this.dialogTableVisible = true
-          this.onAdjust(res.data)
+          this.onAdjust(this.form)
+        }else {
+          this.loading = true
+          this.form.orderratio = (this.form.orderratio / 100).toFixed(4)
+          let res = await this.$api.requested({
+            "id": 20221121185302,
+            "content": this.form
+          })
+          if (res.code == 0){
+            this.form.orderratio = Math.round((this.form.orderratio * 100)*100)/100
+            this.loading = false
+            this.tool.showMessage(res,()=>{
+
+            })
+          }else {
+            this.dialogTableVisible = true
+            this.onAdjust(res.data)
+          }
         }
       })
     },
     async onAdjust(data){
       this.adjustParam.content.sa_contractid = data.sa_contractid
-      this.adjustParam.content.orderratio = data.orderratio
+      this.adjustParam.content.orderratio = this.title == '编辑居间协议'?(data.orderratio / 100).toFixed(4):data.orderratio
       this.adjustParam.content.ascription_contractid = data.ascription_contractid
       this.sys_enterpriseid = this.form.sys_enterpriseid?this.form.sys_enterpriseid:data.sys_enterpriseid
+      this.adjustParam.content.type = this.isCheck? 2 : this.title == '新建居间协议' ? 0 : 1
       const res = await this.$api.requested(this.adjustParam)
       this.adjustList = res.data
       this.adjustTotal = res.total
@@ -286,28 +298,42 @@ export default {
     },
     onClose(){
       this.drawerFormVisible = false
+      this.adjustLoading = false
       this.form.orderratio = ''
       this.$refs.form.resetFields()
       this.form.remarks = ''
+      this.$emit('adjustSuccess')
     },
     async adjustClick(){
-      this.adjustLoading = true
-      const res = await this.$api.requested({
-        "id": "20240828163204",
-        "content": {
-          "sa_contractid": this.adjustParam.content.sa_contractid,
-          "orderratio": this.adjustParam.content.orderratio,
-          "sys_enterpriseid":this.sys_enterpriseid,
-          "remarks":""
-        }
-      })
-      this.tool.showMessage(res,()=>{
-        this.adjustLoading = false
-        this.loading = false
+      if (this.isCheck){
+        this.adjustLoading = true
         this.drawerFormVisible = false
         this.dialogTableVisible = false
         this.$emit('adjustSuccess')
-      })
+      }else {
+        this.adjustLoading = true
+        const res = await this.$api.requested({
+          "id": "20240828163204",
+          "content": {
+            "sa_contractid": this.adjustParam.content.sa_contractid,
+            "orderratio": this.adjustParam.content.orderratio,
+            "sys_enterpriseid":this.sys_enterpriseid,
+            "remarks":this.form.remarks,
+            "title":this.form.title
+          }
+        })
+        if (res.code == 0){
+          this.adjustLoading = false
+          this.tool.showMessage(res,()=>{})
+        }
+        this.tool.showMessage(res,()=>{
+          this.adjustLoading = false
+          this.loading = false
+          this.drawerFormVisible = false
+          this.dialogTableVisible = false
+        })
+      }
+
     },
     adjustCancel(){
       this.adjustLoading = false

+ 9 - 3
src/HDrpManagement/contractManage/components/priceDifference/index.vue

@@ -2,8 +2,8 @@
   <div>
     <el-input style="width:200px;" placeholder="输入搜索内容" :suffix-icon="param.content.where.condition?param.content.where.condition.length > 0?'':'':'el-icon-search'" v-model="param.content.where.condition" @keyup.native.enter="listData(param.content.pageNumber = 1)" @clear="listData(param.content.pageNumber = 1)" size="small" class="mt-10 input-with-select inline-16 layout_search__panel" clearable>
     </el-input>
-    <addPriceDiff ref="priceDiff" class="inline-16" :data="data" @adjustSuccess="adjustSuccess"></addPriceDiff>
-    <table-detail  :layout="tablecols" :data="list" :custom="true" :width="true" :height="tableHieght">
+    <addPriceDiff ref="priceDiff" class="inline-16" :data="data" :isCheck="isCheck" @adjustSuccess="adjustSuccess" :checkTitle="checkTitle"></addPriceDiff>
+    <table-detail  :layout="tablecols" :data="list" :custom="true" :width="true" :height="tableHieght" minHeight="200px">
       <template v-slot:customcol="scope" >
         <div v-if="scope.column.columnname == 'orderratio'">
           {{scope.column.data[[scope.column.columnname]]?Math.round((scope.column.data[[scope.column.columnname]] * 100)*100)/100 + '%':scope.column.data[[scope.column.columnname]] == 0?'0%':'--'}}
@@ -14,6 +14,12 @@
         <div v-else-if="scope.column.columnname == 'rebate'" style="color: red">
           {{scope.column.data[[scope.column.columnname]]?tool.formatAmount(scope.column.data[[scope.column.columnname]],2):scope.column.data[[scope.column.columnname]] == 0?'0.00':'--'}}
         </div>
+        <div v-else-if="scope.column.columnname == 'status'">
+          <span style="color:#3874f6" v-if="scope.column.data[[scope.column.columnname]] == '新建'">{{scope.column.data[[scope.column.columnname]]}}</span>
+          <span style="color:#52c41a" v-else-if="scope.column.data[[scope.column.columnname]] == '已提交'">{{scope.column.data[[scope.column.columnname]]}}</span>
+          <span style="color:#333333" v-else-if="scope.column.data[[scope.column.columnname]] == '审核'">{{scope.column.data[[scope.column.columnname]]}}</span>
+          <span style="color:#000000" v-else>{{scope.column.data[[scope.column.columnname]]}}</span>
+        </div>
         <div v-else>
           {{ scope.column.data[[scope.column.columnname]] || scope.column.columnname === 'operation' ? scope.column.data[[scope.column.columnname]] : '--' }}
         </div>
@@ -42,7 +48,7 @@
 import addPriceDiff from "./addPriceDiff"
 export default {
   name: "index",
-  props:["data"],
+  props:["data","isCheck","checkTitle"],
   components:{addPriceDiff},
   data(){
     return {

+ 6 - 1
src/HDrpManagement/contractManage/components/reverseCheck.vue

@@ -1,7 +1,7 @@
 <template>
   <div>
     <el-button size="mini" @click="submit" type="primary">反 审 核 </el-button>
-    <adjust v-show="false" ref="adjustRef" @adjustSuccess="onCheck"></adjust>
+    <adjust v-show="false" :isCheck="true" ref="adjustRef" @adjustSuccess="onCheck" checkTitle="确定反审核"></adjust>
   </div>
 </template>
 
@@ -44,7 +44,12 @@ export default {
           "sa_contractid": this.data.sa_contractid
         },
       })
+      if (res.code == 0){
+        this.$refs.adjustRef.$refs.priceDiff.adjustLoading = false
+        this.tool.showMessage(res,()=>{})
+      }
       this.tool.showMessage(res,() => {
+        this.$refs.adjustRef.$refs.priceDiff.adjustLoading = false
         this.$emit('onSuccess')
       })
     }

+ 6 - 1
src/HDrpManagement/contractManage/components/submitCheck.vue

@@ -2,7 +2,7 @@
   <div >
     <el-button  @click="submit" size="mini" slot="reference" type="primary" :disabled="data.status == '已过期'" v-if="data.status=='新建' && tool.checkAuth($route.name,'submit') && !disabled && data.status">提 交</el-button>
     <el-button @click="submit" size="mini" slot="reference" type="primary" v-if="data.status=='已提交' && tool.checkAuth($route.name,'check') && data.status">审 核</el-button>
-    <adjust v-show="false" ref="adjustRef" @adjustSuccess="onCheck"></adjust>
+    <adjust v-show="false" ref="adjustRef" @adjustSuccess="onCheck" :isCheck="true" checkTitle="确定审核"></adjust>
   </div>
 </template>
 
@@ -107,7 +107,12 @@ export default {
           "sa_contractid": this.data.sa_contractid
         },
       })
+      if (res.code == 0){
+        this.tool.showMessage(res,()=>{})
+        this.$refs.adjustRef.$refs.priceDiff.adjustLoading = false
+      }
       this.tool.showMessage(res,() => {
+        this.$refs.adjustRef.$refs.priceDiff.adjustLoading = false
         this.$emit('onSuccess')
       })
     }

+ 191 - 121
src/HDrpManagement/contractManage/modules/detail.vue

@@ -33,160 +33,228 @@
         <Del class="inline-16" :idName="20221121202502" :id="mainData.sa_contractid" idKey="sa_contractids"  v-if="tool.checkAuth($route.name,'toVoid') && (mainData.status == '新建' || mainData.status == '已终止' || mainData.status == '已过期') && isLeader"/>
       </div>
       <div slot="slot0" >
-        <!--项目产品明细折扣表-->
-        <productBillno :data="mainData" :isLeader="isLeader" ref="billno" @priceChange="queryMainData($route.query.id)" @delSuccess="queryMainData" @onSuccess="productAdd" v-if="mainData.type == '项目'">
-          <template v-slot:edit="scope">
-          </template>
-          <template v-slot:del="scope">
-          </template>
-          <template v-slot:cooperate="scope">
-            <el-button :disabled="mainData.status !== '新建'" size="small" :type="mainData.status === '新建'?'primary':''" @click="cooperateVisible = true" v-if="tool.checkAuth($route.name,'productBillManage') && isLeader">同步合作协议</el-button>
-            <el-dialog title="同步合作协议" :visible.sync="cooperateVisible" append-to-body width="703px">
-              <span style="color: #8C8C8C;font-size: 14px">请选择同步更新经销商/直销客户合作协议产品的方式:</span>
-              <el-form :model="cooperateForm" style="margin-top: 20px">
-                <el-radio v-model="cooperateForm.isadd" label="1" style="margin-bottom: 20px">
-                  <span style="font-size: 16px;color: #333333">同步添加合作协议产品</span><br><br>
-                  <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
+        <div v-if="mainData.type == '项目'">
+          <!--项目产品明细折扣表-->
+          <productBillno :data="mainData" :isLeader="isLeader" ref="billno" @priceChange="queryMainData($route.query.id)" @delSuccess="queryMainData" @onSuccess="productAdd" >
+            <template v-slot:edit="scope">
+            </template>
+            <template v-slot:del="scope">
+            </template>
+            <template v-slot:cooperate="scope">
+              <el-button :disabled="mainData.status !== '新建'" size="small" :type="mainData.status === '新建'?'primary':''" @click="cooperateVisible = true" v-if="tool.checkAuth($route.name,'productBillManage') && isLeader">同步合作协议</el-button>
+              <el-dialog title="同步合作协议" :visible.sync="cooperateVisible" append-to-body width="703px">
+                <span style="color: #8C8C8C;font-size: 14px">请选择同步更新经销商/直销客户合作协议产品的方式:</span>
+                <el-form :model="cooperateForm" style="margin-top: 20px">
+                  <el-radio v-model="cooperateForm.isadd" label="1" style="margin-bottom: 20px">
+                    <span style="font-size: 16px;color: #333333">同步添加合作协议产品</span><br><br>
+                    <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
                     将协议中所有产品添加到表体,若表体已存在产品,则协议中相同产品的信息及其折扣价格覆盖更新
                   </span><br><br>
-                  <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
+                    <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
                     到表体。
                   </span> <br><br>
-                </el-radio>
+                  </el-radio>
 
-                <el-radio v-model="cooperateForm.isadd" label="0">
-                  <span style="font-size: 16px;color: #333333">仅更新合作协议的产品折扣价格</span><br><br>
-                  <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
+                  <el-radio v-model="cooperateForm.isadd" label="0">
+                    <span style="font-size: 16px;color: #333333">仅更新合作协议的产品折扣价格</span><br><br>
+                    <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
                    将协议中与表体相同的产品信息及其折扣价格覆盖更新到表体,不添加协议产品。
                   </span>
-                </el-radio>
-              </el-form>
-              <div slot="footer" class="dialog-footer">
-                <el-button size="small" @click="cooperateVisible = false" class="normal-btn-width">取 消</el-button>
-                <el-button size="small" type="primary" @click="onCooperate" class="normal-btn-width">确 定</el-button>
-              </div>
-            </el-dialog>
-          </template>
-        </productBillno>
-        <!--产品明细折扣表-->
-        <productDetailList :data="mainData" :isLeader="isLeader" ref="productDetailList" v-if="mainData.type == '框架' || mainData.type == '直销' || (mainData.type == '居间' && siteid !== 'HY')"  @priceChange="queryMainData($route.query.id)" @closeDrawer="queryMainData($route.query.id)">
-          <importFile
-            v-if="tool.checkAuth($route.name,'exportProduct') && isLeader && mainData.status === '新建'"
-            slot="export"
-            ref="importFile"
-            class="inline-16"
-            :bindData="{ownertable:'sa_contract',ownerid:$route.query.id,usetype:'default'}"
-            :errorUrl="errorUrl"
-            @clearUrl="errorUrl = null"
-            @onSuccess="bindImportOrder"
-          ></importFile>
-          <template v-slot:cooperate="scope">
-            <el-button class="inline-16" :disabled="mainData.status !== '新建'" size="small" :type="mainData.status === '新建'?'primary':''" @click="cooperateVisible = true" v-if="tool.checkAuth($route.name,'productDetailManage') && isLeader && mainData.type == '居间'">同步协议</el-button>
-            <el-dialog title="同步协议" :visible.sync="cooperateVisible" append-to-body width="703px" center>
+                  </el-radio>
+                </el-form>
+                <div slot="footer" class="dialog-footer">
+                  <el-button size="small" @click="cooperateVisible = false" class="normal-btn-width">取 消</el-button>
+                  <el-button size="small" type="primary" @click="onCooperate" class="normal-btn-width">确 定</el-button>
+                </div>
+              </el-dialog>
+            </template>
+          </productBillno>
+        </div>
+        <div v-if="mainData.type == '框架' || mainData.type == '直销' ">
+          <!--产品明细折扣表-->
+          <productDetailList :data="mainData" :isLeader="isLeader" ref="productDetailList"   @priceChange="queryMainData($route.query.id)" @closeDrawer="queryMainData($route.query.id)">
+            <importFile
+                v-if="tool.checkAuth($route.name,'exportProduct') && isLeader && mainData.status === '新建'"
+                slot="export"
+                ref="importFile"
+                class="inline-16"
+                :bindData="{ownertable:'sa_contract',ownerid:$route.query.id,usetype:'default'}"
+                :errorUrl="errorUrl"
+                @clearUrl="errorUrl = null"
+                @onSuccess="bindImportOrder"
+            ></importFile>
+            <template v-slot:cooperate="scope">
+              <el-button class="inline-16" :disabled="mainData.status !== '新建'" size="small" :type="mainData.status === '新建'?'primary':''" @click="cooperateVisible = true" v-if="tool.checkAuth($route.name,'productDetailManage') && isLeader && mainData.type == '居间'">同步协议</el-button>
+              <el-dialog title="同步协议" :visible.sync="cooperateVisible" append-to-body width="703px" center>
+              <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
+                是否添加关联的项目或客户合同中的产品明细同步更新到列表
+              </span>
+                <div slot="footer" class="dialog-footer">
+                  <el-button size="small" @click="cooperateVisible = false" class="normal-btn-width">取 消</el-button>
+                  <el-button size="small" type="primary" @click="onCooperate" class="normal-btn-width">确 定</el-button>
+                </div>
+              </el-dialog>
+            </template>
+          </productDetailList>
+        </div>
+        <div v-if="mainData.type == '居间'">
+          <!--  详细信息      -->
+          <BaseInfo v-if="siteid === 'HY'" :detailInfo="detailInfo"/>
+          <!--产品明细折扣表-->
+          <productDetailList v-else :data="mainData" :isLeader="isLeader" ref="productDetailList"   @priceChange="queryMainData($route.query.id)" @closeDrawer="queryMainData($route.query.id)">
+            <importFile
+                v-if="tool.checkAuth($route.name,'exportProduct') && isLeader && mainData.status === '新建'"
+                slot="export"
+                ref="importFile"
+                class="inline-16"
+                :bindData="{ownertable:'sa_contract',ownerid:$route.query.id,usetype:'default'}"
+                :errorUrl="errorUrl"
+                @clearUrl="errorUrl = null"
+                @onSuccess="bindImportOrder"
+            ></importFile>
+            <template v-slot:cooperate="scope">
+              <el-button class="inline-16" :disabled="mainData.status !== '新建'" size="small" :type="mainData.status === '新建'?'primary':''" @click="cooperateVisible = true" v-if="tool.checkAuth($route.name,'productDetailManage') && isLeader && mainData.type == '居间'">同步协议</el-button>
+              <el-dialog title="同步协议" :visible.sync="cooperateVisible" append-to-body width="703px" center>
               <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
                 是否添加关联的项目或客户合同中的产品明细同步更新到列表
               </span>
-              <div slot="footer" class="dialog-footer">
-                <el-button size="small" @click="cooperateVisible = false" class="normal-btn-width">取 消</el-button>
-                <el-button size="small" type="primary" @click="onCooperate" class="normal-btn-width">确 定</el-button>
-              </div>
-            </el-dialog>
-          </template>
-        </productDetailList>
-        <!--工具清单-->
-        <toolList :data="mainData" :isLeader="isLeader" ref="toolList" v-if="mainData.type == '工具借用'" @priceChange="queryMainData($route.query.id)">
-          <template v-slot:edit="scope">
-          </template>
-        </toolList>
-        <!--  详细信息      -->
-        <BaseInfo v-if="mainData.type === '居间' && siteid === 'HY'" :detailInfo="detailInfo"/>
+                <div slot="footer" class="dialog-footer">
+                  <el-button size="small" @click="cooperateVisible = false" class="normal-btn-width">取 消</el-button>
+                  <el-button size="small" type="primary" @click="onCooperate" class="normal-btn-width">确 定</el-button>
+                </div>
+              </el-dialog>
+            </template>
+          </productDetailList>
+        </div>
+        <div v-if="mainData.type == '工具借用'">
+          <!--工具清单-->
+          <toolList :data="mainData" :isLeader="isLeader" ref="toolList" v-if="mainData.type == '工具借用'" @priceChange="queryMainData($route.query.id)">
+            <template v-slot:edit="scope">
+            </template>
+          </toolList>
+        </div>
+
       </div>
       <div slot="slot1" >
-        <!--产品类别折扣表-->
-        <productClassList :data="mainData" :isLeader="isLeader" ref="classList" @priceChange="queryMainData($route.query.id)" v-if="mainData.type == '框架' || mainData.type == '直销' || mainData.type == '居间'">
-          <addClass class="inline-16" v-if="tool.checkAuth($route.name,'productClassManage')" :disabled="mainData.status != '新建' || !isLeader" :typeName="mainData.type" slot="addProduct" @onSuccess="$refs.classList.listData()"   ref="addProduct" @closeDrawer="closeDrawer"/>
-          <template v-slot:edit="scope">
-          </template>
-          <template v-slot:cooperate="scope">
-            <el-button class="inline-16" :disabled="mainData.status !== '新建'" size="small" :type="mainData.status === '新建'?'primary':''" @click="cooperateVisible = true" v-if="tool.checkAuth($route.name,'productClassManage') && isLeader && mainData.type == '居间'">同步协议</el-button>
-            <el-dialog title="同步协议" :visible.sync="cooperateVisible" append-to-body width="703px" center>
+        <!--   居间     -->
+        <div v-if="mainData.type === '居间'">
+          <contactList v-if="siteid === 'HY' && mainData && tool.checkAuth($route.name,'contact')" :data="mainData"></contactList>
+          <productClassList v-else :data="mainData" :isLeader="isLeader" ref="classList" @priceChange="queryMainData($route.query.id)">
+            <addClass class="inline-16" v-if="tool.checkAuth($route.name,'productClassManage')" :disabled="mainData.status != '新建' || !isLeader" :typeName="mainData.type" slot="addProduct" @onSuccess="$refs.classList.listData()"   ref="addProduct" @closeDrawer="closeDrawer"/>
+            <template v-slot:edit="scope">
+            </template>
+            <template v-slot:cooperate="scope">
+              <el-button class="inline-16" :disabled="mainData.status !== '新建'" size="small" :type="mainData.status === '新建'?'primary':''" @click="cooperateVisible = true" v-if="tool.checkAuth($route.name,'productClassManage') && isLeader && mainData.type == '居间'">同步协议</el-button>
+              <el-dialog title="同步协议" :visible.sync="cooperateVisible" append-to-body width="703px" center>
+              <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
+                是否添加关联的项目或客户合同中的产品类别同步更新到列表
+              </span>
+                <div slot="footer" class="dialog-footer">
+                  <el-button size="small" @click="cooperateVisible = false" class="normal-btn-width">取 消</el-button>
+                  <el-button size="small" type="primary" @click="onCooperateItem" class="normal-btn-width">确 定</el-button>
+                </div>
+              </el-dialog>
+            </template>
+          </productClassList>
+        </div>
+        <div v-if="mainData.type == '框架' || mainData.type == '直销' ">
+          <!--产品类别折扣表-->
+          <productClassList :data="mainData" :isLeader="isLeader" ref="classList" @priceChange="queryMainData($route.query.id)" >
+            <addClass class="inline-16" v-if="tool.checkAuth($route.name,'productClassManage')" :disabled="mainData.status != '新建' || !isLeader" :typeName="mainData.type" slot="addProduct" @onSuccess="$refs.classList.listData()"   ref="addProduct" @closeDrawer="closeDrawer"/>
+            <template v-slot:edit="scope">
+            </template>
+            <template v-slot:cooperate="scope">
+              <el-button class="inline-16" :disabled="mainData.status !== '新建'" size="small" :type="mainData.status === '新建'?'primary':''" @click="cooperateVisible = true" v-if="tool.checkAuth($route.name,'productClassManage') && isLeader && mainData.type == '居间'">同步协议</el-button>
+              <el-dialog title="同步协议" :visible.sync="cooperateVisible" append-to-body width="703px" center>
               <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
                 是否添加关联的项目或客户合同中的产品类别同步更新到列表
               </span>
-              <div slot="footer" class="dialog-footer">
-                <el-button size="small" @click="cooperateVisible = false" class="normal-btn-width">取 消</el-button>
-                <el-button size="small" type="primary" @click="onCooperateItem" class="normal-btn-width">确 定</el-button>
-              </div>
-            </el-dialog>
-          </template>
-        </productClassList>
-        <!--    产品类别折扣    -->
-        <itemClass ref="itemClass" :data="mainData" v-if="mainData.type == '项目'" :isLeader="isLeader" >
-          <template v-slot:cooperate="scope">
-            <el-button :disabled="mainData.status !== '新建'" size="small" :type="mainData.status === '新建'?'primary':''" @click="cooperateVisible = true" v-if="tool.checkAuth($route.name,'productClassManage') && isLeader">同步合作协议</el-button>
-            <el-dialog title="同步合作协议" :visible.sync="cooperateVisible" append-to-body width="703px">
-              <span style="color: #8C8C8C;font-size: 14px">请选择同步更新经销商/直销客户合作协议产品类别的方式:</span>
-              <el-form :model="cooperateForm" style="margin-top: 20px">
-                <el-radio v-model="cooperateForm.isadd" label="1" style="margin-bottom: 20px">
-                  <span style="font-size: 16px;color: #333333">同步添加合作协议产品类别及其折扣</span><br><br>
-                  <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
+                <div slot="footer" class="dialog-footer">
+                  <el-button size="small" @click="cooperateVisible = false" class="normal-btn-width">取 消</el-button>
+                  <el-button size="small" type="primary" @click="onCooperateItem" class="normal-btn-width">确 定</el-button>
+                </div>
+              </el-dialog>
+            </template>
+          </productClassList>
+        </div>
+        <div v-if="mainData.type == '项目'">
+          <!--    产品类别折扣    -->
+          <itemClass ref="itemClass" :data="mainData"  :isLeader="isLeader" >
+            <template v-slot:cooperate="scope">
+              <el-button :disabled="mainData.status !== '新建'" size="small" :type="mainData.status === '新建'?'primary':''" @click="cooperateVisible = true" v-if="tool.checkAuth($route.name,'productClassManage') && isLeader">同步合作协议</el-button>
+              <el-dialog title="同步合作协议" :visible.sync="cooperateVisible" append-to-body width="703px">
+                <span style="color: #8C8C8C;font-size: 14px">请选择同步更新经销商/直销客户合作协议产品类别的方式:</span>
+                <el-form :model="cooperateForm" style="margin-top: 20px">
+                  <el-radio v-model="cooperateForm.isadd" label="1" style="margin-bottom: 20px">
+                    <span style="font-size: 16px;color: #333333">同步添加合作协议产品类别及其折扣</span><br><br>
+                    <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
                     将协议中所有产品类别及其折扣添加到表体,若表体已存在产品类别,则协议中相同产品类别的折扣
                   </span><br><br>
-                  <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
+                    <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
                     覆盖更新到表体。
                   </span> <br><br>
-                </el-radio>
+                  </el-radio>
 
-                <el-radio v-model="cooperateForm.isadd" label="0">
-                  <span style="font-size: 16px;color: #333333">仅更新合作协议的产品类别折扣</span><br><br>
-                  <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
+                  <el-radio v-model="cooperateForm.isadd" label="0">
+                    <span style="font-size: 16px;color: #333333">仅更新合作协议的产品类别折扣</span><br><br>
+                    <span style="font-size: 14px;color: #8C8C8C;margin: 20px 0 0 22px;padding-top: 20px">
                    将协议中与表体相同的产品类别的折扣价格覆盖更新到表体,不添加协议的产品类别。
                   </span>
-                </el-radio>
-              </el-form>
-              <div slot="footer" class="dialog-footer">
-                <el-button size="small" @click="cooperateVisible = false" class="normal-btn-width">取 消</el-button>
-                <el-button size="small" type="primary" @click="onCooperateItem" class="normal-btn-width">确 定</el-button>
-              </div>
-            </el-dialog>
-          </template>
-        </itemClass>
-        <BaseInfo v-if="mainData.type === '工具借用'" :detailInfo="detailInfo"/>
+                  </el-radio>
+                </el-form>
+                <div slot="footer" class="dialog-footer">
+                  <el-button size="small" @click="cooperateVisible = false" class="normal-btn-width">取 消</el-button>
+                  <el-button size="small" type="primary" @click="onCooperateItem" class="normal-btn-width">确 定</el-button>
+                </div>
+              </el-dialog>
+            </template>
+          </itemClass>
+        </div>
+        <div v-if="mainData.type === '工具借用'">
+          <BaseInfo :detailInfo="detailInfo"/>
+        </div>
       </div>
       <div slot="slot2">
-        <!--业绩目标-->
-        <taskTarget ref="taskTarget" v-if="Object.keys(mainData).length > 0 && (mainData.type == '框架' || mainData.type == '直销')" :data="mainData">
-          <template v-slot:addTarget="scope">
+        <div v-if="Object.keys(mainData).length > 0 && (mainData.type == '框架' || mainData.type == '直销')" >
+          <!--业绩目标-->
+          <taskTarget ref="taskTarget" :data="mainData">
+            <template v-slot:addTarget="scope">
               <add-target :disabled="mainData.status != '新建' || !isLeader" v-if="tool.checkAuth($route.name,'taskTargetManage')" :data="mainData" @onSuccess="successYear"></add-target>
-          </template>
-          <template v-slot:edit="scope">
-            <edit-target class="inline-16" :disabled="mainData.status != '新建' || !isLeader" v-if="tool.checkAuth($route.name,'taskTargetManage')" :data="scope.data" :salerId="mainData" @onSuccess="$refs.taskTarget.queryData()"/>
-          </template>
-          <template v-slot:delete="scope">
-            <del-target @onSuccess="$refs.taskTarget.queryData()" class="inline-16" :disabled="mainData.status != '新建' || !isLeader" v-if="tool.checkAuth($route.name,'taskTargetManage')" :id="scope.data.sa_salestargetbillid"></del-target>
-          </template>
-        </taskTarget>
-        <div>
+            </template>
+            <template v-slot:edit="scope">
+              <edit-target class="inline-16" :disabled="mainData.status != '新建' || !isLeader" v-if="tool.checkAuth($route.name,'taskTargetManage')" :data="scope.data" :salerId="mainData" @onSuccess="$refs.taskTarget.queryData()"/>
+            </template>
+            <template v-slot:delete="scope">
+              <del-target @onSuccess="$refs.taskTarget.queryData()" class="inline-16" :disabled="mainData.status != '新建' || !isLeader" v-if="tool.checkAuth($route.name,'taskTargetManage')" :id="scope.data.sa_salestargetbillid"></del-target>
+            </template>
+          </taskTarget>
+        </div>
+        <div v-if="mainData.type == '项目'">
           <!--   差价     -->
-          <priceDifference v-if="mainData.type == '项目' && siteid == 'HY' && tool.checkAuth($route.name,'brokerageFeeEntrySet')" :data="mainData"></priceDifference>
-
+          <priceDifference v-if="siteid == 'HY' && tool.checkAuth($route.name,'brokerageFeeEntrySet')" :data="mainData"></priceDifference>
           <!--   详细信息     -->
           <BaseInfo v-else :detailInfo="detailInfo"/>
         </div>
-
-        <!--   详细信息     -->
-        <BaseInfo v-if="(mainData.type !== '框架' && mainData.type !== '直销' && mainData.type !== '项目')" :detailInfo="detailInfo"/>
+        <div v-if="mainData.type == '居间'">
+          <BaseInfo v-if="siteid !== 'HY'" :detailInfo="detailInfo"/>
+        </div>
       </div>
       <div slot="slot3">
-        <BaseInfo v-if="mainData.type !== '居间' && mainData.type !== '框架' && mainData.type !== '直销' " :detailInfo="detailInfo"/>
-        <div>
-          <!--   差价     -->
-          <priceDifference v-if="(mainData.type == '框架' || mainData.type == '直销') && siteid == 'HY' && tool.checkAuth($route.name,'brokerageFeeEntrySet')" :data="mainData"></priceDifference>
+        <div  v-if="mainData.type === '居间' && siteid !== 'HY'">
+          <contactList v-if="mainData && tool.checkAuth($route.name,'contact')" :data="mainData"></contactList>
+        </div>
+        <div v-if="mainData.type == '框架' || mainData.type == '直销'">
+          <priceDifference v-if="siteid == 'HY' && tool.checkAuth($route.name,'brokerageFeeEntrySet')" :data="mainData"></priceDifference>
           <BaseInfo v-else :detailInfo="detailInfo"/>
         </div>
+        <div v-if="mainData.type == '项目'">
+          <BaseInfo :detailInfo="detailInfo"/>
+        </div>
       </div>
       <div slot="slot4">
-        <BaseInfo  :detailInfo="detailInfo"/>
+        <div v-if="mainData.type == '框架' || mainData.type == '直销'">
+          <BaseInfo  :detailInfo="detailInfo"/>
+        </div>
       </div>
     </basicDetails>
   </div>
@@ -217,6 +285,7 @@ import itemClass from '../components/itemClass/index.vue'
 import importFile from '../components/importFile'
 import copyTo from '../components/copyTo'
 import priceDifference from '../components/priceDifference/index'
+import contactList from '../components/contactList/index'
 import { Loading } from 'element-ui';
 export default {
   name: "detail",
@@ -262,7 +331,8 @@ export default {
     itemClass,
     importFile,
     copyTo,
-    priceDifference
+    priceDifference,
+    contactList
   },
   provide () {
     return {
@@ -323,7 +393,7 @@ export default {
           this.tabs = this.siteid == 'HY'?this.tool.checkAuth(this.$route.name,'brokerageFeeEntrySet')?['产品明细折扣','产品类别折扣','业绩目标','差价','详细信息']:['产品明细折扣','产品类别折扣','业绩目标','详细信息']:['产品明细折扣','产品类别折扣','业绩目标','详细信息']
               break
         case '居间':
-          this.tabs = this.siteid == 'HY'?['详细信息']:['产品明细折扣','产品类别折扣','详细信息']
+          this.tabs = this.siteid == 'HY'?this.tool.checkAuth(this.$route.name,'contact')?['详细信息','联系人']:['详细信息']:this.tool.checkAuth(this.$route.name,'contact')?['产品明细折扣','产品类别折扣','详细信息','联系人']:['产品明细折扣','产品类别折扣','详细信息']
               break
         case '直销':
           this.tabs = this.siteid == 'HY'?this.tool.checkAuth(this.$route.name,'brokerageFeeEntrySet')?['产品明细折扣','产品类别折扣','业绩目标','差价','详细信息']:['产品明细折扣','产品类别折扣','业绩目标','详细信息']:['产品明细折扣','产品类别折扣','业绩目标','详细信息']

+ 4 - 1
src/HDrpManagement/orderManage/details/tabs/rebatesettlement.vue

@@ -6,7 +6,7 @@
           <el-descriptions-item :labelStyle="{width:'120px'}" label="订单金额比例">{{item.orderratio}}</el-descriptions-item>
           <el-descriptions-item :labelStyle="{width:'120px'}" label="订单金额">{{item.amount?tool.formatAmount(item.amount,2):''}}</el-descriptions-item>
           <el-descriptions-item :labelStyle="{width:'120px'}" label="居间产品折扣">{{Math.round((item.productdiscount * 100)*100)/100 + '%'}}</el-descriptions-item>
-          <el-descriptions-item :labelStyle="{width:'120px'}" label="居间费">{{item.rebate}}</el-descriptions-item>
+          <el-descriptions-item :labelStyle="{width:'120px'}" label="居间费">{{tool.formatAmount(item.rebate,2)}}</el-descriptions-item>
           <el-descriptions-item :labelStyle="{width:'120px'}" label="结算经销商">{{item.enterprisename?item.enterprisename:'--'}}</el-descriptions-item>
         </el-descriptions>
         <table-new-layout :layout="tablecols" :data="tableData" :custom="true" :width="true" height="calc(100vh - 750px)" minHeight="400px">
@@ -14,6 +14,9 @@
             <div v-if="scope.column.columnname === 'price'">
               {{tool.formatAmount(scope.column.data[scope.column.columnname],2)}}
             </div>
+            <div v-else-if="scope.column.columnname === 'marketprice'">
+              {{tool.formatAmount(scope.column.data[scope.column.columnname],2)}}
+            </div>
             <div v-else-if="scope.column.columnname === 'amount'">
               {{tool.formatAmount(scope.column.data[scope.column.columnname],2)}}
             </div>

+ 4 - 4
src/HDrpManagement/rebatesettlement/details/index.vue

@@ -96,15 +96,15 @@ export default {
         },
         {
           label:'订单金额比例',
-          value:this.mainData.calculatemodel
+          value:Math.round((this.mainData.orderratio * 100)*100)/100 + '%'
         },
         {
-          label:'产品折扣',
-          value:this.mainData.productdiscount
+          label:'居间产品折扣',
+          value:Math.round((this.mainData.productdiscount * 100)*100)/100 + '%'
         },
         {
           label:'居间费',
-          value:this.mainData.rebate
+          value:this.tool.formatAmount(this.mainData.rebate,2)
         }
       ]
     },

+ 10 - 1
src/HDrpManagement/rebatesettlement/details/tabs/rebatesettlementmx.vue

@@ -19,11 +19,17 @@
         prop="marketprice"
         label="牌价"
         width="90">
+        <template slot-scope="scope">
+          {{tool.formatAmount(scope.row.marketprice,2)}}
+        </template>
       </el-table-column>
       <el-table-column
         prop="discountrate"
         label="折扣"
         width="90">
+        <template slot-scope="scope">
+          <span>{{Math.round((scope.row.discountrate * 100)*100)/100}}%</span>
+        </template>
       </el-table-column>
       <el-table-column
         prop="price"
@@ -45,6 +51,9 @@
         prop="rebate_discountrate"
         label="居间产品折扣"
         width="150">
+        <template slot-scope="scope">
+          <span>{{Math.round((scope.row.rebate_discountrate * 100)*100)/100}}%</span>
+        </template>
       </el-table-column>
       <el-table-column
         prop="rebate_price"
@@ -132,4 +141,4 @@ export default {
 
 </script>
 <style>
-</style>
+</style>

+ 3 - 0
src/HDrpManagement/rebatesettlement/index.vue

@@ -42,6 +42,9 @@
           <span style="color:#000000" v-if="scope.data.column.data[[scope.data.column.columnname]] == '新建'">{{scope.data.column.data[[scope.data.column.columnname]]}}</span>
           <span style="color:#52C41A" v-else-if="scope.data.column.data[[scope.data.column.columnname]] == '审核'">{{scope.data.column.data[[scope.data.column.columnname]]}}</span>
         </div>
+        <div v-else-if="scope.data.column.columnname == 'rebate'">
+          {{tool.formatAmount(scope.data.column.data[[scope.data.column.columnname]],2)}}
+        </div>
         <div v-else>
           {{scope.data.column.data[[scope.data.column.columnname]]?scope.data.column.data[[scope.data.column.columnname]]:'--'}}
         </div>

+ 8 - 4
src/template/contactsNewTemplate/index.vue

@@ -77,7 +77,7 @@
             :total="total">
         </el-pagination>
       </div>
-      <el-input  slot="reference"  autosize v-model="name?name:nameValue" placeholder="请填写联系人" @focus="listData"  :disabled="disabled" @change="inputChange"></el-input>
+      <el-input  slot="reference" :readonly="isParam" autosize v-model="name?name:nameValue" placeholder="请填写联系人" @focus="listData"  :disabled="disabled" @change="inputChange"></el-input>
     </el-popover>
   </div>
 </template>
@@ -85,7 +85,7 @@
 <script>
 export default {
   name: "index",
-  props:['disabled','ownertable','ownerid','name','placement'],
+  props:['disabled','ownertable','ownerid','name','placement','isParam','newParam'],
   data(){
     return {
       list:[],
@@ -110,8 +110,12 @@ export default {
   },
   methods:{
     async listData(){
-      this.param.content.ownertable = this.ownertable
-      this.param.content.ownerid = this.ownerid
+      if (this.isParam){
+        this.param = this.newParam
+      }else {
+        this.param.content.ownertable = this.ownertable
+        this.param.content.ownerid = this.ownerid
+      }
       const res = await this.$api.requested(this.param)
       this.list = res.data
       this.total = res.total