Commit e4567b90 authored by 沈良进's avatar 沈良进
parents e6875468 09d5b242
......@@ -642,9 +642,9 @@
<el-table-column label="利润" style="background:#EAEAEA">
<template slot-scope="scope">
<span
:class="{'cF1416C':(scope.row.income*100-scope.row.costMoney*100-scope.row.refundMoney*100)/100>0}">
:class="{'cF1416C':(scope.row.income*100+scope.row.platformMoney*100-scope.row.costMoney*100-scope.row.refundMoney*100)/100>0}">
<span class="fz15 fbold">
{{moneyFormat((scope.row.income*100-scope.row.costMoney*100-scope.row.refundMoney*100)/100)}}
{{moneyFormat((scope.row.income*100+scope.row.platformMoney*100-scope.row.costMoney*100-scope.row.refundMoney*100)/100)}}
</span>
</span>
</template>
......
......@@ -101,10 +101,10 @@
class="w135 _border_b_1"
>
<el-option
v-for="item in supplierList"
v-for="(item,index) in supplierList"
:label="item.Name"
:value="item.ID"
:key="item.ID"
:key="index"
>
</el-option>
</el-select>
......@@ -379,11 +379,17 @@
methods: {
// 获取客户类型
getType(){
this.supplierMsg.Type = this.addMsg.Type
this.supplierList = []
if(this.addMsg.Type==4){
this.supplierMsg.Type = 5
}else{
this.supplierMsg.Type = this.addMsg.Type
}
if(this.addMsg.Type!=10){
this.addMsg.ObjID = null
this.addMsg.ObjIdStr = ''
this.getSupplierGetPageList()
this.supplierMsg.Name = ''
// this.getSupplierGetPageList()
}else{
this.addMsg.ObjID = this.$route.query.id
}
......@@ -406,12 +412,12 @@
}
},
getSupplierGetPageList(){
if(this.supplierMsg.Type==10) {
if(this.addMsg.Type==10) {
return
}
let url = "supplier_get_GetPageList"
let msg = JSON.parse(JSON.stringify(this.supplierMsg))
if(this.supplierMsg.Type==5) {
if(this.addMsg.Type==5) {
url = "dmc_post_visa_GetCommuneInfoPageList"
msg = {
pageIndex:1,
......@@ -424,7 +430,7 @@
Province:""
}
}
if(this.supplierMsg.Type==7) {
if(this.addMsg.Type==7) {
url = "leader_post_GetPageList"
msg = {
Type:"0",
......@@ -438,7 +444,7 @@
LeaderGuidClass:-1
}
}
if(this.supplierMsg.Type==8) {
if(this.addMsg.Type==8) {
url = "app_customer_GetCustomerListForCareOf"
msg = {
pageIndex:1,
......@@ -456,7 +462,7 @@
ExceptionCount:0,
}
}
if(this.supplierMsg.Type==9) {
if(this.addMsg.Type==9) {
url = "admin_get_EmployeeList"
msg = {
pageIndex:1,
......@@ -475,7 +481,7 @@
IsParentCompany:1
}
}
if(this.supplierMsg.Type==11) {
if(this.addMsg.Type==11) {
url = "travel_get_GetGroundingSupplierPageList"
msg = {
pageIndex:1,
......@@ -487,7 +493,7 @@
Id:""
}
}
if(this.supplierMsg.Type==6) {
if(this.addMsg.Type==6) {
url = "airline_post_GetPageList"
msg = {
pageIndex:1,
......@@ -502,19 +508,41 @@
url,
msg,
(res) => {
if (res.data.resultCode == 1 &&res.data.data&&res.data.data.pageData.length>0) {
this.supplierList = []
res.data.data.pageData.forEach(x=>{
if (res.data.resultCode == 1) {
let dataList
if(res.data.data.pageData&&res.data.data.pageData.length>0){
dataList = res.data.data.pageData
}
if(res.data.data.pages&&res.data.data.pages.pageData.length>0){
dataList = res.data.data.pages.pageData
}
dataList&&dataList.forEach(x=>{
let Obj = {
Name: '',
ID: 0
}
if(this.supplierMsg.Type==9){
if(this.addMsg.Type==9){
Obj = {
Name: x.EmName,
ID: x.EmployeeId
}
}else{
}else if(this.addMsg.Type==8){
Obj = {
Name: x.CustomerName,
ID: x.CustomerId
}
}else if(this.addMsg.Type==7){
Obj = {
Name: x.Surname+x.Name,
ID: x.ID
}
}else if(this.addMsg.Type==6){
Obj = {
Name: x.AlName,
ID: x.AirLineId
}
} else{
Obj = {
Name:x.Name,
ID: x.ID
......@@ -522,8 +550,7 @@
}
this.supplierList.push(Obj)
})
// this.supplierList = res.data.data.pageData
console.log(this.supplierMsg.Type,'-------',this.supplierList[0])
// console.log(this.supplierMsg.Type,'-------',this.supplierList[0])
if(this.addMsg.ObjIdStr&&this.supplierList.length>0){
this.addMsg.ObjID = Number(this.supplierList[0].ID)
}
......@@ -648,6 +675,9 @@
if(res.data.resultCode==1){
if(res.data.data && res.data.data.length) {
this.accountList = res.data.data
this.outerVisible = false;
this.getList();
this.resetForm("addMsg");
} else {
this.addAccount()
}
......
......@@ -572,8 +572,13 @@ export default {
this.supplierList = []
this.addMsg.ObjID = null
this.addMsg.ObjIdStr = ''
this.supplierMsg.Type = this.addMsg.Type
this.getSupplierGetPageList()
this.supplierMsg.Name = ''
if(this.addMsg.Type==4){
this.supplierMsg.Type = 5
}else{
this.supplierMsg.Type = this.addMsg.Type
}
// this.getSupplierGetPageList()
},
getObjName(){
this.supplierList.filter(x=>{
......@@ -592,14 +597,14 @@ export default {
}
},
getSupplierGetPageList(){
if(this.supplierMsg.Type==10) {
if(this.addMsg.Type==10) {
this.addMsg.ObjID = this.addMsg.CreateBy
return
}
this.addMsg.ObjID = null
let url = "supplier_get_GetPageList"
let msg = JSON.parse(JSON.stringify(this.supplierMsg))
if(this.supplierMsg.Type==5) {
if(this.addMsg.Type==5) {
url = "dmc_post_visa_GetCommuneInfoPageList"
msg = {
pageIndex:1,
......@@ -612,7 +617,7 @@ export default {
Province:""
}
}
if(this.supplierMsg.Type==7) {
if(this.addMsg.Type==7) {
url = "leader_post_GetPageList"
msg = {
Type:"0",
......@@ -626,7 +631,7 @@ export default {
LeaderGuidClass:-1
}
}
if(this.supplierMsg.Type==8) {
if(this.addMsg.Type==8) {
url = "app_customer_GetCustomerListForCareOf"
msg = {
pageIndex:1,
......@@ -644,7 +649,7 @@ export default {
ExceptionCount:0
}
}
if(this.supplierMsg.Type==9) {
if(this.addMsg.Type==9) {
url = "admin_get_EmployeeList"
msg = {
pageIndex:1,
......@@ -663,7 +668,7 @@ export default {
IsParentCompany:1
}
}
if(this.supplierMsg.Type==11) {
if(this.addMsg.Type==11) {
url = "travel_get_GetGroundingSupplierPageList"
msg = {
pageIndex:1,
......@@ -675,7 +680,7 @@ export default {
Id:""
}
}
if(this.supplierMsg.Type==6) {
if(this.addMsg.Type==6) {
url = "airline_post_GetPageList"
msg = {
pageIndex:1,
......@@ -691,7 +696,47 @@ export default {
msg,
(res) => {
if (res.data.resultCode == 1) {
this.supplierList = res.data.data.pageData
this.supplierList = []
let dataList
if(res.data.data.pageData&&res.data.data.pageData.length>0){
dataList = res.data.data.pageData
}
if(res.data.data.pages&&res.data.data.pages.pageData.length>0){
dataList = res.data.data.pages.pageData
}
dataList&&dataList.forEach(x=>{
let Obj = {
Name: '',
ID: 0
}
if(this.addMsg.Type==9){
Obj = {
Name: x.EmName,
ID: x.EmployeeId
}
}else if(this.addMsg.Type==8){
Obj = {
Name: x.CustomerName,
ID: x.CustomerId
}
}else if(this.addMsg.Type==7){
Obj = {
Name: x.Surname+x.Name,
ID: x.ID
}
}else if(this.addMsg.Type==6){
Obj = {
Name: x.AlName,
ID: x.AirLineId
}
} else{
Obj = {
Name:x.Name,
ID: x.ID
}
}
this.supplierList.push(Obj)
})
if(this.addMsg.ObjIdStr&&this.supplierList&&this.supplierList.length>0){
this.addMsg.ObjID = Number(this.supplierList[0].ID)
}
......@@ -842,6 +887,9 @@ export default {
if (res.data.resultCode == 1) {
if (res.data.data && res.data.data.length) {
this.accountList = res.data.data;
this.outerVisible = false;
this.getList();
this.resetForm("addMsg");
} else {
this.addAccount();
}
......
......@@ -141,16 +141,20 @@
</el-table-column>
<el-table-column prop="" label="操作" width="165">
<template slot-scope="scope">
<el-tooltip class="item" effect="dark" content="账户管理" placement="top">
<el-button @click="AccountManage(scope.row)"
<template v-if="(scope.row.IsSeeAll==1&&userInfo.EmployeeId==scope.row.CreateBy)||scope.row.IsSeeAll==0">
<el-tooltip class="item" effect="dark" content="账户管理" placement="top">
<el-button @click="AccountManage(scope.row)"
class="button" type="primary"
icon="el-icon-s-finance" circle>
</el-button>
</el-tooltip>
<el-button @click="Edit(scope.row)"
class="button" type="primary"
icon="el-icon-s-finance" circle>
icon="el-icon-edit" circle>
</el-button>
</el-tooltip>
<el-button @click="Edit(scope.row)"
class="button" type="primary"
icon="el-icon-edit" circle>
</el-button>
</template>
<!-- <el-tooltip class="item" effect="dark" content="详情" placement="top">
<el-button @click="Edit(scope.row,1)"
class="button" type="info"
......@@ -163,9 +167,11 @@
icon="el-icon-check" circle>
</el-button>
</el-tooltip>
<el-button @click="Delete(scope.row)"
class="button" type="danger"
icon="el-icon-delete" circle></el-button>
<template v-if="(scope.row.IsSeeAll==1&&userInfo.EmployeeId==scope.row.CreateBy)||scope.row.IsSeeAll==0">
<el-button @click="Delete(scope.row)"
class="button" type="danger"
icon="el-icon-delete" circle></el-button>
</template>
</template>
</el-table-column>
</el-table>
......@@ -207,7 +213,7 @@
<el-form-item label="供应商名称" prop="Name">
<el-input v-model="form.Name" clearable></el-input>
</el-form-item>
</div>
</div>
<div class="msgbox">
<el-form-item label="到期时间" prop="ContractEndTime">
<el-date-picker
......@@ -268,7 +274,7 @@
</div>
</el-form-item>
</div>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="resetForm('form'),showVisible = false">取 消</el-button>
......@@ -335,10 +341,12 @@
ContractUrl: [{ required: true, message: '请上传合同', trigger: "buttom"}],
ContractEndTime: [{ required: true, message: '请选择合同到期时间', trigger: "change"}],
},
titleName: '新增'
titleName: '新增',
userInfo: {}
}
},
created() {
this.userInfo = this.getLocalStorage();
this.msg.Id = this.$route.query.Id?this.$route.query.Id:''
},
components: {
......
......@@ -333,7 +333,7 @@
</div>
<OrderList :pagesTitle="Title" :OrderList="OrderList" v-loading="loading" @success="msg.pageIndex=1,GetList()"> </OrderList>
<OrderList :pagesTitle="Title" :OrderList="OrderList" v-loading="loading" @success="msg.pageIndex=1,msg2.pageIndex=1,GetList()"> </OrderList>
<!-- <div v-if="OrderList&&OrderList.length==0" style="text-align: center;padding: 100px;">暂无数据</div> -->
<el-pagination v-if="OrderList&&OrderList.length>0&&pagesTitle!='审核'" background
@current-change="handleCurrentChange" :current-page.sync="currentPage"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment