83 lines
2.0 KiB
Vue
83 lines
2.0 KiB
Vue
<!--
|
|
* @Date: 2021-01-07 20:09:37
|
|
* @LastEditors: zwq
|
|
* @LastEditTime: 2022-03-19 13:47:06
|
|
* @FilePath: \basic-admin\src\components\BaseTable\subcomponents\CheckDetail.vue
|
|
* @Description:
|
|
-->
|
|
<template>
|
|
<span>
|
|
<el-popover
|
|
v-model="visible"
|
|
placement="top"
|
|
width="160"
|
|
>
|
|
<div>
|
|
<el-select v-model="value" :placeholder="$t('module.basicData.Warehouse.RelateProcess')">
|
|
<el-option
|
|
v-for="item in options"
|
|
:key="item.id"
|
|
:label="item.name"
|
|
:value="item.id"
|
|
/>
|
|
</el-select>
|
|
</div>
|
|
<div style="text-align: right; margin: 0">
|
|
<el-button size="mini" type="text" @click="visible = false">{{ 'btn.cancel' | i18nFilter }}</el-button>
|
|
<el-button type="primary" size="mini" @click="emitClick">{{ 'btn.confirm' | i18nFilter }}</el-button>
|
|
</div>
|
|
<el-button slot="reference" type="text">{{ $t('module.basicData.Warehouse.RelateProcess') }}</el-button>
|
|
</el-popover>
|
|
</span>
|
|
</template>
|
|
|
|
<script>
|
|
import { list } from '@/api/art-manage/art.js'
|
|
import { ProcessInfoUpdata } from '@/api/orderManage/00A'
|
|
export default {
|
|
props: {
|
|
injectData: {
|
|
type: Object,
|
|
default: () => ({})
|
|
}
|
|
},
|
|
data() {
|
|
return {
|
|
visible: false,
|
|
options: [],
|
|
value: ''
|
|
}
|
|
},
|
|
created() {
|
|
this.init()
|
|
},
|
|
methods: {
|
|
init() {
|
|
list({
|
|
current: 1,
|
|
size: 999
|
|
}).then(response => {
|
|
this.options = response.data.records
|
|
})
|
|
this.value = this.injectData.processId
|
|
},
|
|
emitClick() {
|
|
const data = {
|
|
id: this.injectData.id,
|
|
subProcessId: this.value
|
|
}
|
|
ProcessInfoUpdata(data).then(res => {
|
|
this.$message({
|
|
message: this.$t('module.basicData.visual.success'),
|
|
type: 'success',
|
|
duration: 1500,
|
|
onClose: () => {
|
|
this.visible = false
|
|
}
|
|
})
|
|
})
|
|
}
|
|
}
|
|
}
|
|
</script>
|