|
@@ -207,7 +207,7 @@ import permissionApi from '@/api/oilcontract/permission'
|
|
|
import submitPopup from '@/components/oilcontract/submitPopup.vue'
|
|
import submitPopup from '@/components/oilcontract/submitPopup.vue'
|
|
|
import FileSaver from 'file-saver'
|
|
import FileSaver from 'file-saver'
|
|
|
import XLSX from 'xlsx'
|
|
import XLSX from 'xlsx'
|
|
|
-import util from "../../../utils/util";
|
|
|
|
|
|
|
+import util from '../../../utils/util'
|
|
|
|
|
|
|
|
export default {
|
|
export default {
|
|
|
computed: {
|
|
computed: {
|
|
@@ -263,7 +263,7 @@ export default {
|
|
|
let timeString = this.timeStyle(item)
|
|
let timeString = this.timeStyle(item)
|
|
|
return timeString
|
|
return timeString
|
|
|
} else {
|
|
} else {
|
|
|
- return item;
|
|
|
|
|
|
|
+ return item
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -281,20 +281,20 @@ export default {
|
|
|
editeBoolean: false,
|
|
editeBoolean: false,
|
|
|
deleteBoolean: false,
|
|
deleteBoolean: false,
|
|
|
dialogVisible: false,
|
|
dialogVisible: false,
|
|
|
- //列表数据
|
|
|
|
|
|
|
+ // 列表数据
|
|
|
entityList: [],
|
|
entityList: [],
|
|
|
- //分页参数
|
|
|
|
|
|
|
+ // 分页参数
|
|
|
size: 10,
|
|
size: 10,
|
|
|
currentPage: 1,
|
|
currentPage: 1,
|
|
|
currentItemCount: 0,
|
|
currentItemCount: 0,
|
|
|
- //列表排序
|
|
|
|
|
|
|
+ // 列表排序
|
|
|
Column: {
|
|
Column: {
|
|
|
Order: '',
|
|
Order: '',
|
|
|
Prop: ''
|
|
Prop: ''
|
|
|
},
|
|
},
|
|
|
- //查询时间 new Date(new Date().getTime() - 30 * 24 * 60 * 60 * 1000), new Date()
|
|
|
|
|
|
|
+ // 查询时间 new Date(new Date().getTime() - 30 * 24 * 60 * 60 * 1000), new Date()
|
|
|
CreateOn: [],
|
|
CreateOn: [],
|
|
|
- //查询项
|
|
|
|
|
|
|
+ // 查询项
|
|
|
searchFormReset: {},
|
|
searchFormReset: {},
|
|
|
searchForm: {
|
|
searchForm: {
|
|
|
Id: '',
|
|
Id: '',
|
|
@@ -330,118 +330,116 @@ export default {
|
|
|
CreateBy: '',
|
|
CreateBy: '',
|
|
|
ModifiedOn: '',
|
|
ModifiedOn: '',
|
|
|
ModifiedUserId: '',
|
|
ModifiedUserId: '',
|
|
|
- ModifiedBy: '',
|
|
|
|
|
|
|
+ ModifiedBy: ''
|
|
|
},
|
|
},
|
|
|
tableColumns: [
|
|
tableColumns: [
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "Status",
|
|
|
|
|
|
|
+ prop: 'Status',
|
|
|
label: '状态',
|
|
label: '状态',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
// {
|
|
// {
|
|
|
- // prop: "SupplierId",
|
|
|
|
|
|
|
+ // prop: 'SupplierId',
|
|
|
// label: '评价单位',
|
|
// label: '评价单位',
|
|
|
// width: 100,
|
|
// width: 100,
|
|
|
// sort: true
|
|
// sort: true
|
|
|
// },
|
|
// },
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "SupplierName",
|
|
|
|
|
|
|
+ prop: 'SupplierName',
|
|
|
label: '企业名称',
|
|
label: '企业名称',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "ProjectName",
|
|
|
|
|
|
|
+ prop: 'ProjectName',
|
|
|
label: '项目名称',
|
|
label: '项目名称',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "ContractNo",
|
|
|
|
|
|
|
+ prop: 'ContractNo',
|
|
|
label: '合同编号',
|
|
label: '合同编号',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "ProjectPlace",
|
|
|
|
|
|
|
+ prop: 'ProjectPlace',
|
|
|
label: '工程地点',
|
|
label: '工程地点',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "ProjectOwner",
|
|
|
|
|
|
|
+ prop: 'ProjectOwner',
|
|
|
label: '项目负责人',
|
|
label: '项目负责人',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "Telephone",
|
|
|
|
|
|
|
+ prop: 'Telephone',
|
|
|
label: '联系人电话',
|
|
label: '联系人电话',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "ProjectType",
|
|
|
|
|
|
|
+ prop: 'ProjectType',
|
|
|
label: '项目类别',
|
|
label: '项目类别',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
// {
|
|
// {
|
|
|
- // prop: "ContractMode",
|
|
|
|
|
|
|
+ // prop: 'ContractMode',
|
|
|
// label: '合同模式',
|
|
// label: '合同模式',
|
|
|
// width: 100,
|
|
// width: 100,
|
|
|
// sort: true
|
|
// sort: true
|
|
|
// },
|
|
// },
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "Amount",
|
|
|
|
|
|
|
+ prop: 'Amount',
|
|
|
label: '合同总金额(万元)',
|
|
label: '合同总金额(万元)',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "ContractPeriod",
|
|
|
|
|
|
|
+ prop: 'ContractPeriod',
|
|
|
label: '合同总工期(天)',
|
|
label: '合同总工期(天)',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "OpenDate",
|
|
|
|
|
|
|
+ prop: 'OpenDate',
|
|
|
label: '开工日期',
|
|
label: '开工日期',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
{
|
|
{
|
|
|
- prop: "PlanFinishDate",
|
|
|
|
|
|
|
+ prop: 'PlanFinishDate',
|
|
|
label: '计划竣工时间',
|
|
label: '计划竣工时间',
|
|
|
width: 100,
|
|
width: 100,
|
|
|
sort: true
|
|
sort: true
|
|
|
- },
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
|
|
+ }
|
|
|
]
|
|
]
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
- created() {
|
|
|
|
|
- //查询条件初始值备份
|
|
|
|
|
- Object.assign(this.searchFormReset, this.searchForm);
|
|
|
|
|
- //查询列表
|
|
|
|
|
- this.initDatas();
|
|
|
|
|
- //this.getDictOptions()
|
|
|
|
|
|
|
+ created () {
|
|
|
|
|
+ // 查询条件初始值备份
|
|
|
|
|
+ Object.assign(this.searchFormReset, this.searchForm)
|
|
|
|
|
+ // 查询列表
|
|
|
|
|
+ this.initDatas()
|
|
|
|
|
+ // this.getDictOptions()
|
|
|
this.statusFun()
|
|
this.statusFun()
|
|
|
// console.log(8888888,localStorage.getItem('userRoleids'))
|
|
// console.log(8888888,localStorage.getItem('userRoleids'))
|
|
|
// if(localStorage.getItem('userRoleids')!=''&&localStorage.getItem('userRoleids')!=undefined){
|
|
// if(localStorage.getItem('userRoleids')!=''&&localStorage.getItem('userRoleids')!=undefined){
|
|
@@ -450,7 +448,6 @@ export default {
|
|
|
// }else{
|
|
// }else{
|
|
|
// this.userRoleids = -1
|
|
// this.userRoleids = -1
|
|
|
// }
|
|
// }
|
|
|
-
|
|
|
|
|
},
|
|
},
|
|
|
methods: {
|
|
methods: {
|
|
|
timeStyle (item) {
|
|
timeStyle (item) {
|
|
@@ -459,8 +456,8 @@ export default {
|
|
|
}
|
|
}
|
|
|
return util.formatDate('year', item)
|
|
return util.formatDate('year', item)
|
|
|
},
|
|
},
|
|
|
- //一键处理
|
|
|
|
|
- onSelectAll(e) {
|
|
|
|
|
|
|
+ // 一键处理
|
|
|
|
|
+ onSelectAll (e) {
|
|
|
console.log(e)
|
|
console.log(e)
|
|
|
var list = []
|
|
var list = []
|
|
|
e.map((item, index) => {
|
|
e.map((item, index) => {
|
|
@@ -468,27 +465,27 @@ export default {
|
|
|
})
|
|
})
|
|
|
this.eveIdList = list
|
|
this.eveIdList = list
|
|
|
},
|
|
},
|
|
|
- //筛选
|
|
|
|
|
- selectableFun(row, index) {
|
|
|
|
|
|
|
+ // 筛选
|
|
|
|
|
+ selectableFun (row, index) {
|
|
|
if (row.Status == 4) {
|
|
if (row.Status == 4) {
|
|
|
- return true;
|
|
|
|
|
|
|
+ return true
|
|
|
} else {
|
|
} else {
|
|
|
- return false;
|
|
|
|
|
|
|
+ return false
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
- //一键处理按钮
|
|
|
|
|
- onSelectAllButton() {
|
|
|
|
|
|
|
+ // 一键处理按钮
|
|
|
|
|
+ onSelectAllButton () {
|
|
|
this.selectAllButtonBoolean = true
|
|
this.selectAllButtonBoolean = true
|
|
|
},
|
|
},
|
|
|
- //一键处理确定
|
|
|
|
|
- onSelectAllButtonTrue() {
|
|
|
|
|
|
|
+ // 一键处理确定
|
|
|
|
|
+ onSelectAllButtonTrue () {
|
|
|
if (this.eveIdList != 0 && this.eveIdList != undefined) {
|
|
if (this.eveIdList != 0 && this.eveIdList != undefined) {
|
|
|
this.$refs.submitpopup.dialogCommonAuditMakeSureVisible = true
|
|
this.$refs.submitpopup.dialogCommonAuditMakeSureVisible = true
|
|
|
} else {
|
|
} else {
|
|
|
this.$message({
|
|
this.$message({
|
|
|
type: 'warning',
|
|
type: 'warning',
|
|
|
message: '请选择评价'
|
|
message: '请选择评价'
|
|
|
- });
|
|
|
|
|
|
|
+ })
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
// 一键处理取消
|
|
// 一键处理取消
|
|
@@ -538,25 +535,25 @@ export default {
|
|
|
console.error(err)
|
|
console.error(err)
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
- //跳转评价
|
|
|
|
|
- onNavigateEvaluate(item) {
|
|
|
|
|
|
|
+ // 跳转评价
|
|
|
|
|
+ onNavigateEvaluate (item) {
|
|
|
console.log('跳转', item)
|
|
console.log('跳转', item)
|
|
|
this.$router.push({
|
|
this.$router.push({
|
|
|
path: '/oilcontract/contract-basis/' + item.Id + '/evaluate',
|
|
path: '/oilcontract/contract-basis/' + item.Id + '/evaluate',
|
|
|
query: {
|
|
query: {
|
|
|
item: item,
|
|
item: item,
|
|
|
- type: 2,
|
|
|
|
|
|
|
+ type: 2
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
- initDatas() {
|
|
|
|
|
- //分页及列表条件
|
|
|
|
|
|
|
+ initDatas () {
|
|
|
|
|
+ // 分页及列表条件
|
|
|
let params = {
|
|
let params = {
|
|
|
_currentPage: this.currentPage,
|
|
_currentPage: this.currentPage,
|
|
|
_size: this.size,
|
|
_size: this.size,
|
|
|
Order: this.Column.Order,
|
|
Order: this.Column.Order,
|
|
|
Prop: this.Column.Prop,
|
|
Prop: this.Column.Prop,
|
|
|
- ContractClass: '02',
|
|
|
|
|
|
|
+ ContractClass: '02'
|
|
|
}
|
|
}
|
|
|
// <el-option label="物资类" value="01" key="01"></el-option>
|
|
// <el-option label="物资类" value="01" key="01"></el-option>
|
|
|
// <el-option label="基建类" value="02" key="02"></el-option>
|
|
// <el-option label="基建类" value="02" key="02"></el-option>
|
|
@@ -572,9 +569,9 @@ export default {
|
|
|
myCreateOn.push(this.formatDateTime(this.CreateOn[0]))
|
|
myCreateOn.push(this.formatDateTime(this.CreateOn[0]))
|
|
|
myCreateOn.push(this.formatDateTime(this.CreateOn[1]))
|
|
myCreateOn.push(this.formatDateTime(this.CreateOn[1]))
|
|
|
}
|
|
}
|
|
|
- //查询条件
|
|
|
|
|
|
|
+ // 查询条件
|
|
|
Object.assign(params, this.searchForm)
|
|
Object.assign(params, this.searchForm)
|
|
|
- //访问接口
|
|
|
|
|
|
|
+ // 访问接口
|
|
|
api.getReviewList(myCreateOn.join(','), params, this.$axios).then(res => {
|
|
api.getReviewList(myCreateOn.join(','), params, this.$axios).then(res => {
|
|
|
console.log('评价接口', res)
|
|
console.log('评价接口', res)
|
|
|
this.entityList = res.data.items
|
|
this.entityList = res.data.items
|
|
@@ -584,25 +581,25 @@ export default {
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
- getDictOptions() {
|
|
|
|
|
|
|
+ getDictOptions () {
|
|
|
api.getDictList(this.$axios).then(res => {
|
|
api.getDictList(this.$axios).then(res => {
|
|
|
- //this.dictOptions.customerList = res.data.items['customerList']
|
|
|
|
|
- //this.dictOptions.projectList = res.data.items['projectList']
|
|
|
|
|
|
|
+ // this.dictOptions.customerList = res.data.items['customerList']
|
|
|
|
|
+ // this.dictOptions.projectList = res.data.items['projectList']
|
|
|
|
|
|
|
|
}).catch(err => {
|
|
}).catch(err => {
|
|
|
console.error(err)
|
|
console.error(err)
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
- searchCommand(command) {
|
|
|
|
|
|
|
+ searchCommand (command) {
|
|
|
if (command == 'search') {
|
|
if (command == 'search') {
|
|
|
this.dialogVisible = true
|
|
this.dialogVisible = true
|
|
|
} else if (command == 'clear') {
|
|
} else if (command == 'clear') {
|
|
|
this.clearSearch()
|
|
this.clearSearch()
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
- //列表排序功能
|
|
|
|
|
- orderby(column) {
|
|
|
|
|
|
|
+ // 列表排序功能
|
|
|
|
|
+ orderby (column) {
|
|
|
if (column.order == 'ascending') {
|
|
if (column.order == 'ascending') {
|
|
|
this.Column.Order = 'asc'
|
|
this.Column.Order = 'asc'
|
|
|
} else if (column.order == 'descending') {
|
|
} else if (column.order == 'descending') {
|
|
@@ -611,46 +608,46 @@ export default {
|
|
|
this.Column.Prop = column.prop
|
|
this.Column.Prop = column.prop
|
|
|
this.initDatas()
|
|
this.initDatas()
|
|
|
},
|
|
},
|
|
|
- clearSearch() {
|
|
|
|
|
- Object.assign(this.searchForm, this.searchFormReset);
|
|
|
|
|
- //this.searchForm = this.searchFormReset;
|
|
|
|
|
|
|
+ clearSearch () {
|
|
|
|
|
+ Object.assign(this.searchForm, this.searchFormReset)
|
|
|
|
|
+ // this.searchForm = this.searchFormReset;
|
|
|
this.CreateOn = ''
|
|
this.CreateOn = ''
|
|
|
this.initDatas()
|
|
this.initDatas()
|
|
|
},
|
|
},
|
|
|
- handleSearch() {
|
|
|
|
|
- this.currentPage = 1;
|
|
|
|
|
- this.dialogVisible = false;
|
|
|
|
|
- this.initDatas();
|
|
|
|
|
|
|
+ handleSearch () {
|
|
|
|
|
+ this.currentPage = 1
|
|
|
|
|
+ this.dialogVisible = false
|
|
|
|
|
+ this.initDatas()
|
|
|
},
|
|
},
|
|
|
- handleCurrentChange(value) {
|
|
|
|
|
|
|
+ handleCurrentChange (value) {
|
|
|
this.currentPage = value
|
|
this.currentPage = value
|
|
|
this.initDatas()
|
|
this.initDatas()
|
|
|
},
|
|
},
|
|
|
- handleSizeChange(value) {
|
|
|
|
|
|
|
+ handleSizeChange (value) {
|
|
|
this.size = value
|
|
this.size = value
|
|
|
this.currentPage = 1
|
|
this.currentPage = 1
|
|
|
this.initDatas()
|
|
this.initDatas()
|
|
|
},
|
|
},
|
|
|
- deleteEntity(row, index) {
|
|
|
|
|
|
|
+ deleteEntity (row, index) {
|
|
|
this.$refs['popover-' + `${index}`].doClose()
|
|
this.$refs['popover-' + `${index}`].doClose()
|
|
|
apiReview.deleteEntity(row.Id, this.$axios).then(res => {
|
|
apiReview.deleteEntity(row.Id, this.$axios).then(res => {
|
|
|
if (res.data.code === 0) {
|
|
if (res.data.code === 0) {
|
|
|
- this.initDatas();
|
|
|
|
|
|
|
+ this.initDatas()
|
|
|
this.$message({
|
|
this.$message({
|
|
|
type: 'success',
|
|
type: 'success',
|
|
|
message: res.data.message
|
|
message: res.data.message
|
|
|
- });
|
|
|
|
|
|
|
+ })
|
|
|
} else {
|
|
} else {
|
|
|
this.$message({
|
|
this.$message({
|
|
|
type: 'warning',
|
|
type: 'warning',
|
|
|
message: res.data.message
|
|
message: res.data.message
|
|
|
- });
|
|
|
|
|
|
|
+ })
|
|
|
}
|
|
}
|
|
|
}).catch(err => {
|
|
}).catch(err => {
|
|
|
console.error(err)
|
|
console.error(err)
|
|
|
- });
|
|
|
|
|
|
|
+ })
|
|
|
},
|
|
},
|
|
|
- jstimehandle(val) {
|
|
|
|
|
|
|
+ jstimehandle (val) {
|
|
|
if (val === '') {
|
|
if (val === '') {
|
|
|
return '----'
|
|
return '----'
|
|
|
} else if (val === '0001-01-01T08:00:00+08:00') {
|
|
} else if (val === '0001-01-01T08:00:00+08:00') {
|
|
@@ -662,7 +659,7 @@ export default {
|
|
|
return val.substring(0, 10)
|
|
return val.substring(0, 10)
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
- exportExcel() {
|
|
|
|
|
|
|
+ exportExcel () {
|
|
|
/* generate workbook object from table */
|
|
/* generate workbook object from table */
|
|
|
let wb = XLSX.utils.table_to_book(
|
|
let wb = XLSX.utils.table_to_book(
|
|
|
document.querySelector('#rebateSetTable')
|
|
document.querySelector('#rebateSetTable')
|
|
@@ -685,20 +682,19 @@ export default {
|
|
|
}
|
|
}
|
|
|
return wbout
|
|
return wbout
|
|
|
},
|
|
},
|
|
|
- formatDateTime(date) {
|
|
|
|
|
- var y = date.getFullYear();
|
|
|
|
|
- var m = date.getMonth() + 1;
|
|
|
|
|
- m = m < 10 ? ('0' + m) : m;
|
|
|
|
|
- var d = date.getDate();
|
|
|
|
|
- d = d < 10 ? ('0' + d) : d;
|
|
|
|
|
- var h = date.getHours();
|
|
|
|
|
- var minute = date.getMinutes();
|
|
|
|
|
- minute = minute < 10 ? ('0' + minute) : minute;
|
|
|
|
|
- return y + '-' + m + '-' + d + ' ' + h + ':' + minute;
|
|
|
|
|
|
|
+ formatDateTime (date) {
|
|
|
|
|
+ var y = date.getFullYear()
|
|
|
|
|
+ var m = date.getMonth() + 1
|
|
|
|
|
+ m = m < 10 ? ('0' + m) : m
|
|
|
|
|
+ var d = date.getDate()
|
|
|
|
|
+ d = d < 10 ? ('0' + d) : d
|
|
|
|
|
+ var h = date.getHours()
|
|
|
|
|
+ var minute = date.getMinutes()
|
|
|
|
|
+ minute = minute < 10 ? ('0' + minute) : minute
|
|
|
|
|
+ return y + '-' + m + '-' + d + ' ' + h + ':' + minute
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
</script>
|
|
</script>
|
|
|
|
|
|
|
|
<style lang="scss">
|
|
<style lang="scss">
|