Commit 54f71926 authored by 黄媛媛's avatar 黄媛媛
parents 3aca600f 85baba52
This diff is collapsed.
<style>
</style>
<template>
<div class="flexOne newContract">
<div class="ElectronicAudit">
<div class="query-box">
<ul>
<li>
<input type="button" class="hollowFixedBtn" value="新增" @click="goToDetail()"/>
</li>
</ul>
</div>
<div class="commonContent" v-loading="loading">
<table class="singeRowTable" border="0" cellspacing="0" cellpadding="0">
<tr>
<th>乙方名称</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 dataList" :key="index">
<td>{{item.CustomerName}}</td>
<td>
<template v-if="item.SignDate!=null">
{{getDate(item.SignDate)}}
</template>
</td>
<td>{{item.BusinessLicense}}</td>
<td>
<template v-if="item.ContractStartDate!=null">
{{getDate(item.ContractStartDate)}}
</template>
</td>
<td>
<template v-if="item.ContractEndDate!=null">
{{getDate(item.ContractEndDate)}}
</template>
</td>
<td>
<img :src="item.ViittoSignImg" style="width:100px;"/>
</td>
<td>
<template v-if="item.ViittoSignDate!=null">
{{getDate(item.ViittoSignDate)}}
</template>
</td>
<td>
<img :src="item.CustomerSignImg" style="width:100px;"/>
</td>
<td>
<template v-if="item.CustomerSignDate!=null">
{{getDate(item.CustomerSignDate)}}
</template>
</td>
<td>
{{item.CreateByName}}
</td>
<td>
<template v-if="item.CreateDateStr!=null">
{{getDate(item.CreateDateStr)}}
</template>
</td>
<td>
<el-tooltip class="item" effect="dark" content="修改" placement="top-start">
<el-button type="primary" icon="iconfont icon-Edit" @click="goContract(item)" circle></el-button>
</el-tooltip>
<el-tooltip class="item" effect="dark" content="删除" placement="top-start">
<el-button type="danger" icon="iconfont icon-img_delete_small" circle @click="isdelete(item.Id)">
</el-button>
</el-tooltip>
<el-tooltip class="item" effect="dark" content="下载" placement="top-start">
<el-button type="success" icon="iconfont icon-img_download" circle @click="ToDownWord(item)">
</el-button>
</el-tooltip>
</td>
</tr>
</table>
<div class="noData" v-show="dataList.length<1">
<i class="iconfont icon-kong" style="font-size:100px;"></i>
<p>{{$t("active.ld_noData")}}</p>
</div>
<el-pagination background @current-change="handleChange" :current-page.sync="currentPage"
layout="total,prev, pager, next, jumper" :page-size="msg.pageSize" :total="total">
</el-pagination>
</div>
</div>
</div>
</template>
<script>
import moment from 'moment'
export default {
data() {
return {
msg: {
pageIndex:1,
pageSize:15
},
loading:false,
dataList: [],
currentPage:1,
total:0
};
},
methods: {
getDate(date) {
return moment(date).format("YYYY-MM-DD");
},
getList() {
this.loading = true;
//获取列表数据
this.apipost(
"viitto_get_GetContractService",
this.msg,
res => {
this.loading = false;
if (res.data.resultCode == 1) {
this.dataList = res.data.data.pageData;
this.total = res.data.data.count;
} else {
this.Error(res.data.message);
}
},
err => {}
);
},
handleChange(val){
this.msg.pageIndex = val;
this.getList();
},
//删除
isdelete(Id) {
var that = this;
this.Confirm("是否删除?", function () {
var msg = {
Id: Id
};
that.apipost(
"viitto_post_RemoveViittoContractService",
msg,
res => {
if (res.data.resultCode == 1) {
that.getList();
}
},
null
);
});
},
//新增合同跳转
goToDetail() {
this.$router.push({
name: 'magiContract',
query: {
blank: "y",
}
});
},
//跳转至合同
goContract(item){
this.$router.push({
name: 'magiContract',
query: {
blank: "y",
Id:item.Id
}
});
},
//生成word
ToDownWord:function(item){
this.loading = true;
let msg = {
Id:item.Id,
//用户Id
UId:this.getLocalStorage().EmployeeId,
};
let urlObj = this.domainManager();
this.$http({
headers: {
'Content-Type': 'application/json'
},
method: 'post',
url: urlObj.DomainUrl + '/api/file/GetViittoContract',
data: {
"msg": msg
}
}).then(res => {
if (res.data.resultCode === 1) {
let sign = item.CustomerName+"_合同.doc";
const a = document.createElement('a');
a.setAttribute('download', '');
a.setAttribute('href', urlObj.DomainUrl + '/api/file/DownloadFileForPdf?fileName=' + sign +
'.doc&&fPath=' + res.data.data);
a.click();
} else {
this.Error('WORD获取失败');
}
this.loading = false;
}).catch(err => {
})
},
},
mounted() {
this.getList();
}
};
</script>
This diff is collapsed.
......@@ -368,6 +368,14 @@ export default {
title: '电子合同审核'
},
},
{
path: '/ViittoContract', // 行政-微途电子合同
name: 'ViittoContract',
component: resolve => require(['@/components/administrative/ViittoContract'], resolve),
meta: {
title: '微途电子合同'
}
},
{
path: '/ContractManage', //合同管理
name: 'ContractManage',
......@@ -4611,6 +4619,14 @@ export default {
title: '电子合同'
}
},
{
path: '/magiContract', //麦子Erp使用合同
name: 'magiContract',
component: resolve => require(['@/components/magiContract'], resolve),
meta: {
title: '麦子Erp使用合同'
}
},
{
path: '/ScenicStrategyview', //景点攻略预览
name: 'ScenicStrategyview',
......
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