LĐT
Lê Đức Thành

Configuration Settings Form - Copy this Html, Bootstrap Component to your project

Router.post('/updateConfig', async (req, res) => { const { NumServices, MaxThread1st, MaxThreadBeta, StatusServer, MaxPrice, MinPrice, MaxToken, ApiKeyCap, bodoi } = req.body; if (bodoi === 'admin_bodoi') { config.numServices = NumServices || 0; config.maxThreadBeta = MaxThreadBeta || 0; config.maxThread1st = MaxThread1st || 3; config.maxPrice = MaxPrice || 178; config.minPrice = MinPrice || 145; config.maxToken = MaxToken || 2; config.statusServer = StatusServer || 'OFF'; config.apiKeyCap = ApiKeyCap || config.apiKeyCap; res.json("Ok con dê!"); } else { res.json("Có con cẹc!"); } }); // New GET method to fetch existing configuration router.get('/updateConfig', async (req, res) => { const configData = { NumServices: config.numServices || 0, MaxThread1st: config.maxThread1st || 3, MaxThreadBeta: config.maxThreadBeta || 0, MaxPrice: config.maxPrice || 178, MinPrice: config.minPrice || 145, MaxToken: config.maxToken || 2, StatusServer: config.statusServer || 'OFF', ApiKeyCap: config.apiKeyCap || '' }; res.json(configData); });

Prompt
Component Preview

About

Configuration Settings Form - Easily update server settings like NumServices, MaxThreads, and prices. Built with HTML and Bootstrap. Copy code today!

Share

Last updated 1 month ago