Commit c8685c68 authored by Mac's avatar Mac

1

parent d1d12806
...@@ -3,7 +3,8 @@ ...@@ -3,7 +3,8 @@
<div class="el-card__header"> <div class="el-card__header">
<span>损益核算</span> <span>损益核算</span>
<div style="display: flex;flex-direction: row;align-items: center"> <div style="display: flex;flex-direction: row;align-items: center">
<el-button type="primary" class="el-button--small" @click="Export">导出全部</el-button> <!---->
<el-button type="primary" class="el-button--small" @click="getDateList,getSupplierList">导出全部</el-button>
</div> </div>
</div> </div>
...@@ -131,7 +132,7 @@ ...@@ -131,7 +132,7 @@
}, },
methods:{ methods:{
getDateList(){ getDateList(){
console.log('进入方法')
if(this.value!=''){ if(this.value!=''){
this.msg.StartDate = this.value[0]; this.msg.StartDate = this.value[0];
this.msg.EndDate = this.value[1]; this.msg.EndDate = this.value[1];
...@@ -142,6 +143,7 @@ ...@@ -142,6 +143,7 @@
this.msg.SupplierId= 0 this.msg.SupplierId= 0
} }
this.loading=true; this.loading=true;
console.log('11111111')
this.mallapipost("/api/Statistics/GetOrderProfitLossList", this.msg, res => { this.mallapipost("/api/Statistics/GetOrderProfitLossList", this.msg, res => {
this.loading=false; this.loading=false;
if(res.data.resultCode==1){ if(res.data.resultCode==1){
...@@ -154,6 +156,7 @@ ...@@ -154,6 +156,7 @@
}) })
}, },
getSupplierList(){//获取供应商接口 getSupplierList(){//获取供应商接口
console.log("222222")
this.mallapipost("/api/Supplier/GetSupplierAllList", {}, res => { this.mallapipost("/api/Supplier/GetSupplierAllList", {}, res => {
this.loading = false; this.loading = false;
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
......
...@@ -234,7 +234,11 @@ export default { ...@@ -234,7 +234,11 @@ export default {
//HTTP提交数据 //HTTP提交数据
Vue.prototype.apipost = function (cmd, msg, successCall, faildCall, isOnline) { Vue.prototype.apipost = function (cmd, msg, successCall, faildCall, isOnline) {
if (this.$route.name.indexOf('login') === -1 && this.$route.name.indexOf('clientConfirm') === -1 && this.$route.name.indexOf('confirmationOrderDownLoad') === -1 && this.$route.name.indexOf('PrintPage') === -1 && this.$route.name.indexOf('TravelContractConfirm') === -1 && this.$route.name.indexOf('ViittoContractConfirm') === -1 ) { if (this.$route.name.indexOf('login') === -1 && this.$route.name.indexOf('clientConfirm') === -1
&& this.$route.name.indexOf('confirmationOrderDownLoad') === -1 && this.$route.name.indexOf('PrintPage') === -1
&& this.$route.name.indexOf('TravelContractConfirm') === -1 && this.$route.name.indexOf('ViittoContractConfirm') === -1
&& this.$route.name.indexOf('OrderProfitLossList') === -1
) {
let previousPathInfo = { let previousPathInfo = {
path: this.$route.name, path: this.$route.name,
...@@ -335,7 +339,7 @@ export default { ...@@ -335,7 +339,7 @@ export default {
//HTTP提交数据 //HTTP提交数据
Vue.prototype.mallapipost = function(cmd, msg, successCall, faildCall, isOnline) { Vue.prototype.mallapipost = function(cmd, msg, successCall, faildCall, isOnline) {
console.log('进入方法1')
var apiurl = this.domainManager().mallUrl + cmd; var apiurl = this.domainManager().mallUrl + cmd;
var postData = this.GetPostData(cmd, msg, ""); var postData = this.GetPostData(cmd, msg, "");
this.$http.post(apiurl, postData, { this.$http.post(apiurl, postData, {
...@@ -345,15 +349,16 @@ export default { ...@@ -345,15 +349,16 @@ export default {
} }
}) })
.then(res => { .then(res => {
if (res.data.resultCode == 10000 || res.data.resultCode == 10001) { console.log("res",res);
this.$router.push({ // if (res.data.resultCode == 10000 || res.data.resultCode == 10001) {
path: '/login' // // this.$router.push({
}); // // path: '/login'
} else if (res.resultCode == 10005) { // // });
this.$router.go(-1); // } else if (res.resultCode == 10005) {
} else { // this.$router.go(-1);
successCall(res); // } else {
} // successCall(res);
// }
}, faildCall) }, faildCall)
} }
//获取请求参数 //获取请求参数
...@@ -361,7 +366,7 @@ export default { ...@@ -361,7 +366,7 @@ export default {
if (msg == null || msg == "") { if (msg == null || msg == "") {
msg = {} msg = {}
} }
console.log('进入方2')
var timestamp = (new Date()).valueOf(); var timestamp = (new Date()).valueOf();
// if (!localStorage.mall_userInfo && localStorage.mall_userInfo != "" && // if (!localStorage.mall_userInfo && localStorage.mall_userInfo != "" &&
// this.$route.path.toLowerCase() != "/login" && // this.$route.path.toLowerCase() != "/login" &&
...@@ -384,9 +389,10 @@ export default { ...@@ -384,9 +389,10 @@ export default {
// TenantId = this.getLocalStorage().TenantId; // TenantId = this.getLocalStorage().TenantId;
// EmpId = this.getLocalStorage().EmpId; // EmpId = this.getLocalStorage().EmpId;
// } // }
console.log('进入方法3')
var encodeMsg = encodeURIComponent(JSON.stringify(msg)).toLowerCase(); var encodeMsg = encodeURIComponent(JSON.stringify(msg)).toLowerCase();
var md5Str = md5(`cmd=${cmd}&msg=${encodeMsg}&timestamp=${timestamp}&token=${token}&key=${key}`); var md5Str = md5(`cmd=${cmd}&msg=${encodeMsg}&timestamp=${timestamp}&token=${token}&key=${key}`);
let tempLanguage = 0; let tempLanguage = 0;
if (localStorage.language && localStorage.language != '') { if (localStorage.language && localStorage.language != '') {
if (localStorage.language == "zh-TW") { if (localStorage.language == "zh-TW") {
...@@ -413,6 +419,7 @@ export default { ...@@ -413,6 +419,7 @@ export default {
// OpenId:"ow_7I5ZQKhAB66yvOTGI35Xk-Kmg", // OpenId:"ow_7I5ZQKhAB66yvOTGI35Xk-Kmg",
// UserId:19992, // UserId:19992,
} }
return postData return postData
}, },
......
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