调整toml格式的内容显示与编辑
This commit is contained in:
@@ -18,7 +18,6 @@
|
|||||||
<!-- Axios -->
|
<!-- Axios -->
|
||||||
<script src="/static/js/axios.min.js"></script>
|
<script src="/static/js/axios.min.js"></script>
|
||||||
|
|
||||||
<script src="https://cdn.jsdelivr.net/npm/@iarna/toml@2.2.5/toml.js"></script>
|
|
||||||
<style>
|
<style>
|
||||||
body {
|
body {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
|||||||
@@ -228,12 +228,6 @@
|
|||||||
try {
|
try {
|
||||||
// 验证TOML格式
|
// 验证TOML格式
|
||||||
let configObj;
|
let configObj;
|
||||||
try {
|
|
||||||
configObj = toml.parse(this.editedConfig);
|
|
||||||
} catch (e) {
|
|
||||||
this.configError = 'TOML格式错误: ' + e.message;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// 发送到后端保存
|
// 发送到后端保存
|
||||||
axios.post('/api/plugins/config/update', {
|
axios.post('/api/plugins/config/update', {
|
||||||
|
|||||||
Reference in New Issue
Block a user