Update App.jsx via upload script - 2026-08-01 18:59:03
This commit is contained in:
parent
e8b80c802d
commit
11db4b9dd5
12
App.jsx
12
App.jsx
|
|
@ -4477,6 +4477,18 @@ function JmsPage({ lines, onSave, onDelete, onCheck, onNotify, dragIdx, onDragSt
|
|||
|
||||
function handleSave() {
|
||||
if (!draft.addr || !draft.port) { onNotify('请填写服务器地址和端口'); return; }
|
||||
const missing = [];
|
||||
if (group === 'selfbuilt') {
|
||||
if (!draft.uuid) missing.push('UUID');
|
||||
} else if (protocol === 'ss') {
|
||||
if (!draft.password) missing.push('密码');
|
||||
} else if (protocol === 'vless-reality') {
|
||||
if (!draft.uuid) missing.push('UUID');
|
||||
if (!draft.publicKey) missing.push('Public Key');
|
||||
if (!draft.shortId) missing.push('Short ID');
|
||||
if (!draft.sni) missing.push('SNI');
|
||||
}
|
||||
if (missing.length) { onNotify(`请填写:${missing.join('、')}`); return; }
|
||||
onSave({ ...draft, group, protocol }, editingId);
|
||||
closeModal();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue