mirror of
https://github.com/jumpserver/lina.git
synced 2026-01-13 19:35:24 +00:00
fix:Disabled assets have no audit records
This commit is contained in:
@@ -61,8 +61,11 @@ export default {
|
||||
},
|
||||
callbacks: {
|
||||
change: function(val) {
|
||||
const category = this.object.category.value
|
||||
const normalizedCategory =
|
||||
category === 'ds' ? 'directorie' : category
|
||||
this.$axios.patch(
|
||||
`/api/v1/assets/assets/${this.object.id}/`,
|
||||
`/api/v1/assets/${normalizedCategory}s/${this.object.id}/`,
|
||||
{ is_active: val }
|
||||
).then(res => {
|
||||
this.$message.success(this.$tc('UpdateSuccessMsg'))
|
||||
|
||||
Reference in New Issue
Block a user