Commit 490e77d1 authored by huangyuanyuan's avatar huangyuanyuan
parents 742779b8 f8a155c9
......@@ -87,16 +87,19 @@
{{item.GuideName}}
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<div v-for="subItem in item.CommonReport.PriceShopList">{{ subItem.ShopDetailsList!=null && subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].ShopNum:""}}</div>
<div v-for="subItem in item.CommonReport.PriceShopList">{{ subItem.ShopDetailsList!=null &&
subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].ShopNum:""}}</div>
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopName}}</div>
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<div v-for="subItem in item.CommonReport.PriceShopList">{{ subItem.ShopDetailsList!=null && subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].EnterTimeStr:""}}</div>
<div v-for="subItem in item.CommonReport.PriceShopList">{{ subItem.ShopDetailsList!=null &&
subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].EnterTimeStr:""}}</div>
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null && subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].EnterNum:""}}</div>
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null &&
subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].EnterNum:""}}</div>
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<template v-for="subItem in item.CommonReport.PriceShopList">
......@@ -110,12 +113,13 @@
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<!--佣金领取状况-->
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null && subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].CommissionStatusStr:""}}</div>
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null &&
subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].CommissionStatusStr:""}}</div>
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<!--凭证上传-->
<div v-for="subItem in item.CommonReport.PriceShopList" v-if="subItem.ShopDetailsList!=null && subItem.ShopDetailsList.length>0">
<p v-for="(img, imgIndex) in subItem.ShopDetailsList[0].imgList" title="点击下载" @click="downLoadPZ(img)"
<p v-for="(img, imgIndex) in subItem.ShopDetailsList[0].imgList" title="点击下载" @click="downLoadPZ(img)"
v-if="img !== ''" style="cursor: pointer;">{{ '凭证' + (imgIndex + 1)}}</p>
</div>
</td>
......@@ -127,7 +131,8 @@
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<!--导游佣金调整-->
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null && subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].GuideCommission:""}}</div>
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null &&
subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].GuideCommission:""}}</div>
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<template v-for="subItem in item.CommonReport.PriceShopList">
......@@ -137,15 +142,18 @@
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<!--其余扣除(返佣余额)-->
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null && subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].OtherDeduct:""}}</div>
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null &&
subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].OtherDeduct:""}}</div>
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<!--返佣总计(返佣余额)-->
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null && subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].BackTotalMoney:""}}</div>
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null &&
subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].BackTotalMoney:""}}</div>
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<!--汇率-->
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null && subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].DMCRate:""}}</div>
<div v-for="subItem in item.CommonReport.PriceShopList">{{subItem.ShopDetailsList!=null &&
subItem.ShopDetailsList.length>0? subItem.ShopDetailsList[0].DMCRate:""}}</div>
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<!--地接OP凭证-->
......@@ -154,8 +162,8 @@
v-if="img !== ''" style="cursor: pointer;">{{ '凭证' + (imgIndex + 1)}}</p>
</div>
</td>
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0' >
<template v-for="subItem in item.CommonReport.PriceShopList" >
<td class="more_td" :rowspan="2*outItem.StaticsReportList.length" v-if='index==0'>
<template v-for="subItem in item.CommonReport.PriceShopList">
<div>
<!--subItem.ShopDetailsList-->
<p style="cursor: pointer;color:blue;" @click="CreateBill(subItem.ShopDetailsList,outItem.StaticsReportList)">生成单据</p>
......@@ -313,31 +321,35 @@
},
//生成单据
CreateBill(ShopDetailsList, outItem) {
this.loading = true;
var array = [];
outItem.forEach(subItem => {
var obj = {
LeaderId: subItem.LeaderId != null ? subItem.LeaderId : 0,
LeaderName: subItem.LeaderName != null ? subItem.LeaderName : "",
TCID: subItem.TCID,
GuideId: subItem.GuideId != null ? subItem.GuideId : 0,
GuideName: subItem.GuideName != null ? subItem.GuideName : "",
TCNUM: subItem.TCNUMS,
}
array.push(obj)
var that = this;
this.Confirm('是否生成财务单据?', function () {
that.loading = true;
var array = [];
outItem.forEach(subItem => {
var obj = {
LeaderId: subItem.LeaderId != null ? subItem.LeaderId : 0,
LeaderName: subItem.LeaderName != null ? subItem.LeaderName : "",
TCID: subItem.TCID,
GuideId: subItem.GuideId != null ? subItem.GuideId : 0,
GuideName: subItem.GuideName != null ? subItem.GuideName : "",
TCNUM: subItem.TCNUMS,
}
array.push(obj)
});
var billMsg = {
ShopDetailsList: ShopDetailsList,
LeaderGuide: array
};
that.apipost('dmcstatistics_post_ShopCreateBill', billMsg, res => {
that.loading = false;
if (res.data.resultCode == 1) {
that.Success(res.data.message);
} else {
that.Error(res.data.message);
}
}, err => {})
});
var billMsg = {
ShopDetailsList: ShopDetailsList,
LeaderGuide: array
};
this.apipost('dmcstatistics_post_ShopCreateBill', billMsg, res => {
this.loading = false;
if (res.data.resultCode == 1) {
this.Success(res.data.message);
} else {
this.$message.error(res.data.message)
}
}, err => {})
},
},
mounted() {
......
......@@ -577,55 +577,55 @@
<div class="btmAddStore" :class="{'fillShow':fillShow}">
<div class="btmTitle">导入营销数据<span class="litTip">(红色边框代表未匹配到的数据)</span></div>
<div style="height:250px;overflow-y: auto;">
<table class="impoTable" style="border-spacing: 0px 1px;">
<thead>
<tr>
<th width="200">团号</th>
<th>店名</th>
<th>进店时间</th>
<th>导游名称</th>
<th>领队名称</th>
<th>购物总额</th>
<th>组团社提成</th>
<th>领队提成</th>
<th>导游提成</th>
<th>汇率</th>
<th>币种</th>
<th>操作</th>
</tr>
<tr v-for="(item,index) in importData" :key="item.subCode">
<td :class="{'redType':item.TCIDExist==-1}">
<el-input v-model="item.TCNUM" class="w150"></el-input>
</td>
<td :class="{'redType':item.ShoppingNameExist==-1}">
<el-select clearable class="w150" v-model='item.ShoppingID' filterable :placeholder="$t('hotel.hotel_area')">
<el-option v-for='item in getShop' :key="item.ID" :label="item.Name" :value="item.ID">
</el-option>
</el-select>
</td>
<td>{{item.EnterTime}}</td>
<td :class="{'redType':item.GuideExist==-1}">
<el-select clearable class="w150" v-model='item.GuideID' filterable :placeholder="$t('hotel.hotel_area')">
<el-option v-for='item in guidList' :key="item.ID" :label="item.Name" :value="item.ID">
</el-option>
</el-select>
</td>
<td :class="{'redType':item.LeaderName==-1}">
<el-select clearable class="w150" v-model='item.LeaderID' filterable :placeholder="$t('hotel.hotel_area')">
<el-option v-for='item in leaderList' :key="item.ID" :label="item.Name" :value="item.ID">
</el-option>
</el-select>
</td>
<td>{{item.NowTotalPrice}}({{item.TotalPrice}}*{{item.Rate}})</td>
<td>{{item.NowGroupExtract}}({{item.GroupExtract}}*{{item.Rate}})</td>
<td>{{item.NowLeaderExtract}}({{item.LeaderExtract}}*{{item.Rate}})</td>
<td>{{item.NowGuideExtract}}({{item.GuideExtract}}*{{item.Rate}})</td>
<td>{{item.Rate}}</td>
<td :class="{'redType':item.CurrencyExist==-1}">{{item.Currency}}</td>
<td><span class="delInfo" @click="delInfo(index)">删除</span></td>
</tr>
</thead>
</table>
<table class="impoTable" style="border-spacing: 0px 1px;" v-loading="tabLoading">
<thead>
<tr>
<th width="200">团号</th>
<th>店名</th>
<th>进店时间</th>
<th>导游名称</th>
<th>领队名称</th>
<th>购物总额</th>
<th>组团社提成</th>
<th>领队提成</th>
<th>导游提成</th>
<th>汇率</th>
<th>币种</th>
<th>操作</th>
</tr>
<tr v-for="(item,index) in importData" :key="item.subCode">
<td :class="{'redType':item.TCIDExist==-1}">
<el-input v-model="item.TCNUM" class="w150"></el-input>
</td>
<td :class="{'redType':item.ShoppingNameExist==-1}">
<el-select clearable class="w150" v-model='item.ShoppingID' filterable :placeholder="$t('hotel.hotel_area')">
<el-option v-for='item in getShop' :key="item.ID" :label="item.Name" :value="item.ID">
</el-option>
</el-select>
</td>
<td>{{item.EnterTime}}</td>
<td :class="{'redType':item.GuideExist==-1}">
<el-select clearable class="w150" v-model='item.GuideID' filterable :placeholder="$t('hotel.hotel_area')">
<el-option v-for='item in guidList' :key="item.ID" :label="item.Name" :value="item.ID">
</el-option>
</el-select>
</td>
<td :class="{'redType':item.LeaderName==-1}">
<el-select clearable class="w150" v-model='item.LeaderID' filterable :placeholder="$t('hotel.hotel_area')">
<el-option v-for='item in leaderList' :key="item.ID" :label="item.Name" :value="item.ID">
</el-option>
</el-select>
</td>
<td>{{item.TotalPrice}}</td>
<td>{{item.GroupExtract}}</td>
<td>{{item.LeaderExtract}}</td>
<td>{{item.GuideExtract}}</td>
<td>{{item.Rate}}</td>
<td :class="{'redType':item.CurrencyExist==-1}">{{item.Currency}}</td>
<td><span class="delInfo" @click="delInfo(index)">删除</span></td>
</tr>
</thead>
</table>
</div>
<div class="btmBtn impotBtn">
<input type="button" class="normalBtn" @click="importInfo" value="确认导入" />
......@@ -690,6 +690,8 @@
AddMsgProvinceList: [],
//城市列表
AddMsgCityList: [],
//表格Loading
tabLoading:false,
msg: {
pageIndex: 1,
pageSize: 14,
......@@ -751,7 +753,6 @@
var imgUrl = this.domainManager().AliUrl + str;
this.imgArray.push(imgUrl);
this.PicPathArray.push(str);
// this.updatePic();
});
},
//更新购物店图片
......@@ -773,7 +774,6 @@
delImg(index) {
this.PicPathArray.splice(index, 1);
this.imgArray.splice(index, 1);
// this.updatePic();
},
handleCurrentChange(val) {
this.msg.pageIndex = val;
......@@ -931,7 +931,6 @@
this.addMsg.BusinessHours = "";
}
this.addMsg.PicPath = this.PicPathArray.toString();
// console.log("addMsg",this.addMsg);
this.apipost(
"Shopping_Post_Set",
this.addMsg,
......@@ -953,7 +952,7 @@
ID: ID
};
this.imgArray = [];
this.PicPathArray=[];
this.PicPathArray = [];
this.titleInfo = "修改购物店";
this.apipost(
"Shopping_Post_Get",
......@@ -1051,35 +1050,35 @@
this.importData[index].infoShow = true;
},
delInfo(index) {
this.$confirm("是否删除?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
})
.then(() => {
this.Success("删除成功!");
this.importData.splice(index, 1);
})
.catch(() => {
this.Info("已取消删除");
});
var that = this;
this.Confirm('是否删除?删除后将不能恢复', function () {
that.Success("删除成功!");
that.importData.splice(index, 1);
});
},
//导入数据
importInfo() {
let msg = this.importData;
this.apipost(
"ShoppingInfo_Post_Set",
msg,
res => {
if (res.data.resultCode == 1) {
this.fillShow = false;
this.Success("导入成功");
this.getList();
} else {
this.Error(res.data.message);
}
},
err => {}
);
var that = this;
this.Confirm('是否导入此数据?', function () {
that.tabLoading = true;
let msg = that.importData;
that.apipost(
"ShoppingInfo_Post_Set",
msg,
res => {
that.tabLoading = false;
if (res.data.resultCode == 1) {
that.fillShow = false;
that.Success("导入成功");
that.getList();
} else {
that.Error(res.data.message);
}
},
err => {}
);
});
},
getDownList() {
let msg = {};
......@@ -1110,30 +1109,23 @@
// this.addMsg.Address = msg.address;
},
delShoppingStore(ID) {
this.$confirm("是否删除?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
})
.then(() => {
this.Success("删除成功!");
var msg = {
ID: ID
};
this.apipost(
"Shopping_Post_Remove",
msg,
res => {
if (res.data.resultCode == 1) {
this.getList();
}
},
null
);
})
.catch(() => {
this.Info("已取消删除!");
});
var that = this;
this.Confirm('是否删除?删除后将不能恢复', function () {
that.Success("删除成功!");
var msg = {
ID: ID
};
that.apipost(
"Shopping_Post_Remove",
msg,
res => {
if (res.data.resultCode == 1) {
that.getList();
}
},
null
);
});
}
},
mounted() {
......
......@@ -10,6 +10,8 @@
<input type="button" style="width: auto !important;" class="travelControlTripBtn" value="下载电脑版PDF" @click="toPDF(orderMsg.startDate + orderMsg.lineteamName+orderMsg.dayNum+'日游')" />
<input type="button" style="width: auto !important;" class="travelControlTripBtn" value="下载手机版WORD" @click="gernalFeature(0)" />
<input type="button" style="width: auto !important;" class="travelControlTripBtn" value="下载电脑版WORD" @click="gernalFeature(1)" />
<a class="travelControlTripBtn" v-if="priceList!=null&& priceList[0].wordPath!=''" style="display:inline-block;text-decoration:none;
width:135px;text-align:center;line-height:30px;font-size:13px;position:relative;top:2px;" :href="domainManager().ViittoFileUrl+priceList[0].wordPath">下载WORD行程</a>
<!-- ToWord(orderMsg.startDate + orderMsg.lineteamName+orderMsg.dayNum+'日游') -->
<!--&&isopOperation HK 注释 可以让销售修改基本信息-->
<input type="button" v-if="orderId>0" class="travelControlTripBtn" value="修改信息" @click="editMsgShow=true" />
......
......@@ -149,11 +149,10 @@ export default {
GoogleMapUrl: "http://ditu.google.cn/maps/api/js?key=AIzaSyAZ5MIfzicStzKbIkbI3RcBBeZBjQFKsp0&sensor=false&language=zh-CN",
//google地图图片地址
GoogleMapImageUrl: "http://super.oytour.com",
// "http://upload.oytour.com"
UploadUrl: locationName.indexOf('oytour') !== -1 ? "http://upload.oytour.com" : "http://127.0.0.1:8120",
// 读取文件
ViittoFileUrl:'http://imgfile.oytour.com'
// UploadUrl: "http://upload.oytour.com"
//上传站点
UploadUrl: locationName.indexOf('oytour') !== -1||locationName.indexOf('viitto')!==-1 ? "http://upload.oytour.com" : "http://192.168.2.214:8120",
//文件站点
ViittoFileUrl: locationName.indexOf('oytour') !== -1 || locationName.indexOf('viitto')!==-1 ? "http://imgfile.oytour.com" : 'http://192.168.2.214:8130'
};
return obj;
},
......@@ -228,6 +227,7 @@ export default {
successCall(res);
}, faildCall)
}
//HTTP提交数据
Vue.prototype.apipost = function (cmd, msg, successCall, faildCall) {
if (msg == null || msg == "") {
......@@ -320,9 +320,7 @@ export default {
successCall(res);
}).catch(function (res) {});
},
Vue.prototype.getCookieItem = function () {
return JSON.parse(this.getCookie("userInfo"))
},
Vue.prototype.getLocalStorage = function () {
var localStorageData = window.localStorage["userInfo"];
if (localStorageData !== undefined && localStorageData!='undefined') {
......@@ -331,23 +329,7 @@ export default {
return null;
}
},
Vue.prototype.getCookie = function (cookieName) {
var strCookie = document.cookie;
var arrCookie = strCookie.split("; ");
for (var i = 0; i < arrCookie.length; i++) {
var arr = arrCookie[i].split("=");
if (cookieName == arr[0]) {
return arr[1];
}
}
return "";
},
Vue.prototype.getLoginUser = function () {
return this.loginUser
},
Vue.prototype.setLoginUser = function (user) {
this.loginUser = user
}
//PDF预览
Vue.prototype.previewPDF = function (url) {
......@@ -470,6 +452,32 @@ export default {
});
}
},
//上传文件到本地服务器
Vue.prototype.UploadSelfFile=function(path,files,successCall)
{
if (files && files.length > 0) {
let nameList = new Array()
for (let index = 0; index < files.length; index++) {
nameList.push(this.random_string());
}
let that = this;
co(function* () {
for (let index = 0; index < files.length; index++) {
let fileName = nameList[index]
fileName = path + fileName + "." + files[index].name.split('.').pop()
var formData = new FormData();
var uploadUrl=that.domainManager().UploadUrl+"/Upload?filePath="+path;
formData.append("myfile", files[index]);
that.$http.post(uploadUrl, formData, {})
.then(res => {
successCall(res);
})
}
}).catch(function (err) {
console.log("上传文件出错"+err);
});
}
}
Vue.prototype.uploadBlob = function (path, files, successCall) {
if (files && files.length > 0) {
......
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