|
|
|
@ -9,6 +9,7 @@
|
|
|
|
|
header-cell-style="text-align:center;background-color:#57c9cd;color:#fff"
|
|
|
|
|
cell-style="text-align:center"
|
|
|
|
|
:row-style="tableRowStyle"
|
|
|
|
|
:row-class-name="tableRowClass"
|
|
|
|
|
style="width: 100%">
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="ROWSEQ"
|
|
|
|
@ -352,20 +353,36 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
tableRowStyle({row, rowIndex}) {
|
|
|
|
|
console.log(row)
|
|
|
|
|
let date = `${new Date().getFullYear()}-${(new Date().getMonth()) > 10 ? (new Date().getMonth() + 1) : ('0' + (new Date().getMonth() + 1))}-${(new Date().getDate() > 10) ? (new Date().getDate()) : ('0' + new Date().getDate())}`
|
|
|
|
|
let date1 = new Date(row.PLAN_DATE).getTime()
|
|
|
|
|
let date2 = new Date(date).getTime()
|
|
|
|
|
if ((date2 - date1) === (1000 * 60 * 60 * 24)) {
|
|
|
|
|
return {'background-color': 'yellow', color: '#fff'};
|
|
|
|
|
}
|
|
|
|
|
if (row.STATUS === 1) {
|
|
|
|
|
console.log(123)
|
|
|
|
|
return {'background-color': 'red', color: '#fff'};
|
|
|
|
|
} else {
|
|
|
|
|
console.log(456)
|
|
|
|
|
return {}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
tableRowClass({row, rowIndex}) {
|
|
|
|
|
let date = `${new Date().getFullYear()}-${(new Date().getMonth()) > 10 ? (new Date().getMonth() + 1) : ('0' + (new Date().getMonth() + 1))}-${(new Date().getDate() > 10) ? (new Date().getDate()) : ('0' + new Date().getDate())}`
|
|
|
|
|
let date1 = new Date(row.PLAN_DATE).getTime()
|
|
|
|
|
let date2 = new Date(date).getTime()
|
|
|
|
|
if ((date2 - date1) === (1000 * 60 * 60 * 24)) {
|
|
|
|
|
return 'blackHover'
|
|
|
|
|
}
|
|
|
|
|
if (row.STATUS === 1) {
|
|
|
|
|
return 'blackHover'
|
|
|
|
|
} else {
|
|
|
|
|
return {}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
|
<style lang="less" scoped>
|
|
|
|
|
.dashboard-editor-container {
|
|
|
|
|
padding: 32px;
|
|
|
|
|
background-color: rgb(240, 242, 245);
|
|
|
|
@ -387,4 +404,8 @@ export default {
|
|
|
|
|
.el-table th.el-table__cell > .cell {
|
|
|
|
|
text-align: center;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/deep/ .blackHover:hover {
|
|
|
|
|
color: #000!important;
|
|
|
|
|
}
|
|
|
|
|
</style>
|
|
|
|
|