Browse Source

Repair worklist cannot be deleted

pull/3/MERGE
break60 5 years ago
parent
commit
8583b60df5
  1. 22
      dolphinscheduler-ui/src/js/conf/home/pages/projects/pages/definition/pages/list/_source/list.vue
  2. 24
      dolphinscheduler-ui/src/js/conf/home/pages/projects/pages/instance/pages/list/_source/list.vue

22
dolphinscheduler-ui/src/js/conf/home/pages/projects/pages/definition/pages/list/_source/list.vue

@ -86,7 +86,7 @@
<span v-if="item.scheduleReleaseState === 'ONLINE'">{{$t('online')}}</span> <span v-if="item.scheduleReleaseState === 'ONLINE'">{{$t('online')}}</span>
<span v-if="!item.scheduleReleaseState">-</span> <span v-if="!item.scheduleReleaseState">-</span>
</td> </td>
<td> <td style="z-index: inherit;">
<x-button type="info" shape="circle" size="xsmall" data-toggle="tooltip" :title="$t('Edit')" @click="_edit(item)" :disabled="item.releaseState === 'ONLINE'" icon="ans-icon-edit"><!--{{$t('编辑')}}--></x-button> <x-button type="info" shape="circle" size="xsmall" data-toggle="tooltip" :title="$t('Edit')" @click="_edit(item)" :disabled="item.releaseState === 'ONLINE'" icon="ans-icon-edit"><!--{{$t('编辑')}}--></x-button>
<x-button type="success" shape="circle" size="xsmall" data-toggle="tooltip" :title="$t('Start')" @click="_start(item)" :disabled="item.releaseState !== 'ONLINE'" icon="ans-icon-play"><!--{{$t('启动')}}--></x-button> <x-button type="success" shape="circle" size="xsmall" data-toggle="tooltip" :title="$t('Start')" @click="_start(item)" :disabled="item.releaseState !== 'ONLINE'" icon="ans-icon-play"><!--{{$t('启动')}}--></x-button>
<x-button type="info" shape="circle" size="xsmall" data-toggle="tooltip" :title="$t('Timing')" @click="_timing(item)" :disabled="item.releaseState !== 'ONLINE' || item.scheduleReleaseState !== null" icon="ans-icon-timer"><!--{{$t('定时')}}--></x-button> <x-button type="info" shape="circle" size="xsmall" data-toggle="tooltip" :title="$t('Timing')" @click="_timing(item)" :disabled="item.releaseState !== 'ONLINE' || item.scheduleReleaseState !== null" icon="ans-icon-timer"><!--{{$t('定时')}}--></x-button>
@ -122,20 +122,6 @@
</tr> </tr>
</table> </table>
</div> </div>
<x-poptip
v-show="strSelectIds !== ''"
ref="poptipDeleteAll"
placement="bottom-start"
width="90">
<p>{{$t('Delete?')}}</p>
<div style="text-align: right; margin: 0;padding-top: 4px;">
<x-button type="text" size="xsmall" shape="circle" @click="_closeDelete(-1)">{{$t('Cancel')}}</x-button>
<x-button type="primary" size="xsmall" shape="circle" @click="_delete({},-1)">{{$t('Confirm')}}</x-button>
</div>
<template slot="reference">
<x-button size="xsmall" style="position: absolute; bottom: -48px; left: 22px;" >{{$t('Delete')}}</x-button>
</template>
</x-poptip>
<template v-if="strSelectIds !== ''"> <template v-if="strSelectIds !== ''">
<x-button size="xsmall" style="position: absolute; bottom: -48px; left: 80px;" @click="_batchExport(item)" >{{$t('Export')}}</x-button> <x-button size="xsmall" style="position: absolute; bottom: -48px; left: 80px;" @click="_batchExport(item)" >{{$t('Export')}}</x-button>
@ -264,11 +250,7 @@
* Close the delete layer * Close the delete layer
*/ */
_closeDelete (i) { _closeDelete (i) {
if (i > 0) { this.$refs[`poptip-delete-${i}`][0].doClose()
this.$refs[`poptip-delete-${i}`][0].doClose()
}else{
this.$refs['poptipDeleteAll'].doClose()
}
}, },
/** /**
* delete * delete

24
dolphinscheduler-ui/src/js/conf/home/pages/projects/pages/instance/pages/list/_source/list.vue

@ -99,7 +99,7 @@
<span style="word-break: break-all" v-if="item.executorName">{{item.executorName}}</span> <span style="word-break: break-all" v-if="item.executorName">{{item.executorName}}</span>
<span v-else>-</span> <span v-else>-</span>
</td> </td>
<td> <td style="z-index: inherit;">
<div v-show="item.disabled"> <div v-show="item.disabled">
<x-button type="info" <x-button type="info"
shape="circle" shape="circle"
@ -143,7 +143,7 @@
:disabled="item.state !== 'RUNNING_EXEUTION' && item.state !== 'PAUSE'"></x-button> :disabled="item.state !== 'RUNNING_EXEUTION' && item.state !== 'PAUSE'"></x-button>
<x-poptip <x-poptip
:ref="'poptip-delete-' + $index" :ref="'poptip-delete-' + $index"
placement="bottom-end" placement="top-end"
width="90"> width="90">
<p>{{$t('Delete?')}}</p> <p>{{$t('Delete?')}}</p>
<div style="text-align: right; margin: 0;padding-top: 4px;"> <div style="text-align: right; margin: 0;padding-top: 4px;">
@ -287,20 +287,6 @@
</tr> </tr>
</table> </table>
</div> </div>
<x-poptip
v-show="strDelete !== ''"
ref="poptipDeleteAll"
placement="bottom-start"
width="90">
<p>{{$t('Delete?')}}</p>
<div style="text-align: right; margin: 0;padding-top: 4px;">
<x-button type="text" size="xsmall" shape="circle" @click="_closeDelete(-1)">{{$t('Cancel')}}</x-button>
<x-button type="primary" size="xsmall" shape="circle" @click="_delete({},-1)">{{$t('Confirm')}}</x-button>
</div>
<template slot="reference">
<x-button size="xsmall" style="position: absolute; bottom: -48px; left: 22px;" >{{$t('Delete')}}</x-button>
</template>
</x-poptip>
</div> </div>
</template> </template>
<script> <script>
@ -344,11 +330,7 @@
* Close the delete layer * Close the delete layer
*/ */
_closeDelete (i) { _closeDelete (i) {
if (i > 0) { this.$refs[`poptip-delete-${i}`][0].doClose()
this.$refs[`poptip-delete-${i}`][0].doClose()
}else{
this.$refs['poptipDeleteAll'].doClose()
}
}, },
/** /**
* delete * delete

Loading…
Cancel
Save