【fix ESLint】src/views/system/modules

This commit is contained in:
danshihao
2023-03-07 14:23:25 +08:00
parent 0e41300963
commit 9e05297813
33 changed files with 179 additions and 183 deletions
@@ -108,9 +108,9 @@ export default {
align: 'center',
dataIndex: 'sex',
customRender: function (text) {
if (text == 1) {
if ((text + '') === '1') {
return '男'
} else if (text == 2) {
} else if ((text + '') === '2') {
return '女'
} else {
return text
@@ -129,9 +129,9 @@ export default {
align: 'center',
dataIndex: 'status',
customRender: function (text) {
if (text == 1) {
if ((text + '') === '1') {
return '正常'
} else if (text == 2) {
} else if ((text + '') === '2') {
return '冻结'
} else {
return text
@@ -178,7 +178,7 @@ export default {
if (!selectUser) {
this.selectionRows = []
} else {
var that = this
const that = this
that.selectionRows = []
selectUser.forEach(function (record, index) {
console.log(record)
@@ -222,11 +222,11 @@ export default {
this.selectedRowKeys = selectedRowKeys
},
onSelect (record, selected) {
if (selected == true) {
if (selected === true) {
this.selectionRows.push(record)
} else {
this.selectionRows.forEach(function (item, index, arr) {
if (item.id == record.id) {
if (item.id === record.id) {
arr.splice(index, 1)
}
})
@@ -245,7 +245,7 @@ export default {
// TODO 筛选
if (Object.keys(sorter).length > 0) {
this.isorter.column = sorter.field
this.isorter.order = sorter.order == 'ascend' ? 'asc' : 'desc'
this.isorter.order = sorter.order === 'ascend' ? 'asc' : 'desc'
}
this.ipagination = pagination
this.loadData()