|
@@ -73,6 +73,36 @@ const BatchTaskInstance = defineComponent({
|
|
|
requestTableData()
|
|
|
}
|
|
|
|
|
|
+ const onClearSearchTaskName = () => {
|
|
|
+ variables.searchVal = ''
|
|
|
+ onSearch()
|
|
|
+ }
|
|
|
+
|
|
|
+ const onClearSearchProcessInstanceName = () => {
|
|
|
+ variables.processInstanceName = null
|
|
|
+ onSearch()
|
|
|
+ }
|
|
|
+
|
|
|
+ const onClearSearchExecutorName = () => {
|
|
|
+ variables.executorName = null
|
|
|
+ onSearch()
|
|
|
+ }
|
|
|
+
|
|
|
+ const onClearSearchHost = () => {
|
|
|
+ variables.host = null
|
|
|
+ onSearch()
|
|
|
+ }
|
|
|
+
|
|
|
+ const onClearSearchStateType = () => {
|
|
|
+ variables.stateType = null
|
|
|
+ onSearch()
|
|
|
+ }
|
|
|
+
|
|
|
+ const onClearSearchTime = () => {
|
|
|
+ variables.datePickerRange = null
|
|
|
+ onSearch()
|
|
|
+ }
|
|
|
+
|
|
|
const onConfirmModal = () => {
|
|
|
variables.showModalRef = false
|
|
|
}
|
|
@@ -152,6 +182,12 @@ const BatchTaskInstance = defineComponent({
|
|
|
requestTableData,
|
|
|
onUpdatePageSize,
|
|
|
onSearch,
|
|
|
+ onClearSearchTaskName,
|
|
|
+ onClearSearchProcessInstanceName,
|
|
|
+ onClearSearchExecutorName,
|
|
|
+ onClearSearchHost,
|
|
|
+ onClearSearchStateType,
|
|
|
+ onClearSearchTime,
|
|
|
onConfirmModal,
|
|
|
refreshLogs,
|
|
|
trim
|
|
@@ -178,6 +214,7 @@ const BatchTaskInstance = defineComponent({
|
|
|
size='small'
|
|
|
placeholder={t('project.task.task_name')}
|
|
|
clearable
|
|
|
+ onClear={this.onClearSearchTaskName}
|
|
|
/>
|
|
|
<NInput
|
|
|
allowInput={this.trim}
|
|
@@ -185,6 +222,7 @@ const BatchTaskInstance = defineComponent({
|
|
|
size='small'
|
|
|
placeholder={t('project.task.workflow_instance')}
|
|
|
clearable
|
|
|
+ onClear={this.onClearSearchProcessInstanceName}
|
|
|
/>
|
|
|
<NInput
|
|
|
allowInput={this.trim}
|
|
@@ -192,6 +230,7 @@ const BatchTaskInstance = defineComponent({
|
|
|
size='small'
|
|
|
placeholder={t('project.task.executor')}
|
|
|
clearable
|
|
|
+ onClear={this.onClearSearchExecutorName}
|
|
|
/>
|
|
|
<NInput
|
|
|
allowInput={this.trim}
|
|
@@ -199,6 +238,7 @@ const BatchTaskInstance = defineComponent({
|
|
|
size='small'
|
|
|
placeholder={t('project.task.host')}
|
|
|
clearable
|
|
|
+ onClear={this.onClearSearchHost}
|
|
|
/>
|
|
|
<NSelect
|
|
|
v-model={[this.stateType, 'value']}
|
|
@@ -207,6 +247,7 @@ const BatchTaskInstance = defineComponent({
|
|
|
placeholder={t('project.task.state')}
|
|
|
style={{ width: '180px' }}
|
|
|
clearable
|
|
|
+ onClear={this.onClearSearchStateType}
|
|
|
/>
|
|
|
<NDatePicker
|
|
|
v-model={[this.datePickerRange, 'value']}
|
|
@@ -215,6 +256,7 @@ const BatchTaskInstance = defineComponent({
|
|
|
start-placeholder={t('project.task.start_time')}
|
|
|
end-placeholder={t('project.task.end_time')}
|
|
|
clearable
|
|
|
+ onClear={this.onClearSearchTime}
|
|
|
/>
|
|
|
<NButton size='small' type='primary' onClick={onSearch}>
|
|
|
<NIcon>
|