diff --git a/src/views/accessPermission/listDoorPermission.vue b/src/views/accessPermission/listDoorPermission.vue index 78ad840..7f31e76 100644 --- a/src/views/accessPermission/listDoorPermission.vue +++ b/src/views/accessPermission/listDoorPermission.vue @@ -60,7 +60,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/accessPermission/listDoorPermission.vue b/src/views/accessPermission/listDoorPermission.vue index 78ad840..7f31e76 100644 --- a/src/views/accessPermission/listDoorPermission.vue +++ b/src/views/accessPermission/listDoorPermission.vue @@ -60,7 +60,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/accessPermission/listDoorPermission.vue b/src/views/accessPermission/listDoorPermission.vue index 78ad840..7f31e76 100644 --- a/src/views/accessPermission/listDoorPermission.vue +++ b/src/views/accessPermission/listDoorPermission.vue @@ -60,7 +60,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/accessPermission/listDoorPermission.vue b/src/views/accessPermission/listDoorPermission.vue index 78ad840..7f31e76 100644 --- a/src/views/accessPermission/listDoorPermission.vue +++ b/src/views/accessPermission/listDoorPermission.vue @@ -60,7 +60,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/memberManage/listVisitor.vue b/src/views/memberManage/listVisitor.vue index f677eed..f72ac49 100644 --- a/src/views/memberManage/listVisitor.vue +++ b/src/views/memberManage/listVisitor.vue @@ -69,7 +69,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/memberManage/listVisitor.vue b/src/views/memberManage/listVisitor.vue index f677eed..f72ac49 100644 --- a/src/views/memberManage/listVisitor.vue +++ b/src/views/memberManage/listVisitor.vue @@ -69,7 +69,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/memberManage/listVisitor.vue b/src/views/memberManage/listVisitor.vue index f677eed..f72ac49 100644 --- a/src/views/memberManage/listVisitor.vue +++ b/src/views/memberManage/listVisitor.vue @@ -69,7 +69,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/memberManage/listVisitor.vue b/src/views/memberManage/listVisitor.vue index f677eed..f72ac49 100644 --- a/src/views/memberManage/listVisitor.vue +++ b/src/views/memberManage/listVisitor.vue @@ -69,7 +69,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/memberManage/listVisitor.vue b/src/views/memberManage/listVisitor.vue index f677eed..f72ac49 100644 --- a/src/views/memberManage/listVisitor.vue +++ b/src/views/memberManage/listVisitor.vue @@ -69,7 +69,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/memberManage/listVisitor.vue b/src/views/memberManage/listVisitor.vue index f677eed..f72ac49 100644 --- a/src/views/memberManage/listVisitor.vue +++ b/src/views/memberManage/listVisitor.vue @@ -69,7 +69,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/memberManage/listVisitor.vue b/src/views/memberManage/listVisitor.vue index f677eed..f72ac49 100644 --- a/src/views/memberManage/listVisitor.vue +++ b/src/views/memberManage/listVisitor.vue @@ -69,7 +69,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/memberManage/listVisitor.vue b/src/views/memberManage/listVisitor.vue index f677eed..f72ac49 100644 --- a/src/views/memberManage/listVisitor.vue +++ b/src/views/memberManage/listVisitor.vue @@ -69,7 +69,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/memberManage/listVisitor.vue b/src/views/memberManage/listVisitor.vue index f677eed..f72ac49 100644 --- a/src/views/memberManage/listVisitor.vue +++ b/src/views/memberManage/listVisitor.vue @@ -69,7 +69,7 @@ item.openStatus === status).length === this.multipleSelection.length @@ -168,19 +168,19 @@ } this.dialogFormVisible = true switch(status) { - case 0: + case 0: let closeStatus = this.closebtn === '常闭' ? 0 : this.closebtn === '取消常闭' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, closeStatus) break; - case 1: + case 1: let openStatus = this.openbtn === '常开' ? 1 : this.openbtn === '取消常开' ? 2 : '' this.$refs.controldoor.initDialog(this.multipleSelection, openStatus) break; - case 3: + case 3: let cardStatus = this.cardbth === '刷卡开门' ? 3 : this.cardbth === '取消刷卡开门' ? 2 : '' this.openCard(cardStatus) break; - default: + default: null } }, diff --git a/src/views/doorManage/listGroup.vue b/src/views/doorManage/listGroup.vue index 344517c..1b4922a 100644 --- a/src/views/doorManage/listGroup.vue +++ b/src/views/doorManage/listGroup.vue @@ -33,7 +33,7 @@ - - - - - + + + + + @@ -67,6 +67,10 @@
- + - - - - - - - - - - - - 搜索 - - - - - + + + + + + + + + + + + + + + + 搜索 +
- +
@@ -148,6 +160,9 @@ components: { DeptSelect, Transfer }, data() { return { + filterMethod(query, item) { + return item.label.indexOf(query) > -1 || item.code.indexOf(query) > -1 + }, textMap: { update: '编辑', create: '新增', @@ -254,6 +269,12 @@ methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, row = null) { + this.$nextTick(() => { + this.$refs.staffTransfer.clearQuery('left') + this.$refs.staffTransfer.clearQuery('right') + this.$refs.visitorTransfer.clearQuery('left') + this.$refs.visitorTransfer.clearQuery('right') + }) this.stafflist = [] this.staffList = [] this.visitorlist = [] @@ -356,11 +377,11 @@ this.visitorlist = response.data.filter(item => item.personType === '0') .map(function(item) { return item.id }) getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading = false }) getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) this.transLoading1 = false }) }) @@ -372,7 +393,7 @@ arr = this.staffList.filter(item => this.stafflist.indexOf(item.key) > -1) } getPerson(this.listQuery).then(response => { - this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.staffList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.staffList.filter(item => this.stafflist.indexOf(item.key) === -1) this.staffList = tmp.concat(arr) this.transLoading = false @@ -385,7 +406,7 @@ arr = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) > -1) } getPerson(this.listQuery1).then(response => { - this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name } }) + this.visitorList = response.data.map(function(item) { return { key: item.id, label: item.name, code: item.personCode } }) const tmp = this.visitorList.filter(item => this.visitorlist.indexOf(item.key) === -1) this.visitorList = tmp.concat(arr) this.transLoading1 = false diff --git a/src/views/memberManage/listGroup.vue b/src/views/memberManage/listGroup.vue index 0547113..a49dfdf 100644 --- a/src/views/memberManage/listGroup.vue +++ b/src/views/memberManage/listGroup.vue @@ -44,7 +44,7 @@ + + + + + @@ -142,7 +147,7 @@ { + this.groupList = response.data + }) + }, // 获取性别 fetchSexType() { getSexType().then(response => { diff --git a/src/views/memberManage/listVisitor.vue b/src/views/memberManage/listVisitor.vue index f677eed..f72ac49 100644 --- a/src/views/memberManage/listVisitor.vue +++ b/src/views/memberManage/listVisitor.vue @@ -69,7 +69,7 @@