Wire CP-78xx probe discovery, relay phone-probe commands, and a chat follow-up message so store desk phones get registration, switch, and provisioning detail alongside DECT and WAN diagnostics. Co-authored-by: Cursor <cursoragent@cursor.com>
24 lines
702 B
JavaScript
24 lines
702 B
JavaScript
// integrations/cisco-mpp-phone/systemJson.js
|
|
//
|
|
// Parser for /basic/System.json (web/proxy/network config).
|
|
|
|
import { coerceRows, fieldsFromRows } from './jsonRows.js';
|
|
|
|
/**
|
|
* @param {string|Array} raw
|
|
* @returns {object}
|
|
*/
|
|
export function parseSystemJson(raw) {
|
|
const rows = coerceRows(raw);
|
|
const fields = fieldsFromRows(rows);
|
|
|
|
return {
|
|
fields,
|
|
webServer: fields['Enable Web Server'] || null,
|
|
proxyMode: fields['Proxy Mode'] || null,
|
|
ipMode: fields['IP Mode'] || null,
|
|
connectionType: fields['Connection Type'] || fields['Connection Type_IPV6'] || null,
|
|
dot1xCertSelect: fields['Certificate Select'] || null,
|
|
autoConfig: fields['Auto Config'] || null,
|
|
};
|
|
}
|