* NEW: adding tms and datec to email templates
* Escaping a timestamp string I just generated myself
* switching single and double quotes in escape line for tms and datec to make the build system happy?
* Add an id to the table
* showing better names than tms and datec
* Changing code to label to fix#29116
* using hregis advice to use idate not escape the string with date
* requested changes
* forgot to add my name to editors
* had to make class changes for API to work
* setting datec back to int|string
* removing unused code lines and using idate in the api file
* no tms in create or update, but select. No datec in update
* expanding hurl tests to prevent post with id or tms, put with id or datec
---------
Co-authored-by: Jon Bendtsen <xcodeauthor@jonb.dk>
* NEW add api List VAT
Enhance getListOfVAT method with SQL filters and pagination.
* Update parameter type for fk_country in docblock
* Ensure integer casting for SQL parameters
Cast variables to integers for SQL query safety.
---------
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
* mostly updating fetch with all the fields and adding 2 missing variables
* adding throw RestException numbers, @url and a test for if you try with id=0
* Adding hurl file that do some testing og warehouses API endpoints
* Class for API prevented ever seeing model_pdf in API json
* Check for auth before doing other tests on the request
* New function list Products in warehouse. Work done by defrance, revived by JonB
* API PUT/update now allows for more database fields
* hurl tests for the new list products in warehouse endpoint
* also rejecting warehouse_id in a post
* pre-commit fix api warehouses
* copy paste error from api_usergroup
* Just return the lines, no cleaning needed
* PHAN fixes
* trying to fix PHAN error
* fix api update so it returns error when error, and fix object->update with import_key
* this->db not global db
* Advice from hregis
* Typo this d not dB
* Array of strings
* Changed listProducts in warehouse, uses api_product->get with variables from that
* hurl tests for API warehouses, and the new function get products in warehouse
* some STAN fixes
* more phan fixes
* changes revealed necessary by hurl testing
---------
Co-authored-by: Jon Bendtsen <xcodeauthor@jonb.dk>
* add fetchAll in abstract class commondict
* add fetchAll in abstract class commondict
* add fetchAll in abstract class commondict
* add fetchAll in abstract class commondict
* add fetchAll in abstract class commondict
* add fetchAll in abstract class commondict
* add fetchAll in abstract class commondict
* clean code
* NEW API for getting, adding, deleting and/or modifying email templates
* removing duplicate class formmail which has been moved to a separate file
* hurl file for testing the emailtemplates api
* more comprehensive tests of posting a new email template, all required fields and making sure that ID is rejected
* first GUI test of email templates
---------
Co-authored-by: Jon Bendtsen <xcodeauthor@jonb.dk>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
* Modify getListOfContactTypes for expedition type
Adjust the contact type based on shipping settings.
* Update api_setup.class.php
* Update api_setup.class.php
---------
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
* Reviving some old PR with API get, activate and disable modules
* expanding hurl test for setup wih some module tests
* return array, not object
* fix PHPStan on getmodules
* typecasting module functions to string
* instiating class DolibarrModule into an object so we can call functions on it
---------
Co-authored-by: Jon Bendtsen <xcodeauthor@jonb.dk>
* Add support for 'societe' modules on api upload document
* Add ticket module handling in API documents class
* Update api_documents.class.php
* Update api_documents.class.php
---------
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
* API get documents dont support "projects_tasks"
Fixes#35650
* fix: add missing whitespace formatting in api_documents class
---------
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
* adding function to set it to draft mode
* New API endpoint for controlling mass mailings
* report which id we could not find + unset some fields not on this object + write that source was com/propal/class/api_propal.class.php
* extending the fetch function for the mailing object so the API can show all columns in the database
* filling more data into the object and don't unset it later
* adding notrigger to clone creation
* still some cleaning up from when cloning api_proposals.class.php
* do not unset the ID, because we want the ID so we can use it
* adding endpoint to clone a mass mailing
* extending count function with 'all' that just returns all rows, no matter the status
* API endpoints to delete all targets of a mass mailing
* setting which http method to use
* pretty print clone endpoint in API explorer
* endpoint resetTargetsStatus of mass mailing
* Typo receipients fixed
* Update api_mailings.class.php
* Update api_mailings.class.php
* Update api_mailings.class.php
---------
Co-authored-by: Jon Bendtsen <xcodeauthor@jonb.dk>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>