fix: 修复复制应用和函数库问题
This commit is contained in:
parent
fa463231c5
commit
7a596eb853
@ -132,8 +132,9 @@ watch(dialogVisible, (bool) => {
|
|||||||
})
|
})
|
||||||
|
|
||||||
const open = (data: any) => {
|
const open = (data: any) => {
|
||||||
delete data['id']
|
const obj = cloneDeep(data)
|
||||||
applicationForm.value = cloneDeep(data)
|
delete obj['id']
|
||||||
|
applicationForm.value = obj
|
||||||
dialogVisible.value = true
|
dialogVisible.value = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -71,6 +71,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, onMounted, reactive } from 'vue'
|
import { ref, onMounted, reactive } from 'vue'
|
||||||
|
import { cloneDeep } from 'lodash'
|
||||||
import functionLibApi from '@/api/function-lib'
|
import functionLibApi from '@/api/function-lib'
|
||||||
import FunctionFormDrawer from './component/FunctionFormDrawer.vue'
|
import FunctionFormDrawer from './component/FunctionFormDrawer.vue'
|
||||||
import { MsgSuccess, MsgConfirm } from '@/utils/message'
|
import { MsgSuccess, MsgConfirm } from '@/utils/message'
|
||||||
@ -120,8 +121,9 @@ function deleteFunctionLib(row: any) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function copyFunctionLib(row: any) {
|
function copyFunctionLib(row: any) {
|
||||||
delete row['id']
|
const obj = cloneDeep(row)
|
||||||
functionLibApi.postFunctionLib(row, loading).then((res) => {
|
delete obj['id']
|
||||||
|
functionLibApi.postFunctionLib(obj, loading).then((res) => {
|
||||||
MsgSuccess('复制成功')
|
MsgSuccess('复制成功')
|
||||||
paginationConfig.total = 0
|
paginationConfig.total = 0
|
||||||
paginationConfig.current_page = 1
|
paginationConfig.current_page = 1
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user