mirror of
https://dev.iopsys.eu/bbf/bbfdm.git
synced 2026-02-28 15:17:39 +01:00
Added json plugin for Device.CWMPManagementServer.
This commit is contained in:
parent
a4c67d5a05
commit
3f1d9e6b90
3 changed files with 41 additions and 7 deletions
|
|
@ -452,13 +452,7 @@ int dm_entry_restart_services(void)
|
|||
bbf_uci_commit_bbfdm();
|
||||
|
||||
list_for_each_entry(pc, &head_package_change, list) {
|
||||
if (strcmp(pc->package, "cwmp") == 0) {
|
||||
dmuci_init();
|
||||
dmuci_commit_package("cwmp");
|
||||
dmuci_exit();
|
||||
} else {
|
||||
dmubus_call_set("uci", "commit", UBUS_ARGS{{"config", pc->package, String}}, 1);
|
||||
}
|
||||
dmubus_call_set("uci", "commit", UBUS_ARGS{{"config", pc->package, String}}, 1);
|
||||
}
|
||||
|
||||
dmuci_commit_package_varstate("cwmp");
|
||||
|
|
|
|||
|
|
@ -49,6 +49,10 @@ echo "Validate X_IOPSYS_EU_URLFilter JSON Plugin"
|
|||
./tools/validate_json_plugin.py test/files/etc/bbfdm/json/urlfilter.json
|
||||
check_ret $?
|
||||
|
||||
echo "Validate CWMPManagementServer JSON Plugin"
|
||||
./tools/validate_json_plugin.py test/files/etc/bbfdm/json/cwmp_management_server.json
|
||||
check_ret $?
|
||||
|
||||
echo "Validate TR-181 JSON Plugin after generating from XML"
|
||||
json_path=$(./tools/convert_dm_xml_to_json.py test/tools/tr-181-2-15-0-cwmp-full.xml test/tools/tr-181-2-15-0-usp-full.xml Device.)
|
||||
./tools/validate_json_plugin.py $json_path
|
||||
|
|
|
|||
36
test/files/etc/bbfdm/json/cwmp_management_server.json
Normal file
36
test/files/etc/bbfdm/json/cwmp_management_server.json
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
{
|
||||
"json_plugin_version": 1,
|
||||
"Device.CWMPManagementServer.": {
|
||||
"type": "object",
|
||||
"version": "2.15",
|
||||
"protocols": [
|
||||
"usp"
|
||||
],
|
||||
"access": false,
|
||||
"array": false,
|
||||
"dependency": "file:/etc/config/cwmp",
|
||||
"EnableCWMP": {
|
||||
"type": "boolean",
|
||||
"version": "2.15",
|
||||
"read": true,
|
||||
"write": true,
|
||||
"protocols": [
|
||||
"usp"
|
||||
],
|
||||
"mapping": [
|
||||
{
|
||||
"type": "uci",
|
||||
"uci": {
|
||||
"file": "cwmp",
|
||||
"section": {
|
||||
"name": "cpe"
|
||||
},
|
||||
"option": {
|
||||
"name": "enable"
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Reference in a new issue