diff --git a/package.json b/package.json
index a3c730c84..83ca7d71d 100644
--- a/package.json
+++ b/package.json
@@ -66,7 +66,7 @@
"normalize.css": "7.0.0",
"npm": "^7.8.0",
"nprogress": "0.2.0",
- "path-to-regexp": "2.4.0",
+ "path-to-regexp": "3.3.0",
"v-sanitize": "^0.0.13",
"vue": "2.6.10",
"vue-codemirror": "4.0.6",
@@ -117,7 +117,7 @@
"sass-loader": "^7.1.0",
"script-ext-html-webpack-plugin": "2.1.3",
"script-loader": "0.7.2",
- "serve-static": "^1.13.2",
+ "serve-static": "^1.16.0",
"strip-ansi": "^7.1.0",
"svg-sprite-loader": "4.1.3",
"svgo": "1.2.2",
diff --git a/src/api/settings.js b/src/api/settings.js
index 1365b2475..892232ab8 100644
--- a/src/api/settings.js
+++ b/src/api/settings.js
@@ -15,6 +15,7 @@ export function testEmailSetting(data) {
data: data
})
}
+
export function importLicense(formData) {
return request({
url: '/api/v1/xpack/license/import',
@@ -25,6 +26,7 @@ export function importLicense(formData) {
data: formData
})
}
+
export function testLdapSetting(data, refresh = true) {
let url = '/api/v1/settings/ldap/testing/config/'
if (refresh) {
@@ -96,9 +98,17 @@ export function getPublicSettings(isOpen) {
method: 'get'
})
}
+
export function getLogo() {
return request({
url: '/api/v1/xpack/interface/setting/',
method: 'get'
})
}
+
+export function getPreference() {
+ return request({
+ url: '/api/v1/users/preference/?category=luna',
+ method: 'get'
+ })
+}
diff --git a/src/components/Apps/AssetTreeTable/index.vue b/src/components/Apps/AssetTreeTable/index.vue
index 33b508107..244dd51c2 100644
--- a/src/components/Apps/AssetTreeTable/index.vue
+++ b/src/components/Apps/AssetTreeTable/index.vue
@@ -32,6 +32,10 @@ export default {
type: String,
default: '/api/v1/assets/assets/'
},
+ typeUrl: {
+ type: String,
+ default: '/api/v1/assets/nodes/category/tree/'
+ },
nodeUrl: {
type: String,
default: '/api/v1/assets/nodes/'
@@ -105,9 +109,9 @@ export default {
showAssets: false,
showSearch: false,
customTreeHeaderName: this.$t('TypeTree'),
- url: '/api/v1/assets/nodes/category/tree/',
+ url: this.typeUrl,
nodeUrl: this.treeSetting?.nodeUrl || this.nodeUrl,
- treeUrl: `/api/v1/assets/nodes/category/tree/?assets=${showAssets ? '1' : '0'}&count_resource=${this.treeSetting.countResource || 'asset'}`,
+ treeUrl: `${this.typeUrl}?assets=${showAssets ? '1' : '0'}&count_resource=${this.treeSetting.countResource || 'asset'}`,
callback: {
onSelected: (event, treeNode) => this.getAssetsUrl(treeNode)
}
diff --git a/src/components/Cards/DetailCard/ItemValue.vue b/src/components/Cards/DetailCard/ItemValue.vue
index f8b76c4a7..4b1bccf70 100644
--- a/src/components/Cards/DetailCard/ItemValue.vue
+++ b/src/components/Cards/DetailCard/ItemValue.vue
@@ -78,7 +78,7 @@ export default {
formatterData = data
}
return (
- {formatterData}
+ {formatterData}
)
}
if (this.value instanceof Array) {
diff --git a/src/components/Dialog/index.vue b/src/components/Dialog/index.vue
index cbed6fe07..23ea0e696 100644
--- a/src/components/Dialog/index.vue
+++ b/src/components/Dialog/index.vue
@@ -123,6 +123,7 @@ export default {
&__body {
padding: 20px 30px;
+ font-size: 13px;
&:has(.el-table) {
background: #f3f3f4;
diff --git a/src/components/Form/AutoDataForm/index.vue b/src/components/Form/AutoDataForm/index.vue
index 2168d3841..cb233523d 100644
--- a/src/components/Form/AutoDataForm/index.vue
+++ b/src/components/Form/AutoDataForm/index.vue
@@ -7,7 +7,7 @@
v-bind="$attrs"
v-on="$listeners"
>
-
-
+
diff --git a/src/components/Form/AutoDataForm/utils.js b/src/components/Form/AutoDataForm/utils.js
index 55deadb1b..ac4b1f077 100644
--- a/src/components/Form/AutoDataForm/utils.js
+++ b/src/components/Form/AutoDataForm/utils.js
@@ -7,7 +7,6 @@ import BasicTree from '@/components/Form/FormFields/BasicTree.vue'
import JsonEditor from '@/components/Form/FormFields/JsonEditor.vue'
import { assignIfNot, toSentenceCase } from '@/utils/common'
import TagInput from '@/components/Form/FormFields/TagInput.vue'
-import TransferSelect from '@/components/Form/FormFields/TransferSelect.vue'
import i18n from '@/i18n/i18n'
export class FormFieldGenerator {
@@ -135,9 +134,6 @@ export class FormFieldGenerator {
case 'comment':
field.el.type = 'textarea'
break
- case 'users':
- field.component = TransferSelect
- field.el.label = field.label
}
return field
}
diff --git a/src/components/Form/DataForm/components/el-form-renderer/components/render-form-item.vue b/src/components/Form/DataForm/components/el-form-renderer/components/render-form-item.vue
index e73ea0578..93a678483 100755
--- a/src/components/Form/DataForm/components/el-form-renderer/components/render-form-item.vue
+++ b/src/components/Form/DataForm/components/el-form-renderer/components/render-form-item.vue
@@ -17,7 +17,7 @@
placement="right"
popper-class="help-tips"
>
-
+
@@ -322,4 +322,9 @@ export default {
cursor: pointer;
}
}
+
+.help-tip-content {
+ white-space: pre-wrap;
+ word-wrap: break-word;
+}
diff --git a/src/components/Form/FormFields/InputWithUnit.vue b/src/components/Form/FormFields/InputWithUnit.vue
index bcd4568a2..09010e379 100644
--- a/src/components/Form/FormFields/InputWithUnit.vue
+++ b/src/components/Form/FormFields/InputWithUnit.vue
@@ -1,5 +1,5 @@
-
+
{{ iUnit }}
@@ -30,9 +30,6 @@ export default {
computed: {
iUnit() {
return this.displayMapper[this.unit] || this.unit
- },
- iValue() {
- return this.$attrs.value ? this.$attrs.value : this.defaultValue
}
}
}
diff --git a/src/components/Form/FormFields/PasswordRule.vue b/src/components/Form/FormFields/PasswordRule.vue
index 8f7424833..dd578a58a 100644
--- a/src/components/Form/FormFields/PasswordRule.vue
+++ b/src/components/Form/FormFields/PasswordRule.vue
@@ -48,7 +48,8 @@ export default {
type: 'input-number',
el: {
min: 8,
- max: 30
+ max: 36,
+ size: 'mini'
}
},
{
diff --git a/src/components/Form/FormFields/UserPassword.vue b/src/components/Form/FormFields/UserPassword.vue
index 2d3daecaf..441dfa5dd 100644
--- a/src/components/Form/FormFields/UserPassword.vue
+++ b/src/components/Form/FormFields/UserPassword.vue
@@ -42,7 +42,7 @@ export default {
patterns.push([/\d/, i18n.t('NUMBER_REQUIRED')])
}
if (passwordRule['SECURITY_PASSWORD_SPECIAL_CHAR']) {
- const pattern = new RegExp("[`~!@#$^&*()=|{}':;',\\[\\].<>/?~!@#¥……&*()——|{}【】‘;:”“'。,、?]")
+ const pattern = new RegExp("[`~!@#$^&*()=|{}':;',\\[\\].<>/?~!@#¥……&*()——|{}【】‘;:”“'。,、?_+-]")
patterns.push([pattern, i18n.t('SPECIAL_CHAR_REQUIRED')])
}
for (const [pattern, msg] of patterns) {
diff --git a/src/components/Table/TableFormatters/LabelsFormatter.vue b/src/components/Table/TableFormatters/LabelsFormatter.vue
index f3067a0bc..cb9cf4b48 100644
--- a/src/components/Table/TableFormatters/LabelsFormatter.vue
+++ b/src/components/Table/TableFormatters/LabelsFormatter.vue
@@ -131,6 +131,16 @@ export default {
}
},
computed: {},
+ watch: {
+ cellValue: {
+ handler(newValue) {
+ if (newValue) {
+ this.initial = this.formatterArgs.getLabels(this.cellValue)
+ this.iLabels = [...this.initial]
+ }
+ }
+ }
+ },
mounted() {
this.initial = this.formatterArgs.getLabels(this.cellValue)
this.iLabels = [...this.initial]
diff --git a/src/layout/components/NavHeader/index.vue b/src/layout/components/NavHeader/index.vue
index a2f7de1b9..83fdcefa4 100644
--- a/src/layout/components/NavHeader/index.vue
+++ b/src/layout/components/NavHeader/index.vue
@@ -176,7 +176,7 @@ export default {
// 未找到与之对应的
& ::v-deep .el-submenu__title {
- font-family: "open sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
+ font-family: "Open Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
padding: 0 8px;
line-height: $headerHeight;
height: $headerHeight;
diff --git a/src/styles/index.scss b/src/styles/index.scss
index d692e30aa..9741489d7 100644
--- a/src/styles/index.scss
+++ b/src/styles/index.scss
@@ -38,7 +38,7 @@ body {
-moz-osx-font-smoothing: grayscale;
-webkit-font-smoothing: auto;
color: var(--color-text-primary);
- font-family: "open sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
+ font-family: "Open Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 13px;
line-height: 1.428;
}
@@ -593,3 +593,9 @@ li.rmenu i.fa {
height: 6px; /* 设置水平滚动条的高度 */
}
}
+
+.black-theme-popover {
+ width: 300px;
+ max-height: 700px;
+ overflow-y: scroll;
+}
diff --git a/src/styles/menu.scss b/src/styles/menu.scss
index f6be8d70e..1265e4b52 100644
--- a/src/styles/menu.scss
+++ b/src/styles/menu.scss
@@ -23,6 +23,10 @@ $single-menu-height: 38px;
}
}
+.el-menu--vertical {
+ background-color: #fff;
+}
+
.el-menu {
border-right: none !important;
background-color: inherit !important;
@@ -139,6 +143,10 @@ $single-menu-height: 38px;
.nest-menu .level2-menu {
line-height: $single-menu-height;
}
+
+ .el-tooltip {
+ width: 55px !important;
+ }
}
}
}
diff --git a/src/utils/common.js b/src/utils/common.js
index 388fef90f..5fdbfa3c6 100644
--- a/src/utils/common.js
+++ b/src/utils/common.js
@@ -128,6 +128,8 @@ export function getErrorResponseMsg(error) {
}).filter(i => i).join('; ')
} else if (typeof data === 'string') {
return data
+ } else {
+ msg = error.toString()
}
return msg
}
@@ -310,4 +312,26 @@ export function toSentenceCase(string) {
}).join(' ')
return s[0].toUpperCase() + s.slice(1)
}
+
export { BASE_URL }
+
+export function openNewWindow(url) {
+ let count
+ let top = 50
+ count = parseInt(window.sessionStorage.getItem('newWindowCount'), 10)
+ if (isNaN(count)) {
+ count = 0
+ }
+ let left = 100 + count * 100
+ top = 50 + count * 50
+ if (left + screen.width / 3 > screen.width) {
+ // 支持两排足以
+ top = screen.height / 3
+ count = 1
+ left = 100
+ }
+ let params = 'toolbar=yes,scrollbars=yes,resizable=yes'
+ params = params + `,top=${top},left=${left},width=${screen.width / 3},height=${screen.height / 3}`
+ window.sessionStorage.setItem('newWindowCount', `${count + 1}`)
+ window.open(url, '_blank', params)
+}
diff --git a/src/views/accounts/AccountChangeSecret/AccountChangeSecretCreateUpdate.vue b/src/views/accounts/AccountChangeSecret/AccountChangeSecretCreateUpdate.vue
index b722d700b..52fa9b16c 100644
--- a/src/views/accounts/AccountChangeSecret/AccountChangeSecretCreateUpdate.vue
+++ b/src/views/accounts/AccountChangeSecret/AccountChangeSecretCreateUpdate.vue
@@ -19,7 +19,7 @@ export default {
initial: {
is_periodic: false,
password_rules: {
- length: 16
+ length: 36
},
interval: 24,
accounts: [],
diff --git a/src/views/accounts/AccountPush/AccountPushCreateUpdate.vue b/src/views/accounts/AccountPush/AccountPushCreateUpdate.vue
index 39c095290..87688d4e1 100644
--- a/src/views/accounts/AccountPush/AccountPushCreateUpdate.vue
+++ b/src/views/accounts/AccountPush/AccountPushCreateUpdate.vue
@@ -21,7 +21,7 @@ export default {
initial: {
is_periodic: false,
password_rules: {
- length: 30
+ length: 36
},
interval: 24,
secret_type: 'password',
diff --git a/src/views/accounts/const.js b/src/views/accounts/const.js
index 4d9a94b54..fecd4826b 100644
--- a/src/views/accounts/const.js
+++ b/src/views/accounts/const.js
@@ -4,7 +4,7 @@ import InputWithUnit from '@/components/Form/FormFields/InputWithUnit.vue'
import store from '@/store'
const validatorInterval = (rule, value, callback) => {
- if (parseInt(value) < 1) {
+ if (isNaN(parseInt(value, 10)) || parseInt(value) < 1) {
return callback(new Error(i18n.t('EnsureThisValueIsGreaterThanOrEqualTo1')))
}
callback()
diff --git a/src/views/acl/CommandAcl/index.vue b/src/views/acl/CommandAcl/index.vue
index 9c58d8f09..5101940f8 100644
--- a/src/views/acl/CommandAcl/index.vue
+++ b/src/views/acl/CommandAcl/index.vue
@@ -2,7 +2,6 @@
@@ -35,18 +34,6 @@ export default {
]
}
}
- },
- methods: {
- handleTabClick(tab) {
- const query = _.cloneDeep(this.$route.query)
- const newQuery = {
- ...query,
- tab: tab.name
- }
- this.$nextTick(() => {
- this.$router.replace({ query: newQuery })
- })
- }
}
}
diff --git a/src/views/assets/Asset/AssetList/AllList.vue b/src/views/assets/Asset/AssetList/AllList.vue
index e4925c7ec..94cff56d9 100644
--- a/src/views/assets/Asset/AssetList/AllList.vue
+++ b/src/views/assets/Asset/AssetList/AllList.vue
@@ -48,7 +48,8 @@ export default {
},
tableConfig: {
url: tableUrl,
- category: 'all'
+ category: 'all',
+ extraQuery: { 'order': '-date_updated' }
},
headerActions: {
handleImportClick: ({ selectedRows }) => {
diff --git a/src/views/assets/Cloud/Account/components/TimingPanel.vue b/src/views/assets/Cloud/Account/components/TimingPanel.vue
index 3d15c4196..a89b2af24 100644
--- a/src/views/assets/Cloud/Account/components/TimingPanel.vue
+++ b/src/views/assets/Cloud/Account/components/TimingPanel.vue
@@ -73,13 +73,7 @@ export default {
btn.loading = true
}
})
-
- if (form.value.interval && typeof form.value.interval === 'number') {
- form.value.interval = parseInt(form.value.interval, 10)
- } else {
- form.value.interval = 24
- }
-
+ form.value.interval = parseInt(form.value.interval, 10)
this.$refs.form.$refs.form.dataForm.submitForm('form', false)
},
handleSubmitSuccess(res) {
diff --git a/src/views/assets/Cloud/Strategy/components/ActionInput.vue b/src/views/assets/Cloud/Strategy/components/ActionInput.vue
index b3cd79448..632784159 100644
--- a/src/views/assets/Cloud/Strategy/components/ActionInput.vue
+++ b/src/views/assets/Cloud/Strategy/components/ActionInput.vue
@@ -39,7 +39,8 @@ export default {
submitBtnSize: 'mini',
submitBtnText: this.$t('Add'),
hasReset: false,
- onSubmit: () => {},
+ onSubmit: () => {
+ },
submitMethod: () => 'post',
getUrl: () => '',
cleanFormValue(data) {
@@ -86,7 +87,11 @@ export default {
this.formConfig.fieldsMeta.protocols.el.hidden = true
}
this.resourceType = val
- this.formConfig.fieldsMeta.value.el.ajax.url = url
+ if (url) {
+ this.formConfig.fieldsMeta.value.el.ajax.url = url
+ } else {
+ this.formConfig.fieldsMeta.attr.el.remote = false
+ }
this.formConfig.fieldsMeta.value.el.options = options
}
}
@@ -151,21 +156,31 @@ export default {
tableConfig: {
columns: [
{ prop: 'attr', label: this.$t('ResourceType'), formatter: tableFormatter('resource_type') },
- { prop: 'value', label: this.$t('Resource'), formatter: tableFormatter('resource', () => { return this.globalResource }) },
+ {
+ prop: 'value', label: this.$t('Resource'), formatter: tableFormatter('resource', () => {
+ return this.globalResource
+ })
+ },
{ prop: 'protocols', label: this.$t('Other'), formatter: tableFormatter('protocols') },
- { prop: 'action', label: this.$t('Action'), align: 'center', width: '100px', formatter: (row, col, cellValue, index) => {
- return (
-
-
-
- )
- } }
+ {
+ prop: 'action',
+ label: this.$t('Action'),
+ align: 'center',
+ width: '100px',
+ formatter: (row, col, cellValue, index) => {
+ return (
+
+
+
+ )
+ }
+ }
],
totalData: this.value || [],
hasPagination: false
@@ -177,7 +192,9 @@ export default {
},
methods: {
init() {
- this.nameOptions.map((o) => { this.globalResource[o.value] = o.label })
+ this.nameOptions.map((o) => {
+ this.globalResource[o.value] = o.label
+ })
},
onSubmit() {
this.$emit('input', this.tableConfig.totalData)
@@ -218,9 +235,11 @@ export default {
::v-deep .el-form-item:nth-child(-n+3) {
width: 43.5%;
}
+
::v-deep .el-form-item:last-child {
width: 6%;
}
+
.action-input {
margin-top: -10px;
}
diff --git a/src/views/assets/Platform/PlatformList.vue b/src/views/assets/Platform/PlatformList.vue
index fdfe78ec2..b8dc7c8c5 100644
--- a/src/views/assets/Platform/PlatformList.vue
+++ b/src/views/assets/Platform/PlatformList.vue
@@ -162,7 +162,7 @@ export default {
},
activated() {
setTimeout(() => {
- this.tab.activeMenu = window.localStorage.getItem('lastTab')
+ this.tab.activeMenu = window.localStorage.getItem('lastTab') || 'host'
this.$refs.genericListTable.reloadTable()
}, 300)
},
diff --git a/src/views/dashboard/components/ProgressChart.vue b/src/views/dashboard/components/ProgressChart.vue
index cdfe46cd3..95afb9d48 100644
--- a/src/views/dashboard/components/ProgressChart.vue
+++ b/src/views/dashboard/components/ProgressChart.vue
@@ -128,7 +128,8 @@ export default {
tip += current.label + ':' + current.total + '
'
}
return tip
- }
+ },
+ appendToBody: true
},
grid: {
top: '60%',
diff --git a/src/views/ops/Adhoc/QuickJob.vue b/src/views/ops/Adhoc/QuickJob.vue
index 6c93c038f..22ccb6067 100644
--- a/src/views/ops/Adhoc/QuickJob.vue
+++ b/src/views/ops/Adhoc/QuickJob.vue
@@ -35,6 +35,7 @@
diff --git a/src/views/settings/Msg/Subscribe/index.vue b/src/views/settings/Msg/Subscribe/index.vue
index 72e6157ad..ea3e8eeca 100644
--- a/src/views/settings/Msg/Subscribe/index.vue
+++ b/src/views/settings/Msg/Subscribe/index.vue
@@ -26,11 +26,14 @@
-
-
-
- {{ scope.row.receivers.map(item => item.name).join(', ') }}
-
+
+
+
+ {{ item.name }}
+
+ {{ scope.row.receivers.map(item => item.name).join(', ') }}
+
+
@@ -186,4 +189,25 @@ export default {
margin-bottom: 0;
width: 50%;
}
+
+::v-deep .el-table .cell {
+ display: flex;
+
+ .name-wrapper {
+ display: inline-block;
+ max-height: 55px;
+ max-width: 200px;
+ white-space: nowrap;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ vertical-align: middle;
+ cursor: pointer;
+ }
+}
+
+::v-deep .black-theme-popover .el-popover__inner {
+ background-color: #000 !important;
+ color: #fff !important;
+ border-color: #000 !important;
+}
diff --git a/src/views/settings/Terminal/Endpoint/EndpointCreateUpdate.vue b/src/views/settings/Terminal/Endpoint/EndpointCreateUpdate.vue
index 8c93fdd85..2b86444cd 100644
--- a/src/views/settings/Terminal/Endpoint/EndpointCreateUpdate.vue
+++ b/src/views/settings/Terminal/Endpoint/EndpointCreateUpdate.vue
@@ -33,7 +33,7 @@ export default {
'redis_port', 'sqlserver_port', 'oracle_port_range'
]
],
- [this.$t('Other'), ['comment']]
+ [this.$t('Other'), ['is_active', 'comment']]
],
fieldsMeta: {
host: {
@@ -41,13 +41,17 @@ export default {
},
oracle_port_range: {
disabled: true
+ },
+ is_active: {
+ disabled: this.$route.params.id === '00000000-0000-0000-0000-000000000001'
}
},
hasDetailInMsg: false
}
},
computed: {},
- created() {},
+ created() {
+ },
methods: {}
}
diff --git a/src/views/settings/Terminal/Endpoint/EndpointList.vue b/src/views/settings/Terminal/Endpoint/EndpointList.vue
index 3603bee2d..60226af73 100644
--- a/src/views/settings/Terminal/Endpoint/EndpointList.vue
+++ b/src/views/settings/Terminal/Endpoint/EndpointList.vue
@@ -25,7 +25,7 @@ export default {
'name', 'host', 'actions',
'http_port', 'https_port', 'ssh_port', 'rdp_port',
'mysql_port', 'mariadb_port', 'postgresql_port',
- 'redis_port', 'sqlserver_port', 'oracle_port_range'
+ 'redis_port', 'sqlserver_port', 'oracle_port_range', 'is_active'
]
},
columnsMeta: {
diff --git a/src/views/tickets/components/Comments.vue b/src/views/tickets/components/Comments.vue
index 63a9dbbda..ce4d3b04e 100644
--- a/src/views/tickets/components/Comments.vue
+++ b/src/views/tickets/components/Comments.vue
@@ -25,7 +25,7 @@
{{ $t('Accept') }}
this.reloadPage()).catch(err => this.$message.error(err))
+ this.$axios.put(url).then(res => {
+ this.reloadPage()
+ }).catch(err => {
+ this.$message.error(err)
+ }).finally(() => {
+ this.isDisabled = false
+ })
},
defaultReject() {
this.createComment(function() {
})
const url = `/api/v1/tickets/${this.type_api}/${this.object.id}/reject/`
- this.$axios.put(url).then(res => this.reloadPage()).catch(err => this.$message.error(err))
+ this.$axios.put(url).then(res => {
+ this.reloadPage()
+ }).catch(err => {
+ this.$message.error(err)
+ }).finally(() => {
+ this.isDisabled = false
+ })
},
defaultClose() {
const url = `/api/v1/tickets/${this.type_api}/${this.object.id}/close/`
- this.$axios.put(url).then(res => this.reloadPage()).catch(err => this.$message.error(err))
+ this.$axios.put(url).then(res => {
+ this.reloadPage()
+ }).catch(err => {
+ this.$message.error(err)
+ }).finally(() => {
+ this.isDisabled = false
+ })
},
createComment(successCallback) {
const commentText = this.form.comments
@@ -185,17 +204,42 @@ export default {
}
})
},
+ handleAction(actionType) {
+ if (this.isDisabled) {
+ return
+ }
+
+ this.isDisabled = true
+ let handler
+ switch (actionType) {
+ case 'approve':
+ handler = this.approve || this.defaultApprove
+ break
+ case 'reject':
+ handler = this.reject || this.defaultReject
+ break
+ case 'close':
+ handler = this.close || this.defaultClose
+ break
+ default:
+ handler = null
+ break
+ }
+
+ if (handler) {
+ handler()
+ } else {
+ this.$message.error('No handler for action')
+ }
+ },
handleApprove() {
- const handler = this.approve || this.defaultApprove
- handler()
+ this.handleAction('approve')
},
handleReject() {
- const handler = this.reject || this.defaultReject
- handler()
+ this.handleAction('reject')
},
handleClose() {
- const handler = this.close || this.defaultClose
- handler()
+ this.handleAction('close')
},
handleComment() {
this.createComment(
diff --git a/src/views/users/Group/UserGroupCreateUpdate.vue b/src/views/users/Group/UserGroupCreateUpdate.vue
index 8acd8477f..d0810b73b 100644
--- a/src/views/users/Group/UserGroupCreateUpdate.vue
+++ b/src/views/users/Group/UserGroupCreateUpdate.vue
@@ -4,7 +4,6 @@
diff --git a/yarn.lock b/yarn.lock
index b37bd61ef..36723c5ba 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -9227,7 +9227,7 @@ npm-normalize-package-bin@^1.0.0, npm-normalize-package-bin@^1.0.1:
resolved "https://registry.npmjs.org/npm-normalize-package-bin/-/npm-normalize-package-bin-1.0.1.tgz"
integrity sha512-EPfafl6JL5/rU+ot6P3gRSCpPDW5VmIzX959Ob1+ySFUuuYHWHekXpwdUZcKP5C+DS4GEtdJluwBjnsNDl+fSA==
-npm-package-arg@^8.0.0, npm-package-arg@^8.0.1, npm-package-arg@^8.1.0, npm-package-arg@^8.1.2, npm-package-arg@^8.1.4, npm-package-arg@^8.1.5:
+npm-package-arg@^8.0.0, npm-package-arg@^8.0.1, npm-package-arg@^8.1.0, npm-package-arg@^8.1.1, npm-package-arg@^8.1.2, npm-package-arg@^8.1.5:
version "8.1.5"
resolved "https://registry.npmjs.org/npm-package-arg/-/npm-package-arg-8.1.5.tgz"
integrity sha512-LhgZrg0n0VgvzVdSm1oiZworPbTxYHUJCgtsJW8mGvlDpxTM1vSJc3m5QZeUkhAHIzbz3VCHd/R4osi1L1Tg/Q==
@@ -9733,7 +9733,7 @@ p-try@^2.0.0:
resolved "https://registry.npmmirror.com/p-try/-/p-try-2.2.0.tgz"
integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==
-pacote@^11.1.11, pacote@^11.2.6, pacote@^11.3.1, pacote@^11.3.4, pacote@^11.3.5:
+pacote@^11.1.11, pacote@^11.2.6, pacote@^11.3.0, pacote@^11.3.1, pacote@^11.3.5:
version "11.3.5"
resolved "https://registry.npmjs.org/pacote/-/pacote-11.3.5.tgz"
integrity sha512-fT375Yczn4zi+6Hkk2TBe1x1sP8FgFsEIZ2/iWaXY2r/NkhDJfxbcn5paz1+RTFCyNf+dPnaoBDJoAxXSU8Bkg==
@@ -9931,10 +9931,10 @@ path-to-regexp@0.1.7:
resolved "https://registry.npmmirror.com/path-to-regexp/-/path-to-regexp-0.1.7.tgz"
integrity sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==
-path-to-regexp@2.4.0:
- version "2.4.0"
- resolved "https://registry.npmmirror.com/path-to-regexp/-/path-to-regexp-2.4.0.tgz"
- integrity sha512-G6zHoVqC6GGTQkZwF4lkuEyMbVOjoBKAEybQUypI1WTkqinCOrq2x6U2+phkJ1XsEMTy4LjtwPI7HW+NVrRR2w==
+path-to-regexp@3.3.0:
+ version "3.3.0"
+ resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-3.3.0.tgz#f7f31d32e8518c2660862b644414b6d5c63a611b"
+ integrity sha512-qyCH421YQPS2WFDxDjftfc1ZR5WKQzVzqsp4n9M2kQhVOo/ByahFoUNJfl58kOcEGfQ//7weFTDhm+ss8Ecxgw==
path-type@^1.0.0:
version "1.1.0"
@@ -11538,7 +11538,7 @@ serve-index@^1.9.1:
mime-types "~2.1.17"
parseurl "~1.3.2"
-serve-static@1.15.0, serve-static@^1.13.2:
+serve-static@1.15.0:
version "1.15.0"
resolved "https://registry.npmmirror.com/serve-static/-/serve-static-1.15.0.tgz"
integrity sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==
@@ -11548,6 +11548,16 @@ serve-static@1.15.0, serve-static@^1.13.2:
parseurl "~1.3.3"
send "0.18.0"
+serve-static@^1.16.0:
+ version "1.16.0"
+ resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.16.0.tgz#2bf4ed49f8af311b519c46f272bf6ac3baf38a92"
+ integrity sha512-pDLK8zwl2eKaYrs8mrPZBJua4hMplRWJ1tIFksVC3FtBEBnl8dxgeHtsaMS8DhS9i4fLObaon6ABoc4/hQGdPA==
+ dependencies:
+ encodeurl "~1.0.2"
+ escape-html "~1.0.3"
+ parseurl "~1.3.3"
+ send "0.18.0"
+
set-blocking@^2.0.0, set-blocking@~2.0.0:
version "2.0.0"
resolved "https://registry.npmmirror.com/set-blocking/-/set-blocking-2.0.0.tgz"