feat(proxy): update proxy edit api to feat "oldName" && "newName"
This commit is contained in:
@@ -323,6 +323,7 @@ export default {
|
||||
const showDeleteProxyModal = ref(false);
|
||||
const isEditProxy = ref(false);
|
||||
const selectedProxyName = ref('');
|
||||
const originalProxyName = ref('');
|
||||
const loading = ref(false);
|
||||
const userType = ref(getCookie('user-type') || 'visitor');
|
||||
const formData = ref({
|
||||
@@ -544,6 +545,7 @@ export default {
|
||||
|
||||
const editProxy = (proxy) => {
|
||||
isEditProxy.value = true;
|
||||
originalProxyName.value = proxy.name;
|
||||
formData.value = {
|
||||
name: proxy.name,
|
||||
type: proxy.type,
|
||||
@@ -577,6 +579,7 @@ export default {
|
||||
const closeAddProxyModal = () => {
|
||||
showAddProxyModal.value = false;
|
||||
selectedProxyName.value = '';
|
||||
originalProxyName.value = '';
|
||||
};
|
||||
|
||||
const closeEditConfigModal = () => {
|
||||
@@ -601,7 +604,8 @@ export default {
|
||||
loading.value = true;
|
||||
try {
|
||||
const proxyInfo = {
|
||||
name: formData.value.name,
|
||||
oldName: isEditProxy.value ? originalProxyName.value : undefined,
|
||||
newName: formData.value.name,
|
||||
type: formData.value.type,
|
||||
localIP: formData.value.localIP,
|
||||
localPort: formData.value.localPort,
|
||||
@@ -720,6 +724,7 @@ export default {
|
||||
showDeleteProxyModal,
|
||||
isEditProxy,
|
||||
selectedProxyName,
|
||||
originalProxyName,
|
||||
loading,
|
||||
formData,
|
||||
goBack,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { defineConfig } from 'vite'
|
||||
import vue from '@vitejs/plugin-vue'
|
||||
|
||||
const APP_TARGET = '192.168.20.4:19090'
|
||||
const APP_TARGET = '192.168.1.19:19090'
|
||||
|
||||
export default defineConfig({
|
||||
define: {
|
||||
|
||||
Reference in New Issue
Block a user