Commit graph

81 commits

Author SHA1 Message Date
steve-lad 91d6ad2f48 Fix incompatibility with new Describe table 2021-08-09 09:23:00 +02:00
steve-lad 0b03d58c09 Remove debug code and update version 2021-08-08 09:57:36 +02:00
steve-lad 481c8929a9 Correct handling of device vendor settings
Prefix was incorrect following removal of _column names
2021-08-08 09:56:04 +02:00
steve-lad 8dc1175b37 Update installer to add parent extensions to sccpline if they exist
Previously ignored sccp extensions in freepbx devices and so created 'orphans'. Now create rows for sccpline for devices that already exist as sccp extensions in devices.

Remove dbug code
2021-08-08 09:03:05 +02:00
steve-lad b30340eab5 Update ajaxHelper.php 2021-08-07 16:07:18 +02:00
steve-lad 6775b6686b Simplify getPhoneGrid 2021-08-01 14:54:17 +02:00
steve-lad 4ffcfaf6b7 Correct getExtensionGrid method and optimise
Was dropping last line
Logic was overly complicated; optimise as called frequently
2021-08-01 13:58:11 +02:00
steve-lad 28bb5a63da Optimise validate part of getSccpModelInformation
Remove needless iterations and use array functions.
Use basename to remove file extension to facilitate this
2021-08-01 11:57:03 +02:00
steve-lad ab7b295b87 switch basedir path source
Use $amp_conf['AMPWEBROOT'] instead of $_SERVER['DOCUMENT_ROOT'] as at least in one case the latter appears to be empty
2021-07-31 17:07:37 +02:00
steve-lad d8d2f946ce Minor optimisations 2021-07-31 15:41:32 +02:00
steve-lad 43a656cebc Correct XML Path in installer and optimise findAllFiles
XML Path in installer was in single quotes - corrected
Remove unnecessary tests in findallfiles
2021-07-31 12:30:24 +02:00
steve-lad b7a64e854f Update ajaxHelper.php 2021-07-30 14:05:59 +02:00
steve-lad e8cabfbd1a Improve parsing of firewall rules 2021-07-30 14:05:00 +02:00
steve-lad 472d73489e Update ajaxHelper.php 2021-07-29 17:21:18 +02:00
steve-lad fb25407611 Improve presentation of shared lines 2021-07-29 17:20:43 +02:00
steve-lad b659f55170 Remove _ prefixes in db column names
Mariadb does not accept _prefixed fields by spec, and these columns may give future issues. Migrate all fields in installer to remove this prefix (without data loss) and:
Create new view sccplineconfig for chan-sccp where only accepted fields are shown
Update sccpdeviceconfig to only show accepted fields
Update extconfigs.conf to use sccplineconfig
Remove references to _ prefixed fields
2021-07-28 15:48:57 +02:00
steve-lad 26f750296a Fix various issues with buttons
Add choice of default line on add device
Partially fix buttoncount (will not work if default device is selected)
Correct database save logic for buttons - triggers should be OK but more verification needed
Fix various save issues where defaults not correctly set
Delete default buttons when deleting line to avoid orphans
2021-07-25 13:42:42 +02:00
steve-lad 80cf629c0f Update ajaxHelper.php 2021-07-24 09:39:57 +02:00
steve-lad 75858d7cc1 Optimise and add error handling to getFilesFromProvisioner 2021-07-24 09:31:30 +02:00
steve-lad 4151b4fdae Restructure languages and locales management
Base off of provision file structure
Store netlang and devlang
Stop usage of extconfig ->sccplang
2021-07-23 12:14:46 +02:00
steve-lad 215cacae41 Get Country tones with locales
Get country files with locales
WIP incompatibility between provision, its rewrite rules and the file structure
WIP - need to clean up get files from provisioner
2021-07-21 16:44:23 +02:00
steve-lad 3a53e9ac8b Optimise database calls
Remove unnecessary post processing on returned object
2021-07-21 12:54:05 +02:00
steve-lad 3475efc2c6 Database request modifications and page improvements
Add device to extensions page - permits to see unassigned  lines and shared lines easily
Reformat status to centred
change 'replace' in sccp class to only 'insert on duplicate key' (UPSET equivalent)
Change request in phoneGrid to left join to show all lines, even unassigned to a device
2021-07-21 11:30:50 +02:00
steve-lad a4aa4eb03b Simplify db queries and change alignment 2021-07-21 08:57:43 +02:00
steve-lad 97c1395eb1 Fix Fill Phone status column
Add db query to include mac to allow join with ami active device data
Change output fields
2021-07-20 18:03:44 +02:00
steve-lad 477eb69146 Fix phonepersonalisation
Set expected numeric value for phonepersonalization
WIP fix - adv.ini
2021-07-20 12:53:29 +02:00
steve-lad 2898f5e3c9 Fix bug codecs storage
codecs were stored as a ',' separated list while chan-sccp expects a ';' separated list
Correct all existing db values when running installer
make sure that disallow is not unset in installer (set to all)
make sure that disallow is not empty
correct help text
2021-07-20 09:32:01 +02:00
steve-lad b3b3858965 standardise get ext file modal and add via include
Create standard modal for insertion via include in firmcreate class and adserver view
2021-07-19 08:04:12 +02:00
steve-lad 3d69090767 Fix finding master file 2021-07-18 12:50:53 +02:00
steve-lad d7fd77dfe8 Get locales from provisioner
Add progress bar and xhr handler
2021-07-18 11:30:19 +02:00
steve-lad 1b32e0977e Optimise locale (language) management
Optimise function calls
Use array functions instead of loops
findInstalledlangs is currently called by the construct - as this is called frequently, maximise its efficiency
2021-07-15 12:12:07 +02:00
steve-lad a4f8fa4600 Impliment retrieving firmware from Provision_sccp
WIP - need to handle exceptions etc
2021-07-14 17:16:27 +02:00
steve-lad ef77bce159 Add retrieve device files 2021-07-14 13:10:15 +02:00
steve-lad 2ffe4028e6 Add download function
WIP - debug with ringtones
2021-07-12 16:32:57 +02:00
steve-lad 6e26428b1d Update rewrite rules
Add header with credits
Add specific rule for sccp_manager
Add correct fields to parse xml for sccpvalues
Add new option to update files from @dkgroot/provision
2021-07-12 13:50:09 +02:00
steve-lad 651f3adb44 Finalise TFTP Mapping treatment
User no longer can select on or pro: If remapping is enabled and rules are set, then must use pro or phones will not find files
Otherwise is Off (flat directory)
2021-07-12 12:26:56 +02:00
steve-lad 5a184ededb Integrate Provision functionality into Sccp_Manager
Create required directory structure
Check if mapping support is enabled
Check if mapping rules are defined
Change options available based on above
Create index.cnf and sccpManagerRewrite.rules
2021-07-11 16:52:24 +02:00
steve-lad 248abe6cb7 Clean up and correct missing save settings
Remove unnecessary method from formcreate
Correct indentation in formcreate
Remove debug code in Sccp.class
correct logic for updating TFTP mode
2021-07-10 17:51:55 +02:00
steve-lad 6429b6add9 Finalise Codec Management
Add video codec treatment
Correct missing defaults
Simplify defaults in Sccp.class
2021-07-08 08:56:42 +02:00
steve-lad f929267910 Provide mechanism to reset codecs to system defaults
Unchecking all codecs will return to chan-sccp defaults
Document this behaviour
Remove various debug code
2021-07-06 16:12:25 +02:00
steve-lad 2e5028f438 Finalise Codecs tab for site defaults
Partially revert changes to sccpvalues keys
Remove obsolete code
Improve help and set as open by default
Move getMyConfig to AjaxHelper as only used there
2021-07-06 15:22:12 +02:00
steve-lad acdf777bcc Clean up xml in cnf files
Indentation was not satisfactory. Improves readability and presentation of cnf files created

Thanks to @dkgroot for proposing this improvement
2021-07-06 12:24:34 +02:00
steve-lad a6a9850a3c rewrite codec methods to be more compliant with chan-sccp
Update db Fields for defaults
Update save logic
WIP update save defaults Field  in sccpline
2021-07-05 17:08:01 +02:00
steve-lad 2809b0796e Simplify List Button Presentation
Standardise method for all SL Types
WIP - unused method needs to be removed after full testing
2021-07-05 10:27:26 +02:00
steve-lad b7766fcf64 First test of new interface to manage defaults hierarchy
WIP
Need to better manage display of system defaults when customising
Need to override XML defaults
2021-06-29 16:41:53 +02:00
steve-lad d1e72714af add systemdefault field to sccpvalues for savesccpsettings 2021-06-28 13:02:24 +02:00
steve-lad 22d845ced3 Initialise all chan_sccp defaults in sccp_settings
Get default system settings from chan_sccp and add to sccpsettings
Remove legacy settings from sccpsettings
Change tftpReadTestFile to accept host as argument
Change sccpsettings structure to include systemdefaults
2021-06-28 11:51:05 +02:00
steve-lad f882a66eb4 Tighten TFTP read controls
Avoid hanging if no data received by setting timeout. Thanks to @dkgroot  for soulution
2021-06-28 07:17:51 +02:00
steve-lad f74978c1b3 Add timer on TFTP read; Get Metadata
TFTP read caused a hang if no server available

Set to DONTWAIT and loop and then check for valid data

Use metadat to set system defaults
2021-06-27 17:12:10 +02:00
steve-lad 4fcf16b317
Do not die on SQL warning
If we change a field from VARCHAR to enum, we will get warnings as possibly truncating data. Accept this and carry on.

Only fail on an error.
2021-06-27 11:06:33 +02:00