| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- import { disableDeleteAction } from '@/utils/common/tableActions'
- import i18n from '@/locales'
- export default {
- created () {
- this.singleActions = [
- {
- label: i18n.t('middleware.syncstatus'),
- permission: 'elastic_searchs_perform_syncstatus',
- action: obj => {
- this.onManager('performAction', {
- steadyStatus: ['available'],
- id: obj.id,
- managerArgs: {
- action: 'syncstatus',
- },
- })
- },
- meta: () => ({
- validate: true,
- }),
- },
- {
- label: i18n.t('middleware.more'),
- actions: (obj) => {
- return [
- disableDeleteAction(Object.assign(this, {
- permission: 'elastic_searchs_update',
- }), {
- name: this.$t('dictionary.elasticsearch'),
- }),
- {
- label: i18n.t('middleware.delete'),
- permission: 'elastic_searchs_delete',
- action: () => {
- this.createDialog('DeleteResDialog', {
- vm: this,
- title: i18n.t('middleware.delete'),
- name: this.$t('dictionary.elasticsearch'),
- data: [obj],
- columns: this.columns,
- onManager: this.onManager,
- refresh: this.refresh,
- })
- },
- meta: () => this.$getDeleteResult(obj),
- },
- ]
- },
- },
- ]
- },
- }
|