Compare commits

...

1094 Commits

Author SHA1 Message Date
Pierre Goiffon
42dfa2c066 Merge branch 'develop' into release/3.1.0-beta 2023-06-16 10:47:37 +02:00
odain-cbd
49d3f4c2b2 N°6047 - Make iTop scripts work by HTTP via token with specific scopes (#494)
* N°6047 - Make iTop scripts work by HTTP via token with specific scopes

* Update core/contexttag.class.inc.php

---------

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-06-15 15:36:35 +02:00
odain
d91eda1343 ci: enhance AddProfileToUser to work with any User 2023-06-15 15:07:09 +02:00
Timothee
e075bf8e89 Licenses update 2023-06-15 10:47:16 +02:00
Molkobain
40355c9442 N°6426 - Fix RenderAllUiBlocks test page not displaying 2023-06-15 10:20:41 +02:00
Timothee
f548dc2898 Dictionaries update for 3.1 beta 2023-06-15 09:47:51 +02:00
Benjamin Dalsass
0ece69112a N°6416 - In user portal, empty ext key drop down doesn't display error message anymore
Fix wrong jquery element resulting in select all form field instead of links elements
2023-06-15 08:37:03 +02:00
Molkobain
587b6a7148 N°6179 - Add visual test 2023-06-14 19:25:02 +02:00
Pierre Goiffon
baa4641795 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-06-14 19:03:02 +02:00
Pierre Goiffon
52820925b1 N°4725 DeprecatedCallsLog::NotifyDeprecatedFile remove throw ConfigException
Those exceptions are handled silently since 3.0.1
2023-06-14 19:01:50 +02:00
Benjamin Dalsass
578f2dfa8e N°3190 - Edit n:n LinkedSetIndirect in object details using a tagset-like widget
Add security if add option button js code isn't provided
2023-06-14 14:50:17 +02:00
Anne-Catherine
5185f721bd N°5594 - Dashboard Bug with Group by (table) - iTop 3.0 (#466) 2023-06-14 11:06:25 +02:00
Pierre Goiffon
add038d649 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-06-14 10:28:46 +02:00
Pierre Goiffon
1824111de8 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2023-06-14 10:28:30 +02:00
Pierre Goiffon
5a0b5364d6 N°4698 setup/phpinfo.php : if no iTop installation then display a proper message instead of an exception (#265) 2023-06-14 10:18:38 +02:00
Pierre Goiffon
76eed2eba0 N°6098 updateLicenses script : check availability of the required JQ command (#458)
This packaging script requires both bash and the JQ command when running on Windows.
If the later isn't available, it will run without throwing an error...

With this change the script will now check directly at launch for the JQ command availability, and exit in error if it isn't.
2023-06-14 10:17:00 +02:00
Anne-Catherine
c2309876fb N°6239 - Portail: Fix error message when trying to display object with missing icon (#485) 2023-06-14 09:42:43 +02:00
Molkobain
1d12ebd733 N°6398 - Improve PHPDoc 2023-06-14 09:38:05 +02:00
Eric Espie
5578147002 N°5906 - CRUD Event - fire event EVENT_DB_LINKS_CHANGED when an n-n link is created/updated/deleted 2023-06-14 09:32:19 +02:00
Eric Espie
a152c5db66 N°6351 - code hardening 2023-06-14 09:11:36 +02:00
Eric Espie
5d5589dd64 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2023-06-14 09:09:12 +02:00
Eric Espie
1ec671ef61 N°6351 - code hardening 2023-06-14 09:08:42 +02:00
vdumas
04e0950efb N°1350 - Audit selection: use absolute url 2023-06-14 08:13:48 +02:00
Molkobain
79d6cadfde N°4106 - Fix typo in the PHPDoc thanks to @piRGoif 2023-06-13 22:34:50 +02:00
Tarjányi Csaba
a1daef70e2 N°6419 - Update hungarian translations thanks to @tacsaby (#472)
* Update hu.dictionary.itop.ui.php

Some corrections

* Revert formatting changes

---------

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-06-13 18:00:21 +02:00
Molkobain
eb7afd53a1 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	datamodels/2.x/itop-config-mgmt/dictionaries/nl.dict.itop-config-mgmt.php
2023-06-13 17:50:57 +02:00
Thomas Casteleyn
b8199a6e2c N°6418 - Fix dutch translations on impact relation view (#499)
* Fix author and copyrights
* Correct NL dict for impact relation view
2023-06-13 17:48:36 +02:00
Purple Grape
68e1f359d3 N°6417 - Update chinese translations thanks to @purplegrape (#500) 2023-06-13 17:36:27 +02:00
Eric Espie
e574fe3dc5 N°5906 - CRUD Event - fire event EVENT_DB_LINKS_CHANGED when an n-n link is created/updated/deleted 2023-06-13 17:12:35 +02:00
Molkobain
0fbef99875 N°4010 - Remove unnecessary single quote escape 2023-06-13 15:59:16 +02:00
Denis
9a5ad6681d Typo in en.dictionary.itop.core.php 2023-06-13 13:44:20 +02:00
Pierre Goiffon
d0cad4d829 N°1150 Fix regression : cannot add caselog in the user portal
Was caused by field value check added in MultipleChoicesField and SelectObjectField in b71cd218

With this commit the checks are now only done if we have a ContextTag::TAG_REST
2023-06-13 12:34:46 +02:00
Pierre Goiffon
b3ef634d21 N°1150 SelectObjectField : factorize DBObjectSet retrieval between Validate and VerifyCurrentValue 2023-06-13 12:34:46 +02:00
Molkobain
5915b2cc01 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-06-13 11:43:11 +02:00
Molkobain
9f38eec40a N°4106 - Reword PHPDoc to avoid confusion as the @internal was not accurate 2023-06-13 11:42:28 +02:00
Benjamin Dalsass
b2c2d5eaea N°6398 - Portal: Allow linkset visible attributes to be limited to attributes defined in a zlist 2023-06-13 10:51:05 +02:00
Denis
fed149dc66 N°918 - Translate placeholders in notifications (#506)
- Localization of date & time formats
- Use of DataLocalizer (if present)
- All placeholders can be used in the uploaded HTML template as well as in the notification "message"
2023-06-13 09:51:32 +02:00
Molkobain
58a20e9a11 N°1646 - Fix crash in case no value return (real fix about to be discussed) 2023-06-13 09:36:30 +02:00
Benjamin Dalsass
0a45039c5c N°6005 - CSV import : import an object and a linkset fails 2023-06-13 08:14:34 +02:00
Benjamin Dalsass
465388b5e3 N°803 - Allow display & edition of attributes on n:n relations on Portal
- Issue when selecting links rows with checkbox
- Change linked set field validation to prevent checking host id -1
2023-06-12 17:26:34 +02:00
vdumas
ad1836d028 N°1350 - Audit: propose domains selection as default 2023-06-12 14:15:57 +02:00
Eric Espie
1655674543 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-06-12 11:39:39 +02:00
Eric Espie
5f5537b8b9 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	js/breadcrumb.js
2023-06-12 11:39:13 +02:00
Eric Espie
72716b7ec8 N°6396 - Protect URL display 2023-06-12 11:36:51 +02:00
Eric Espie
5084f7fccb N°6396 - Protect URL display 2023-06-12 11:33:33 +02:00
Molkobain
bd96247f97 N°1345 - Fix typo in conf. param. description 2023-06-12 09:56:57 +02:00
vdumas
01fb3466c8 N°1350 - Audit: propose domains selection as default 2023-06-12 09:22:34 +02:00
vdumas
b5a637fa11 N°1350 - Audit: Title, breadcrumb, back button and link to configure 2023-06-09 20:13:44 +02:00
Molkobain
4d6236cbea N°1345 - Restrict unit test iTop community only as it is based on the standard DM (thanks @piRGoif) 2023-06-09 17:55:54 +02:00
vdumas
2829068499 N°6381 - Add rank on Enums of default DataModel 2023-06-09 17:51:00 +02:00
Molkobain
8304e4df00 N°6394 - Force header statistics to sort [meta]enums pills according to the datamodel instead of the selection order 2023-06-09 17:49:20 +02:00
Pierre Goiffon
2824718189 N°6376 Fix french labels (requête => demande) 2023-06-09 16:35:21 +02:00
Pierre Goiffon
2d866b8f47 N°6320 Fix GetSelectFilterTest::testGetSelectFilter crashing when authent-token module installed 2023-06-09 15:47:19 +02:00
vdumas
36ad278b1f N°2199 - Request history tables without the Admin profile 2023-06-09 13:05:05 +02:00
Molkobain
74fec312d8 N°1345 - Add unit test 2023-06-09 13:01:59 +02:00
vdumas
05559a944b N°6381 - Add capital letter on enum values so rank by label works 2023-06-09 12:53:42 +02:00
Molkobain
508647fe0b N°1345 - Add possibility to sort transitions automatically 2023-06-09 12:49:42 +02:00
vdumas
c04c7e06ea N°6381 - Add capital letter on enum values so rank by label works 2023-06-09 11:48:14 +02:00
Benjamin Dalsass
2041a6ad3f N°803 - Allow display & edition of attributes on n:n relations on Portal
- Remove column mandatory information when object is in view mode
2023-06-09 10:40:24 +02:00
Benjamin Dalsass
c486aea299 N°803 - Allow display & edition of attributes on n:n relations on Portal
- Remove input when object is in view mode
- Improve form errors handling
- Prevent row selection when clicking input 
- Attach date time picker to table instead of input to prevent popup truncating (popup will be visible but not aligned on the input)
2023-06-09 10:34:19 +02:00
Eric Espie
1b7529fcb9 N°6384 - Flag LinkedSet to specify that it has CheckToWrite constraint (more specific parameter name) 2023-06-09 10:21:47 +02:00
Eric Espie
191742c2a9 N°6384 - Flag LinkedSet to specify that it has CheckToWrite constraint (more specific parameter name) 2023-06-09 10:17:22 +02:00
vdumas
d985ff860d N°2199 - Request history tables without the Admin profile 2023-06-09 09:20:41 +02:00
Molkobain
ae65856797 N°1646 - Fix unit tests to reflect new enum sort 2023-06-09 08:34:09 +02:00
vdumas
0fb770783d N°6381 - Add rank on Enums of default DataModel 2023-06-08 18:56:45 +02:00
Anne-Catherine
cc8c6ac027 N°3213 - Order transition attributes like in the "details" zlist instead of reordering them regarding the dependencies (#306)
N°3213 - Order transition attributes like in the "details" zlist instead of reordering them regarding the dependencies (#306)

---------

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-06-08 17:29:53 +02:00
Eric Espie
99e84e86cd N°6384 - fix typo 2023-06-08 17:19:45 +02:00
Eric Espie
7ebf5a6dd4 N°6384 - Flag LinkedSet (Indirect) when CheckToWrite must be requested to Hosted Object 2023-06-08 17:07:01 +02:00
Vincent Dumas
55009b53e2 N°2199 - Request history tables without the Admin profile (#497) 2023-06-08 16:50:06 +02:00
vdumas
42304fb489 N°2199 - New History Group for access to other than Administrator 2023-06-08 16:38:09 +02:00
Eric Espie
f4fcfee03b N°6359 - Add comment 2023-06-08 15:52:08 +02:00
Eric Espie
a6e56e37c9 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	tests/php-unit-tests/ItopDataTestCase.php
2023-06-08 15:11:39 +02:00
Eric Espie
e288af4ddb Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	tests/setup_params/default-params.xml
2023-06-08 14:33:54 +02:00
Eric Espie
4f999de844 N°6359 - ⬆️ Update jQuery BBQ (from https://github.com/cee-chen/jquery-bbq) 2023-06-08 14:30:09 +02:00
denis.flaven@combodo.com
1809ea647f 💄 More explicit icon for the 'Add criterion' button 2023-06-08 11:55:08 +02:00
Anne-Catherine
f47133bc28 N°6125 - Issue with GetAttributeFlags and GetInitialStateAttributeFlags within iTop 3.0.2 (#474) 2023-06-08 11:12:22 +02:00
Pierre Goiffon
14d3eb6624 N°6238 Security hardening 2023-06-08 09:31:15 +02:00
odain
ea49c0a87c enable authent-cas in ci 2023-06-07 21:44:17 +02:00
odain
6cc971849b ci: enhance AddProfile 2023-06-07 21:44:00 +02:00
vdumas
68a1c0f0cb N°1350 - Audit result and audit configuration: add navigation from one to the other 2023-06-07 20:17:39 +02:00
Molkobain
edba3270a2 N°1646 - Update standard datamodel with enum sorted by rank 2023-06-07 19:53:12 +02:00
Molkobain
4d5d149079 N°1646 - Add unit tests 2023-06-07 19:53:12 +02:00
Molkobain
bac6cbc1d8 N°1646 - Add possibility to sort Attribute[Meta]Enum either by code (default), rank or label 2023-06-07 19:53:11 +02:00
Eric Espie
f886c78f24 Merge remote-tracking branch 'origin/support/3.0' into develop -> fix unit tests 2023-06-07 17:49:52 +02:00
Eric Espie
62ed5adbc5 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	application/loginwebpage.class.inc.php
#	composer.json
#	lib/composer/installed.json
#	lib/guzzlehttp/psr7/.github/workflows/ci.yml
#	lib/guzzlehttp/psr7/.github/workflows/integration.yml
#	lib/guzzlehttp/psr7/.github/workflows/static.yml
#	lib/guzzlehttp/psr7/CHANGELOG.md
#	lib/guzzlehttp/psr7/composer.json
#	lib/guzzlehttp/psr7/src/MessageTrait.php
#	tests/php-unit-tests/ItopDataTestCase.php
2023-06-07 17:45:50 +02:00
Eric Espie
0fbd41a884 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 -> fix syntax error 2023-06-07 17:30:39 +02:00
Eric Espie
70e6f707c4 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 -> composer autoloader 2023-06-07 17:23:47 +02:00
Eric Espie
e76ada641f Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	application/loginbasic.class.inc.php
#	application/loginexternal.class.inc.php
#	application/loginform.class.inc.php
#	application/loginurl.class.inc.php
#	application/loginwebpage.class.inc.php
#	composer.lock
#	datamodels/2.x/authent-cas/src/CASLoginExtension.php
#	lib/composer/autoload_real.php
#	lib/composer/installed.php
#	synchro/synchro_exec.php
#	synchro/synchro_import.php
#	tests/php-unit-tests/unitary-tests/application/utilsTest.php
2023-06-07 17:21:09 +02:00
Pierre Goiffon
2405810864 N°6238 Security hardening 2023-06-07 16:45:35 +02:00
Denis
120b8b55ed Typo 2023-06-07 15:53:52 +02:00
Eric Espie
fff46d99fc N°6358 - Login REST API - renamed test 2023-06-07 15:31:51 +02:00
Benjamin Dalsass
11c147574a N°803 - Allow display & edition of attributes on n:n relations on Portal 2023-06-07 15:30:08 +02:00
odain
3a891f707c ci: enhance AddProfile test method to work with any User (not only UserLocal) 2023-06-07 15:06:28 +02:00
odain
8b6ea43ebe N°6358 - Login REST API - fix cas + add tests 2023-06-07 15:05:32 +02:00
Eric Espie
90cf7502e8 N°6358 - Login REST API 2023-06-07 10:09:30 +02:00
Eric Espie
c596fa2967 N°6358 - Login API REST 2023-06-07 09:17:24 +02:00
Timothee
a45177410e N°6350 - Fixing phpunit test 2023-06-06 16:47:06 +02:00
vdumas
d778203f99 N°6370 - Replace Audit Category menu by a dashboard 2023-06-05 18:32:57 +02:00
vdumas
652a9f6e40 N°6370 - Replace Audit Category menu by a dashboard 2023-06-05 17:58:14 +02:00
Benjamin Dalsass
8eb1053daa N°803 - Allow display & edition of attributes on n:n relations on Portal 2023-06-05 16:19:06 +02:00
Eric Espie
519751faa1 N°6348 - Add unit test 2023-06-05 14:50:37 +02:00
Eric Espie
b99ff5e84a ✏️ typo 2023-06-05 08:22:29 +02:00
Benjamin Dalsass
4264123ef6 N°6219 - 1:n Read: tooltip, modal title and message on Add-Edit-Remove-Delete 2023-06-02 08:08:29 +02:00
vdumas
eb1ff95437 N°6347 - 1:n Add nice french dico entry on standard 1:n relationship 2023-06-01 17:12:47 +02:00
Eric Espie
cb7cbe9297 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	pages/UI.php
#	tests/php-unit-tests/unitary-tests/application/utilsTest.php
2023-06-01 16:59:59 +02:00
Eric Espie
b8f61362f5 N°6348 - Hardening code 2023-06-01 16:44:40 +02:00
Eric Espie
e3ba826e5d N°6349 - Hardening code 2023-06-01 16:36:56 +02:00
Eric Espie
17d22219d2 N°6350 - Fix unit tests 2023-06-01 16:30:09 +02:00
Eric Espie
a49025f371 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	application/utils.inc.php
2023-06-01 16:04:52 +02:00
Eric Espie
9e96ea2873 N°6350 - code hardening 2023-06-01 15:35:56 +02:00
Eric Espie
1172159745 N°6351 - code hardening 2023-06-01 15:12:50 +02:00
vdumas
c2fb0150b0 N°6347 - 1:n Add nice french dico entry on standard 1:n relationship 2023-06-01 11:56:34 +02:00
Molkobain
41bce359a0 N°6307 - Fix mentions not working in edition due to CRUD changes 2023-05-31 17:45:20 +02:00
Eric Espie
3e7c48d5c6 N°6357 - Prevent entering same password on change user password 2023-05-31 17:12:26 +02:00
vdumas
5e3b813da7 N°6339 - n:n Add nice french dico entry 2023-05-31 16:50:54 +02:00
Eric Espie
d680369733 N°5726 - loose data localizer language in console after impersonating a user with a different langage 2023-05-31 16:45:20 +02:00
vdumas
0af8f65a11 N°6339 - n:n Add nice french dico entry 2023-05-31 16:33:48 +02:00
Molkobain
f41879f0b1 N°6307 - Fix unappropriate confirm message when updating log on object edition
Proper fix as 345a8371 was temporary
2023-05-31 16:26:26 +02:00
Molkobain
eec9b027ac Revert "N°6307 Fix alert when caselog filled and submitting form"
This reverts commit 4b9b0a91a9.
2023-05-31 16:26:26 +02:00
Eric Espie
5f359b2b61 N°6151 - Allow to select classes on union outside the already selected classes 2023-05-31 14:40:13 +02:00
Benjamin Dalsass
31a96d24dd N°6219 - 1:n Read: tooltip, modal title and message on Add-Edit-Remove-Delete 2023-05-31 10:10:02 +02:00
Molkobain
d07bce3063 N°6352 - Portal: Fix autoloaders 2023-05-30 16:29:07 +02:00
Molkobain
c9beba0cea N°6352 - Portal: Fix "Combodo\iTop\Portal\Controller\AggregatePageBrickController" has no container set due to Symfony 5.4 migration 2023-05-30 16:09:58 +02:00
vdumas
4d9b054430 N°2639 - Add Tooltips EN/FR dico entries for Data Synchro 2023-05-30 15:42:42 +02:00
Eric Espie
2c4c69fcfc Fixed regression due to forcing camel case names in operation methods, now allow both camel case and snake case 2023-05-30 15:25:00 +02:00
Eric Espie
173960e717 N°6324 - CRUD Event for one time treatment before creation and before update 2023-05-30 11:54:15 +02:00
vdumas
79585c7128 N°6339 - n:n Add nice french dico entry on standard lnk 2023-05-30 11:34:33 +02:00
Eric Espie
c3bb995407 N°6324 - CRUD Event for one time treatment before creation and before update 2023-05-30 11:29:24 +02:00
vdumas
e3dd805f24 N°6338 - Add silo (org_id) and location on all final Interfaces, LogicalVolume & NASFileSystem 2023-05-26 13:49:49 +02:00
acognet
649457bfc2 N°6308 - issue on displaying a userrequest list with Service_details fields with PHP 8 2023-05-26 00:25:42 +02:00
vdumas
e933807b1c N°6203 - Complementary name on Ticket sub-classes 2023-05-24 18:41:02 +02:00
vdumas
52fd333922 N°6339 - n:n Add nice french dico entry on standard lnk 2023-05-24 18:17:58 +02:00
vdumas
91a9997480 N°6203 - Overcard & complementary on Ticket classes 2023-05-24 15:39:22 +02:00
vdumas
906ad70156 N°6331 - Add Service tab in Provider Contract and add fieldsets 2023-05-24 13:07:52 +02:00
Pierre Goiffon
0508608e78 N°6322 Delegate \AttributeCustomFields::CheckValue to the handler
This allows to move template_id checks from BuildForm (which is called in the UI to construct the form also) to a dedicated method only called for validation
2023-05-24 09:28:26 +02:00
vdumas
63fcf4e6f9 N°6203 - Add summary to CMDB classes 2023-05-23 20:00:57 +02:00
vdumas
f805c2f834 N°6203 - Add complementary name to CMDB classes 2023-05-22 18:30:33 +02:00
vdumas
976c9c1523 N°6311 - Add a Log on User Local, LDAP and External 2023-05-20 18:54:10 +02:00
vdumas
22a14a2de2 N°6323 - n:n Add filter on lnk ExtKey aligned to PrefillSearchForm 2023-05-20 17:21:10 +02:00
vdumas
bd04b2a24c N°6203 - Standard DM overcard, complementary name 2023-05-20 17:20:16 +02:00
Eric Espie
0188108a68 Add EVENT_DB_BEFORE_CREATE and EVENT_DB_BEFORE_UPDATE events in CRUD calls 2023-05-17 10:16:18 +02:00
Pierre Goiffon
4038d4d925 N°6314 N°1150 Fix cannot reopen or close a UR in the user portal
Since introduction of MultipleChoicesField and SelectObjectField value checks with b71cd218, when a portal user was trying to do an action on a resolved UR the agent_id field was rejected. The reason for the rejection is the corresponding SelectObjectField query is containing the portal user scopes (query generated in ObjectFormManager::Build), and of course the agent_id set isn't in this scope...

As a workaround we are disabling those checks for read only fields (values are set server side and possibly in a different context than the portal user)
2023-05-16 17:54:24 +02:00
acognet
ea88aa85df N°4517 - PHP 8.1 compatibility : Replace htmlentities(***, ENT_QUOTES,'UTF-8') with utils::EscapeHtml 2023-05-16 17:45:58 +02:00
Eric Espie
8f2814a590 Undo... Move event declaration where the object is defined 2023-05-16 15:59:50 +02:00
Eric Espie
ad25d8823f Add EVENT_DB_BEFORE_CREATE and EVENT_DB_BEFORE_UPDATE events in CRUD calls 2023-05-16 15:52:02 +02:00
Eric Espie
59cd489e72 N°6252 - Make designer itop 3.1 compatible - Fix deprecated calls of opendir() with null value 2023-05-16 14:06:01 +02:00
Pierre Goiffon
4b9b0a91a9 N°6307 Fix alert when caselog filled and submitting form
Regression was introduced in 8dc7d68b
Temporary fix, as the alert is caused by activity-panel.js which is disabled only if another handler is registered before 🤯 As a temporary fix I add an empty handler at the same place as the one that was there before, but we need a better way to disable activity-panel.js handler !
2023-05-16 12:14:26 +02:00
vdumas
a21def5329 N°4010 - Configuration file overwritten - fine tune messages 2023-05-16 12:06:26 +02:00
vdumas
55f8efe0db N°4010 - Configuration file overwritten - fine tune messages 2023-05-16 12:06:26 +02:00
Eric Espie
0cc28b42b2 Move EventService init to Metamodel::Startup() for unit tests 2023-05-16 10:23:01 +02:00
Anne-Catherine
a98fab8f66 N°6240 - Improve display of picture in read or edit mode (#484) 2023-05-15 16:12:26 +02:00
vdumas
bf21481bf6 N°6212 - Replace 'case logs' by 'logs' in naming of ActionEmail for TriggerOnObjectMention 2023-05-15 12:32:31 +02:00
Eric Espie
cda51c67c5 Fix warning 2023-05-15 11:46:25 +02:00
Eric Espie
64264eb7ed Move event declaration where the object is defined (Fix undefined constant) 2023-05-15 10:42:58 +02:00
Eric Espie
940118967c Move event declaration where the object is defined 2023-05-15 09:33:53 +02:00
vdumas
a647c235c3 N°1350 - Audit domains: add description as complementary name 2023-05-15 09:27:02 +02:00
vdumas
752ac5a469 N°5971 - Allow changing the Org of a Person having Portal User without allowed orgs 2023-05-15 08:54:19 +02:00
vdumas
c61faf453c N°5971 - Prevent changing the Org of a Person having Portal User without the new Org allowed 2023-05-12 18:24:46 +02:00
Pierre Goiffon
b71cd2182f N°1150 Add value checks in MultipleChoicesField and SelectObjectField
Now current value is checked against list of possible values
2023-05-12 10:59:33 +02:00
Pierre Goiffon
7c594db4b9 N°1150 AtributeCustomFields : FromJSONToValue is now delegated to the handler
Method was always returning null before
2023-05-12 10:58:43 +02:00
Pierre Goiffon
cca27674d0 ItopDataTestCase : extract UR params to a method to allow overrides 2023-05-12 10:58:43 +02:00
Eric Espie
f426626b9a N°6299 - DBUpdate regression in 3.1 - Fix unit tests 2023-05-12 09:09:39 +02:00
Eric Espie
5dc80f31f5 N°6299 - DBUpdate regression in 3.1 when setting a field with same value in the concerned object 2023-05-11 16:16:49 +02:00
denis.flaven@combodo.com
7fe565c4fb Merge branch 'feature/6133-add-extra-files-to-backup-and-restore' into develop 2023-05-11 14:41:02 +02:00
denis.flaven@combodo.com
08ebac1b5c Fix PR remarks 2023-05-10 17:42:50 +02:00
vdumas
380723056a N°5559 - Obsolete replica locks object edition - fix default param value 2023-05-10 10:24:12 +02:00
Stephen Abello
2f20cf52f3 N°6219 Fix issues in dictionary entries 2023-05-10 10:08:18 +02:00
Stephen Abello
5219541b74 N°6154 Fix some classes names hardcoded in dict entries and calls MetaModel GetName instead of hardcoded dict entry 2023-05-10 10:03:02 +02:00
Pierre Goiffon
4695511b46 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-05-09 15:37:05 +02:00
odain
0b5bf7bf6f N°6299 - DBUpdate regression in 3.1 when setting a field with same value in the concerned object - fix temporarly ci until fix comes 2023-05-09 14:51:26 +02:00
Pierre Goiffon
cdcc069099 Fix typo in exception message
Regression introduced in fe179079 in support/3.0 branch and upwards
2023-05-09 14:02:02 +02:00
Vincent Dumas
5c252849fa N°5559 - Prevent obsolete replica to lock iTop object (#376)
* N°5559 prevent obsolete replica to lock iTop object

* N°5559 - new config param for ignoring obsolete replica

* N°5559 - new config param for ignoring obsolete replica (2)
2023-05-09 11:28:44 +02:00
Eric Espie
9c50f0d072 Fixed regression due to typo 2023-05-05 17:09:10 +02:00
odain
b4f517b03b Merge branch 'support/3.0' into develop 2023-05-05 15:57:04 +02:00
odain
8c639fc23a N°5753 - add config parameter allow_rest_services_via_tokens to bypass rest secure profile option 2023-05-05 15:53:32 +02:00
Anne-Catherine
f29e748baa N°6265 - Too many call to current person in database (#488) 2023-05-05 15:08:48 +02:00
Eric Espie
f1d1aa8833 Fixed regression due to forcing camel case names in operation methods, now allow both camel case and snake case 2023-05-05 14:55:45 +02:00
bdalsass
b9cfb62d1a N°6251 - 1:n - Actions must not be proposed to user not allowed (#491) 2023-05-05 14:28:37 +02:00
odain
da5a825c7e N°6171 - Password Expiration: can expire mode has no effect on user who have never changed their password 2023-05-05 11:37:44 +02:00
Pierre Goiffon
d10e2ac25a Merge remote-tracking branch 'origin/support/3.0' into develop 2023-05-05 10:17:10 +02:00
Pierre Goiffon
b9230ad402 N°6274 DeprecatedCallsLogTest : replace expectException deprecated calls
Message was : Support for using expectException() with PHPUnit\Framework\Error\Warning is deprecated and will be removed in PHPUnit 10. Use expectWarning() instead.
2023-05-05 10:16:56 +02:00
Pierre Goiffon
436e6b80db Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	tests/php-unit-tests/ItopTestCase.php
2023-05-05 09:45:02 +02:00
Pierre Goiffon
959ac7e3be N°6274 DeprecatedCallsLogTest : fix expected exception mismatch in PHP 8.0+
Undefined offset notice was changed to a warning in PHP 8.0... Also message was changed :(
2023-05-05 09:13:03 +02:00
Molkobain
53e2d1103a Improve PHPDoc and type hints 2023-05-04 23:16:14 +02:00
Molkobain
8dc7d68b8c N°5890 - Use leave handler in backoffice forms to better handle leave confirmation message with multiple forms in a single page 2023-05-04 22:15:10 +02:00
Molkobain
bb46875679 N°5890 - Refactor leave handler to a global helper (not portal only) 2023-05-04 22:15:10 +02:00
Molkobain
1271bb31cb Fix "Syntax error, unrecognized expression" during object editing due to object class being already JSON encoded 2023-05-04 22:15:09 +02:00
Pierre Goiffon
1884596ecd N°6274 Fix log.class.inc.php crashing cause cannot load ItopTestCase class
Now the constant name is defined in approot
2023-05-04 17:34:14 +02:00
Pierre Goiffon
584cfa8cbf N°6274 Fix PHP Notices not caught in ItopDataTestCase PHPUnit
This was caused by the set_error_handler() done in DeprecatedCallsLog during startup

Now we are :
* not registering the handler if a PHPUnit test is running (based on a constant set in ItopTestCase::setUp)
* on registration only do it for the required notices
2023-05-04 17:08:47 +02:00
BenGrenoble
ae8012c75f N°4577 - Move service dependencies from "itop-bridge-cmdb-ticket" to another module
Add two more bridge for flexibilty and teemip needs
2023-05-04 15:42:51 +02:00
Benjamin Dalsass
34f3b92e2e N°5916 - Generic message on Link Uniqueness rules
Add unit test
2023-05-04 15:24:14 +02:00
Pierre Goiffon
881aa87ad2 N°6270 Remove empty model.*.php files
Not necessary anymore in 3.1.0 since :
* N°4875 - Compiler : do not force the model.*.php file to be present in the module.*.php file ('datamodel' key)
* N°4280 - Module loading : do not crash if 'datamodel' file doesn't exists (model.*.php)
2023-05-04 12:14:52 +02:00
Benjamin Dalsass
03e22ce42d N°5916 - Generic message on Link Uniqueness rules 2023-05-04 11:21:06 +02:00
Eric Espie
4f6e74a3ee N°2250 - DisplayObject with ormLinkSet ignore Removed 2023-05-04 11:01:51 +02:00
Benjamin Dalsass
5a856f96eb N°6124 - Workaround performance problem on the modification of an object with an n:n relation having a large volume
Add new bForceTableRefresh flag description
2023-05-04 10:54:04 +02:00
Benjamin Dalsass
c7e8c70ced N°6124 - Workaround performance problem on the modification of an object with an n:n relation having a large volume 2023-05-04 10:34:37 +02:00
Benjamin Dalsass
aa01003042 N°5916 - Generic message on Link Uniqueness rules
Replace space by non-breaking space
2023-05-03 12:48:33 +02:00
Benjamin Dalsass
27d9d6a822 N°6154 - n:n Read - tooltip, buttons tooltips on edit widgets 2023-05-03 12:42:45 +02:00
BenGrenoble
e16ffe5a99 N°4577 - Move service dependencies from "itop-bridge-cmdb-ticket" to another module
Fix empty files issue from previous commit
2023-05-03 10:57:57 +02:00
Eric Espie
befef6c71e N°5658 - Fix spinning wheel appearing on all application upgrade buttons - fix css 2023-05-03 10:49:08 +02:00
BenGrenoble
d86b3dba0e N°4577 - Move service dependencies from "itop-bridge-cmdb-ticket" to another module 2023-05-03 10:19:54 +02:00
Eric Espie
a972393685 N°5658 - Fix spinning wheel appearing on all application upgrade buttons - fix css 2023-05-03 10:17:04 +02:00
bdalsass
e16a32bad2 Feature/6154 - Change dict key (#490) 2023-05-03 09:47:56 +02:00
bdalsass
375677612d Feature/6154 - Confirmation modal issue (#489) 2023-05-03 09:47:40 +02:00
Molkobain
99376225de Improve PHPDoc 2023-05-03 09:46:45 +02:00
Molkobain
3ce810ee99 N°5655 - Router: Improve robustness
* Change visibility from public to protected of methods for which it was not necessary
  * Change visibility from static to non-static of methods that could be used as such for easier testability
  * Cache available routes for better performances
  * Finish Router::GetRoutes() so we can use the available routes data to display them to the developers somewhere (ideally in the toolkit)
  * Improve unit tests
2023-05-02 23:56:25 +02:00
Stephen Abello
1945708c16 Merge branch 'support/3.0' into develop 2023-05-02 09:25:55 +02:00
Stephen Abello
eebc61385d N°6009 - Fix restore backup button not working when JS dependencies are present 2023-05-02 09:24:54 +02:00
Eric Espie
9dd8ed2317 N°5658 - Fix spinning wheel appearing on all application upgrade buttons - fix css 2023-04-28 17:25:04 +02:00
Stephen Abello
98430bc16e N°6148 - Add icons to Ticket, AuditRule, AuditCategory and AuditDomain 2023-04-28 17:16:30 +02:00
Eric Espie
21fec412c3 N°5658 - Fix spinning wheel appearing on all application upgrade buttons - fix css 2023-04-28 17:14:22 +02:00
Eric Espie
cc45da5f29 N°5658 - Fix spinning wheel appearing on all application upgrade buttons - fix css 2023-04-28 17:14:01 +02:00
Eric Espie
e4412a5201 N°5658 - Fix spinning wheel appearing on all application upgrade buttons - move twig_base and itop-core-update to new router 2023-04-28 16:56:16 +02:00
Eric Espie
b1d32646d9 N°5658 - Fix spinning wheel appearing on all application upgrade buttons - move twig_base and itop-core-update to new router 2023-04-28 16:42:39 +02:00
Stephen Abello
55628288aa Add french translations to informative modals 2023-04-28 16:33:06 +02:00
Eric Espie
5dedb138bf N°5658 - Fix spinning wheel appearing on all application upgrade buttons - move twig_base and itop-core-update to new router 2023-04-28 16:15:51 +02:00
Eric Espie
e960d20826 N°5658 - Fix spinning wheel appearing on all application upgrade buttons - move twig_base and itop-core-update to new router 2023-04-28 16:02:54 +02:00
bdalsass
d91fafb2af N°5916 - Generic message on Link Uniqueness rules (#487) 2023-04-28 14:45:09 +02:00
bdalsass
de35d941c1 N°6154 N°6219 - Relations Read - tooltip, confirmation title and message (#486)
N°6154 - n:n Read - tooltip, confirmation title and message on Add-Edit-Remove
N°6219 - 1:n Read: tooltip, modal title and message on Add-Edit-Remove-Delete
2023-04-28 14:43:53 +02:00
Molkobain
269c1bf005 N°5957 - Restore transition button on linksets even when only 1 element
Moreover a refactor of the way actions were added has been done to avoid duplication of code among the method.
2023-04-28 11:19:04 +02:00
Stephen Abello
893032ccf5 Replace backup modals with iTop built-in modals 2023-04-28 11:03:08 +02:00
BenGrenoble
33818e188b N°6200 - Hamonize menu entries - Fix missing entries 2023-04-27 17:39:14 +02:00
Molkobain
e4e562d28e N°6253 - Fix crash due to missing test on main class 2023-04-27 16:45:57 +02:00
Molkobain
c1ae0ce7fa N°6253 - Fix only first selected class displayed in lists in run query page
Factorized code from \DataTableUIBlockFactory::MakeForRenderingObject() into \DataTableUIBlockFactory::MakeForRendering as 95% of their code where duplicated. 😵
\DataTableUIBlockFactory::MakeForRenderingObject() is now deprecated.
2023-04-27 16:09:14 +02:00
Pierre Goiffon
9112a06458 N°6237 Set external value reloaded instance in the m_aOrigValues too 2023-04-27 11:44:11 +02:00
Pierre Goiffon
edaa4fca31 💡 N°6237 Comment in ormCustomFieldsValue about current_* keys mandatory for DBUpdate to work 2023-04-27 11:10:01 +02:00
BenGrenoble
81abe68e44 N°6200 - Hamonize menu entries - fix typo 2023-04-27 10:58:06 +02:00
Pierre Goiffon
0cb3d699f0 N°6237 Fix ormCustomFieldsValue not reloaded after DBInsert or DBUpdate 2023-04-26 18:16:18 +02:00
Pierre Goiffon
900aa4a044 N°6043 Add phpdoc 2023-04-26 17:41:07 +02:00
BenGrenoble
0ded36fb52 N°6200 - Hamonize menu entries 2023-04-26 17:28:53 +02:00
Pierre Goiffon
dd5486eaa9 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-04-26 17:13:14 +02:00
Pierre Goiffon
3c15186685 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2023-04-26 17:12:08 +02:00
Pierre Goiffon
fa038ded3d N°6254 ItopDataTestCase::CreateUserRequest : fix new argument default value
Was creating error Too few arguments passed
2023-04-26 16:42:27 +02:00
Pierre Goiffon
e7ea1b831c N°6254 ItopDataTestCase::CreateUserRequest : now pass fields values as array
More versatile way of doing things !
2023-04-26 16:22:26 +02:00
Eric Espie
d8b21e11ed N°6182 - Fix crash with UNION OQL queries when classes / aliases are different 2023-04-26 15:09:12 +02:00
Molkobain
7e08f6131c Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	js/links/links_widget.js
2023-04-26 12:19:04 +02:00
Molkobain
f15ac75f8f Merge remote-tracking branch 'origin/support/3.0.3' into support/3.0 2023-04-26 11:25:04 +02:00
Molkobain
c6edbf982d N°6124 - Performance: Draw datatable only once when elements added in linksets 2023-04-26 11:24:34 +02:00
Stephen Abello
d58ff8d73a N°6235 - Add robustness when creating an object that has a mandatory blob attribute in a modal 2023-04-26 11:02:44 +02:00
Molkobain
5aea7ccbc9 N°6124 - Performance: Draw datatable only once when elements remove in linksets 2023-04-26 10:33:18 +02:00
Molkobain
28f88f3ba3 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-04-25 22:02:44 +02:00
Molkobain
e28dbebbd5 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	application/displayblock.class.inc.php
#	dictionaries/en.dictionary.itop.ui.php
#	dictionaries/fr.dictionary.itop.ui.php
2023-04-25 21:56:42 +02:00
Molkobain
4aff65f98b N°6217 - Add accessiblity meta data for title on "Power menu" 2023-04-25 21:51:32 +02:00
Molkobain
db26a72fd1 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	application/ui.linkswidget.class.inc.php
2023-04-25 21:22:24 +02:00
Molkobain
8aba578cfa Merge remote-tracking branch 'origin/support/3.0.3' into support/3.0 2023-04-25 21:05:42 +02:00
Molkobain
9d3e389011 N°6124 - Workaround performance problem on adding items to an object with an n:n relation having a large volume 2023-04-25 17:43:51 +02:00
Eric Espie
2e219e78c5 N°6182 - Fix crash with UNION OQL queries when classes / aliases are different 2023-04-25 15:30:34 +02:00
acognet
7e7f8577e8 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	application/displayblock.class.inc.php
2023-04-25 15:14:22 +02:00
acognet
3c94974d9d N°541 - Dashlets: Improve readability when to much labels (pie chart) or too long labels (bar chart) 2023-04-25 12:09:11 +02:00
Eric Espie
d0e6572fd0 N°1608 - Fix attachments access rights 2023-04-25 10:05:10 +02:00
Eric Espié
5644587e5d Merge pull request #481
* N°4010 - Configuration file protection against server changes

* N°4010 - Configuration file editor - Fix reset button
2023-04-25 09:35:54 +02:00
Stephen Abello
284117f33a Fix linkset sets' complementary name being double encoded 2023-04-25 09:18:18 +02:00
vdumas
900208f249 N°6212 - Report Target class info on Trigger, so it can be displayed in complementary_name 2023-04-24 18:12:35 +02:00
Molkobain
accd5670fe N°5890 - Handle locked object properly in modals 2023-04-24 17:25:46 +02:00
Molkobain
1a7f97d799 N°5890 - Improve JS selector for concurrent lock 2023-04-24 17:25:46 +02:00
Benjamin Dalsass
4ef93db9a7 N°5958 - 1:n - edit_mode=ADD_ONLY - Location -> Person
Disable blob edition only when editing via ajax
2023-04-24 15:18:08 +02:00
acognet
3e6e3919fb Merge remote-tracking branch 'origin/support/3.0' into develop 2023-04-24 15:04:58 +02:00
acognet
d6e5069dd5 N°541 - Dashlets: Improve readability when to much labels (pie chart) or too long labels (bar chart) 2023-04-24 14:26:33 +02:00
Tarjányi Csaba
55b6f9ebd1 N°6121 - Update hungarian translations (thanks to @tacsaby) (#462)
* Update hu.dictionary.itop.ui.php

Grammatical corrections

* Restore not translated entries

---------

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-04-24 10:09:23 +02:00
Molkobain
861b5fcd01 N°2889 - Fix notifications tab not display if trigger class is neither a leaf nor abstract 2023-04-24 09:44:07 +02:00
Molkobain
3f37858c70 N°2889 - Fix error on attachment download due to $oObj not being a \cmdbAbstractObject 2023-04-23 23:15:05 +02:00
Molkobain
c34bd42945 N°5957 - Introduce constants for DisplayBlock styles 2023-04-22 09:52:30 +02:00
Molkobain
f308d9b478 N°5957 - Relations: Refactor \DisplayBlock to correctly handle 'listInObject' style 2023-04-22 09:52:30 +02:00
Molkobain
58b230cd74 N°5388 - PHP 8.2: Fix dynamic properties that were actually just case-sensitive typos 2023-04-22 09:52:30 +02:00
vdumas
c3ace8e1a0 N°6213 - Add/remove current User from Ticket contacts_list 2023-04-21 17:11:33 +02:00
Stephen Abello
0404727fc9 N°6223 - Linkset modal edition: set extkey to host object read-only 2023-04-21 17:00:33 +02:00
Stephen Abello
f67544bb8a Merge branch 'support/3.0' into develop
# Conflicts:
#	application/cmdbabstract.class.inc.php
#	application/ui.linksdirectwidget.class.inc.php
2023-04-21 16:17:32 +02:00
Stephen Abello
f839638e0b N°6188 - Creation cancellation in pop-up while in edition of parent object wrongfully returns to object list 2023-04-21 16:12:37 +02:00
vdumas
6476e82c3d N°6212 - Mirror Target class on Trigger, so it can be displayed in complementary_name 2023-04-21 15:25:58 +02:00
Stephen Abello
62a717b93b N°6223 - On link modal creation, make ext key to current object readonly, but still submit its value (#483)
* On link creation, make ext key to current object readonly, but still submit it

* Dump autoloader

* Apply suggestions from code review thanks to @Molkobain and @Hipska

---------

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

Co-authored-by: Thomas Casteleyn <thomas.casteleyn@super-visions.com>
2023-04-21 15:02:59 +02:00
Pierre Goiffon
b4e2c79175 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-04-21 14:58:21 +02:00
Pierre Goiffon
740ff8c649 💡 DeprecatedCallsLog phpdoc 2023-04-21 14:58:00 +02:00
Molkobain
aca46fb1d6 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	application/ui.linkswidget.class.inc.php
2023-04-20 17:41:40 +02:00
Molkobain
cfe227e0c7 N°6216 - Fix line-height being too big in the attachments table 2023-04-20 15:28:20 +02:00
Molkobain
ed79c8f099 Merge remote-tracking branch 'origin/support/3.0.3' into support/3.0 2023-04-20 12:53:34 +02:00
Molkobain
4560f751d1 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	application/displayblock.class.inc.php
#	application/itopwebpage.class.inc.php
#	dictionaries/en.dictionary.itop.ui.php
#	dictionaries/fr.dictionary.itop.ui.php
2023-04-20 12:53:12 +02:00
Molkobain
46e869d1f4 N°6124 - Workaround performance problem on the modification of an object with an n:n relation having a large volume 2023-04-20 12:22:12 +02:00
Molkobain
fbd72b2783 N°6217 - Add accessiblity meta data for title on "Power menu" 2023-04-20 11:03:43 +02:00
Molkobain
f026e6f4b8 N°6208 - Router: Move to Service folder 2023-04-20 09:41:12 +02:00
Molkobain
e3252da5a9 N°6208 - Router: Add mechanism to generate complete route URL from its code 2023-04-20 09:41:12 +02:00
Molkobain
866d77dd14 N°5888 - Harmonize / implement missing methods 2023-04-19 22:33:02 +02:00
Molkobain
b078c0d289 N°5888 - Correctly handle size option for modals 2023-04-19 20:16:25 +02:00
Molkobain
5aaaaec829 N°5888 - Move resize observer to dedicated events listener method 2023-04-19 19:24:08 +02:00
vdumas
f8c2d4930d N°1350 - Audit domains: use tagset widget for adding them 2023-04-19 16:37:23 +02:00
vdumas
4645e9b94b N°6210 - Avoid n:n duplicates on User-Profile and Trigger-Actions - uniqueness rules 2023-04-19 16:35:31 +02:00
Pierre Goiffon
8d59542f0d N°6135 Delegate form & field creation in AttributeDefinition
Will allow to create SubFormField for the portal
2023-04-19 15:27:23 +02:00
Benjamin Dalsass
b2c0c5253a N°6201 - Change a CI role to "computed" in pop-up freeze the screen 2023-04-19 14:03:15 +02:00
jf-cbd
e436f9bf8d N°6179 - Tooltip attribute in field component (in Twig) (#478)
N°6179 - Tooltip attribute in field component (in Twig) (#478)
2023-04-19 11:02:47 +02:00
Stephen Abello
866a09e0c8 N°3191 - Handle max width and max height for summary cards -- missing file 2023-04-19 09:17:49 +02:00
Benjamin Dalsass
b8560e4862 N°6207 - Click on Tag Widget Tagset for n:n open in new tab, why? 2023-04-19 08:33:05 +02:00
Benjamin Dalsass
1c3117dd2c N°5958 - 1:n - edit_mode=ADD_ONLY - Location -> Person
Disable blob edition only when editing via ajax
2023-04-19 08:17:39 +02:00
Molkobain
6fbe66d2ec Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	tests/php-unit-tests/unitary-tests/webservices/RestTest.php
2023-04-18 22:50:31 +02:00
Molkobain
778118cfb4 N°6204 - REST API: Add unit test for callback parameter 2023-04-18 22:34:11 +02:00
Molkobain
096ed9a63a N°6204 - Improve REST API unit test readability 2023-04-18 22:14:39 +02:00
Molkobain
60ae3621c5 N°3191 - Refactor SCSS 2023-04-18 21:49:14 +02:00
Molkobain
9c9628b82c N°5958 - Fix regression from 51617113 2023-04-18 21:33:57 +02:00
vdumas
df0b0d1b00 N°6203 - standard DM - add summary and complementary (1) 2023-04-18 18:09:55 +02:00
vdumas
b8d5e811a4 N°3191 - Introduce summary cards - FR dico 2023-04-18 17:01:36 +02:00
Stephen Abello
b31bce7269 N°3191 - Add modify button as default action 2023-04-18 16:46:13 +02:00
Stephen Abello
e09749b288 N°3191 - Handle max width and max height for summary cards 2023-04-18 16:19:51 +02:00
Stephen Abello
e8c9255e0a N°3191 - Fix icon padding on object summary when no icon 2023-04-18 15:50:14 +02:00
Stephen Abello
41b4ef357f Do not render script methods when no script present, adcd0eb9 followup 2023-04-18 15:46:33 +02:00
Molkobain
51617113eb N°6204 - Fix REST/JSON API crash when using JSON-P and iBackofficeDictXXX interfaces 2023-04-18 15:33:57 +02:00
Pierre Goiffon
d46d1db8e4 💡 PHPDoc for ormCustomFieldsValue 2023-04-18 15:33:18 +02:00
Benjamin Dalsass
acf26754ef N°5958 - 1:n - edit_mode=ADD_ONLY - Location -> Person 2023-04-18 15:30:58 +02:00
Molkobain
425fb14188 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-04-18 14:44:17 +02:00
Molkobain
06eb79d4f4 N°6204 - Fix REST/JSON API crash when using JSON-P and iBackofficeDictXXX interfaces 2023-04-18 14:42:36 +02:00
Pierre Goiffon
b9833f26e8 Fix request template regression : after selecting template no form displayed anymore
Caused by invalid returned JSON
This bug was introduced by adcd0eb9
2023-04-18 12:19:43 +02:00
Pierre Goiffon
3e454de77e N°1150 AtributeCustomFields : GetForJSON is now delegated to the handler
Method was always returning null before
2023-04-18 11:44:00 +02:00
Stephen Abello
adcd0eb9b0 Fix some js scripts being loaded before their dependencies in ajax calls 2023-04-18 10:38:29 +02:00
Pierre Goiffon
de32b96a83 💡 N°6172 PHPDoc typo 2023-04-18 08:48:53 +02:00
Pierre Goiffon
ebc5631d4e N°6172 \utils::DoPostRequest : crash if curl php ext not available
First commit was made in 3fc663a but I forgot to throw an exception
2023-04-17 17:09:33 +02:00
Molkobain
7b7c6d1136 N°5888 - Add move cursor on modals' header 2023-04-17 16:14:31 +02:00
Stephen Abello
cf74431543 N°3191 - Introduce summary cards for objects hyperlinks (#476) 2023-04-17 12:20:49 +02:00
Benjamin Dalsass
e645e9b006 N°4148 - LinkedSet 1:n in place edition, created then removed object are still created 2023-04-17 07:55:05 +02:00
Benjamin Dalsass
a70c3d7f92 N°5350 - 1:n in place edition, deleted object re-appears 2023-04-17 07:55:05 +02:00
vdumas
752b74c0ce N°6159 - Mail notification default search - remove importance 2023-04-14 17:19:48 +02:00
vdumas
95632f40d4 N°5972 - User details: improve tooltips in EN and FR 2023-04-14 11:42:34 +02:00
Stephen Abello
ff62b5fc0b N°5888 - Use spinner for modal template and regular loader 2023-04-14 11:27:27 +02:00
Stephen Abello
16e27ef189 Add features to Spinner block 2023-04-14 11:27:27 +02:00
vdumas
95f0e97b5e N°5972 - User details: align LDAP and external users with fieldsets 2023-04-13 18:16:34 +02:00
Stephen Abello
92e044fdf4 N°5888 - Handle modal sizes using CSS instead of JS 2023-04-13 15:30:53 +02:00
Stephen Abello
68817c70ee N°5888 - Add missing dict entry for success modal 2023-04-13 15:29:25 +02:00
Stephen Abello
c7e3dd74a5 N°5957 - Fix typo in French dictionaries 2023-04-13 14:33:16 +02:00
vdumas
a86a67e404 N°5972 - User creation- Enhance details display, search, FR dico 2023-04-13 13:10:01 +02:00
Stephen Abello
b245a5c0c1 N°5888 - Add robustness when a modal is closed as resize observer is still here 2023-04-13 11:38:05 +02:00
Anne-Catherine
4e95ca3c7b N°541 - Dashlets: Improve readability when to much labels (pie chart) or too long labels (bar chart) (#452)
* N°541 - Dashlets: Improve readability when to much labels (pie chart) or too long labels (bar chart)
2023-04-13 11:23:20 +02:00
Stephen Abello
aeb8229e9e N°5888 - Replace modal resize event listener by a resize observer as it's more reactive 2023-04-13 11:16:19 +02:00
Pierre Goiffon
c9af546867 💡 AttributeDefinition : fix phpdoc for GetForJSON and FromJSONToValue methods 2023-04-13 10:56:45 +02:00
Stephen Abello
615a38cfe3 N°5981 - Change links Add button tooltip dict entry / value 2023-04-13 10:41:49 +02:00
vdumas
4bab32264b N°5972 - Allow User creation in Pop-up - Add Profile description 2023-04-12 18:46:04 +02:00
vdumas
0e8fd1eead N°6159 - Enhancement on mail notification screen (2) 2023-04-12 18:20:36 +02:00
Stephen Abello
564c9388da N°6176 - Allow to deny creation on linkset tagset widget 2023-04-12 15:31:05 +02:00
Benjamin Dalsass
1960f370e9 Merge branch 'develop' of https://github.com/Combodo/iTop into develop 2023-04-12 14:39:09 +02:00
Benjamin Dalsass
284ede77db N°6153 - n:n - Polish edition in Tagset
Object option renderer conditional additional fields
2023-04-12 14:26:22 +02:00
vdumas
84b1eca6c8 N°6159 - Enhancement on mail notification screen 2023-04-12 14:16:46 +02:00
Stephen Abello
1be7e8526e N°5981 - Change Add button label/tooltip on links 2023-04-12 11:23:31 +02:00
Stephen Abello
478d1b41be N°5981 - Change create button label/tooltip on direct links 2023-04-12 11:07:51 +02:00
Stephen Abello
38dd095e40 N°5981 - Remove exclamation mark from delete buttons 2023-04-12 11:07:51 +02:00
Pierre Goiffon
45f792d5ae Merge remote-tracking branch 'origin/support/3.0' into develop 2023-04-12 10:22:52 +02:00
Pierre Goiffon
4c626d0782 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	core/log.class.inc.php
2023-04-12 10:22:34 +02:00
Pierre Goiffon
1114ed9562 N°6099 DeadLockLog : improve documentation and use existing constants (#441) 2023-04-12 10:21:34 +02:00
vdumas
169d5a81ed N°6169 - Prevent Profile creation from Link object 2023-04-12 09:20:36 +02:00
vdumas
4d33f6d165 French dictionary typo 2023-04-12 09:20:36 +02:00
Benjamin Dalsass
288641646c N°6147 - Filter list : tooltip and new action 2023-04-12 07:53:12 +02:00
Benjamin Dalsass
544ee695be N°5957 - actions rows order and color (use constant) 2023-04-12 07:44:59 +02:00
vdumas
ac245f6ff7 N°5915 - Remove Action using tagset widget on Trigger (keep only the opposite) 2023-04-11 19:32:12 +02:00
vdumas
63447ce5c8 N°5972 - Allow User creation in pop-up 2023-04-11 19:16:47 +02:00
Pierre Goiffon
3fc663a2c6 N°6172 \utils::DoPostRequest : remove fallback when curl not present
The CURL php extension is mandatory now (see a547358be4)
Note a fix was proposed in the fallback in #459
2023-04-11 18:22:38 +02:00
Pierre Goiffon
9a4307c518 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-04-11 18:10:20 +02:00
Pierre Goiffon
1ddfaf0b61 N°6100 ObjectFormManager::OnSubmit : better log for DBWrite exceptions (#353)
Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-04-11 18:09:45 +02:00
jbostoen
cf8d675cb2 🐛 N°6174 Fix attachments to host objects without org_id can not be downloaded from the portal (#303) 2023-04-11 18:04:48 +02:00
Pierre Goiffon
924b28fd4c Merge remote-tracking branch 'origin/support/3.0' into develop 2023-04-11 17:56:12 +02:00
Pierre Goiffon
c6fb03547f Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2023-04-11 17:55:26 +02:00
Pierre Goiffon
34368fe795 N°6173 \HTMLSanitizer::Sanitize : Fix handling only svg_sanitizer (#450) 2023-04-11 17:52:41 +02:00
Stephen Abello
b7b578eee5 N°5888 - Avoid modals being larger than window, when a modal is resized, recenter it 2023-04-11 15:35:12 +02:00
Pierre Goiffon
c6d9fceff9 💡 N°4756 more info in the deprecated tag 2023-04-11 14:43:29 +02:00
Stephen Abello
a73f0ba362 N°6164 - Fix linkset tagset widget dropdown in modal 2023-04-11 14:41:28 +02:00
Benjamin Dalsass
31f163c8ca N°6006 - Linksetindirect export fails
Remove unnecessary escape html handled by twig
2023-04-11 11:40:41 +02:00
Benjamin Dalsass
a2d5e37714 N°5957 - actions rows order and color 2023-04-11 09:59:26 +02:00
Pierre Goiffon
db46298cb8 Merge branch 'support/3.0.3' into support/3.0 2023-04-11 09:19:56 +02:00
Pierre Goiffon
064e8ee511 Fix AttributeDefinitionTest parse error in PHP 7.2
(cherry picked from commit 307edd3f7a)
2023-04-11 09:19:31 +02:00
Stephen Abello
adb80b8f9a N°6153 - Add complementary attributes on linkset set tooltip 2023-04-07 11:13:15 +02:00
Eric Espie
57dce9a0f7 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-04-07 09:46:55 +02:00
Eric Espie
424e7b37d7 Merge branch 'support/3.0.3' into support/3.0 2023-04-07 09:44:38 +02:00
Eric Espie
ca7aa482ab N°6085 - UNION is not supported in UserRightsProfile::GetSelectFilter
(cherry picked from commit 8ffddeff01)
2023-04-07 09:43:50 +02:00
Eric Espie
368b3f4ef7 N°6085 - UNION is not supported in UserRightsProfile::GetSelectFilter
(cherry picked from commit 21d37fb237)
2023-04-07 09:43:40 +02:00
Molkobain
dc8e6f314a N°6085 - UNION is not supported in UserRightsProfile::GetSelectFilter
(cherry picked from commit fca4006811)
2023-04-07 09:43:25 +02:00
Stephen Abello
51c76841ec N°6153 - Prevent Link set set items from wrapping and force them to truncate with ellipsis 2023-04-06 15:39:14 +02:00
Stephen Abello
4d2107f596 N°6153 - Prevent Link set set items from wrapping and force them to truncate with ellipsis 2023-04-06 15:35:20 +02:00
Molkobain
7df0526bda 💚 LinkedSet: Fix rename namespace not propagated everywhere in e6f1a872 2023-04-06 14:39:27 +02:00
Denis
d28b099401 N°6132 - Introduce API to disable tabs dynamically (#470)
* N°6132 - disable tabs dynamically

* Apply suggestions from code review

JS cleanup after review

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Disable tabs by ID instead of index
Disabled tabs are visible (with a 'not-allowed' cursor)  instead of being hidden from the extra tabs menu.

* Typo!

* Update code to match conventions

* N°6132 - Fix show/hide of disabled tabs as it collided with internal methods

---------

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-04-06 12:12:42 +02:00
Eric Espie
2907efde4b N°6151 - Portal rules: source_oql containing UNION not allowed 2023-04-06 11:07:05 +02:00
denis.flaven@combodo.com
001194835f Config file may not exist during unattended setup/backup 2023-04-06 10:50:47 +02:00
Molkobain
e6f1a87234 💚 LinkedSet: Attempt to fix renaming 2023-04-05 19:24:42 +02:00
Molkobain
7ad3b07e89 LinkedSet: Rename classes / files to match conventions 2023-04-05 19:10:52 +02:00
Eric Espie
aafd05afd1 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-04-05 18:00:46 +02:00
Molkobain
daa4cc3a5e N°2889 - Add tooltip on download counter 2023-04-05 17:46:09 +02:00
Molkobain
d47e3ecda4 N°2889 - Fix counter not updated when downloaded by a user that don't have write permission on the host object 2023-04-05 17:46:09 +02:00
Eric Espie
8ffddeff01 N°6085 - UNION is not supported in UserRightsProfile::GetSelectFilter 2023-04-05 17:42:26 +02:00
Eric Espie
21d37fb237 N°6085 - UNION is not supported in UserRightsProfile::GetSelectFilter 2023-04-05 17:07:23 +02:00
Molkobain
fca4006811 N°6085 - UNION is not supported in UserRightsProfile::GetSelectFilter 2023-04-05 15:58:31 +02:00
Eric Espie
f91259695a Move Event service from sources/Application/Service to sources/Service 2023-04-05 10:48:20 +02:00
Eric Espie
1c2cf116da N°6085 - UNION is not supported in UserRightsProfile::GetSelectFilter - Add unit tests 2023-04-05 10:37:03 +02:00
Pierre Goiffon
fe670fa1dd Fix freeze after choosing request template form to display
When having multiple request template for the same service, you have to choose first which template to fill.
After choosing from the drop down the form was reset and nothing displayed, with an error server side.

Regression introduced in 82d2ac66
2023-04-04 18:33:37 +02:00
Pierre Goiffon
5fbd49d386 💡 type hinting 2023-04-04 18:10:04 +02:00
Pierre Goiffon
d4af51e0cc N°6142 Remove new "filter this list" link from search_form and search_oql pages
search_oql is legacy and isn't used anymore,  but adding the ContextTag anyway
2023-04-04 15:19:26 +02:00
denis.flaven@combodo.com
955aefc05b Ignore non-existing files. 2023-04-04 14:26:31 +02:00
Benjamin Dalsass
dcc524c687 Revert "Add ResourceLogMenu in application data model"
This reverts commit 5b3e71d3c1.
2023-04-03 14:15:18 +02:00
denis.flaven@combodo.com
034ca26d01 Do NOT backup unsafe files. 2023-04-03 11:54:01 +02:00
Benjamin Dalsass
5b3e71d3c1 Add ResourceLogMenu in application data model 2023-04-03 11:34:22 +02:00
Pierre Goiffon
81d1c4a37e N°6042 Fix invalid test in utils::IsNotNullOrEmptyString
Introduced in 7fa06832
Thanks Molkobain and Hipska !
2023-04-03 09:50:15 +02:00
Molkobain
80cf094c02 N°3795 - Improve JSDoc 2023-03-31 20:16:26 +02:00
Molkobain
4651b09f13 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-03-31 18:04:36 +02:00
Molkobain
c3b00939dd N°6140 - Add HTML metadata on custom fields to be aligned with regular fields 2023-03-31 17:58:09 +02:00
Pierre Goiffon
82ddc64e44 N°6042 Field init : use existing method in AttDef
Thanks Molkobain for the review in 0c70bd9
2023-03-31 16:58:40 +02:00
Pierre Goiffon
7fa06832b2 N°6042 Use utils::IsNotNullOrEmptyString
Thanks Molkobain for the review in 0c70bd9
2023-03-31 11:55:08 +02:00
Stephen Abello
d415db16d3 N°5976 - Correctly pass down context parameters when selecting a subclass 2023-03-31 11:38:05 +02:00
Stephen Abello
2758aaaa89 N°5976 - Add modal creation for linksets displayed with tagset-like widget (#469) 2023-03-31 10:32:07 +02:00
Stephen Abello
a80506b8e8 N°3795 - Replace JS alert native calls with centralized informative modals (#456)
* N°3795 - Replace JS alert native calls with centralized informative modals

* N°3795 - Add constants for severity

* N°3795 - Fix success severity value wrongfully set to 'error'

* N°3795 - Add constants for severity

* N°3795 - Simplify API consumption

* N°3795 - Allows to pass more options when consuming API
2023-03-31 10:24:49 +02:00
Pierre Goiffon
383b5623b1 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-03-31 09:12:07 +02:00
Molkobain
75df33f606 N°6139 - Add HTML metadata on activity panel to be aligned with regular fields 2023-03-30 18:39:09 +02:00
Pierre Goiffon
ca7a920498 💡 N°5906 N°4756 add missing @since pdpdoc tags 2023-03-30 15:28:33 +02:00
denis.flaven@combodo.com
d03bd706e2 Support of extra files (configurable) in the backup. 2023-03-29 16:53:38 +02:00
Molkobain
c975affecf Merge remote-tracking branch 'origin/support/3.0' into develop 2023-03-29 16:36:20 +02:00
Tarjányi Csaba
17801d044f N°6121 Update HU translations (#471) 2023-03-29 09:27:08 +02:00
Pierre Goiffon
a2763df627 📝 Version history : add 3.0.3 2023-03-28 12:26:29 +02:00
Pierre Goiffon
cdb655f69f N°6042 Delegate history creation (CMDBChangeOp instances) to the new AttributeDefinition::RecordAttChange method 2023-03-28 12:08:29 +02:00
Pierre Goiffon
3e6ab57094 N°6042 Console : save values of AttDef with the FormField edit class
For this kinf of AttDef we are calling a new AttributeDefinition::ReadValueFromPostedForm method
2023-03-28 12:08:12 +02:00
Pierre Goiffon
0c70bd9f12 N°6042 Console : now handles AttDef with FormField edit class
Those fields will use FormField / Form / FieldRenderer mechanism (previously only implemented in the portal and custom fields)
2023-03-28 12:07:47 +02:00
Pierre Goiffon
639caaafa9 🎨 Fix formatting 2023-03-28 12:02:59 +02:00
Pierre Goiffon
82d2ac66d6 🎨 Fix argument of \ormCustomFieldsValue::GetForm 2023-03-28 12:02:59 +02:00
Molkobain
78d8829d65 N°6131 - Improve robustness of tooltips helper when no DOM element passed to CombodoTooltip::InitTooltipFromMarkup() 2023-03-27 18:04:01 +02:00
Molkobain
04a80fcd39 N°6055 - Fix undefined offset error in synchro_exec.php (#465)
Co-authored-by: odain <olivier.dain@combodo.com>
2023-03-24 22:25:58 +01:00
Tarjányi Csaba
1ca1c2b06a N°6121 - Update hungarian translations thanks to @tacsaby (#461)
Grammatical corrections
2023-03-22 17:14:31 +01:00
Tarjányi Csaba
8dc499479a N°6121 - Update hungarian translations thanks to @tacsaby (#463) 2023-03-22 17:06:38 +01:00
Pierre Goiffon
43ecac7e6a N°6119 Fix fresh install crashing on profile creation
Regression brought by fc97491 / #453
2023-03-22 11:19:29 +01:00
Pierre Goiffon
1fc1746e6d 💡 N°6042 iFieldRendererMappingsExtension is experimental 2023-03-22 10:16:32 +01:00
Pierre Goiffon
cd8dd59641 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-03-21 09:24:32 +01:00
Pierre Goiffon
307edd3f7a Fix AttributeDefinitionTest parse error in PHP 7.2 2023-03-21 09:03:54 +01:00
Benjamin Dalsass
4a9c3d3582 🐛 N°6043 - fix linkset attribute default handler impact 2023-03-21 07:55:22 +01:00
Pierre Goiffon
d8d8756623 N°6043 - Booking: Add prerequisites in iTop core - Attribute extensibility 2023-03-20 14:33:02 +01:00
Molkobain
fa17a7db2d 💚 Revert year bump change on test reference files 2023-03-18 19:10:21 +01:00
Molkobain
c767ebe989 📝 Copyright year bump 2023-03-17 18:28:47 +01:00
Molkobain
5fd998819e Merge remote-tracking branch 'origin/support/3.0' into develop 2023-03-17 15:52:41 +01:00
Molkobain
6bf906a72f Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	js/dashboard.js
2023-03-17 15:44:23 +01:00
Molkobain
0f016d7511 N°6112 - Dashboard: Improve robustness by trimming dashlet ID returned by server 2023-03-17 15:37:57 +01:00
Pierre Goiffon
53fbbcb536 💡 \utils::GetClassesForInterface Add comment about return array ordering 2023-03-17 12:08:48 +01:00
Molkobain
673eca38e4 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	approot.inc.php
#	datamodels/2.x/authent-cas/module.authent-cas.php
#	datamodels/2.x/authent-external/module.authent-external.php
#	datamodels/2.x/authent-ldap/module.authent-ldap.php
#	datamodels/2.x/authent-local/module.authent-local.php
#	datamodels/2.x/combodo-backoffice-darkmoon-theme/module.combodo-backoffice-darkmoon-theme.php
#	datamodels/2.x/combodo-db-tools/module.combodo-db-tools.php
#	datamodels/2.x/itop-attachments/module.itop-attachments.php
#	datamodels/2.x/itop-backup/module.itop-backup.php
#	datamodels/2.x/itop-bridge-cmdb-ticket/module.itop-bridge-cmdb-ticket.php
#	datamodels/2.x/itop-bridge-virtualization-storage/module.itop-bridge-virtualization-storage.php
#	datamodels/2.x/itop-change-mgmt-itil/module.itop-change-mgmt-itil.php
#	datamodels/2.x/itop-change-mgmt/module.itop-change-mgmt.php
#	datamodels/2.x/itop-config-mgmt/module.itop-config-mgmt.php
#	datamodels/2.x/itop-config/module.itop-config.php
#	datamodels/2.x/itop-core-update/module.itop-core-update.php
#	datamodels/2.x/itop-datacenter-mgmt/module.itop-datacenter-mgmt.php
#	datamodels/2.x/itop-endusers-devices/module.itop-endusers-devices.php
#	datamodels/2.x/itop-faq-light/module.itop-faq-light.php
#	datamodels/2.x/itop-files-information/module.itop-files-information.php
#	datamodels/2.x/itop-full-itil/module.itop-full-itil.php
#	datamodels/2.x/itop-hub-connector/module.itop-hub-connector.php
#	datamodels/2.x/itop-incident-mgmt-itil/module.itop-incident-mgmt-itil.php
#	datamodels/2.x/itop-knownerror-mgmt/module.itop-knownerror-mgmt.php
#	datamodels/2.x/itop-oauth-client/module.itop-oauth-client.php
#	datamodels/2.x/itop-portal-base/module.itop-portal-base.php
#	datamodels/2.x/itop-portal/module.itop-portal.php
#	datamodels/2.x/itop-problem-mgmt/module.itop-problem-mgmt.php
#	datamodels/2.x/itop-profiles-itil/module.itop-profiles-itil.php
#	datamodels/2.x/itop-request-mgmt-itil/module.itop-request-mgmt-itil.php
#	datamodels/2.x/itop-request-mgmt/module.itop-request-mgmt.php
#	datamodels/2.x/itop-service-mgmt-provider/module.itop-service-mgmt-provider.php
#	datamodels/2.x/itop-service-mgmt/module.itop-service-mgmt.php
#	datamodels/2.x/itop-sla-computation/module.itop-sla-computation.php
#	datamodels/2.x/itop-storage-mgmt/module.itop-storage-mgmt.php
#	datamodels/2.x/itop-structure/module.itop-structure.php
#	datamodels/2.x/itop-themes-compat/module.itop-themes-compat.php
#	datamodels/2.x/itop-tickets/module.itop-tickets.php
#	datamodels/2.x/itop-virtualization-mgmt/module.itop-virtualization-mgmt.php
#	datamodels/2.x/itop-welcome-itil/module.itop-welcome-itil.php
#	datamodels/2.x/version.xml
#	setup/licenses/community-licenses.xml
2023-03-16 14:12:33 +01:00
Molkobain
2ca00caf49 N°6040 - Improve consistency of methods' visibility / arrangement 2023-03-16 14:08:32 +01:00
Molkobain
47399f083c N°6041 - Improve readability of the API 2023-03-15 11:02:05 +01:00
Molkobain
482261845c N°6041 - Introduce dynamic register of fields and renderers in Console form renderers 2023-03-15 11:02:05 +01:00
Molkobain
9023e338a5 N°6041 - Introduce dynamic register of fields and renderers in Bootstrap form renderers 2023-03-15 11:02:05 +01:00
Molkobain
7d01030d7c N°6041 - Introduce new \iFieldRendererMapping interface to register mapping between Field / FormRenderer (console, bootstrap, ...) / FieldRenderer 2023-03-15 11:02:05 +01:00
Molkobain
59586ad001 N°2889 - Improve PHPDoc and unit test cases 2023-03-14 19:16:19 +01:00
Molkobain
d75805fb5e N°2889 - Add placeholders for file data base64-encoded (simplifies many webhook calls) 2023-03-14 19:16:19 +01:00
Molkobain
0701f92143 N°2889 - MetaModel::ApplyParams now support placeholders with an arrow for non-object value (eg. $foo->bar$) 2023-03-14 19:16:19 +01:00
Molkobain
788a88fdc6 N°2889 - Fix attachment preview being handled as a download instead of a preview 2023-03-14 19:16:19 +01:00
Molkobain
0c8717f1f6 N°2889 - Adapt triggers to the new event system 2023-03-14 19:16:19 +01:00
Molkobain
d649d48153 N°2889 - Add triggers on file attributes / attachments downloads 2023-03-14 19:16:19 +01:00
Molkobain
0aa0229170 N°2889 - Add counter on file attributes / attachments downloads 2023-03-14 19:16:19 +01:00
Thomas Casteleyn
fc97491708 N°6105 - Cleanup unnecessary use of dirname(__FILE__) (#453) 2023-03-14 18:51:01 +01:00
Vladimir Kunin
799b6a9725 N°6104 - Fix exception thrown if 'item_class' has 'org_id' attcode mapped to another attcode (#311) 2023-03-14 18:44:16 +01:00
Pierre Goiffon
c3816c9d0b run_query : replace JQuery.hotkeys by standard keys detection (#359)
Use same technique as the one in #345
2023-03-14 17:54:09 +01:00
Pierre Goiffon
d782987f50 README : fix requirements link 2023-03-14 17:08:55 +01:00
Molkobain
b1fd7716f6 Fix community-licenses.xml 2023-03-14 12:08:54 +01:00
Molkobain
ac7abb3049 Prepare iTop 3.0.3 release
* Increase constants version to 3.0.3
* Increase modules version to 3.0.3
* Update licenses file
2023-03-14 09:55:18 +01:00
Pierre Goiffon
5d20b76476 N°5893 Fix \TriggerOnObject::LogException for PHPUnit 9
Replaced assertContains by assertStringContainsString
2023-03-10 16:50:57 +01:00
Pierre Goiffon
4548bba96a Merge remote-tracking branch 'origin/support/3.0' into develop 2023-03-10 16:25:58 +01:00
Pierre Goiffon
3689f3d026 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	tests/php-unit-tests/unitary-tests/core/TriggerTest.php
2023-03-10 16:24:17 +01:00
Pierre Goiffon
5ee6223434 N°5893 Add test for \TriggerOnObject::LogException 2023-03-10 16:04:55 +01:00
Eric Espie
ae5f4cc30f N°6040 - Booking: Add prerequisites in iTop core - Compilation extensibility - rework of properties 2023-03-10 11:48:22 +01:00
Pierre Goiffon
69beb05a55 N°6077 - Attachment class: now creation_date and user_id are init by default (#339)
Those fields were empty in case the Attachment instance was created in an extension (Mail to Ticket for example).

Now the values are set in the object DBInsertNoReload method : 
* creation_date : current date
* user_id : current user

The previous values set for console and portal are removed.

A fix for Mail to Ticket extension is also planned : N°4081.
2023-03-08 16:34:32 +01:00
Molkobain
559f5b4bdb Merge remote-tracking branch 'origin/support/3.0' into develop 2023-03-08 11:04:24 +01:00
Molkobain
4bfc1747b7 N°5784 - Fix AttributeOneWayPassword::HasAValue() implementation 2023-03-08 10:54:55 +01:00
Molkobain
15f32bf843 N°5784 - Fix ormPassword::IsEmpty() method 2023-03-08 10:04:59 +01:00
Molkobain
0ba386c0bc N°5784 - Rename unit test file to match convention 2023-03-08 09:47:42 +01:00
Molkobain
0c3cdb202b N°5784 - Fix ormPassword::IsEmpty() using the wrong class property 2023-03-08 09:36:52 +01:00
Molkobain
03ac3d4e7c N°5784 - Fix unit test for PHP 8.2 2023-03-08 09:34:35 +01:00
acognet
6510dc5c51 N°3805 - Collectors not working on iTop 3.0 (cherry picked from 4d7bac89f3 on origin/develop) 2023-03-07 22:58:38 +01:00
Molkobain
01faf39372 Tests: Force Synchro unit tests not to verify SSL certificate as most dev / test envs are self-signed 2023-03-07 22:50:29 +01:00
Molkobain
ec643d1975 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	templates/pages/backoffice/webpage/layout.html.twig
2023-03-07 22:10:47 +01:00
Molkobain
176e373d6c N°5530 - Fix list of impacted elements (Impact Analysis) not display correctly due to mixup in async JS files loading 2023-03-07 22:03:44 +01:00
Molkobain
19db527bf7 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-03-07 10:25:15 +01:00
Molkobain
a34274b883 N°5784 - PHP 8.0: Fix mandatory attribute not visible in transition form due to bad emptiness test (#379)
* N°5784 - PHP 8.0: Fix mandatory attribute not visible in transition form due to bad emptiness test

* N°5784 - Rework AttributeDefinition::HasAValue() implementation after code review

* N°5784 - Add unit test
2023-03-07 10:16:14 +01:00
Eric Espie
4bd66ac0fe N°6040 - Booking: Add prerequisites in iTop core - Compilation extensibility for new attributes 2023-03-06 16:46:00 +01:00
Benjamin Dalsass
5da76096cf 🐛 Add missing data attributes in select template 2023-03-06 15:44:09 +01:00
bdalsass
baafb97bdd N°5993 - Add purge mechanism to log system (#447)
* N°5993 - Add purge mechanism to log system

* Update core/config.class.inc.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update core/log.class.inc.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update core/log.class.inc.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update core/log.class.inc.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update core/log.class.inc.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Namespace the log purge config parameters

---------

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-03-06 15:25:26 +01:00
Pierre Goiffon
08a0c7ec88 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-03-06 14:57:11 +01:00
Pierre Goiffon
03fb78c38c N°6068 Setup : fix no formatting on error messages 2023-03-06 14:23:21 +01:00
Stephen Abello
c9e656f7a0 N°4460 - Fix configuration editor selected line contrast in Darkmoon 2023-03-06 11:40:32 +01:00
Pierre Goiffon
2ccd1a667d Merge remote-tracking branch 'origin/support/3.0' into develop 2023-03-06 11:32:48 +01:00
Pierre Goiffon
976566ec71 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	setup/setuppage.class.inc.php
2023-03-06 11:26:33 +01:00
Pierre Goiffon
d908827787 N°6016 Setup Wizard : fix MissingDependencyException message logged as html in setup.log
Was the case since e831d66b (commit for parent bug N°5090)
Now we are getting the text version in the log (and still the html one on screen)

The unattended install isn't concerned : it just prints back CheckResult returned by \SetupUtils::CheckSelectedModules, with the exception text message ($e->getMessage())
2023-03-06 11:24:46 +01:00
Benjamin Dalsass
7ae86a8bf3 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	css/backoffice/pages/_csv-import.scss
#	pages/ajax.render.php
2023-03-03 14:26:21 +01:00
Denis
93c0b98eb7 N°5922 - Fix plus button semantic on ext. key widget (#448)
* N°5922 - Enhance plus button on extkeywidget

* Properly reset the target class when closing the dialog

* Make icon buttons as actual clickable links for BeHat

* Apply suggestions from code review

Review by Guillaume. Thanks!

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-03-03 14:20:38 +01:00
Stephen Abello
98ab5aa1a4 N°4460 - Fix menu drawer color in Darkmoon 2023-03-03 10:59:49 +01:00
Stephen Abello
f117a2912b N°4460 - Fix minor contrast issue in Darkmoon 2023-03-03 10:50:02 +01:00
Stephen Abello
6594072617 N°4460 - Fix import contrast in Darkmoon 2023-03-03 10:43:39 +01:00
Stephen Abello
6bed56b34e Fix csv import SCSS file 2023-03-03 10:43:17 +01:00
Stephen Abello
94e8151519 N°4460 - Fix popover menu icons and separators style in Darkmoon 2023-03-03 10:24:52 +01:00
Stephen Abello
75b350f638 N°4460 - Fix ace editor style in Darkmoon 2023-03-03 10:06:47 +01:00
Stephen Abello
14cd60dd17 Fix hardcoded white color in markup 2023-03-02 16:36:07 +01:00
Stephen Abello
08f1e5a041 N°4460 - Fix configure this list contrast in Darkmoon 2023-03-02 16:36:07 +01:00
Stephen Abello
4c117d1a33 Fix hardcoded orange in backoffice style 2023-03-02 16:36:07 +01:00
Stephen Abello
f91dfbcf23 N°4460 - Fix datamodel viewer autocomplete contrast in Darkmoon 2023-03-02 16:36:07 +01:00
Stephen Abello
58497b380b Allow to overload datamodel viewer autocomplete style 2023-03-02 16:36:07 +01:00
Stephen Abello
03bff9f2c2 N°4460 - Fix export header contrast in Darkmoon 2023-03-02 16:36:07 +01:00
Stephen Abello
a34d3f91be Fix tabular fields selector SCSS variables 2023-03-02 16:36:06 +01:00
Stephen Abello
05753f174a N°4460 - Fix "load more entries" activity panel buttons contrast in Darkmoon 2023-03-02 16:36:06 +01:00
Stephen Abello
d0c89343b4 N°4460 - Fix skeletons placeholders contrast issue in Darkmoon 2023-03-02 16:36:06 +01:00
Stephen Abello
3021234895 N°4460 - Allow to customize skeleton placeholders colors using CSS3 variables 2023-03-02 16:36:06 +01:00
Stephen Abello
bccdb1bc3a N°4460 - Fix <code> contrast in Darkmoon 2023-03-02 16:36:06 +01:00
Molkobain
a0483738bc Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	core/dbobject.class.php
#	core/trigger.class.inc.php
2023-02-28 21:54:40 +01:00
Molkobain
143410f4cd Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	core/dbobject.class.php
2023-02-28 15:20:07 +01:00
Pierre Goiffon
4cea418517 N°5893 - Log triggers exception in CRUD stack (#390)
* Log TriggerOnObjectCreate crash

* Log TriggerOnObjectUpdate crash

* Log TriggerOnObjectDelete crash

* Factorize TriggerOnObject log

* \TriggerOnObject::LogException : do not replace not persisted yet object keys
2023-02-28 15:13:28 +01:00
Molkobain
759b1825fe N°5918 - Fix activity panel disappearing when DoCheckToWrite fails 2023-02-28 13:33:47 +01:00
acognet
ba21687e5f Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	core/bulkchange.class.inc.php
2023-02-28 12:34:47 +01:00
Anne-Catherine
370c1345d9 N°2916 - Import of IPv6 addresses fails when reconciliation is done on the IP (#382) 2023-02-28 12:08:32 +01:00
acognet
948cbb1446 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-02-27 16:44:16 +01:00
Anne-Catherine
af8f06c8c3 N°5603 - Autocomplete fails with error for an external key pointing to an abstract class with no friendlyname (#375) 2023-02-27 16:18:36 +01:00
Pierre Goiffon
099a045852 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-02-27 15:20:12 +01:00
Pierre Goiffon
bfe55183d0 N°6023 Fix error log
Thanks @Hipska !
2023-02-27 15:09:49 +01:00
Eric Espie
cf5fd3e2a8 N°5906 - CRUD Event - 🎨 rename event_listeners/listener XML nodes by event_listeners/event_listener 2023-02-27 11:23:55 +01:00
Eric Espie
bb62723114 N°5906 - CRUD Event - Fix listener launched twice and refactor calls to Tickets::UpdateImpactedItems() 2023-02-27 11:17:05 +01:00
Pierre Goiffon
937313c20e N°5906 - CRUD Event - Fix \DBObject::IsCrudStackEmpty not static 2023-02-27 11:17:05 +01:00
odain
939771aa15 N°6022 - Make synchro scripts work by http via token authentication with SYNCHRO scopes 2023-02-27 11:07:52 +01:00
Molkobain
70cbaeac7a Merge remote-tracking branch 'origin/support/3.0' into develop 2023-02-24 22:42:06 +01:00
Molkobain
b174e4cab3 N°4517 - PHP 8.1: Fix deprecated notice for null value passed to string parameter of native PHP functions 2023-02-24 22:40:17 +01:00
Molkobain
b1bd1e1677 PHPUnit: Migrate deprecated usages of assertFileNotExists() and assertRegExp() 2023-02-24 21:41:53 +01:00
Molkobain
029c01b13e Merge remote-tracking branch 'origin/support/3.0' into develop 2023-02-24 21:41:05 +01:00
Molkobain
61bd8b6bb4 N°4517 - PHP 8.1: Fix deprecated notice for null value passed to string parameter of native PHP functions 2023-02-24 21:40:10 +01:00
Pierre Goiffon
3a77423b38 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	tests/php-unit-tests/unitary-tests/application/utilsTest.php
2023-02-23 18:57:50 +01:00
Pierre Goiffon
5c9eb7fa38 N°6020 PHPUnit for \utils::EscapeHtml and EscapedHtmlDecode methods
This will ensure conversion back and forth is working as expected (in other words, parameters to the php functions stays the same in both methods)
2023-02-23 18:56:28 +01:00
Pierre Goiffon
4e8a1563f8 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-02-23 18:38:39 +01:00
Pierre Goiffon
e960a4ad53 N°6023 Fix cannot load SVG files in AttributeImage since 3.0.0 (#449)
Caused by merge error in ddd6bf2

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-02-23 18:38:03 +01:00
Molkobain
1980cf4700 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	composer.json
#	composer.lock
#	lib/composer/autoload_files.php
#	lib/composer/autoload_real.php
#	lib/composer/autoload_static.php
#	lib/composer/installed.json
#	lib/composer/installed.php
#	lib/firebase/php-jwt/README.md
#	lib/firebase/php-jwt/src/CachedKeySet.php
#	lib/firebase/php-jwt/src/JWK.php
#	lib/firebase/php-jwt/src/JWT.php
2023-02-23 16:29:06 +01:00
Molkobain
7aad60ed1b Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	composer.json
#	composer.lock
#	lib/composer/autoload_classmap.php
#	lib/composer/autoload_static.php
#	lib/composer/installed.php
#	lib/composer/platform_check.php
#	setup/setuputils.class.inc.php
2023-02-23 16:21:56 +01:00
Molkobain
97965277c7 N°6017 - Update OAuth dependencies 2023-02-23 15:57:32 +01:00
Pierre Goiffon
758933ae74 N°5849 use the new \utils::EscapedHtmlDecode method 2023-02-23 15:19:36 +01:00
Pierre Goiffon
f6a4cdbd8f Merge remote-tracking branch 'origin/support/3.0' into develop 2023-02-23 15:18:06 +01:00
Pierre Goiffon
93aee5883b N°6020 New \utils::EscapedHtmlDecode method 2023-02-23 15:17:46 +01:00
Molkobain
18ed5ed526 N°6019 - Increase PHP min version to 7.1.3 to enable dependencies update 2023-02-23 14:53:48 +01:00
Pierre Goiffon
93291454e5 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-02-23 12:05:55 +01:00
Pierre Goiffon
bbf6476570 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2023-02-23 12:05:38 +01:00
Pierre Goiffon
94c4f8c929 N°6016 MissingDependencyException : better log message (#355)
The error displayed on screen was already improved (see #280)
This commit improves the log message we can have for example by running unattended install.
2023-02-23 12:04:56 +01:00
Pierre Goiffon
5e6ed950cb ReOrder LogChannels const 2023-02-23 11:55:31 +01:00
Pierre Goiffon
8ab459dfbc Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	core/log.class.inc.php
2023-02-23 11:54:42 +01:00
Pierre Goiffon
d40cf7fe3b ReOrder LogChannels const 2023-02-23 11:52:19 +01:00
Pierre Goiffon
6997c0fd83 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	core/log.class.inc.php
2023-02-23 11:47:49 +01:00
Pierre Goiffon
822922df5c N°5588 - Improve PDF export robustness when AttributeImage dimensions cannot be determined (#350)
Can happen for example on SVG images
Now the export won't crash anymore, and we'll get a log (export channel, warning level) with  the object and attribute causing a problem as context

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-02-23 11:45:29 +01:00
Pierre Goiffon
d39ecb7406 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-02-23 11:23:31 +01:00
Pierre Goiffon
cb2be0eccd N°5121 New AttributeURL validation use case
In comment as it isn't handled yet
2023-02-23 11:16:50 +01:00
Molkobain
26169111ed Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	css/backoffice/utils/helpers/_misc.scss
2023-02-23 11:05:54 +01:00
Pierre Goiffon
f55fc8d264 N°6014 Validation pattern for URL : now handles commas in params (#356)
Seen on PRTG URLs

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-02-23 10:59:38 +01:00
Molkobain
577f125a8d PHP 8.1: Fix trim() usage with a null value in Trigger 2023-02-23 10:40:29 +01:00
Molkobain
04269747b7 N°5920 - Increase delay before displaying tooltip 2023-02-23 10:17:30 +01:00
Molkobain
826fbe10c8 N°6002 - Explicitly add symfony/http-foundation and symfony/http-kernel to composer.json for easier lib update 2023-02-22 22:38:15 +01:00
Molkobain
ea2140258c N°5317 - Handle overlapping tables when table cells have fixed widths 2023-02-22 18:57:56 +01:00
Molkobain
d997e36de0 N°6002 - Update Symfony libs to 5.4.19 2023-02-22 18:19:56 +01:00
Molkobain
5ee603f2ba Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	datamodels/2.x/itop-portal-base/portal/src/Form/ObjectFormManager.php
2023-02-22 18:08:56 +01:00
Stephen Abello
31f2666941 Merge branch 'support/2.7' into support/3.0
# Conflicts:
#	js/wizardhelper.js
2023-02-22 15:46:13 +01:00
Stephen Abello
cac7e94a67 N°5729 - Fix disabled button in bulk update/transition when picking a value in a drop-down list 2023-02-22 15:42:20 +01:00
Pierre Goiffon
7925a5bd7e N°6013 Remove combodo-webhook-integration file
Will be pushed in the corresponding module repo
2023-02-22 15:28:26 +01:00
Molkobain
cd72eee6dd N°6013 - Update hungarian translations thanks to @tacsaby 2023-02-22 14:47:10 +01:00
Stephen Abello
da02a05fa3 Merge branch 'support/2.7' into support/3.0 2023-02-22 10:18:38 +01:00
Stephen Abello
6d019615d0 N°5865 - Restore DoCheckToWrite error messages in portal 2023-02-22 10:17:34 +01:00
BenGrenoble
d3a5bb723f N°5968 - Add structural data for Brand, OSFamily and OSVersion 2023-02-22 10:15:51 +01:00
BenGrenoble
a37dea9cc2 N°4577 - Move service dependencies from "itop-bridge-cmdb-ticket" to another module
Move Document Services_list and Document Contracts_list to the bridge cmdb-services
2023-02-22 09:24:24 +01:00
Molkobain
0c962d7e32 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	datamodels/2.x/itop-bridge-cmdb-ticket/dictionaries/cs.dict.itop-bridge-cmdb-ticket.php
#	datamodels/2.x/itop-bridge-cmdb-ticket/dictionaries/da.dict.itop-bridge-cmdb-ticket.php
#	datamodels/2.x/itop-bridge-cmdb-ticket/dictionaries/de.dict.itop-bridge-cmdb-ticket.php
#	datamodels/2.x/itop-bridge-cmdb-ticket/dictionaries/fr.dict.itop-bridge-cmdb-ticket.php
#	datamodels/2.x/itop-bridge-cmdb-ticket/dictionaries/ja.dict.itop-bridge-cmdb-ticket.php
#	datamodels/2.x/itop-bridge-cmdb-ticket/dictionaries/sk.dict.itop-bridge-cmdb-ticket.php
#	datamodels/2.x/itop-config-mgmt/dictionaries/hu.dict.itop-config-mgmt.php
#	datamodels/2.x/itop-problem-mgmt/dictionaries/hu.dict.itop-problem-mgmt.php
#	datamodels/2.x/itop-service-mgmt/dictionaries/fr.dict.itop-service-mgmt.php
#	datamodels/2.x/itop-structure/dictionaries/fr.dict.itop-structure.php
#	dictionaries/hu.dictionary.itop.core.php
2023-02-21 22:26:54 +01:00
Molkobain
ccdd315357 N°5919 - Add missing linkset descriptions in french and other languages 2023-02-21 22:14:57 +01:00
Eric Espie
a9f08e87f9 N°5906 - CRUD Event - move some code 2023-02-21 11:06:10 +01:00
Molkobain
2d80d1c1df N°5741 - Fix wrong merge from 649674c7 2023-02-21 10:34:24 +01:00
Eric Espie
43d17f9519 Fix unit tests for PHP8.1 2023-02-20 11:57:39 +01:00
Molkobain
6c4289a491 Tests: Rename file to match conventions 2023-02-17 15:33:09 +01:00
Eric Espie
8940051c3d N°5906 - CRUD Event - fire event EVENT_DB_LINKS_CHANGED when an n-n link is created/updated/deleted 2023-02-17 14:25:01 +01:00
Eric Espie
72dad5dd07 N°5891 - Make CSV import unit tests work 2023-02-16 16:14:37 +01:00
Molkobain
dc38db1c3d PHP 8.1: Reduce time interval to something more pragmatic for quicker test execution 2023-02-16 11:40:59 +01:00
Molkobain
45df1002ec N°5388 - PHP 8.2: Fix dynamic properties to standard declared properties 2023-02-15 23:02:40 +01:00
Molkobain
737388053f PHP 8.1: Fix FunctionExpression::Evaluate() "TO_DAYS" misalignment due to PHP 8.1 bug fix 2023-02-15 21:31:11 +01:00
dariocodes
d0b000d125 Update README.md to improve grammar
- Using hyphens to combine "web-based" ensures that the reader understands that it is a compound modifier.
- Adding a comma after "platform" helps to separate the list of items that follows and improve readability.
- Using commas to separate the list of items in the series (CMDB, helpdesk system, and document management tool) helps to clarify that each item is a distinct element.
- Fixed a typo where "adds-on" was written instead of "add-ons".
- Uses the wrong form of the verb "be." In this context, the correct form of the verb to use is "become," not "being." 
- Adding a comma after led is grammatically better as is referenced here: https://github.com/Combodo/combodo-workflow-graphical-view/pull/1
2023-02-15 18:02:54 +01:00
Eric Espie
1d0ce1862d N°4756 - Ease extensibility for CRUD operations : Event Service - Fix unit tests 2023-02-14 15:53:12 +01:00
Eric Espie
c0589715c1 N°4756 - Ease extensibility for CRUD operations : Event Service - Fix RegisterListener() signature and calls 2023-02-14 11:26:47 +01:00
Eric Espie
8b18fd7cc0 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-02-14 09:35:59 +01:00
Eric Espie
9f81e4875a Merge branch 'hotfix/5944_GetClassesForInterface_filter' into support/3.0 2023-02-14 09:16:49 +01:00
Molkobain
33717b9610 N°5951 - Fix crash when creating a user with a non valid password
/!\ Mind that this could have impact on DoCheckToWrite() overloads for people using \DBObject::GetKey() instead of \DBObject::IsNew()
2023-02-13 20:22:39 +01:00
Molkobain
b97a464bb1 N°2783 - Initialize property correctly (highlighted by 58c0da7e) 2023-02-13 19:36:46 +01:00
Pierre Goiffon
58c0da7e87 N°2783 Fix setup crashing because of a php warning (#389) 2023-02-13 17:09:24 +01:00
Molkobain
4203382920 N°2783 - Add support for custom zlists (#389) 2023-02-13 16:13:51 +01:00
Molkobain
825e402dd6 N°5279 - Improve DBBackup::MakeName() unit test by evaluating placeholders 2023-02-13 15:57:29 +01:00
Molkobain
fa75c8964a Tests: Improve REST API tests robustness when output JSON is not always ordered the same (even though the content is semantically the same) 2023-02-13 10:27:28 +01:00
Pierre Goiffon
fc58c6f4ce N°4577 setup params : add itop-bridge-cmdb-services 2023-02-13 09:23:19 +01:00
Molkobain
ef4e38f6b9 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-02-11 09:55:15 +01:00
Molkobain
4f102d764a Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2023-02-10 23:18:37 +01:00
Molkobain
dbd58cfeb6 Tests: Force RestAPI unit tests not to verify SSL certificate as most dev / test envs are self-signed 2023-02-10 23:07:27 +01:00
Molkobain
1086eaaffe N°3190 - Fix XML conversion unit test 2023-02-10 22:37:24 +01:00
Molkobain
f7ee21f1d7 N°5279 - PHP 8.1: Migrate usages of deprecated strftime() function
In the end we made an adapter to keep using the strftime() format (https://www.php.net/manual/fr/function.strftime.php); not to ease migration but because we couldn't use \DateTime::format().
We can't use \DateTime::format() directly on the whole filename as it would also format characters that are not supposed to be. eg. "__DB__-Y-m-d-production" would become "itopdb-2023-02-09-+01:00Thu, 09 Feb 2023 11:34:01 +0100202309", mind the "production" part being converted.
2023-02-10 22:15:18 +01:00
Pierre Goiffon
35b0b16e20 N°4756 Add listenerId to register call for debug purposes 2023-02-10 17:31:48 +01:00
Pierre Goiffon
ca72ec736e N°4756 DBObject Rename Event* methods to FireEvent* 2023-02-10 15:22:33 +01:00
Pierre Goiffon
e63d66aa5d N°4756 Fix TypeError on EventData::$aCallbackData 2023-02-10 15:01:56 +01:00
bdalsass
2803f0be49 N°3190 - Add iTop design format compatibility converter
- Add converter for  for display_style property
- Update php unit test to control conversion
2023-02-10 13:47:10 +01:00
BenGrenoble
278b0d643f N°5968 - Add structural data for Brand, OSFamily and OSVersion
Refactor file model.itop-bridge-cmdb-services.php
2023-02-10 11:21:19 +01:00
vdumas
569045f675 N°5946 - Error in a french translation - user preference 2023-02-09 17:30:17 +01:00
vdumas
25989bc00f N°5947 - Typos in french translation for incident 2023-02-09 17:25:25 +01:00
vdumas
fc60759db5 N°5920 - Align icon, title and tooltip for extra tabs in standard DM 2023-02-09 17:13:07 +01:00
BenGrenoble
3a931ff79e N°5968 - Add structural data for Brand, OSFamily and OSVersion
Change path and correct osversion id
2023-02-09 11:32:57 +01:00
BenGrenoble
f6bd380ad0 N°5968 - Add structural data for Brand, OSFamily and OSVersion
Remove sample brand
2023-02-09 11:10:00 +01:00
BenGrenoble
97c4ecf8bc N°5968 - Add structural data for Brand, OSFamily and OSVersion
Correct brand id
2023-02-09 10:50:59 +01:00
BenGrenoble
5f4ef74d34 N°5968 - Add structural data for Brand, OSFamily and OSVersion
Move data to config-mgmt
2023-02-09 10:45:10 +01:00
BenGrenoble
6184dbafff N°4577 - Move service dependencies from "itop-bridge-cmdb-ticket" to another module 2023-02-09 10:32:39 +01:00
BenGrenoble
630c1dcdc8 N°5968 - Add structural data for Brand, Model, OSFamily and OSVersion 2023-02-09 09:59:06 +01:00
vdumas
cb84cbf7a8 N°5106 - Add Associated User tab on Person 2023-02-09 09:40:19 +01:00
vdumas
b025f86b21 N°5106 - Add Associated User tab on Person 2023-02-09 09:06:48 +01:00
vdumas
5a76175ec1 N°5908 - add a description on "known error" tab on UserRequest and Incident 2023-02-09 09:03:18 +01:00
vdumas
ce162f05da N°5908 - add a description on "known error" tab on UserRequest and Incident 2023-02-08 19:00:57 +01:00
Molkobain
d358c9e8fa N°5920 - Tab manager: Fallback on dict entry code convention (tab code followed by "+" sign) for tab's description / tooltip if none given 2023-02-08 18:23:20 +01:00
bdalsass
86a208a86d N°5904 - Use attribute linked set edit mode to enable actions in view (improvement) 2023-02-08 14:34:46 +01:00
vdumas
372888c7a7 N°5106 - Add Associated User tab on Person 2023-02-08 13:01:41 +01:00
Molkobain
547a520ab1 N°5951 - Temporary fix to unblock 3.1.0-alpha1, we need to discuss the DBObject::DBInsertNoReload() sequence before going further 2023-02-07 19:41:03 +01:00
Molkobain
8bf788dcb9 N°5904 - PHP 8.1: Migrate usage of deprecated FILTER_SANITIZE_STRING constant 2023-02-07 14:57:24 +01:00
Molkobain
a157e754a9 N°5074 - Clean up of dynamically created class properties due to bdb29fd99 2023-02-07 14:51:42 +01:00
Molkobain
eae84ab399 N°5074 - Clean up of dynamically created class properties due to bdb29fd99 2023-02-07 14:51:00 +01:00
Molkobain
4d4d3bd9a2 N°5904 - Fix crash when adding a 1:n link item in object edition 2023-02-07 14:35:49 +01:00
Benjamin Dalsass
9f9630d011 N°5904 - remove link as tagset add button 2023-02-07 09:42:41 +01:00
Benjamin Dalsass
de1c58a84c N°5904 - Use attribute linked set edit mode to enable actions in view 2023-02-06 17:22:30 +01:00
bdalsass
1fe9520b7e N°5904 - Use attribute linked set edit mode to enable actions (#440)
* Add corresponding buttons depending on old edit mode (need to check with piR pour récuperer l'ancienne valeur.

* N°5904 - Handle attribute linked set edit_mode

* N°5904 Move calls to private jquery widget methods to public

* N°5904 - Worker improvements add button on link tagset

* Change itop set widget to new set block UI (5)

* Change itop set widget to new set block UI (5)

* Renommage variables JS avec le prefix combodo

* Search dialog block id conflict with form id

* add moved js files in iTopWebPage compatibility list

---------

Co-authored-by: Stephen Abello <stephen.abello@combodo.com>
2023-02-06 16:07:55 +01:00
Stephen Abello
3fbc5e1ce0 N°5904 Hide decorative plus icon on attribute set edit 2023-02-06 14:24:44 +01:00
Molkobain
786e7d647c N°5388 - PHP 8.2: Fix partially supported callable 2023-02-03 23:01:24 +01:00
Eric Espie
99b7d66cf2 N°5944 - Wrong filter for utils::GetClassesForInterface() 2023-02-03 11:10:37 +01:00
Molkobain
1768274aaf N°5943 - Fix undefined array key "Remote" in AjaxRenderController.php with DokuWiki extension 2023-02-03 09:38:28 +01:00
Stephen Abello
7cc1e33950 N°5904 Fix attribute set / linkset wrapping 2023-02-02 10:05:55 +01:00
Molkobain
72a586e490 N°5905 - Fix linkset panel description still in an alert when editing host object 2023-02-01 18:09:46 +01:00
Stephen Abello
0cce58e0cf N°5904 Fix hardcoded string when existing dict entry was available 2023-02-01 09:40:38 +01:00
Stephen Abello
53b68f88b8 Fix typo in dictionaries 2023-02-01 09:39:33 +01:00
Stephen Abello
7fb10da013 N°5904 Fix hardcoded strings when existing dict entries were available 2023-02-01 09:33:58 +01:00
Stephen Abello
0b1352fe37 N°5904 Move dict entries 2023-01-31 09:57:06 +01:00
acognet
e0cc00e772 N°5849 - Fix wrong encoding of external keys in "Header with statstics" dashlet - fix for 3.1 2023-01-30 17:29:51 +01:00
Molkobain
002e52cc3e N°5929 - Fix parse error due to not closed array from bbea9782 2023-01-30 17:21:41 +01:00
Thomas Casteleyn
bbea978259 N°5929 - Update hungarian translations thanks to @tacsaby (#438)
Co-authored-by: tacsaby
Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-01-30 17:15:08 +01:00
Molkobain
bddfa4cd7a Merge remote-tracking branch 'origin/support/3.0' into develop 2023-01-30 17:09:36 +01:00
Anne-Catherine
12ef74ec42 N°5849 - Fix wrong encoding of external keys in "Header with statstics" dashlet (#384)
N°5849 - Fix wrong encoding of external keys in "Header with statstics" dashlet #384
2023-01-30 16:06:10 +01:00
Eric Espie
cd1b441025 N°4756 - Ease extensibility for CRUD operations: 🎨 add log 2023-01-30 14:45:58 +01:00
Pierre Goiffon
0f97b93617 N°5856 Fix object lists always ajax loaded
Regression introduced in N°3200 with 4f7a1ea9
2023-01-30 09:31:10 +01:00
Molkobain
b61c8ea4ca N°5388 - PHP 8.2: Fix dynamic properties to standard declared properties 2023-01-27 19:00:59 +01:00
Molkobain
f48df74933 N°5388 - PHP 8.2: Fix dynamic properties that were actually just case-sensitive typos 2023-01-27 17:57:50 +01:00
Molkobain
6fb00cbbf3 N°5388 - PHP 8.2: Fix dynamic properties to standard declared properties 2023-01-27 17:56:55 +01:00
Molkobain
af2421a2cb N°5905 - Move tab description to a tooltip on the panel's title instead of a big blue alert 2023-01-27 17:25:03 +01:00
Molkobain
0374e303e4 N°5905 - Refactor CSS class .ibo-has-description so it can be used on any element 2023-01-27 17:25:03 +01:00
Molkobain
27bd78d76b Refactor SCSS misc. partial to dedicated partials as it was growing too much 2023-01-27 17:25:03 +01:00
Stephen Abello
bc3b43958c N°5904 When getting an error in a popup (e.g. uniqueness rule), remove submit state, so we can submit the form again 2023-01-27 14:33:49 +01:00
Molkobain
fd4a2f17d2 N°4481 - Fix CSS class name 2023-01-27 13:24:54 +01:00
vdumas
d741656028 N°5904 - Linksets: tooltip & pop-up title 2023-01-27 11:00:08 +01:00
Molkobain
f7e8bd31f5 N°5905 - Fix "+" button displayed twice on linksets with 1 item 2023-01-26 17:49:17 +01:00
Eric Espie
1e37370789 N°4756 - Ease extensibility for CRUD operations : 🎨 refactor after code review with PG 2023-01-26 17:32:08 +01:00
Tarjányi Csaba
5844717980 Update hu.dict.authent-local.php
a small fix
2023-01-26 16:20:11 +01:00
Vincent Dumas
9437968d0e N°5825 - Add friendlyname & uniqueness rule on Links (#416)
* N°5825 - Add label, friendlyname, filter, details view, uniqueness rules on Link classes
* N°5825 - Add label, friendlyname, details view, uniqueness rules on Link classes
2023-01-26 14:26:31 +01:00
Molkobain
e72ed33a40 N°5920 - Add linkset's description as corresponding tab's tooltip in object details 2023-01-26 12:01:56 +01:00
Molkobain
2a825c6ba0 N°5905 - Fix "+" button displayed twice on linksets with no item 2023-01-26 11:03:01 +01:00
vdumas
6b8d9ea08d N°5915 - Complementary Name on Trigger and Action 2023-01-26 09:03:52 +01:00
vdumas
52d57293c9 N°5825 - Add label, friendlyname, details view (on LnkPersonToTeam) 2023-01-25 18:37:38 +01:00
Molkobain
40cebf1eb7 N°5923 - Align panel's header within another panel when it has no icon 2023-01-25 16:50:21 +01:00
Molkobain
f1d6f3e5c2 N°5905 - Harmonize how known errors are displayed in an object 2023-01-25 15:33:44 +01:00
Pierre Goiffon
834c4a2654 N°5563 Restore edit_mode getter
Woops forgot in 13550fd6
2023-01-25 14:57:30 +01:00
Molkobain
ed1a076ebb N°5905 - Harmonize how notifications are displayed in an object 2023-01-25 10:41:18 +01:00
Molkobain
1dcf38f2ea N°5905 - Harmonize how linksets are displayed in edition part I
* Always display a table and its actions to ease link creation
* Display linkset description in an alert block
2023-01-25 10:29:48 +01:00
odain
2f034253e7 N°5891 - Make CSV import unit tests work-use another password for user authentication 2023-01-25 08:56:15 +01:00
Molkobain
a10ac7fdcb N°5905 - Harmonize how linksets are displayed part I
* Always display a table and its actions to ease link creation
* Display linkset description in an alert block
2023-01-24 21:12:49 +01:00
vdumas
3775ccea74 N°5915 - Display n:n in Trigger and Action using tagset widget 2023-01-24 17:23:44 +01:00
bdalsass
f743971c93 N°5914 - Wrong encoding in modules configuration editor (#392) 2023-01-24 16:33:02 +01:00
Stephen Abello
dd213df9c4 N°5822 Fix 7127b192 SCSS rule 2023-01-24 14:33:41 +01:00
Molkobain
96825c646e N°4756 - Move event register to dedicated folder 2023-01-24 14:20:35 +01:00
Stephen Abello
1152b2f401 N°5904 Hide transitions in modals 2023-01-24 11:21:35 +01:00
Stephen Abello
8f7003c694 N°5904 Change dict entry value 2023-01-24 11:21:33 +01:00
bdalsass
fb1ceebaa4 N°3190 - Edit n:n LinkedSetIndirect in object details using a tagset-like widget
- Add generic set block ui component
- Add model link set (direct and indirect) attribute (display style)
- Add model link set direct allowed values
- Create link set viewer block UI (BlockLinksSetDisplayAsProperty)
- Add set block ui factory for linkset
- Add object factory and create new endpoint in object controller (with data binder)
- Add link set model, link set repository and link set data transformer services
2023-01-24 10:03:10 +01:00
Stephen Abello
9482139b5a N°5904 Fix undefined attribute when refreshing Datatables 2023-01-23 16:42:43 +01:00
Stephen Abello
7ea2315323 Fix php warning and missing dict entry for 1-n (3d9a85d follow-up) 2023-01-23 16:36:13 +01:00
Stephen Abello
9487d63b9c N°5904 When detaching/deleting a linked object, refresh datatable or display an error message 2023-01-23 16:16:23 +01:00
Stephen Abello
3d9a85d577 Fix php warning and missing dict entry 2023-01-23 15:36:38 +01:00
Molkobain
b2397fc570 N°4517 - Fix missing use statement from 7ec12f1e1 2023-01-20 15:30:53 +01:00
Molkobain
0d15b01b3f Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	pages/UI.php
2023-01-20 11:59:26 +01:00
vdumas
f7e87c1ea1 N°5347 - Change default value of allow_menu_on_linkset 2023-01-20 11:30:55 +01:00
Molkobain
3ca4122673 N°5834 - Fix activity panel disappearing when creating a Ticket in 'resolved' state 2023-01-20 11:30:05 +01:00
Stephen Abello
f21f6aec30 Missing class import 2023-01-20 10:10:05 +01:00
Pierre Goiffon
c76d351379 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	datamodels/2.x/combodo-db-tools/module.combodo-db-tools.php
2023-01-19 17:54:29 +01:00
Pierre Goiffon
efa20e77d0 N°3769 Add data-input-id HTML attribute to fields in a transition form
Was only present in object edit mode :(
2023-01-19 17:53:14 +01:00
Eric Espie
effc4141c7 N°5900 - DB integrity analysis crashes when too many errors - module version 2023-01-19 09:30:37 +01:00
Eric Espie
b4813de0a5 Merge branch 'support/3.0' into develop
# Conflicts:
#	datamodels/2.x/combodo-db-tools/module.combodo-db-tools.php
2023-01-19 08:52:47 +01:00
Eric Espie
f75a51d59e N°5900 - DB integrity analysis crashes when too many errors - limit the results to 100 to avoid memory errors 2023-01-19 08:51:02 +01:00
Molkobain
8e3bad11ae N°5563 - Fix XML conversion XPaths 2023-01-18 19:35:59 +01:00
Pierre Goiffon
13550fd643 N°5563 Relations XML : restore edit_mode node
There are (yet !) not change in the relations UI when in object is in edit mode, so we need to keep previous behaviors.
2023-01-18 18:11:02 +01:00
Molkobain
44977d69b6 N°5608 - Fix event service unit tests namespace 2023-01-18 17:50:22 +01:00
Molkobain
15f108152c N°5608 - Fix Twig unit test and re-enable all tests under /sources dir that were not run! (Application/Helper, Application/Service, Application/TwigBase, Composer, Router) 2023-01-18 17:41:47 +01:00
Molkobain
9be167cf5e N°5608 - Rename unit tests dirs "sources/application" to match counter-part dirs name 2023-01-18 17:39:55 +01:00
Eric Espie
34688c2bf6 Merge branch 'support/3.0' into develop 2023-01-18 16:42:30 +01:00
Eric Espie
9dc54d6e4c N°5901 - Warnings in Details part of file system Tab 2023-01-18 16:39:40 +01:00
Eric Espie
640b1b9176 ✏️ Added missing use of class Toolbar 2023-01-18 16:38:16 +01:00
Stephen Abello
c1922e2b3f N°3300 - Add creation and modification of 1-n objects in object details (#385)
* Rebase onto develop

* Use exit condition instead of englobing condition

* Add informative modals that can be called from modal toolbox

* Refactor "apply_modify" and "apply_new" into own controller, handle ajax requests with a json response and handle these responses in linkset creation/edition

* Fix merge issues

* Remove inverted condition

* Move linkset create button to a better place, still needs to fix duplicate "New" button caused by a refactor

* Handle "Cancel" button in modals

* Do not display relations when editing an object in a modal

* More elegant way to add "New" button to relations lists

* Factorize vertical highlights in alerts and modal in a single mixin

* Replace button name with dict entry code

* Change route name to snake case

* More elegant way to add "Create in modal" button to relations lists

* Replace triple if with in_array

* Move listener to body

* Rename variable to match boolean rules

* Rename event

* Rename extra param

* Add phpdoc

* Revert changes

* Check indirect linkset rights before allowing creation in modal

* Allow to modify linked object from 1-n relation in modal

* Add "New" button to 1-n relations

* Fix "new" button on 1-n

* Add todo

* Handle multiple classes choice

* Rework multiple classes choice and only allow LinksetController to be called from an ajax context

* PhpDoc

* Update sources/Application/UI/Links/Direct/BlockDirectLinksViewTable.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2023-01-18 15:43:31 +01:00
Stephen Abello
e1ffa65d8b N°3136 - Add creation and modification of n-n objects in object details (#378)
* Rebase onto develop

* Use exit condition instead of englobing condition

* Add informative modals that can be called from modal toolbox

* Refactor "apply_modify" and "apply_new" into own controller, handle ajax requests with a json response and handle these responses in linkset creation/edition

* Fix merge issues

* Remove inverted condition

* Move linkset create button to a better place, still needs to fix duplicate "New" button caused by a refactor

* Handle "Cancel" button in modals

* Do not display relations when editing an object in a modal

* More elegant way to add "New" button to relations lists

* Factorize vertical highlights in alerts and modal in a single mixin

* Replace button name with dict entry code

* Change route name to snake case

* More elegant way to add "Create in modal" button to relations lists

* Replace triple if with in_array

* Move listener to body

* Rename variable to match boolean rules

* Rename event

* Rename extra param

* Add phpdoc

* Revert changes

* Check indirect linkset rights before allowing creation in modal
2023-01-18 13:35:48 +01:00
Molkobain
cc2881a7b0 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-01-17 19:21:52 +01:00
Molkobain
0d8a21f6ef N°5897 - Improve deprecated logs relevance for PHP "trigger_deprecation" 2023-01-17 16:30:35 +01:00
Molkobain
3459dc5997 N°5897 - Improve deprecated logs relevance for PHP "trigger_deprecation" 2023-01-17 16:29:25 +01:00
Pierre Goiffon
01d9d34118 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-01-17 15:37:43 +01:00
Pierre Goiffon
de7c9d965e 💡 PHPDoc in \DeprecatedCallsLog 2023-01-17 15:37:23 +01:00
Eric Espie
6549c95d4f N°4756 - Ease extensibility for CRUD operations : XML format migration 2023-01-17 10:17:11 +01:00
Molkobain
da07fadfb3 N°5302 - PHP 8.1: Migrate some strlen() usages to internal method 2023-01-16 16:47:26 +01:00
Molkobain
b2c256e51e Merge remote-tracking branch 'origin/support/3.0' into develop 2023-01-16 16:37:22 +01:00
Pierre Goiffon
7305a30b50 N°3200 Remove "Filter list" icon
The link is still here but on objects total (see c693d03a)
2023-01-16 15:29:18 +01:00
Molkobain
4c127b6f61 Revert "N°4517 - PHP 8.1: Fix return type hint for iterable classes"
This reverts commit 61be903eb2.
2023-01-16 14:38:20 +01:00
Molkobain
61be903eb2 N°4517 - PHP 8.1: Fix return type hint for iterable classes 2023-01-16 14:21:00 +01:00
Pierre Goiffon
59792b2a3d N°4660 Remove useless chmod 2023-01-16 11:55:18 +01:00
Pierre Goiffon
19dda61d4f Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	tests/php-unit-tests/unitary-tests/webservices/RestTest.php
2023-01-16 11:54:24 +01:00
Pierre Goiffon
a50ed02057 N°4660 Fix OQLTest 2023-01-16 11:39:38 +01:00
Pierre Goiffon
0a7c8f9fd1 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	tests/php-unit-tests/unitary-tests/core/OQLTest.php
#	tests/php-unit-tests/unitary-tests/core/iTopConfigParserTest.php
#	tests/php-unit-tests/unitary-tests/webservices/RestTest.php
2023-01-16 11:36:02 +01:00
Pierre Goiffon
f65e14397c N°4660 Fix permissions changes in tests 2023-01-16 11:22:23 +01:00
Eric Espie
06a5d645da N°4756 - Ease extensibility for CRUD operations : Add unit tests 2023-01-12 17:40:17 +01:00
Pierre Goiffon
5d1852fe45 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-01-12 16:43:41 +01:00
Pierre Goiffon
d7b94fb123 N°3769 Add data-input-type HTML attribute to fields in a transition form
Was only present in object edit mode :(
2023-01-12 16:40:31 +01:00
Eric Espie
ced4f82585 N°5412 - Upgrade to PHPUnit 9 to fix PHPUnit 8.5 error with PHP 8.1 - replaced removed function 2023-01-12 16:34:14 +01:00
Pierre Goiffon
de0110abc6 RestTest : test json_decode return value 2023-01-12 15:50:57 +01:00
Molkobain
a53bea5eb9 Add @jf-cbd to the sample data, welcome! 👋 2023-01-12 14:41:41 +01:00
Pierre Goiffon
47435869b3 Merge remote-tracking branch 'origin/support/3.0' into develop 2023-01-12 10:43:31 +01:00
Pierre Goiffon
80a9ded404 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2023-01-12 10:43:09 +01:00
Pierre Goiffon
c696a81c3a N°5821 JenkinsFile : introduce buildDiscarder 2023-01-12 10:42:06 +01:00
Molkobain
e04ea2d178 N°5608 - Fix status unit tests for PHPUNit 9 2023-01-11 18:22:48 +01:00
Molkobain
42ce397e13 N°5608 - Fix event service unit tests suite 2023-01-11 18:22:48 +01:00
Pierre Goiffon
22162aa55f Merge remote-tracking branch 'origin/support/3.0' into develop 2023-01-11 18:09:49 +01:00
Pierre Goiffon
c693d03a77 N°3200 Add "Filter list" link on datatable count 2023-01-11 17:19:49 +01:00
Pierre Goiffon
b9ed00d53f N°4660 Fix iTopConfigParserTest setting permissions of iTop config file
Alternative method to restore config file
chmod cannot be used with +w
In \Config::WriteToFile we are using fopen with mode=w, so using the same
In consequence we are not modifying anymore the iTop config file permissions \o/
2023-01-11 16:04:21 +01:00
Molkobain
29e0df9bbc Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	test/sources/application/Helper/WebResourcesHelperTest.php
#	tests/php-unit-tests/ItopTestCase.php
#	tests/php-unit-tests/composer.lock
#	tests/php-unit-tests/unitary-tests/.make/release/DatamodelsXmlFilesTest.php
#	tests/php-unit-tests/unitary-tests/application/UI/Base/Layout/NavigationMenuTest.php
#	tests/php-unit-tests/unitary-tests/application/query/QueryTest.php
#	tests/php-unit-tests/unitary-tests/core/DBSearchTest.php
#	tests/php-unit-tests/unitary-tests/datamodels/2.x/itop-config/BulkChangeExtKeyTest.inc.php
#	tests/php-unit-tests/unitary-tests/datamodels/2.x/itop-config/CRUD/DBObjectTest.php
#	tests/php-unit-tests/unitary-tests/service/EventTest.php
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/3.0_to_3.1.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/3.0_to_3.1.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/3.1_to_3.0.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/3.1_to_3.0.input.xml
#	tests/php-unit-tests/unitary-tests/sources/Application/Helper/WebResourcesHelperTest.php
#	tests/php-unit-tests/unitary-tests/sources/Router/RouterTest.php
#	tests/php-unit-tests/unitary-tests/sources/application/Helper/WebResourcesHelperTest.php
#	tests/php-unit-tests/unitary-tests/webservices/ImportTest.inc.php
#	tests/php-unit-tests/unitary-tests/webservices/RestTest.php
2023-01-11 15:55:08 +01:00
Molkobain
c4508ea80c N°4660 - Fix data synchro unit test failure due to another test not restoring correct user permissions on conf file 2023-01-11 14:26:23 +01:00
Molkobain
16390c9b00 N°5857 - PHPUnit: Replace usage of deprecated assetContains with assertStringContainsString 2023-01-11 13:26:54 +01:00
Molkobain
1271a895d1 N°5857 - PHPUnit: Replace usage of deprecated assetContains with assertStringContainsString 2023-01-11 11:59:01 +01:00
Eric Espie
030f1e2463 Fix Status test 2023-01-11 10:28:32 +01:00
Molkobain
ec90c0b6cd N°5872 - Navigation menu: Wrap menu group label instead of ellipsis in drawer 2023-01-11 10:21:46 +01:00
Molkobain
7b79da3f32 N°5871 - Navigation menu: Show ellipsis on long menu group labels 2023-01-11 10:18:15 +01:00
Pierre Goiffon
5729d6a9cd 🎨 StatusIncTest : fix phpdoc, replace @expectedException 2023-01-11 10:02:59 +01:00
acognet
4d7bac89f3 N°3805 - Collectors not working on itop 3.0 2023-01-11 09:47:53 +01:00
Molkobain
a5efef900c N°5608 - Harmonize namespaces and merge duplicated test files 2023-01-10 23:02:54 +01:00
Molkobain
c851a10982 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2023-01-10 22:49:13 +01:00
Molkobain
845adf43c6 N°5608 - Harmonize namespaces and merge duplicated test files 2023-01-10 22:36:35 +01:00
Molkobain
5916e4ea39 N°5608 - Ensure both old & new tests structure are ran for extensions for backward compatibility 2023-01-10 22:03:40 +01:00
Molkobain
7f37de777e N°5608 - Fix unit tests following restructuring Part III
* Missed a usage of "use_legacy_search" conf param on the last commit
* Fix log tests which didn't moved correctly from Git PoV 😕
2023-01-10 21:11:10 +01:00
Molkobain
bcf880f327 N°5608 - Fix unit tests following restructuring Part II
"use_legacy_search" conf param was removed some time ago
2023-01-10 19:23:54 +01:00
Thomas Casteleyn
b593beb8c7 N°5867 Display binary data size in SynchroReplica details (#286) 2023-01-10 18:53:00 +01:00
Lars Kaltefleiter
57ab3a0336 N°1350 - link audit catecories to domains and evaluate only categories of a given domain via interactive audit 2023-01-10 18:20:15 +01:00
Lars Kaltefleiter
4a54b2f8ff N°1350 - Configurable error tolerance for report color of audit categories 2023-01-10 18:20:15 +01:00
Molkobain
6aa9aa2831 N°5608 - Fix unit tests following restructuring Part I 2023-01-10 18:15:53 +01:00
Eric Espie
9b47ee12e7 N°4307 - Replace SwiftMailer by laminas-mail - Fix connecting to server without password 2023-01-10 17:58:03 +01:00
Molkobain
d177ee4a7f Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	tests/manual-visual-tests/Backoffice/RenderAllUiBlocks.php
#	tests/php-unit-tests/ItopDataTestCase.php
#	tests/php-unit-tests/ItopTestCase.php
#	tests/php-unit-tests/integration-tests/dictionaries-test/fr.dictionary.itop.core.KO.wrong_php
#	tests/php-unit-tests/integration-tests/dictionaries-test/fr.dictionary.itop.core.OK.php
#	tests/php-unit-tests/integration-tests/iTopModulesPhpVersionChecklistTest.php
#	tests/php-unit-tests/integration-tests/iTopXmlVersionChecklistTest.php
#	tests/php-unit-tests/phpunit.xml.dist
#	tests/php-unit-tests/unitary-tests/application/SCSSCompilationTest.php
#	tests/php-unit-tests/unitary-tests/application/Session/SessionTest.php
#	tests/php-unit-tests/unitary-tests/application/ThemeHandlerTest.php
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/DO_NOT_CHANGE.css-variables.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/DO_NOT_CHANGE.light-grey.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/README.md
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/_included_file3.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/cross_reference1.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/cross_reference2.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/feature1/_feature1.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/included_file1.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/included_scss/included_file2.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/included_scss/included_file4.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/multi_imports.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/shortcut.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/shortcut2.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/simple_import.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/simple_import2.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/typography.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/css/ui-lightness/DO_NOT_CHANGE.jqueryui.scss
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/css/ui-lightness/images/ui-bg_diagonals-thick_18_b81900_40x40.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/css/ui-lightness/images/ui-bg_diagonals-thick_20_666666_40x40.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/css/ui-lightness/images/ui-icons_1c94c4_256x240.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/css/ui-lightness/images/ui-icons_222222_256x240.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/css/ui-lightness/images/ui-icons_E87C1E_256x240.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/css/ui-lightness/images/ui-icons_F26522_256x240.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/css/ui-lightness/images/ui-icons_ffd27a_256x240.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/css/ui-lightness/images/ui-icons_ffffff_256x240.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/ac-background.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/actions_right.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/bg.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/breadcrumb-separator.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/calendar.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/delete.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/desc.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/error.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/eye-closed-555.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/eye-closed-fff.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/eye-open-555.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/eye-open-fff.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/full-screen.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/green-header.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/green-square.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/indicator.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/info-mini.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/minus.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/ok.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/orange-header.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/plus.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/red-header.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/truncated.png
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/tv-collapsable-last.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/tv-collapsable.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/tv-expandable-last.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/tv-expandable.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/tv-item-last.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/testimages/images/tv-item.gif
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/themes/basque-red/main.css
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/themes/basque-red/main_imagemodified.css
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/themes/basque-red/main_importmodified.css
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/themes/basque-red/main_stylesheet.css
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/themes/basque-red/main_testcompilethemes.css
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/themes/basque-red/main_varchanged.css
#	tests/php-unit-tests/unitary-tests/application/theme-handler/expected/themes/basque-red/theme-parameters.json
#	tests/php-unit-tests/unitary-tests/application/theme-handler/getimages/expected-getimages.json
#	tests/php-unit-tests/unitary-tests/application/theme-handler/getimages/test-getimages.scss
#	tests/php-unit-tests/unitary-tests/core/ActionEmailTest.php
#	tests/php-unit-tests/unitary-tests/core/AttributeDefTest.inc.php
#	tests/php-unit-tests/unitary-tests/core/AttributeURLDefaultPattern.php
#	tests/php-unit-tests/unitary-tests/core/AttributeURLTest.php
#	tests/php-unit-tests/unitary-tests/core/BulkChangeTest.inc.php
#	tests/php-unit-tests/unitary-tests/core/CSVParserTest.php
#	tests/php-unit-tests/unitary-tests/core/DBObjectTest.php
#	tests/php-unit-tests/unitary-tests/core/DBSearchAddConditionPointingTo.php
#	tests/php-unit-tests/unitary-tests/core/ExpressionEvaluateTest.php
#	tests/php-unit-tests/unitary-tests/core/GetSelectFilterTest.php
#	tests/php-unit-tests/unitary-tests/core/InlineImageTest.php
#	tests/php-unit-tests/unitary-tests/core/Log/ExceptionLogTest.php
#	tests/php-unit-tests/unitary-tests/core/Log/ExceptionLogTest/Exceptions.php
#	tests/php-unit-tests/unitary-tests/core/Log/LogAPITest.php
#	tests/php-unit-tests/unitary-tests/core/Log/LogFileNameBuilderTest.php
#	tests/php-unit-tests/unitary-tests/core/LogAPITest.php
#	tests/php-unit-tests/unitary-tests/core/LogFileNameBuilderTest.php
#	tests/php-unit-tests/unitary-tests/core/MetaModelTest.php
#	tests/php-unit-tests/unitary-tests/core/OQLTest.php
#	tests/php-unit-tests/unitary-tests/core/UniquenessConstraintTest.php
#	tests/php-unit-tests/unitary-tests/core/XMLDataLoaderTest.php
#	tests/php-unit-tests/unitary-tests/core/dictApcuTest.php
#	tests/php-unit-tests/unitary-tests/core/dictTest.php
#	tests/php-unit-tests/unitary-tests/core/ormCaseLogTest.php
#	tests/php-unit-tests/unitary-tests/core/ormPasswordTest.php
#	tests/php-unit-tests/unitary-tests/core/ormStyleTest.php
#	tests/php-unit-tests/unitary-tests/setup/MFCompilerTest.php
#	tests/php-unit-tests/unitary-tests/setup/SubMFCompiler.php
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/1.7_to_1.6.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/1.7_to_1.6.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/1.6_to_1.7_2.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/1.6_to_1.7_2.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/1.7.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/1.7_to_1.6.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/1.7_to_1.6.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/1.7_to_1.6_2.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/1.7_to_1.6_2.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/1.7_to_3.0.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/1.7_to_3.0.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/3.0_to_1.7.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/3.0_to_1.7.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/Bug_4569.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/Convert-samples/Bug_4569.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_deleted_to_deleted.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_deleted_to_deleted.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_deleted_to_in-definition.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_deleted_to_in-definition.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_deleted_to_not-in-definition.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_deleted_to_not-in-definition.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_in-definition_to_deleted.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_in-definition_to_deleted.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_in-definition_to_in-definition.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_in-definition_to_in-definition.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_in-definition_to_not-in-definition.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_in-definition_to_not-in-definition.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_not-in-definition_to_deleted.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_not-in-definition_to_deleted.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_not-in-definition_to_in-definition.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_not-in-definition_to_in-definition.input.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_not-in-definition_to_not-in-definition.expected.xml
#	tests/php-unit-tests/unitary-tests/setup/iTopDesignFormat/MoveNode-samples/from_not-in-definition_to_not-in-definition.input.xml
#	tests/php-unit-tests/unitary-tests/setup/ressources/datamodels/datamodel-branding.xml
#	tests/php-unit-tests/unitary-tests/sources/application/Helper/WebResourcesHelperTest.php
#	tests/php-unit-tests/unitary-tests/sources/application/status/StatusIncTest.php
#	tests/php-unit-tests/unitary-tests/sources/application/status/status.php
#	tests/php-unit-tests/unitary-tests/synchro/DataSynchroTest.php
2023-01-10 15:27:44 +01:00
Lars Kaltefleiter
b354058eb5 N°5622 Fix backup cannot be done if TLS enabled with no CA (#354) 2023-01-10 12:13:33 +01:00
Molkobain
fbc0a898ae N°5608 - Move test files to corresponding directories after branch rebase 2023-01-10 12:11:12 +01:00
Molkobain
36f8e58e25 N°5608 - Use new ItopTestCase::RequireOnceXXX in unit tests 2023-01-10 12:11:12 +01:00
Molkobain
6a7dbb06b0 N°5608 - Add methods to require_once an iTop or a unit test file to avoid crashes when tests dir is moved 2023-01-10 12:11:12 +01:00
Pierre Goiffon
43dd0b7df8 N°2013 Fix regression when installing from scratch
Error was "Call to a member function UpdateFromParams() on null"
Regression introduced by 15d3201a
2023-01-10 10:56:21 +01:00
Pierre Goiffon
43d86ad8e2 N°2013 Setup : fix crash on setting readonly mode if initial DB info were wrong
Same as 15d3201a, but this error happened before compilation, when setting read only mode.
As before this is another fix for #351.

This fix introduces the new method \WizardController::GetParamForConfigArray
I replaced existing duplicate code with a call to this new generic method.
2023-01-10 10:56:21 +01:00
Eric Espie
d3d89b1ee2 N°5857 Fix PHPUnitPrettyPrint with PHPUnit 9 2023-01-10 09:42:13 +01:00
Pierre Goiffon
15d3201a40 N°2013 Setup : fix crash on compilation if initial DB info were wrong
Use case :
- having in the iTop config file wrong DB parameters (unreachable server for example)
- launch the setup in update mode
- fix the DB config in the wizard

The PR #351 solved the errors that were happening in the following steps.
But we still had an error during compilation, caused by the maintenance mode activation.
2023-01-09 16:11:27 +01:00
Eric Espie
cf4616d9a1 N°4756 - Ease extensibility for CRUD operations : Unit tests 2023-01-09 13:59:55 +01:00
Molkobain
5721a324c1 Tests: Always display test status for better feedback 2023-01-06 22:30:09 +01:00
Molkobain
7de6c72154 Tests: Rename provider method name to match convention 2023-01-06 22:30:09 +01:00
Molkobain
c0cee02351 N°5608 - Factorize all core modules tests to a single test suite 2023-01-06 22:30:09 +01:00
Molkobain
bb674fb873 N°5608 - Move/rename "status" unit tests to match their counterpart location/name 2023-01-06 22:30:09 +01:00
Molkobain
6136eadd31 N°5608 - Fix some broken require paths since move/rename 2023-01-06 22:30:08 +01:00
Molkobain
87cb73c038 N°5608 - Rename "test" folder to "tests" to better match conventions 2023-01-06 22:30:08 +01:00
Molkobain
11d8547cef N°5608 - Move/rename unit tests to match their counterpart location/name 2023-01-06 22:30:08 +01:00
Molkobain
0998c73a1a N°5608 - Add README files 2023-01-06 22:30:07 +01:00
Molkobain
471f66649a N°5608 - Rename unitary test folders for better understanding 2023-01-06 22:30:07 +01:00
Molkobain
e8bf9cf688 N°5608 - Move "twig" PHP unit test to new folder
Notice: Test was not working, still not working
2023-01-06 22:30:07 +01:00
Molkobain
4f88a0e7d2 N°5608 - Move legacy PHP unit tests (not run by CI) to a dedicated folder 2023-01-06 22:30:07 +01:00
Molkobain
c6b0e273e6 N°5608 - Rename "VisualTests" folder to match new convention 2023-01-06 22:30:07 +01:00
Molkobain
d9539f9d01 N°5608 - Add comments to main autoloader 2023-01-06 22:30:06 +01:00
Molkobain
a3e309acb5 N°5608 - Revert "authent-local" test suite to its original rank as it is crashing the CI 🤔 2023-01-06 22:30:06 +01:00
Molkobain
c06cbfd4a9 N°5608 - Rename "coreExtensions" test suite to correct datamodel module (authent-local) 2023-01-06 22:30:06 +01:00
Molkobain
1d7e4e1a42 N°5608 - Move unit tests to a dedicated folder and start reorganizing to match iTop folder structure 2023-01-06 22:30:06 +01:00
Molkobain
083d19c688 📝 PHPDoc 2023-01-05 21:19:56 +01:00
Eric Espie
4e9a34d8d8 Merge branch 'support/3.0' into develop 2023-01-05 09:25:11 +01:00
Eric Espie
524e65a29b 📝 fix PHPDoc 2023-01-05 09:23:48 +01:00
Pierre Goiffon
25048ba0cc N°3200 🎨 Replace !empty() by \utils::IsNotNullOrEmptyString
Thanks Molkobain !
2023-01-05 09:07:13 +01:00
Pierre Goiffon
4f7a1ea9da N°3200 Datatable "filter list" icon : specific query for 1,n and n,n objects relations
This specific query passes attcodes list to display to UI.php, but this endpoint doesn't handle it yet. Adding this enhancements would require too much time for now (datatables legacy code), hopefully a refactoring work will be done soon and we'll get back to it !

Note that dedicated ContextTag is renamed from Search to ObjectSearch
2023-01-04 16:23:52 +01:00
Pierre Goiffon
a62a373f64 N°3200 ♻️ Refactor relations attcode list generation
The existing code was added in N°2334
Its generic part is now callable in the MetaModel::GetAttributeLinkedSetIndirectDatatableAttCodesToDisplay method
2023-01-04 16:23:52 +01:00
Pierre Goiffon
6b23171d65 N°3200 New "Filter list" icon in datatables
Every datatables will open its query in a new UI.php?operation=search page
2023-01-04 16:23:52 +01:00
Pierre Goiffon
09b69728a0 📝 Version history : highlight for major versions 2023-01-04 14:24:27 +01:00
Pierre Goiffon
bc0dbc7860 📝 Version history : add link to versions details on the wiki 2023-01-04 14:20:34 +01:00
Eric Espie
a693c343e8 N°4756 - Ease extensibility for CRUD operations : Reduce events after review 2023-01-04 14:18:01 +01:00
Eric Espie
cd17eb484a N°4756 - Ease extensibility for CRUD operations : Reduce events after review 2023-01-04 12:23:23 +01:00
Vincent Dumas
259eb60f97 N°5841 - Non-admin managing User can't see Administrator by default (#383) 2023-01-03 14:08:28 +01:00
Eric Espie
1afa3e2003 Merge branch 'support/3.0' into develop 2023-01-03 08:52:10 +01:00
Eric Espie
df7d7c877d N°5490 - PHP 8.0: Fix crash of bulk modify 2023-01-03 08:50:18 +01:00
Eric Espie
4c4d7c12e8 N°4756 - Ease extensibility for CRUD operations : Coherency in method parameters 2023-01-02 14:23:36 +01:00
Eric Espie
97c3cacfaa N°4756 - Ease extensibility for CRUD operations : Pass DeletionPlan to EVENT_DB_CHECK_TO_DELETE 2023-01-02 14:20:17 +01:00
Eric Espie
98ec568788 N°4756 - Ease extensibility for CRUD operations : Events not sent in overridable methods 2023-01-02 14:06:02 +01:00
Eric Espie
626ba7ee66 📝 PHPDoc reworked packages 2022-12-30 14:17:57 +01:00
Eric Espie
3920f84f45 📝 PHPDoc reworked for auto-doc 2022-12-30 10:11:11 +01:00
Eric Espie
30d2557342 Merge branch 'support/3.0' into develop 2022-12-29 16:00:23 +01:00
Eric Espie
4bcad431aa 📝 Change packages for auto-documentation 2022-12-29 15:59:59 +01:00
Eric Espie
f3cea730af Merge branch 'support/3.0' into develop
# Conflicts:
#	application/applicationextension.inc.php
2022-12-29 14:40:26 +01:00
Eric Espie
5fe32aac15 Merge branch 'support/2.7' into support/3.0
# Conflicts:
#	application/applicationextension.inc.php
2022-12-29 12:40:37 +01:00
Eric Espie
88d9a29599 📝 Change packages for auto-documentation 2022-12-29 12:38:31 +01:00
Eric Espie
92a36dcfdd 📝 Change packages for auto-documentation 2022-12-29 12:24:56 +01:00
Eric Espie
23b4d4cb6b Merge branch 'support/2.7' into support/3.0 2022-12-28 09:52:52 +01:00
Eric Espie
b37e74b407 📝 Change packages for auto-documentation 2022-12-28 09:51:46 +01:00
Eric Espie
0fad249124 N°5564 - ⬆️ twig bump 2022-12-26 09:42:56 +01:00
Pierre Goiffon
94d7d94bff 💡 Fix PHPDoc in \ApplicationMenu::GetSubMenuNodes 2022-12-23 16:14:38 +01:00
Vincent Dumas
48645dd519 N°4852 - Navigation menu: Display "+" dict entries as a tooltip on sub-nodes (#380) 2022-12-23 15:48:52 +01:00
Stephen Abello
9df9077595 N°4737 - Adjust progress bar position in iTop hub connector 2022-12-23 15:45:58 +01:00
Stephen Abello
756241918e N°4737 - Adjust button position in iTop hub connector 2022-12-23 15:44:22 +01:00
Stephen Abello
f819fdae98 N°5507 - Fix impact analysis page title when displaying "Depends on" graph 2022-12-23 15:09:13 +01:00
Stephen Abello
7127b192a2 N°5822 - Do not display the tab separator in scroll mode when there is only one tab 2022-12-23 14:28:22 +01:00
Eric Espie
1cac189077 N°4756 - Ease extensibility for CRUD operations : Fix CRUD after review 2022-12-23 10:37:08 +01:00
Eric Espie
0383fb124b N°4756 - Ease extensibility for CRUD operations : Events renamed 2022-12-22 15:28:31 +01:00
Eric Espie
f378fd3d72 N°4756 - Ease extensibility for CRUD operations : Events renamed 2022-12-22 15:22:06 +01:00
Eric Espie
44fac686f9 N°4756 - Ease extensibility for CRUD operations : Events renamed 2022-12-22 15:16:52 +01:00
Molkobain
eff2afbc69 N°4756 - Improve PHPDoc and type hints 2022-12-22 10:25:24 +01:00
Molkobain
86b3129c08 N°4756 - Fix event listeners for modules
Counter part is that we can no longer fire events before MetaModel::Startup
2022-12-22 10:21:39 +01:00
Eric Espie
bdd5741290 N°4756 - Ease extensibility for CRUD operations : Protect against update loops 2022-12-22 08:56:40 +01:00
Eric Espie
53091fc5df N°4756 - Ease extensibility for CRUD operations : 🌐 dictionaries 2022-12-21 09:03:16 +01:00
Eric Espie
06db3561dc N°4756 - Ease extensibility for CRUD operations : Protect against update loops 2022-12-20 14:26:44 +01:00
Molkobain
5cb2f19ea0 N°4756 - Improve PHPDoc and type hints 2022-12-20 11:11:14 +01:00
Eric Espie
a668b92051 N°4307 - Add option verify_peer => not novalidatecert in SMTP 2022-12-20 10:27:41 +01:00
bdalsass
eda11e97e3 N°5074 - Linkset datatable actions row improvements
Linkset updates, feedbacks 09/12:

- Distinguish action label and tool tip message
- Change default action button label Ok => Confirm
- Use action label in place of default confirm button label
- Attach do not show again preference key to table instance
- Obsolescence flag for link selection (select all)  issue correction
2022-12-20 10:10:25 +01:00
Molkobain
64146b6e1b N°5655 - Add dedicated dict entries for bulk modify/delete actions on linksets 2022-12-20 09:43:25 +01:00
Eric Espie
7b85cb92b0 💡 phpdoc 2022-12-19 09:27:46 +01:00
Eric Espie
a28fcb7c8c N°4756 - Ease extensibility for CRUD operations : Event Service - 💄 better model view display 2022-12-16 11:47:26 +01:00
Eric Espie
f8ec180a0f N°4756 - Ease extensibility for CRUD operations : Event Service - 💚 Fix CI 2022-12-16 11:42:40 +01:00
Eric Espie
0810a113c1 N°4756 - Ease extensibility for CRUD operations : Event Service - Moved Events source code under sources/application/events 2022-12-16 11:30:00 +01:00
Eric Espie
1b4a21fafa N°4756 - Ease extensibility for CRUD operations : Event Service - Moved Events source code under sources/application/events 2022-12-16 11:28:52 +01:00
Eric Espie
fae857175b N°4756 - Ease extensibility for CRUD operations : Event Service - Changed CheckToWrite and CheckToDelete events and add two new events to set attributes flags 2022-12-16 11:07:41 +01:00
Eric Espie
9c21ca2ee6 💡 phpdoc @package ventilation and @api on methods 2022-12-16 11:03:15 +01:00
Pierre Goiffon
ccdb5ec79f Merge remote-tracking branch 'origin/support/3.0' into develop 2022-12-15 15:37:09 +01:00
Pierre Goiffon
cb6232cc05 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2022-12-15 15:36:43 +01:00
Pierre Goiffon
0d49c605e2 💡 Fix \DBSearch::FromOQL phpdoc + modifiers order 2022-12-15 15:36:14 +01:00
Eric Espie
207d312b12 N°4756 - Ease extensibility for CRUD operations : Event Service - Moved ApplicationEvents 2022-12-15 14:03:23 +01:00
Eric Espie
08d83478da N°4756 - Ease extensibility for CRUD operations : Event Service - Revert default value for utils::GetClassesForInterface() 2022-12-15 13:54:51 +01:00
Eric Espie
8665f4ff06 N°4756 - Ease extensibility for CRUD operations : Event Service - PHP Doc 2022-12-15 13:46:06 +01:00
Pierre Goiffon
6a5beb89cc 📝 Version history : 2.7.0-1 was a major version
2.7.0 community was never released
2022-12-15 11:55:51 +01:00
Molkobain
3d09e3b57b Merge remote-tracking branch 'origin/support/3.0' into develop 2022-12-14 20:35:47 +01:00
Molkobain
6d47b0f4f8 N°4517 - PHP 8.0: Fix undefined array key due to type cast being done before coalesce 2022-12-14 20:34:40 +01:00
Molkobain
27cf8159d0 N°5388 - PHP 8.2: Fix dynamic properties 2022-12-14 19:55:08 +01:00
Eric Espie
314dd7d7ad Merge remote-tracking branch 'origin/develop' into develop 2022-12-14 15:50:17 +01:00
Eric Espie
6412f1ab23 Merge branch 'support/3.0' into develop
# Conflicts:
#	sources/Core/Email/EmailSwiftMailer.php
2022-12-14 15:48:52 +01:00
jbostoen
32ee1a8226 N°5793 - HTML Sanitizer: Allow 'start' attribute in 'ol' tag (#368)
* * Extended allowed attributes on ol, li (based on W3Schools)

* Change unit test case label

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2022-12-14 15:46:59 +01:00
Eric Espie
e1c28a5c22 Merge branch 'support/2.7' into support/3.0 2022-12-14 15:45:27 +01:00
Eric Espie
296ee019a0 Merge branch 'support/2.7' into support/3.0 - nothing to do 2022-12-14 15:44:05 +01:00
Thomas Casteleyn
fe997d1254 N°2013 Fix setup when doing update to new DB (#351)
During the setup there are some queries done to the DB.
Only the config file parameters were used, meaning changing those parameters in the setup form wasn't effective :(
This is a regression made in 2.5.0 with N°1260 (MySQL TLS)
2022-12-14 10:29:58 +01:00
Eric Espie
e38951ebae N°4756 - Ease extensibility for CRUD operations : Event Service - Changed some tags 2022-12-14 09:43:41 +01:00
Molkobain
7c2f8f4d93 N°5765 - Setup: Never cache folder permissions test response (#374) 2022-12-14 09:33:54 +01:00
Pierre Goiffon
1f76ff940d N°5797 Replace wrong config load (#338) 2022-12-13 18:23:09 +01:00
Pierre Goiffon
fde6cac7a2 📝 SECURITY: Add disclosure policy (#372)
Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2022-12-13 18:15:25 +01:00
jbostoen
93209265f2 N°5792 - Update dutch translations thanks to @jbostoen 2022-12-13 17:49:32 +01:00
Eric Espie
b50675fc29 N°4756 - Ease extensibility for CRUD operations : Event Service - Fix CI 2022-12-13 13:44:20 +01:00
Eric Espie
deb6d1fd9a N°4756 - Ease extensibility for CRUD operations : Event Service - move event description to an object 2022-12-13 11:55:05 +01:00
Eric Espie
432579657c N°4756 - Ease extensibility for CRUD operations : Event Service - cleanup 2022-12-13 11:52:21 +01:00
Molkobain
f09bd5fdff N°5655 - Add icon to linkset bulk actions in case they are set as shortcut actions 2022-12-13 11:47:32 +01:00
Molkobain
4f37a9e447 N°5655 - Router: Add method to dump available routes 2022-12-13 11:47:32 +01:00
Molkobain
32297d93dd N°5655 - Add utils::ToSnakeCase() method 2022-12-13 11:47:32 +01:00
Pierre Goiffon
7083e1263d 📝 Version history : add 2.7.8 2022-12-13 10:53:59 +01:00
Eric Espie
329d1a7c41 N°4756 - Ease extensibility for CRUD operations : Event Service - documentation 2022-12-13 10:43:05 +01:00
Eric Espie
22749caeb4 N°4756 - Ease extensibility for CRUD operations : Event Service - renamed service setup interface 2022-12-13 10:19:25 +01:00
Eric Espie
baaa4474f9 N°5102 - Allow to send emails using GSuite SMTP and OAuth - cleanup unnecessary include 2022-12-13 10:01:57 +01:00
Molkobain
af804a9dc1 N°5655 - Enable bulk modify/delete on linksets 2022-12-12 23:44:31 +01:00
Molkobain
899f4fdc0a N°5655 - Fix regression from e5d67d22
Can't use "let" as this snippet seems to be evaluated several with the same variables 😭
2022-12-12 23:38:55 +01:00
Molkobain
8cced3a79e N°5655 - Refactor of menu actions generation to reduce duplicated code 2022-12-12 17:25:48 +01:00
Eric Espie
bb26e48d38 Update version to next release 2.7.9 2022-12-12 16:19:42 +01:00
Pierre Goiffon
4eb45f1b34 N°5779 iTopDesignFormatTest : test file conversion from version N to N
For example for a 3.1 version content will try to convert the file from 3.0 to 3.1
2022-12-12 10:48:59 +01:00
Pierre Goiffon
c2f503e2ac N°5779 update-xml : update code using iterators 2022-12-12 09:28:42 +01:00
Pierre Goiffon
e4e654100e N°5779 update-xml : check we are indeed targeting all of the design files 2022-12-09 18:19:15 +01:00
Pierre Goiffon
3270c3f775 🔨 N°5779 update-xml : if XML files already at current version, tries to convert from previous one 2022-12-08 17:08:00 +01:00
Eric Espie
7f88a6aa1a Merge branch 'support/3.0' into develop
# Conflicts:
#	datamodels/2.x/itop-portal-base/portal/src/Twig/AppExtension.php
2022-12-08 08:39:55 +01:00
Eric Espie
26042b990f Merge branch 'support/2.7' into support/3.0
# Conflicts:
#	datamodels/2.x/itop-portal-base/portal/src/Twig/AppExtension.php
2022-12-08 08:34:16 +01:00
Eric Espie
cf433f2f80 N°5725 - Twig update 'filter', 'map' and 'reduce' filters 2022-12-08 08:25:11 +01:00
Eric Espie
c02f84969a N°4756 - Ease extensibility for CRUD operations : Event Service 2022-12-08 08:21:13 +01:00
Eric Espie
bdebea62b6 N°5394 - use session for the FSM (use Session object) 2022-12-08 08:21:13 +01:00
Pierre Goiffon
4a22361f39 🔨 N°5633 update-xml.php : add new XML dir (/application and /core) 2022-12-07 17:40:48 +01:00
Pierre Goiffon
025f8b9dc3 🔨 N°5633 update-xml.php : if no version passed, assuming current version 2022-12-07 17:40:48 +01:00
Benjamin Dalsass
9defedb862 N°5073 - Issue, row actions listeners lost on refresh 2022-12-07 15:31:19 +01:00
Eric Espie
ae94e58a43 N°5725 - Twig update 'filter', 'map' and 'reduce' filters 2022-12-07 13:53:15 +01:00
Eric Espie
e4d8489292 Merge branch 'support/3.0' into develop
# Conflicts:
#	datamodels/2.x/itop-portal-base/portal/src/Twig/AppExtension.php
2022-12-07 13:52:42 +01:00
Eric Espie
f66692d5cf Merge branch 'support/2.7' into support/3.0
# Conflicts:
#	datamodels/2.x/itop-portal-base/portal/src/Twig/AppExtension.php
2022-12-07 13:44:54 +01:00
Eric Espie
2b917f6647 Merge branch 'support/2.7' into support/3.0
# Conflicts:
#	datamodels/2.x/itop-oauth-client/src/Service/PopupMenuExtension.php
2022-12-07 13:42:36 +01:00
Eric Espie
cda017fa4f N°5725 - Twig update 'filter', 'map' and 'reduce' filters 2022-12-07 13:37:52 +01:00
Pierre Goiffon
dad22f6f83 📄 Update Licenses 2022-12-07 11:04:33 +01:00
Eduardo Mozart de Oliveira
0579f1b1dc Add Windows / macOS auto-generated files to .gitignore (#367)
Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2022-12-06 18:08:51 +01:00
Pierre Goiffon
a551bf0499 📝 CONTRIBUTING: Improvements (#371) 2022-12-06 17:19:44 +01:00
vdumas
4f36819ab2 Fix @param & @return comments for GetTagFromLabel 2022-12-06 16:43:55 +01:00
Stephen Abello
26359cf1ee Move datatable SCSS files under the same directory 2022-12-06 16:14:42 +01:00
Stephen Abello
00a25f3e8b Move datatable SCSS files under the same directory 2022-12-06 16:10:58 +01:00
Molkobain
2d122448c8 N°5655 - Fix is_callable() call for PHP 8.0+ 2022-12-06 16:04:26 +01:00
Molkobain
e5d67d2219 N°5655 - Small refactor for better reading 2022-12-06 14:07:15 +01:00
Molkobain
4ac0de5fff N°5655 - Code format 2022-12-06 14:07:15 +01:00
bdalsass
dbe7fae82e Feature/modals - generic modal API (#373)
Default modal JS Implementation:

Add title option
Add buttons option
Change template cloning
Confirmation Modal:

Add implementation
Do not show again functionality
Web Page:

Add blocks array with twig loop insertion
2022-12-06 10:18:59 +01:00
Stephen Abello
98a53a46f0 Fix "Configure this list" modal content display 2022-12-02 15:33:35 +01:00
Eric Espie
e6946d33e6 Merge branch 'support/3.0' into develop 2022-12-02 11:21:04 +01:00
Eric Espie
9474f43d61 Merge branch 'support/2.7' into support/3.0
# Conflicts:
#	datamodels/2.x/itop-oauth-client/src/Service/PopupMenuExtension.php
2022-12-02 11:20:31 +01:00
Eric Espie
9077f7ba37 N°5430 - OAuth authentication : customize redirect landing URL - remove unnecessary parameter to JS function OAuthConnect 2022-12-02 11:17:01 +01:00
Eric Espie
3548251997 Merge branch 'support/3.0' into develop 2022-12-02 09:27:40 +01:00
Eric Espie
4d365c8a44 Merge branch 'support/2.7' into support/3.0 2022-12-02 09:26:40 +01:00
Eric Espie
957ff40f30 N°5155 - Email by SMTP with self-signed certificate (changed default values to the previous behaviour) 2022-12-02 09:25:53 +01:00
Eric Espie
93e0dde1a1 Merge branch 'support/3.0' into develop
# Conflicts:
#	sources/Core/Email/EmailSwiftMailer.php

Email by SMTP with self-signed certificate ported from EmailSwiftMailer to EmailLaminas
2022-11-30 14:35:13 +01:00
Eric Espie
7bb12c35ea Merge branch 'support/2.7' into support/3.0
# Conflicts:
#	core/config.class.inc.php
2022-11-30 14:27:32 +01:00
Eric Espie
aff9c7748b N°5155 - Email by SMTP with self-signed certificate 2022-11-30 14:18:11 +01:00
Eric Espie
e518d34bc9 N°5553 - OAuth 2 : Hide Client Secret
* client_id is now 255 chars (AttributeString)
 * client_secret is now 64 chars (AttributePassword) and cannot be anymore in the uniqueness rules
 * The modification of redirect_url, client_id or client_secret change the status to inactive and generate a session message to ask for token regeneration
2022-11-30 14:15:37 +01:00
Eric Espie
f02e95e8bf Merge branch 'support/3.0' into develop
# Conflicts:
#	datamodels/2.x/itop-portal-base/portal/src/Twig/AppExtension.php
#	test/twig/test.html
#	test/twig/test.html.twig
2022-11-30 13:57:28 +01:00
Eric Espie
51a305b445 N°5725 - Twig update 'filter', 'map' and 'reduce' filters (twig functions signature changed) 2022-11-30 13:40:44 +01:00
Eric Espie
5577f4a62e Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2022-11-30 13:36:18 +01:00
Eric Espie
f0141530b9 N°5725 - Twig update 'filter', 'map' and 'reduce' filters (+1 squashed commits)
Squashed commits:

[00148dec5] N°5725 - Twig update 'filter', 'map' and 'reduce' filters
2022-11-30 13:28:33 +01:00
Vladimir Kunin
98bcfeb2ba 🐛 N°5369 - Fix BrowseBrick tree "opening_target" mode for "self" and "new" values (#299)
Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2022-11-30 11:45:06 +01:00
Pierre Goiffon
669c69ff39 Merge remote-tracking branch 'origin/support/3.0' into develop 2022-11-29 19:04:04 +01:00
Pierre Goiffon
92a802947d Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	setup/wizardsteps.class.inc.php
2022-11-29 19:02:51 +01:00
xtophe38
ce5096a896 N°5758 Change setup test for GDPR consent (#336)
We were using SetupUtils::IsProductVersion, but this was blocking for certain packages like TeemIP standalone.
After this change we are now relying on a new method : \SetupUtils::IsConnectableToITopHub. It will check the iTop Hub Connector module presence instead.
2022-11-29 19:00:17 +01:00
Pierre Goiffon
c5e00194b7 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	pages/ajax.render.php
2022-11-29 18:22:35 +01:00
Pierre Goiffon
5efd45eafc Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	pages/ajax.render.php
2022-11-29 18:18:24 +01:00
Pierre Goiffon
23e0ed5e56 N°4449 Test for FPD detection in RuntimeDashboard 2022-11-29 18:10:17 +01:00
Pierre Goiffon
d412a52fcc N°4449 Fix FPD in dashboard export/import 2022-11-29 18:10:17 +01:00
Eric Espie
ded2f8af9a Fix CI 2022-11-29 14:39:16 +01:00
Molkobain
084f3ec52b N°5655 - Continue work on CombodoModal Part 2 2022-11-28 15:57:25 +01:00
Molkobain
bedc8bbf46 Merge remote-tracking branch 'origin/support/3.0' into develop 2022-11-26 00:25:05 +01:00
Molkobain
cf5745b985 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	core/pdfbulkexport.class.inc.php
2022-11-26 00:09:10 +01:00
Molkobain
3e18ad590f Fix image attributes not being visible in PDF exports 2022-11-25 19:30:35 +01:00
Eric Espie
b174aa9aeb Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	datamodels/2.x/itop-oauth-client/vendor/composer/InstalledVersions.php
#	datamodels/2.x/itop-oauth-client/vendor/composer/installed.php
2022-11-25 17:37:01 +01:00
Pierre Goiffon
4ec3f22173 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	core/log.class.inc.php
2022-11-24 17:28:39 +01:00
Pierre Goiffon
34f03715b6 LogChannel : add missing @since 2022-11-24 17:27:30 +01:00
Eric Espie
ebf3f48584 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	datamodels/2.x/itop-oauth-client/vendor/composer/installed.php
2022-11-24 14:37:35 +01:00
Eric Espie
6a0cdb8705 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	datamodels/2.x/itop-oauth-client/vendor/composer/InstalledVersions.php
#	datamodels/2.x/itop-oauth-client/vendor/composer/installed.php
2022-11-24 14:35:51 +01:00
Eric Espie
22111bf667 N°5611 - Fix missing composer files in itop-oauth-client 2022-11-24 14:32:51 +01:00
Eric Espie
6d0c46595d N°5611 - Fix missing composer files in itop-oauth-client 2022-11-24 14:27:42 +01:00
Eric Espie
8db89c3d5f Merge remote-tracking branch 'origin/support/3.0' into develop 2022-11-24 13:58:52 +01:00
Eric Espie
1e2205ecb0 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2022-11-24 13:58:12 +01:00
Eric Espie
d292a6b0c3 N°5333 - OAuth and iTop url change 2022-11-24 13:55:36 +01:00
Eric Espie
74702c8d06 N°5430 - OAuth authentication : customize redirect landing URL 2022-11-24 13:55:36 +01:00
Eric Espie
649674c786 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	application/twigextension.class.inc.php
#	datamodels/2.x/authent-cas/composer.json
#	datamodels/2.x/authent-cas/composer.lock
#	datamodels/2.x/authent-cas/main.php
#	datamodels/2.x/authent-cas/vendor/apereo/phpcas/composer.json
#	datamodels/2.x/authent-cas/vendor/composer/ClassLoader.php
#	datamodels/2.x/authent-cas/vendor/composer/autoload_classmap.php
#	datamodels/2.x/authent-cas/vendor/composer/autoload_psr4.php
#	datamodels/2.x/authent-cas/vendor/composer/autoload_real.php
#	datamodels/2.x/authent-cas/vendor/composer/autoload_static.php
#	datamodels/2.x/authent-cas/vendor/composer/installed.json
#	datamodels/2.x/itop-portal-base/portal/src/Twig/AppExtension.php
#	lib/apereo/phpcas/source/CAS.php
#	lib/apereo/phpcas/source/CAS/Client.php
#	lib/apereo/phpcas/source/CAS/Languages/Galego.php
#	lib/apereo/phpcas/source/CAS/Languages/Portuguese.php
#	lib/symfony/cache-contracts/InstalledVersions.php
#	lib/symfony/cache-contracts/installed.php
#	lib/symfony/cache-contracts/platform_check.php
#	sources/Application/UI/Base/Layout/NavigationMenu/NavigationMenu.php
#	sources/application/TwigBase/Twig/Extension.php
2022-11-24 13:17:09 +01:00
Benjamin Dalsass
038e6d7f3f datatable - row actions - allow returning null 2022-11-24 09:16:02 +01:00
Pierre Goiffon
df4a205ba0 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2022-11-24 09:00:56 +01:00
Pierre Goiffon
e9c91d986d 📝 CONTRIBUTING : fix typo (stash in stead of squash)
Thanks Molkobain ! (https://github.com/Combodo/iTop/pull/371#discussion_r1030759606)
2022-11-24 09:00:32 +01:00
Eric Espie
feafd5e2c9 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
N°5741 - remove use of get_config_parameter and get_module_setting in Twig

# Conflicts:
#	application/twigextension.class.inc.php
#	datamodels/2.x/itop-portal-base/portal/src/Twig/AppExtension.php
#	sources/application/TwigBase/Twig/Extension.php
2022-11-23 17:38:27 +01:00
bdalsass
bdb29fd99a Issue/5074 - Routage, Block UI relations, Links row actions (#369)
* datatable row actions

Below is a sample of extra param to enable feature:

		$aExtraParams['row_actions'] = [
			[
				'tooltip'        => 'remove an element',
				'icon_css_class' => 'fa-minus',
				'js_row_action'   => 'console.log("You clicked the remove button");',
				'confirmation'  => [
					'message'                  => 'UI:ConfirmationMessage',
					'message_row_data'         => "name",
					'remember_choice_pref_key' => 'remove_do_not_show_again',
				],
			],
			[
				'tooltip'        => 'open in new tab',
				'icon_css_class' => 'fa-external-link-square-alt',
				'on_action_js'   => 'window.open("http://localhost/itop-branchs/dev/pages/UI.php?operation=details&class=UserRequest&id=" + aData.id + "&c[menu]=UserRequest%3AOpenRequests");',
			],
			[
				'tooltip'        => 'other actions',
				'icon_css_class' => 'fa-ellipsis-v',
				'on_action_js'   => 'console.log(event);',
			],
		];

* Contrôleur pour la suppression et le détachement de liens
* Block UI pour l'édition des relations
* Block UI pour la visualisation des relations
* Boutons d'actions pour la suppression et le détachement de liens
* Gestion dialogue de confirmation pour les row actions
2022-11-23 16:10:34 +01:00
Molkobain
a0a5037554 Merge remote-tracking branch 'origin/feature/5655-edit-object-in-modal' into develop
# Conflicts:
#	pages/ajax.render.php
2022-11-23 15:59:23 +01:00
Eric Espie
70a6b276ca Merge branch 'issue/5685-UpgradeApereoPHPCas' into support/2.7 2022-11-23 15:58:36 +01:00
Eric Espie
f77361ceb2 N°5685 - Upgrade apereo/phpcas 2022-11-23 15:53:43 +01:00
Eric Espie
75f4751b82 N°5741 - remove use of get_config_parameter in Twig 2022-11-23 15:09:20 +01:00
Eric Espie
6af62c4a50 Merge remote-tracking branch 'origin/support/3.0' into develop 2022-11-23 11:07:09 +01:00
Eric Espie
65b6c0f4ea Fix CI 2022-11-23 11:04:58 +01:00
Eric Espie
c05684945f Fix CI 2022-11-23 10:34:24 +01:00
Eric Espie
6b1c033ec1 Fix CI 2022-11-23 09:54:30 +01:00
Eric Espie
4f14d1fb23 N°4974 - Session rework 2022-11-22 15:38:02 +01:00
odain
0ef5e9d3ff N°5620 - Hide the organization filter with a conf parameter 2022-11-22 13:57:42 +01:00
odain
1c705bdb94 ci: fix ItopDataTestCase CreateUser contactid unset 2022-11-22 13:57:37 +01:00
odain
28a1324d3a ci: adapt impersonate test to any friendlyname output 2022-11-22 13:57:37 +01:00
odain
af51f05c56 ci: add CreateContactlessUser method in test framework 2022-11-22 13:57:37 +01:00
Pierre Goiffon
1a7b3f0631 N°5563 Fix setup crash when notices enabled and invalid edit_mode value 2022-11-22 09:56:31 +01:00
Eric Espie
4ff82f5c12 Fix CI 2022-11-21 09:54:36 +01:00
Eric Espie
e2e08351b0 Fix CI 2022-11-21 09:51:11 +01:00
Pierre Goiffon
d83c45812d N°5405 UpdateXML update tool now do a full file conversion 2022-11-21 09:15:43 +01:00
Pierre Goiffon
6258b97b92 N°5563 Convert datamodels files with new 3.1 conversion methods 2022-11-21 09:15:23 +01:00
Pierre Goiffon
3aab49c372 N°5563 AttributeLinkedSet & LinkedSetIndirect conversions between 3.0 and 3.1 formats 2022-11-21 09:15:17 +01:00
Pierre Goiffon
ecfae75e10 Setup : catch also fatal error during conversion 2022-11-18 20:15:00 +01:00
Pierre Goiffon
f60331e0f9 iTopFormatTest : better info on conversion error 2022-11-18 20:14:59 +01:00
Pierre Goiffon
8f6065d4f4 ♻️ iTopDesignFormatTest : get version directly from expected content 2022-11-18 19:15:56 +01:00
Eric Espie
52c984d5e7 N°4756 - Fix Unit tests 2022-11-18 10:49:59 +01:00
Eric Espie
6585f717c5 N°4756 - Event service initialization 2022-11-16 21:03:01 +01:00
Molkobain
363a1507cf Merge remote-tracking branch 'origin/support/3.0' into develop 2022-11-16 19:06:51 +01:00
Molkobain
8c95bd5a65 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2022-11-16 19:04:21 +01:00
Romain Quetiez
b56f2f56f1 N°5704 - Fix compatibility with PHP <7.3 (HEREDOC syntax) 2022-11-16 17:12:53 +01:00
Eric Espie
0bba9b0fad Merge remote-tracking branch 'origin/support/3.0' into develop 2022-11-16 13:57:07 +01:00
Eric Espie
282d47aed4 N°5727 - REST API/get_related: Seemingly wrong results, when using [impacts, up] with [redundancy: true] 2022-11-16 13:51:38 +01:00
Eric Espie
2f8f0b658c N°5722 - code hardening 2022-11-16 09:40:19 +01:00
Eric Espie
e4884470ad Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2022-11-16 09:38:31 +01:00
Eric Espie
68d44fa981 N°5724 - code hardening 2022-11-16 09:32:47 +01:00
Eric Espie
7e5307bd96 N°4867 - "Twig content not allowed" error 2022-11-16 09:31:42 +01:00
Stephen Abello
75c8738538 Add an event to refresh Datatables 2022-11-15 10:08:29 +01:00
Molkobain
a553616ea2 N°5655 - Introduce auto-routing mechanism for backoffice pages (Part 1) 2022-11-15 08:42:27 +01:00
Molkobain
8c14d36dfe TwigBase: Allow operation param to be in snake case in order to handle/redirect existing operations 2022-11-15 08:42:26 +01:00
Molkobain
4486842169 N°5655 - Align "activity panel" and "preferences" ajax operation code to new convention 2022-11-15 08:42:26 +01:00
Molkobain
f5b216fd9a N°5655 - Refactor object modification logic to a dedicated controller for both page / modal modes 2022-11-15 08:42:26 +01:00
Molkobain
dcdce52608 N°5655 - Add new sanitization filters for routing
* utils::ENUM_SANITIZATION_FILTER_OPERATION filter to enable operation "namespaces" in current operations for better reading
  * utils::ENUM_SANITIZATION_FILTER_ROUTE filter for upcoming auto routing
2022-11-15 08:42:26 +01:00
Molkobain
73139e82cb N°5655 - Switch backoffice controllers' methods to non-static and now extend an abstract controller 2022-11-15 08:42:25 +01:00
Molkobain
36ec455e6d N°5655 - Refactor portal modal dialog helper to global helper for both GUIs 2022-11-15 08:42:25 +01:00
denis.flaven@combodo.com
d3f8e1c472 Revert "N°5619 - Hide newsroom menu when no provider"
This reverts commit 647b669eb9.
2022-11-14 18:28:18 +01:00
denis.flaven@combodo.com
647b669eb9 N°5619 - Hide newsroom menu when no provider 2022-11-14 18:18:10 +01:00
Pierre Goiffon
df3fc8be7f N°5563 XML for new relations UI : constants for AttributeLinkedSet relation_type values 2022-11-14 18:16:24 +01:00
Pierre Goiffon
3191caa700 N°5563 XML for new relations UI : mock methods in AttributeDefinition 2022-11-14 18:10:48 +01:00
Molkobain
9a3324de07 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	setup/modelfactory.class.inc.php
2022-11-08 21:18:11 +01:00
Molkobain
5839d0e8e3 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	test/ItopTestCase.php
2022-11-08 21:14:50 +01:00
DudekArtur
07fc8c1e5b N°5706 - Update polish translations thanks to @DudekArtur ! (#357)
Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2022-11-08 21:06:25 +01:00
Romain Quetiez
cd010afb48 N°5704 - Unit tests on XML assembly (#329)
* Add a complete test suite for XML assembly

* Add a complete test suite for XML assembly

* Dispatched the test of GetDelta into real unit tests

* Add test for GetDelta on a rename operation

* Add comments on a weird case and a case on rename

* Update XML version after rebase from develop to support/2.7

* Fix phpdoc about coverage

* Remove ModelFactory::GetRootDirs and ItopTestCase::RecurseRmDir+CreateTmpDir+RecurseMkDir+RecurseCopy, that were meant to be introduced in iTop 3.0 and have been copied here by mistake, when rebasing the branch from develop to 2.7.0

* Update test/ItopTestCase.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update test/setup/ModelFactoryTest.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update test/ItopTestCase.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

Co-authored-by: Pierre Goiffon <pierre.goiffon@combodo.com>
Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2022-11-08 19:43:07 +01:00
Pierre Goiffon
e14cf23ecb Merge remote-tracking branch 'origin/support/3.0' into develop 2022-11-08 18:14:55 +01:00
Pierre Goiffon
be5a252be7 iTopDesignTestFormat : improve code readability 2022-11-08 18:14:20 +01:00
Pierre Goiffon
974dddbe19 Merge remote-tracking branch 'origin/support/3.0' into develop 2022-11-08 17:29:24 +01:00
Molkobain
5e0698b7f3 Add support for "Ctrl + Enter" and "Meta (Cmd) + Enter" submit on multi-line fields 2022-11-08 17:28:42 +01:00
Pierre Goiffon
073488a7bd Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2022-11-08 17:27:26 +01:00
Lars Kaltefleiter
2dccedf8d7 🐛 navigation menu z-index workaround for safari
Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2022-11-08 17:25:49 +01:00
Pierre Goiffon
0cf8d731bb Rename iTopDesignFormat test class 2022-11-08 15:59:14 +01:00
acognet
3d083fca05 N°5671 - Export data in Excel does not work with XLSX files 2022-11-04 18:11:59 +01:00
Eric Espie
e496513275 cleanup code (php warning) 2022-10-31 15:09:16 +01:00
Eric Espie
e70e9de1c8 N°4756 - restrict readonly mode to events only for CheckToWrite (keep legacy calls unprotected) 2022-10-31 12:15:52 +01:00
Benjamin Dalsass
fcdfd54066 N°4454 - Measuring the use of the queryphrase book 2022-10-25 14:34:42 +02:00
Pierre Goiffon
efdf780c79 Merge remote-tracking branch 'origin/support/3.0' into develop 2022-10-25 11:58:56 +02:00
Pierre Goiffon
4e7df37931 📝 jqueryui.scss : add comment to inform it is deprecated 2022-10-25 11:54:02 +02:00
Benjamin Dalsass
e90335e943 N°4454 - Measuring the use of the queryphrase book 2022-10-25 10:37:43 +02:00
Molkobain
f0bce86e28 N°4765 - Revert unwanted change on ActionEmail::status values tooltip translations 2022-10-24 23:15:41 +02:00
Pierre Goiffon
fac689ecf7 N°5651 Fix JS method GetAbsoluteUrlModulePage() not reporting parameters values
This JS method is legacy and never used with parameters, so we are choosing to fix it only in the develop branch.
2022-10-21 16:19:10 +02:00
Pierre Goiffon
6e8949a880 Merge remote-tracking branch 'origin/support/3.0' into develop 2022-10-20 16:47:38 +02:00
Pierre Goiffon
4b670cfa90 N°5625 Fix crash when opening DocumentFile in ES language
Regression introduced in 3.0.1 with a merge : 67fa156c
The % was removed in 530ec111 but we kept the call to Dict::Format, and the merge restored the % in ES dict

A larger fix will be done later with N°5491
2022-10-20 16:46:37 +02:00
Molkobain
7028b2f76c N°4703 - Fix english translations of "in-person" 2022-10-19 17:24:05 +02:00
Molkobain
a547358be4 N°5270 - Move cURL from optional to mandatory PHP extension as it is required for authent-cas dependency "apereo/phpcas" 2022-10-19 17:22:23 +02:00
Molkobain
ddcff1f8ba Fix typo 2022-10-19 17:06:49 +02:00
Molkobain
1d7c527ea1 Activity panel: Fix compose button opening log picker menu when only 1 log available 2022-10-19 17:06:49 +02:00
Thomas Casteleyn
4baff1b3d1 N°4703 Add Dutch translations to new origins (#352)
* Add Dutch translations

* Update description
2022-10-19 16:51:48 +02:00
Molkobain
9c4f1419b1 N°4703 - Add "chat" / "in person" as possible "origin" value for tickets 2022-10-19 16:51:48 +02:00
Molkobain
848c4ca204 N°4798 - Align attribute "description" type for Service class 2022-10-19 16:31:07 +02:00
Molkobain
e9aa9cc8df N°5550 - Add missing french translation for "Other Transitions" button (#348)
* Fix typo

* N°5550 - Add missing french translation for "Other Transitions" button
2022-10-19 16:29:00 +02:00
acognet
2eadb632df N°5618 - Setup : Compatibility PHP 8.1 2022-10-19 09:21:16 +02:00
acognet
a57056a035 Merge remote-tracking branch 'origin/support/3.0' into develop 2022-10-18 09:18:57 +02:00
acognet
87db88254b N°4517 - PHP 8.1 compatibility - Fix uppercase 2022-10-17 21:34:26 +02:00
acognet
c1dde51404 Merge remote-tracking branch 'origin/support/3.0' into develop 2022-10-17 16:35:19 +02:00
acognet
5ddc006f51 N°4517 - PHP 8.1 compatibility 2022-10-17 16:27:42 +02:00
acognet
1fcb3af4c0 N°5618 - Setup : Compatibility PHP 8.1 2022-10-14 17:09:35 +02:00
acognet
9ccff4f8de Fix comment. filter created only since 3.1. 2022-10-14 09:27:59 +02:00
BenGrenoble
1e0fc4714d Correction of the system tooltip, following discussion with Molkobain 2022-10-13 09:31:09 +02:00
Eric Espie
8fc8342358 Revert default value for AttributeDateTime 2022-10-12 10:28:10 +02:00
Eric Espie
14673ff1f5 Return HTTP 400 when operation is not found (instead of 404 page not found) 2022-10-11 15:24:54 +02:00
Pierre Goiffon
ae95cf37f5 Merge remote-tracking branch 'origin/support/3.0' into develop 2022-10-11 14:29:26 +02:00
Pierre Goiffon
85a72d6a10 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2022-10-11 14:29:07 +02:00
Pierre Goiffon
189ca3c555 🚚 Move visual test file to the dedicated directory 2022-10-11 14:28:44 +02:00
Eric Espie
567f333017 Remove default value for AttributeDateTime 2022-10-10 14:28:55 +02:00
BenGrenoble
acd8944aec Add tooltip on System 2022-10-06 16:01:30 +02:00
Pierre Goiffon
5b1b5b0cc1 Merge remote-tracking branch 'origin/support/3.0' into develop 2022-10-03 15:56:16 +02:00
Pierre Goiffon
c02b36a00c Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2022-10-03 15:56:02 +02:00
Pierre Goiffon
1e1f1f78bf 📝 Backup : more details on check-backup parameters 2022-10-03 14:41:44 +02:00
Pierre Goiffon
1494604740 📝 Backup : move info from wiki to distrib file 2022-10-03 14:35:14 +02:00
Timmy38
30664bc5ec N°4765 fixing a typo 2022-09-30 11:30:42 +02:00
Molkobain
59b20ac1ee Fix typo 2022-09-27 20:14:53 +02:00
Eric Espie
f32f36fc74 N°5551 - System information database size is way off 2022-09-26 11:51:51 +02:00
bdalsass
5157f511fc N°5073 - Implements line actions in a datatable (#337)
* datatable row actions

Below is a sample of extra param to enable feature:

		$aExtraParams['row_actions'] = [
			[
				'tooltip'        => 'add an element',
				'icon_css_class' => 'fa-plus',
				'css_class'      => 'ibo-is-success',
				'level'          => 'secondary',
				'on_action_js'   => 'console.log(aData);',
			],
			[
				'tooltip'        => 'remove an element',
				'icon_css_class' => 'fa-minus',
				'css_class'      => 'ibo-is-danger',
				'level'          => 'secondary',
				'on_action_js'   => 'console.log("You clicked the remove button");',
			],
			[
				'tooltip'        => 'open in new tab',
				'icon_css_class' => 'fa-external-link-square-alt',
				'on_action_js'   => 'window.open("http://localhost/itop-branchs/dev/pages/UI.php?operation=details&class=UserRequest&id=" + aData.id + "&c[menu]=UserRequest%3AOpenRequests");',
			],
			[
				'tooltip'        => 'other actions',
				'icon_css_class' => 'fa-ellipsis-v',
				'on_action_js'   => 'console.log(event);',
			],
		];

* datatable row actions (update)

* datatable row actions (update)

* datatable row actions (add template role)

* datatable row actions (align actions)

* datatable row actions (change template factory make to make standard)

* datatable row actions (use trait to handle row actions)

* datatable row actions (row actions templates)

* datatable row actions (row actions templates)

* datatable row actions (row actions templates)

* datatable row actions (extends to static and form)

* datatable row actions (extends to static and form)

* datatable row actions (code review S)

* datatable row actions (code review S)

* datatable row actions (code review S)

* Update js/dataTables.main.js

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update js/dataTables.main.js

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update sources/Application/UI/Base/Component/DataTable/StaticTable/StaticTable.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update templates/base/components/datatable/row-actions/handler.js.twig

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* datatable row actions (code review M)

* Update js/dataTables.main.js

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update js/dataTables.main.js

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update js/dataTables.main.js

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update sources/Application/UI/Base/Component/DataTable/StaticTable/StaticTable.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update sources/Application/UI/Base/Component/DataTable/StaticTable/StaticTable.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update sources/Application/UI/Base/Component/DataTable/StaticTable/StaticTable.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update js/dataTables.main.js

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update sources/Application/UI/Base/Component/DataTable/DataTableUIBlockFactory.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update sources/Application/UI/Base/Component/DataTable/StaticTable/StaticTable.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update application/utils.inc.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* datatable row actions (code review M2)

* datatable row actions (code review M3)

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2022-09-26 08:20:28 +02:00
Eric Espie
3196e105a1 N°4756 - small adjustments 2022-09-23 15:10:21 +02:00
Eric Espie
b9d865f881 N°4756 - Fix DBInsert/NoReload call order 2022-09-21 18:08:44 +02:00
Molkobain
2e39a650eb Merge remote-tracking branch 'origin/support/3.0' into develop 2022-09-21 17:48:57 +02:00
Molkobain
c753b57265 Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2022-09-21 16:23:42 +02:00
Molkobain
583ab98210 Fix typo 2022-09-21 16:11:24 +02:00
Pierre Goiffon
e4f6a02de6 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	lib/composer/autoload_files.php
#	lib/composer/autoload_real.php
#	lib/composer/autoload_static.php
2022-09-21 14:28:25 +02:00
Pierre Goiffon
a5b5518533 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	core/cmdbsource.class.inc.php
#	test/core/CMDBSource/TransactionsTest.php
2022-09-21 14:21:28 +02:00
Pierre Goiffon
88d743b1cc N°5538 Make PHPUnit test fail if transaction opened but not closed 2022-09-21 14:05:27 +02:00
Pierre Goiffon
7ac4bc95bb ItopDataTestCase : improve log message 2022-09-21 11:51:07 +02:00
Eric Espie
fac455da48 N°4756 - Global event listeners 2022-09-21 10:34:38 +02:00
odain
b01627f39d Merge branch 'saas/3.0' into develop 2022-09-20 16:04:55 +02:00
odain-cbd
766c9f0e7e N°5305 - CSV import ergonomy PR (#332)
Reworked UI feedbacks on following attributes:
- enum
- date
- external key
2022-09-20 16:00:33 +02:00
Eric Espie
d1414a3f34 N°4756 - revert events for datamodel/2.x objects for backward compatibility 2022-09-20 15:35:59 +02:00
Molkobain
6386a302b2 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	composer.json
2022-09-20 13:44:11 +02:00
Molkobain
7071712a0a N°5535 - Fix PHP max version to 8.1 in composer for iTop 3.0.2+ 2022-09-20 13:42:45 +02:00
Molkobain
31454b2946 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	core/config.class.inc.php
#	setup/setuputils.class.inc.php
2022-09-20 13:27:20 +02:00
Molkobain
e55ac6002a Increase ITOP_VERSION to 3.0.3-dev 2022-09-20 13:22:18 +02:00
Molkobain
e9c6549847 N°5535 - Fix PHP not validated version to 8.1 in iTop 3.0.2+ 2022-09-20 13:17:59 +02:00
Eric Espie
4aad555649 N°4756 - Fix unit tests, 2022-09-20 12:18:53 +02:00
Eric Espie
93ee565d29 N°4756 - Fix unit tests 2022-09-19 16:59:51 +02:00
Eric Espie
6c097a128b N°4756 - Fix unit tests 2022-09-19 16:49:40 +02:00
Eric Espie
eea3f78cec N°4756 - Fix unit tests 2022-09-19 16:28:13 +02:00
Eric Espie
6c4caf64c8 N°4756 - Fix unit tests 2022-09-19 16:26:02 +02:00
Eric Espie
88f0013330 N°4756 - Fix unit tests 2022-09-19 16:09:02 +02:00
Eric Espie
aa31da34e5 N°5389 - Email Notification templates with AttributeLinkedSetIndirect failed 2022-09-19 15:30:24 +02:00
Eric Espie
71464f6d0e Merge branch 'develop' into feature/faf_event_service
# Conflicts:
#	core/cmdbobject.class.inc.php
#	core/dbobject.class.php
#	core/designdocument.class.inc.php
#	lib/composer/autoload_files.php
#	lib/composer/autoload_static.php
2022-09-19 09:45:08 +02:00
Eric Espie
2c265aab44 N°4756 - Ease extensibility for CRUD operations
- Change event order in CRUD
 - Add LinkHostObject for link update
 - Add events EVENT_SERVICE_DB_ARCHIVE and  EVENT_SERVICE_DB_UNARCHIVE
2022-07-08 10:19:54 +02:00
Eric Espie
fe28319d22 Merge from Develop 2022-07-06 14:28:55 +02:00
Eric Espie
7f6f5c0c3b Refactor event name 2022-06-30 16:24:13 +02:00
Eric Espie
682ab44dea Merge branch 'develop' into feature/faf_event_service 2022-06-30 14:22:52 +02:00
Eric Espie
6aef59e42d Merge branch 'develop' into feature/faf_event_service
# Conflicts:
#	core/dbobject.class.php
#	datamodels/2.x/itop-config/config.php
#	lib/composer/autoload_classmap.php
#	lib/composer/autoload_static.php
#	lib/composer/installed.php
2022-06-08 16:51:44 +02:00
Eric Espie
86024107af deprecated includes 2022-06-08 15:55:20 +02:00
Eric Espie
754f87fd0c debug log 2022-06-08 15:54:27 +02:00
Eric Espie
972e894bc5 debug log 2022-06-02 17:32:15 +02:00
Eric Espie
86a2db7e7f Remove AFTER_DISPLAY_PAGE Event 2022-06-02 17:23:07 +02:00
Eric Espie
4c31081de2 Remove AFTER_DISPLAY_PAGE Event 2022-06-02 17:19:43 +02:00
Eric Espie
23c95ebbf3 Block if event is not registered 2022-06-02 13:48:59 +02:00
Eric Espie
e77f21a0b5 refactor Event Listeners 2022-06-01 14:29:43 +02:00
Eric Espie
35e1f080b8 Attachments events 2022-06-01 11:46:00 +02:00
Eric Espie
812c1f6bb4 Migrate datamodel 2022-06-01 11:19:46 +02:00
Eric Espie
9adb7f20ce Event "Compute Values" 2022-06-01 09:11:03 +02:00
Eric Espie
c7e54c66c8 Event "Compute Values" 2022-06-01 09:09:16 +02:00
Eric Espie
f6855b0d2b Display events in the datamodel page 2022-06-01 08:44:12 +02:00
Eric Espie
1ceef602f0 Remove debug 2022-05-31 15:44:56 +02:00
Eric Espie
93cc29f4d9 refactor 2022-05-31 15:42:09 +02:00
Eric Espie
c9317542c8 refactor 2022-05-31 15:37:29 +02:00
Eric Espie
aed8337c51 Protection against reentrance for DBUpdate 2022-05-30 17:03:47 +02:00
Eric Espie
af4a5e1b8d New CRUD behaviour (removed Reload in DBInsert and DBUpdate) and protection against reentrance 2022-05-27 17:46:10 +02:00
Eric Espie
e7c09c83f0 internal doc 2022-05-25 10:59:38 +02:00
Eric Espie
56103d1952 Refactor 2022-05-25 10:38:07 +02:00
Eric Espie
301c308fec Refactor 2022-05-25 10:32:41 +02:00
Eric Espie
b827c68187 Merge branch 'develop' into feature/faf_event_service 2022-05-25 10:04:54 +02:00
Eric Espie
8ba28adf68 Refactor 2022-04-08 15:10:58 +02:00
Eric Espie
34a26d33a1 Fix reloads 2022-04-07 18:15:18 +02:00
Eric Espie
b0a55e057b Events to cmdbAbstract 2022-04-07 17:02:19 +02:00
Eric Espie
5ac9b05b2d new CRUD 2022-04-06 23:51:21 +02:00
Eric Espie
63e582a07f Unit tests 2022-04-05 10:30:47 +02:00
Eric Espie
470076daa2 Unit tests 2022-04-05 10:29:52 +02:00
Eric Espie
f6d92a189b CRUD reentrance protection 2022-04-05 10:28:12 +02:00
Eric Espie
c788c93542 Merge branch 'develop' into feature/faf_event_service 2022-03-30 08:22:47 +02:00
Eric Espie
a773f0d8a2 EventService: refactoring 2022-03-15 17:53:38 +01:00
Eric Espie
29c6b73d93 EventService: refactoring 2022-03-15 17:50:13 +01:00
Eric Espie
5b52ca4776 EventService: phpdoc 2022-03-15 15:45:03 +01:00
Eric Espie
8ddaf1b731 EventService: call FireEvent with only one parameter (PSR14) 2022-03-15 15:41:55 +01:00
Eric Espie
964ce44577 EventService: code cleanup 2022-03-15 15:11:57 +01:00
Eric Espie
cea6c557ce Merge branch 'develop' into feature/faf_event_service 2022-03-15 10:52:45 +01:00
Eric Espie
99819527db Changed the <Hooks> grammar (typo) 2022-02-07 16:28:19 +01:00
Eric Espie
965273009c Changed the <Hooks> grammar to allow module extensibility 2022-02-07 16:10:00 +01:00
Eric Espie
7bee616b1b Update application events definition 2022-02-07 15:25:38 +01:00
Eric Espie
f5302133d9 Add application events definition 2022-02-07 15:06:00 +01:00
Eric Espie
bf2aba1b06 Reformat code 2022-02-07 14:11:00 +01:00
Eric Espie
c04beea38c OnInsert and OnUpdate replacement 2021-12-31 17:07:59 +01:00
Eric Espie
93d88cca37 refactor 2021-12-31 15:26:54 +01:00
Eric Espie
0997750816 cleanup 2021-12-31 15:06:27 +01:00
Eric Espie
427c8b0794 * better comparison 2021-12-31 14:33:23 +01:00
Eric Espie
06008ed8eb * Add KPI object loaded counter 2021-12-31 12:12:32 +01:00
Eric Espie
374b71c017 * refactor
* Add event AFTER_DISPLAY_PAGE
2021-12-31 11:06:03 +01:00
Eric Espie
fba78e7d9b Changed event name to DISPLAY_OBJECT_DETAILS 2021-12-31 08:53:36 +01:00
Eric Espie
551abc861e Merge branch 'develop' into feature/faf_event_service
# Conflicts:
#	application/cmdbabstract.class.inc.php
#	application/loginwebpage.class.inc.php
#	core/dbobject.class.php
#	core/log.class.inc.php
#	lib/composer/autoload_classmap.php
#	lib/composer/autoload_static.php
#	setup/compiler.class.inc.php
#	test/phpunit.xml.dist
2021-12-31 08:42:16 +01:00
Eric
78f51d40f6 DBObject GetValues() 2020-07-17 15:41:52 +02:00
Eric
8bfc54e6b4 Event Service 2020-07-15 14:42:33 +02:00
2601 changed files with 92530 additions and 58297 deletions

View File

@@ -3,14 +3,14 @@
```mermaid
%%{init: { 'logLevel': 'debug', 'theme': 'base', 'gitGraph': {'showBranches': true,'mainBranchName': 'develop','rotateCommitLabel': true}} }%%
gitGraph
commit id: "2016-07-06" tag: "2.3.0"
commit id: "2016-07-06" tag: "2.3.0" type: HIGHLIGHT
branch support/2.3 order: 900
commit id: "2016-07-08" tag: "2.3.1"
commit id: "2016-12-22" tag: "2.3.3"
commit id: "2017-04-14" tag: "2.3.4"
checkout develop
commit id: "2017-07-12" tag: "2.4.0-beta" type: REVERSE
commit id: "2017-11-16" tag: "2.4.0"
commit id: "2017-11-16" tag: "2.4.0" type: HIGHLIGHT
branch support/2.4 order: 890
commit id: "2018-02-14" tag: "2.4.1"
checkout develop
@@ -18,10 +18,10 @@ gitGraph
checkout support/2.4
commit id: "2018-06-14" tag: "2.4.2"
checkout develop
commit id: "2018-06-27" tag: "2.5.0"
commit id: "2018-06-27" tag: "2.5.0" type: HIGHLIGHT
branch support/2.5 order: 880
checkout develop
commit id: "2019-01-09" tag: "2.6.0"
commit id: "2019-01-09" tag: "2.6.0" type: HIGHLIGHT
branch support/2.6 order: 870
commit id: "2019-03-28" tag: "2.6.1"
checkout develop
@@ -32,11 +32,11 @@ gitGraph
commit id: "2020-01-23" tag: "2.6.3"
checkout develop
commit id: "2020-01-29" tag: "2.7.0-beta2" type: REVERSE
branch support/2.7 order: 860
commit id: "2020-04-01" tag: "2.7.0-1"
commit id: "2020-04-01" tag: "2.7.0-1" type: HIGHLIGHT
checkout support/2.6
commit id: "2020-04-22" tag: "2.6.4"
checkout support/2.7
checkout develop
branch support/2.7 order: 860
commit id: "2020-06-26" tag: "2.7.1"
checkout support/2.7
commit id: "2020-12-09" tag: "2.7.3"
@@ -50,7 +50,7 @@ gitGraph
checkout support/2.7
commit id: "2021-12-17" tag: "2.7.6"
checkout develop
commit id: "2022-01-04" tag: "3.0.0"
commit id: "2022-01-04" tag: "3.0.0" type: HIGHLIGHT
branch support/3.0 order: 850
commit id: "2022-04-08" tag: "3.0.1"
checkout support/2.7
@@ -58,4 +58,10 @@ gitGraph
checkout support/3.0
commit id: "2022-09-12" tag: "3.0.2-1"
checkout develop
checkout support/2.7
commit id: "2022-12-28" tag: "2.7.8"
checkout support/3.0
commit id: "2023-04-12" tag: "3.0.3"
```
To learn more, check the [iTop community versions history on the official wiki](https://www.itophub.io/wiki/page?id=latest:release:start).

11
.gitignore vendored
View File

@@ -19,7 +19,7 @@
# composer reserver directory, from sources, populate/update using "composer install"
vendor/*
test/vendor/*
tests/*/vendor/*
# all conf but listing prevention
/conf/**
@@ -46,7 +46,7 @@ test/vendor/*
!/log/web.config
# PHPUnit cache file
/test/.phpunit.result.cache
/tests/php-unit-tests/.phpunit.result.cache
# Jetbrains
@@ -146,3 +146,10 @@ local.properties
.cache-main
.scala_dependencies
.worksheet
# Mac
.DS_Store
# Windows
Thumbs.db

View File

@@ -1,7 +1,7 @@
<?php
/**
* Copyright (C) 2010-2021 Combodo SARL
* Copyright (C) 2010-2023 Combodo SARL
*
* This file is part of iTop.
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Copyright (C) 2010-2021 Combodo SARL
* Copyright (C) 2010-2023 Combodo SARL
*
* This file is part of iTop.
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Copyright (C) 2010-2021 Combodo SARL
* Copyright (C) 2010-2023 Combodo SARL
*
* This file is part of iTop.
*

View File

@@ -19,17 +19,24 @@
* The target license file path is in `$xmlFilePath`
*/
$iTopFolder = __DIR__ . "/../../" ;
$xmlFilePath = $iTopFolder . "setup/licenses/community-licenses.xml";
$iTopFolder = __DIR__."/../../";
$xmlFilePath = $iTopFolder."setup/licenses/community-licenses.xml";
function get_scope($product_node)
{
$jqExec = shell_exec("jq -V"); // a param is mandatory otherwise the script will freeze
if ((null === $jqExec) || (false === $jqExec)) {
echo "/!\ JQ is required but cannot be launched :( \n";
echo "Check this script PHPDoc block for instructions\n";
die(-1);
}
function get_scope($product_node) {
$scope = $product_node->getAttribute("scope");
if ($scope === "")
{ //put iTop first
if ($scope === "") { //put iTop first
return "aaaaaaaaa";
}
return $scope;
}

View File

@@ -6,11 +6,19 @@
* Will update version in the following files :
*
* datamodels/2.x/.../datamodel.*.xml
* application/*.xml
* core/*.xml
*
* Usage :
* `php .make\release\update-xml.php "1.7"`
* `php .make\release\update-xml.php`
*
* @since 2.7.0
* If no parameter provided then the current XML version will be used as target version
*
* @since 2.7.0 simple version change using regexp (not doing conversion)
* @since 3.1.0 N°5405 now does a real conversion
* @since 3.1.0 N°5633 allow to use without parameter
* @since 3.1.0 N°5633 add /application and /core XML files
******************************************************************************/
@@ -22,10 +30,12 @@ require_once (__DIR__.DIRECTORY_SEPARATOR.'update.classes.inc.php');
if (count($argv) === 1)
{
echo '/!\ You must pass the new version as parameter';
exit(1);
echo '/!\ No version passed: assuming target XML version is current XML version ('.ITOP_DESIGN_LATEST_VERSION.")\n";
$sVersionLabel = ITOP_DESIGN_LATEST_VERSION;
} else {
$sVersionLabel = $argv[1];
}
$sVersionLabel = $argv[1];
if (empty($sVersionLabel))
{
echo 'Version passed as parameter is empty !';

View File

@@ -125,16 +125,31 @@ class iTopVersionFileUpdater extends AbstractSingleFileVersionUpdater
abstract class AbstractGlobFileVersionUpdater extends FileVersionUpdater
{
protected $sGlobPattern;
/** @var array|string glob patterns to seek for files to modify */
protected $globPattern;
public function __construct($sGlobPattern)
public function __construct($globPattern)
{
$this->sGlobPattern = $sGlobPattern;
$this->globPattern = $globPattern;
}
public function GetFiles()
{
return glob($this->sGlobPattern);
$aGlobPatterns = (is_array($this->globPattern))
? $this->globPattern
: [$this->globPattern];
$aFiles = [];
foreach ($aGlobPatterns as $sGlobPattern) {
$result = glob($sGlobPattern);
if (false === $result) {
continue;
}
/** @noinspection SlowArrayOperationsInLoopInspection */
$aFiles = array_merge($aFiles, $result);
}
return $aFiles;
}
}
@@ -166,7 +181,11 @@ class DatamodelsXmlFiles extends AbstractGlobFileVersionUpdater
{
public function __construct()
{
parent::__construct(APPROOT.'datamodels/2.x/*/datamodel.*.xml');
parent::__construct([
APPROOT.'datamodels/2.x/*/datamodel.*.xml',
APPROOT.'application/*.xml',
APPROOT.'core/*.xml',
]);
}
/**
@@ -174,10 +193,40 @@ class DatamodelsXmlFiles extends AbstractGlobFileVersionUpdater
*/
public function UpdateFileContent($sVersionLabel, $sFileContent, $sFileFullPath)
{
return preg_replace(
'/(<itop_design .* version=")[^"]+(">)/',
'${1}'.$sVersionLabel.'${2}',
$sFileContent
);
require_once APPROOT.'setup/itopdesignformat.class.inc.php';
$oFileXml = new DOMDocument();
/** @noinspection PhpComposerExtensionStubsInspection */
libxml_clear_errors();
$oFileXml->formatOutput = true;
$oFileXml->preserveWhiteSpace = false;
$oFileXml->loadXML($sFileContent);
$oFileItopFormat = new iTopDesignFormat($oFileXml);
$sDesignVersionToSet = static::GetDesignVersionToSet($oFileItopFormat->GetVersion());
if (false === is_null($sDesignVersionToSet)) {
// N°5779 if same as target version, we will try to convert from version below
$oFileItopFormat->GetITopDesignNode()->setAttribute('version', $sDesignVersionToSet);
}
$bConversionResult = $oFileItopFormat->Convert($sVersionLabel);
if (false === $bConversionResult) {
throw new Exception("Error when converting $sFileFullPath");
}
return $oFileItopFormat->GetXmlAsString();
}
/**
* @return ?string version to use : if file version is same as current version then return previous version, else return null
* @since 3.1.0 N°5779
*/
protected static function GetDesignVersionToSet($sFileDesignVersion):?string {
if ($sFileDesignVersion !== ITOP_DESIGN_LATEST_VERSION) {
return null;
}
return iTopDesignFormat::GetPreviousDesignVersion(ITOP_DESIGN_LATEST_VERSION);
}
}

View File

@@ -134,15 +134,16 @@ Our tests are located in the `test/` directory, containing a PHPUnit config file
When your code is working, please:
* stash as much as possible your commits,
* rebase your branch on our repo last commit,
* create a pull request
* mind to check the "[Allow edits from maintainers](https://docs.github.com/en/github-ae@latest/pull-requests/collaborating-with-pull-requests/working-with-forks/allowing-changes-to-a-pull-request-branch-created-from-a-fork)" option !
Detailed procedure to work on fork and create PR is available [in GitHub help pages](https://help.github.com/articles/creating-a-pull-request-from-a-fork/).
* Squash as much as possible your commits,
* Rebase your branch on our repo last commit,
* Create a pull request. _Detailed procedure to work on fork and create PR is available [in GitHub help pages](https://help.github.com/articles/creating-a-pull-request-from-a-fork/)_.
* Pull request description: mind to add all the information useful to understand why you're suggesting this modification and anything necessary to dive into your work. Especially:
- Bugfixes: exact steps to reproduce the bug (given/when/then), description of the bug cause and what solution is implemented
- Enhancements: use cases, implementation details if needed
* Mind to check the "[Allow edits from maintainers](https://docs.github.com/en/github-ae@latest/pull-requests/collaborating-with-pull-requests/working-with-forks/allowing-changes-to-a-pull-request-branch-created-from-a-fork)" option !
### 🙏 We are thankful
## 🙏 We are thankful
We are thankful for all your contributions to the iTop universe! As a thank you gift, we will send stickers to every iTop (& extensions) contributors!

8
Jenkinsfile vendored
View File

@@ -1,6 +1,14 @@
def infra
node(){
properties([
buildDiscarder(
logRotator(
daysToKeepStr: "28",
numToKeepStr: "500")
)
])
checkout scm
infra = load '/var/lib/jenkins/workspace/itop-test-infra_master/src/Infra.groovy'

View File

@@ -3,9 +3,9 @@
</a></p>
iTop stands for IT Operations Portal. It is a complete open source and web based IT service management platform including a fully customizable CMDB, a helpdesk system and a document management tool. It is ITIL compliant and easily customizable and extensible thanks to a high number of adds-on and web services to integrate with your IT.
iTop stands for IT Operations Portal. It is a complete open source and web-based IT service management platform, including a fully customizable CMDB, a helpdesk system, and a document management tool. It is ITIL compliant and easily customizable and extensible thanks to a high number of add-ons and web services to integrate with your IT.
iTop also offers mass import tools to help you being even more efficient.
iTop also offers mass import tools to help you become even more efficient.
## Features
- Fully configurable [Configuration Management (CMDB)][10]
@@ -37,7 +37,7 @@ iTop also offers mass import tools to help you being even more efficient.
- [iTop Forums][1]: community support
- [iTop Tickets][2]: for feature requests and bug reports
- [Releases download][3]
- [Software requirements][4]
- [iTop requirements][4]
- [Documentation][5] covering both iTop and its official extensions
- [iTop Hub][6] : discover and install extensions !
- [iTop versions history][7]
@@ -46,7 +46,7 @@ iTop also offers mass import tools to help you being even more efficient.
[1]: https://sourceforge.net/p/itop/discussion/
[2]: https://sourceforge.net/p/itop/tickets/
[3]: https://sourceforge.net/projects/itop/files/itop/
[4]: https://www.itophub.io/wiki/page?id=latest:install:upgrading_itop
[4]: https://www.itophub.io/wiki/page?id=latest:install:requirements
[5]: https://www.itophub.io/wiki
[6]: https://store.itophub.io/en_US/
[7]: .doc/itop-version-history.md
@@ -65,7 +65,7 @@ iTop also offers mass import tools to help you being even more efficient.
## About Us
iTop development is sponsored, led and supported by [Combodo][0].
iTop development is sponsored, led, and supported by [Combodo][0].
[0]: https://www.combodo.com

View File

@@ -18,8 +18,7 @@ to [itop-security@combodo.com](mailto:itop-security@combodo.com).
## 📆 Disclosure Policy
## 🔍 Combodo acknowledgment and investigation
Report sent to us will be acknowledged within the week.
Then, a Combodo developer will be assigned to the reported issue and will:
@@ -34,3 +33,12 @@ Then, a Combodo developer will be assigned to the reported issue and will:
Security issues always take precedence over bug fixes and feature work.
The assignee will keep you informed of the resolution progress, and may ask you for additional information or guidance.
## 📆 Disclosure Policy
Once the fix is done and acknowledged by every stakeholder, it will be included in the next iTop version.
Mind we have at least 2 active branches (LTS and STS, see [iTop Community Releases [iTop Documentation]](https://www.itophub.io/wiki/page?id=latest:release:start))
The release communications will include the information of the vulnerability fix.
Corresponding GitHub advisories and CVE will be published 3 months after the iTop version release date so that iTop instances can be updated.

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -19,7 +19,7 @@
/**
* UserRightsMatrix (User management Module)
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -20,7 +20,7 @@
* UserRightsNull
* User management Module - say Yeah! to everything
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -34,14 +34,15 @@ class URP_Profiles extends UserRightsBaseClassGUI
{
$aParams = array
(
"category" => "addon/userrights,grant_by_profile,filter",
"key_type" => "autoincrement",
"name_attcode" => "name",
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_profiles",
"db_key_field" => "id",
"db_finalclass_field" => "",
"category" => "addon/userrights,grant_by_profile,filter",
"key_type" => "autoincrement",
"name_attcode" => "name",
"complementary_name_attcode" => array('description'),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_profiles",
"db_key_field" => "id",
"db_finalclass_field" => "",
);
MetaModel::Init_Params($aParams);
//MetaModel::Init_InheritAttributes();
@@ -219,24 +220,36 @@ class URP_UserProfile extends UserRightsBaseClassGUI
{
$aParams = array
(
"category" => "addon/userrights,grant_by_profile,filter",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"category" => "addon/userrights,grant_by_profile,filter",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"db_finalclass_field" => "",
'uniqueness_rules' => array(
'no_duplicate' => array(
'attributes' => array(
0 => 'userid',
1 => 'profileid',
),
'filter' => '',
'disabled' => false,
'is_blocking' => true,
),
),
);
MetaModel::Init_Params($aParams);
//MetaModel::Init_InheritAttributes();
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass"=>"User", "jointype"=> "", "allowed_values"=>null, "sql"=>"userid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values"=>null, "extkey_attcode"=> 'userid', "target_attcode"=>"login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass" => "User", "jointype" => "", "allowed_values" => null, "sql" => "userid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values" => null, "extkey_attcode" => 'userid', "target_attcode" => "login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid", array("targetclass"=>"URP_Profiles", "jointype"=> "", "allowed_values"=>null, "sql"=>"profileid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values"=>null, "extkey_attcode"=> 'profileid', "target_attcode"=>"name")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid",
array("targetclass" => "URP_Profiles", "jointype" => "", "allowed_values" => null, "sql" => "profileid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array(), "allow_target_creation" => false)));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values" => null, "extkey_attcode" => 'profileid', "target_attcode" => "name")));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values"=>null, "sql"=>"description", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values" => null, "sql" => "description", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
// Display lists
MetaModel::Init_SetZListItems('details', array('userid', 'profileid', 'reason')); // Attributes to be displayed for the complete details

View File

@@ -1,6 +1,6 @@
<?php
/**
* Copyright (C) 2013-2021 Combodo SARL
* Copyright (C) 2013-2023 Combodo SARL
*
* This file is part of iTop.
*
@@ -69,14 +69,15 @@ class URP_Profiles extends UserRightsBaseClassGUI
{
$aParams = array
(
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => "name",
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_profiles",
"db_key_field" => "id",
"db_finalclass_field" => "",
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => "name",
"complementary_name_attcode" => array('description'),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_profiles",
"db_key_field" => "id",
"db_finalclass_field" => "",
);
MetaModel::Init_Params($aParams);
//MetaModel::Init_InheritAttributes();
@@ -325,24 +326,25 @@ class URP_UserProfile extends UserRightsBaseClassGUI
{
$aParams = array
(
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"db_finalclass_field" => "",
);
MetaModel::Init_Params($aParams);
//MetaModel::Init_InheritAttributes();
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass"=>"User", "jointype"=> "", "allowed_values"=>null, "sql"=>"userid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values"=>null, "extkey_attcode"=> 'userid', "target_attcode"=>"login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass" => "User", "jointype" => "", "allowed_values" => null, "sql" => "userid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values" => null, "extkey_attcode" => 'userid', "target_attcode" => "login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid", array("targetclass"=>"URP_Profiles", "jointype"=> "", "allowed_values"=>null, "sql"=>"profileid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values"=>null, "extkey_attcode"=> 'profileid', "target_attcode"=>"name")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid",
array("targetclass" => "URP_Profiles", "jointype" => "", "allowed_values" => null, "sql" => "profileid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array(), "allow_target_creation" => false)));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values" => null, "extkey_attcode" => 'profileid', "target_attcode" => "name")));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values"=>null, "sql"=>"description", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values" => null, "sql" => "description", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
// Display lists
MetaModel::Init_SetZListItems('details', array('userid', 'profileid', 'reason')); // Attributes to be displayed for the complete details

View File

@@ -1,6 +1,6 @@
<?php
/**
* Copyright (C) 2013-2021 Combodo SARL
* Copyright (C) 2013-2023 Combodo SARL
*
* This file is part of iTop.
*
@@ -50,14 +50,15 @@ class URP_Profiles extends UserRightsBaseClass
{
$aParams = array
(
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => "name",
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_profiles",
"db_key_field" => "id",
"db_finalclass_field" => "",
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => "name",
"complementary_name_attcode" => array('description'),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_profiles",
"db_key_field" => "id",
"db_finalclass_field" => "",
);
MetaModel::Init_Params($aParams);
//MetaModel::Init_InheritAttributes();
@@ -268,24 +269,25 @@ class URP_UserProfile extends UserRightsBaseClass
{
$aParams = array
(
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"db_finalclass_field" => "",
);
MetaModel::Init_Params($aParams);
//MetaModel::Init_InheritAttributes();
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass"=>"User", "jointype"=> "", "allowed_values"=>null, "sql"=>"userid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values"=>null, "extkey_attcode"=> 'userid', "target_attcode"=>"login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass" => "User", "jointype" => "", "allowed_values" => null, "sql" => "userid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values" => null, "extkey_attcode" => 'userid', "target_attcode" => "login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid", array("targetclass"=>"URP_Profiles", "jointype"=> "", "allowed_values"=>null, "sql"=>"profileid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values"=>null, "extkey_attcode"=> 'profileid', "target_attcode"=>"name")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid",
array("targetclass" => "URP_Profiles", "jointype" => "", "allowed_values" => null, "sql" => "profileid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array(), "allow_target_creation" => false)));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values" => null, "extkey_attcode" => 'profileid', "target_attcode" => "name")));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values"=>null, "sql"=>"description", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values" => null, "sql" => "description", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
// Display lists
MetaModel::Init_SetZListItems('details', array('userid', 'profileid', 'reason')); // Attributes to be displayed for the complete details

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -2,7 +2,7 @@
/**
* @deprecated will be removed in 3.1.0 - moved to sources/Application/WebPage/AjaxPage.php, now loadable using autoloader
* @license http://opensource.org/licenses/AGPL-3.0
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
*/
// cannot notify depreciation for now as this is still load in autoloader

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -12,6 +12,7 @@ require_once(APPROOT.'/application/applicationcontext.class.inc.php');
require_once(APPROOT.'/application/cmdbabstract.class.inc.php');
require_once(APPROOT.'/application/displayblock.class.inc.php');
require_once(APPROOT.'/application/audit.category.class.inc.php');
require_once(APPROOT.'/application/audit.domain.class.inc.php');
require_once(APPROOT.'/application/audit.rule.class.inc.php');
require_once(APPROOT.'/application/query.class.inc.php');
require_once(APPROOT.'/setup/moduleinstallation.class.inc.php');

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -20,7 +20,7 @@
/**
* Class ApplicationContext
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -376,26 +376,19 @@ class ApplicationContext
{
$oAppContext = new ApplicationContext();
if (is_null($sUrlMakerClass))
{
$sUrlMakerClass = self::GetUrlMakerClass();
}
if (is_null($sUrlMakerClass)) {
$sUrlMakerClass = self::GetUrlMakerClass();
}
$sUrl = call_user_func(array($sUrlMakerClass, 'MakeObjectUrl'), $sObjClass, $sObjKey);
if (strlen($sUrl) > 0)
{
if ($bWithNavigationContext)
{
return $sUrl."&".$oAppContext->GetForLink();
}
else
{
return $sUrl;
}
}
else
{
return '';
}
if (utils::StrLen($sUrl) > 0) {
if ($bWithNavigationContext) {
return $sUrl."&".$oAppContext->GetForLink();
} else {
return $sUrl;
}
} else {
return '';
}
}
/**

File diff suppressed because it is too large Load Diff

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -20,9 +20,9 @@
/**
* This class manages the audit "categories". Each category defines a set of objects
* to check and is linked to a set of rules that determine the valid or invalid objects
* inside the set
* inside the set
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -42,19 +42,55 @@ class AuditCategory extends cmdbAbstractObject
"db_table" => "priv_auditcategory",
"db_key_field" => "id",
"db_finalclass_field" => "",
'style' => new ormStyle(null, null, null, null, null, '../images/icons/icons8-audit-folder.svg'),
);
MetaModel::Init_Params($aParams);
MetaModel::Init_AddAttribute(new AttributeString("name", array("description"=>"Short name for this category", "allowed_values"=>null, "sql"=>"name", "default_value"=>"", "is_null_allowed"=>false, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("description", array("allowed_values"=>null, "sql"=>"description", "default_value"=>"", "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeOQL("definition_set", array("allowed_values"=>null, "sql"=>"definition_set", "default_value"=>"", "is_null_allowed"=>false, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeLinkedSet("rules_list", array("linked_class"=>"AuditRule", "ext_key_to_me"=>"category_id", "allowed_values"=>null, "count_min"=>0, "count_max"=>0, "depends_on"=>array(), "edit_mode" => LINKSET_EDITMODE_INPLACE, "tracking_level" => LINKSET_TRACKING_ALL)));
MetaModel::Init_AddAttribute(new AttributeInteger("ok_error_tolerance", array("allowed_values"=>null, "sql"=>"ok_error_tolerance", "default_value"=>5, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeInteger("warning_error_tolerance", array("allowed_values" => null, "sql" => "warning_error_tolerance", "default_value" => 25, "is_null_allowed" => true, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeLinkedSetIndirect("domains_list",
array("linked_class" => "lnkAuditCategoryToAuditDomain", "ext_key_to_me" => "category_id", "ext_key_to_remote" => "domain_id", "allowed_values" => null, "count_min" => 0, "count_max" => 0, "depends_on" => array(), "display_style" => 'property')));
// Display lists
MetaModel::Init_SetZListItems('details', array('name', 'description', 'definition_set', 'rules_list')); // Attributes to be displayed for the complete details
MetaModel::Init_SetZListItems('details', array('name', 'description', 'definition_set', 'ok_error_tolerance', 'warning_error_tolerance', 'rules_list', 'domains_list')); // Attributes to be displayed for the complete details
MetaModel::Init_SetZListItems('list', array('description', )); // Attributes to be displayed for a list
// Search criteria
MetaModel::Init_SetZListItems('standard_search', array('description', 'definition_set')); // Criteria of the std search form
MetaModel::Init_SetZListItems('default_search', array('name', 'description')); // Criteria of the default search form
}
/**
* @param int $iTotal
* @param int $iErrors
*
* @return string A semantic color name (eg. red, green, orange, success, failure, ... {@see css/backoffice/utils/variables/colors/_semantic-palette.scss}) to use for this category depending on its error count and tolerance
* @throws \CoreException
*
* @since 3.1.0
*/
public function GetReportColor($iTotal, $iErrors)
{
$sResult = 'red';
if ( ($iTotal == 0) || ($iErrors / $iTotal) <= ($this->Get('ok_error_tolerance') / 100) ) {
$sResult = 'green';
} else if (($iErrors / $iTotal) <= ($this->Get('warning_error_tolerance') / 100)) {
$sResult = 'orange';
}
return $sResult;
}
public static function GetShortcutActions($sFinalClass)
{
$aShortcutActions = parent::GetShortcutActions($sFinalClass);
if (!in_array('UI:Menu:RunAudit', $aShortcutActions)) {
$aShortcutActions[] = 'UI:Menu:RunAudit';
}
return $aShortcutActions;
}
}
?>

View File

@@ -0,0 +1,112 @@
<?php
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
// iTop is free software; you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// iTop is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with iTop. If not, see <http://www.gnu.org/licenses/>
/**
* This class manages the audit "categories". Each category defines a set of objects
* to check and is linked to a set of rules that determine the valid or invalid objects
* inside the set
*
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
/**
* @since 3.1.0
*/
class AuditDomain extends cmdbAbstractObject
{
public static function Init()
{
$aParams = array
(
"category" => "application, grant_by_profile",
"key_type" => "autoincrement",
"name_attcode" => "name",
"complementary_name_attcode" => array('description'),
"state_attcode" => "",
"reconc_keys" => array('name'),
"db_table" => "priv_auditdomain",
"db_key_field" => "id",
"db_finalclass_field" => "",
'style' => new ormStyle(null, null, null, null, null, '../images/icons/icons8-audit-album.svg'),
);
MetaModel::Init_Params($aParams);
MetaModel::Init_AddAttribute(new AttributeString("name", array("description" => "Short name for this category", "allowed_values" => null, "sql" => "name", "default_value" => "", "is_null_allowed" => false, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeString("description", array("allowed_values" => null, "sql" => "description", "default_value" => "", "is_null_allowed" => true, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeImage("icon", array("is_null_allowed" => true, "depends_on" => array(), "display_max_width" => 96, "display_max_height" => 96, "storage_max_width" => 256, "storage_max_height" => 256, "default_image" => null, "always_load_in_tables" => false)));
MetaModel::Init_AddAttribute(new AttributeLinkedSetIndirect("categories_list",
array("linked_class" => "lnkAuditCategoryToAuditDomain", "ext_key_to_me" => "domain_id", "ext_key_to_remote" => "category_id", "allowed_values" => null, "count_min" => 0, "count_max" => 0, "depends_on" => array())));
// Display lists
MetaModel::Init_SetZListItems('details', array('name', 'description', 'icon', 'categories_list')); // Attributes to be displayed for the complete details
MetaModel::Init_SetZListItems('list', array('description',)); // Attributes to be displayed for a list
// Search criteria
MetaModel::Init_SetZListItems('standard_search', array('description')); // Criteria of the std search form
MetaModel::Init_SetZListItems('default_search', array('name', 'description')); // Criteria of the default search form
}
public static function GetShortcutActions($sFinalClass)
{
$aShortcutActions = parent::GetShortcutActions($sFinalClass);
if (!in_array('UI:Menu:RunAudit', $aShortcutActions)) {
$aShortcutActions[] = 'UI:Menu:RunAudit';
}
return $aShortcutActions;
}
}
/**
* @since 3.1.0
*/
class lnkAuditCategoryToAuditDomain extends cmdbAbstractObject
{
/**
* @throws \CoreException
* @throws \Exception
*/
public static function Init()
{
$aParams = array
(
"category" => "application, grant_by_profile",
"key_type" => "autoincrement",
"name_attcode" => "",
"state_attcode" => "",
"reconc_keys" => array('category_id', 'domain_id'),
"db_table" => "priv_link_audit_category_domain",
"db_key_field" => "id",
"db_finalclass_field" => "",
"is_link" => true,
);
MetaModel::Init_Params($aParams);
MetaModel::Init_AddAttribute(new AttributeExternalKey("category_id", array("targetclass" => "AuditCategory", "jointype" => '', "allowed_values" => null, "sql" => "category_id", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("category_name", array("allowed_values" => null, "extkey_attcode" => 'category_id', "target_attcode" => "name")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("domain_id", array("targetclass" => "AuditDomain", "jointype" => '', "allowed_values" => null, "sql" => "domain_id", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("domain_name", array("allowed_values" => null, "extkey_attcode" => 'domain_id', "target_attcode" => "name")));
// Display lists
MetaModel::Init_SetZListItems('details', array('category_id', 'domain_id'));
MetaModel::Init_SetZListItems('list', array('category_id', 'domain_id'));
// Search criteria
MetaModel::Init_SetZListItems('standard_search', array('category_id', 'domain_id'));
}
}

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -23,7 +23,7 @@
* or the "bad" ones. The core audit engines computes the complement to the definition
* set when needed to obtain either the valid objects, or the ones with an error
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -35,22 +35,23 @@ class AuditRule extends cmdbAbstractObject
{
$aParams = array
(
"category" => "application, grant_by_profile",
"key_type" => "autoincrement",
"name_attcode" => "name",
"state_attcode" => "",
"reconc_keys" => array('name'),
"db_table" => "priv_auditrule",
"db_key_field" => "id",
"category" => "application, grant_by_profile",
"key_type" => "autoincrement",
"name_attcode" => "name",
"state_attcode" => "",
"reconc_keys" => array('name'),
"db_table" => "priv_auditrule",
"db_key_field" => "id",
"db_finalclass_field" => "",
'style' => new ormStyle(null, null, null, null, null, '../images/icons/icons8-audit.svg'),
);
MetaModel::Init_Params($aParams);
MetaModel::Init_AddAttribute(new AttributeString("name", array("allowed_values"=>null, "sql"=>"name", "default_value"=>"", "is_null_allowed"=>false, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("description", array("allowed_values"=>null, "sql"=>"description", "default_value"=>"", "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeOQL("query", array("allowed_values"=>null, "sql"=>"query", "default_value"=>"", "is_null_allowed"=>false, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeEnum("valid_flag", array("allowed_values"=>new ValueSetEnum('true,false'), "sql"=>"valid_flag", "default_value"=>"true", "is_null_allowed"=>false, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalKey("category_id", array("allowed_values"=>null, "sql"=>"category_id", "targetclass"=>"AuditCategory", "is_null_allowed"=>false, "on_target_delete"=>DEL_MANUAL, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("category_name", array("allowed_values"=>null, "extkey_attcode"=> 'category_id', "target_attcode"=>"name")));
MetaModel::Init_AddAttribute(new AttributeString("name", array("allowed_values" => null, "sql" => "name", "default_value" => "", "is_null_allowed" => false, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeString("description", array("allowed_values" => null, "sql" => "description", "default_value" => "", "is_null_allowed" => true, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeOQL("query", array("allowed_values" => null, "sql" => "query", "default_value" => "", "is_null_allowed" => false, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeEnum("valid_flag", array("allowed_values" => new ValueSetEnum('true,false'), "sql" => "valid_flag", "default_value" => "true", "is_null_allowed" => false, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeExternalKey("category_id", array("allowed_values" => null, "sql" => "category_id", "targetclass" => "AuditCategory", "is_null_allowed" => false, "on_target_delete" => DEL_MANUAL, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("category_name", array("allowed_values" => null, "extkey_attcode" => 'category_id', "target_attcode" => "name")));
// Display lists
MetaModel::Init_SetZListItems('details', array('category_id', 'name', 'description', 'query', 'valid_flag')); // Attributes to be displayed for the complete details
@@ -59,5 +60,16 @@ class AuditRule extends cmdbAbstractObject
MetaModel::Init_SetZListItems('standard_search', array('category_id', 'name', 'description', 'valid_flag', 'query')); // Criteria of the std search form
MetaModel::Init_SetZListItems('default_search', array('name', 'description', 'category_id')); // Criteria of the advanced search form
}
public static function GetShortcutActions($sFinalClass)
{
$aShortcutActions = parent::GetShortcutActions($sFinalClass);
if (!in_array('UI:Menu:RunAudit', $aShortcutActions)) {
$aShortcutActions[] = 'UI:Menu:RunAudit';
}
return $aShortcutActions;
}
}
?>

View File

@@ -2,7 +2,7 @@
/**
* @deprecated will be removed in 3.1.0 - moved to sources/Application/WebPage/CaptureWebPage.php, now loadable using autoloader
* @license http://opensource.org/licenses/AGPL-3.0
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
*/
DeprecatedCallsLog::NotifyDeprecatedFile('moved to sources/Application/WebPage/CaptureWebPage.php, now loadable using autoloader');

View File

@@ -2,7 +2,7 @@
/**
* @deprecated will be removed in 3.1.0 - moved to sources/Application/WebPage/CLIPage.php, now loadable using autoloader
* @license http://opensource.org/licenses/AGPL-3.0
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
*/
DeprecatedCallsLog::NotifyDeprecatedFile('moved to sources/Application/WebPage/CLIPage.php, now loadable using autoloader');

File diff suppressed because it is too large Load Diff

View File

@@ -1,6 +1,6 @@
<?php
/**
* Copyright (C) 2013-2020 Combodo SARL
* Copyright (C) 2013-2023 Combodo SARL
*
* This file is part of iTop.
*

View File

@@ -2,7 +2,7 @@
/**
* @deprecated will be removed in 3.1.0 - moved to sources/Application/WebPage/CSVPage.php, now loadable using autoloader
* @license http://opensource.org/licenses/AGPL-3.0
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
*/
DeprecatedCallsLog::NotifyDeprecatedFile('moved to sources/Application/WebPage/CSVPage.php, now loadable using autoloader');

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -1549,6 +1549,29 @@ JS
return $this->sDefinitionFile;
}
/**
* @param string $sDashboardFileRelative can also be an absolute path (compatibility with old URL)
*
* @return string full path to the Dashboard file
* @throws \SecurityException if path isn't under approot
* @uses utils::RealPath()
* @since 2.7.8 3.0.3 3.1.0 N°4449 remove FPD
*/
public static function GetDashboardFileFromRelativePath($sDashboardFileRelative)
{
if (utils::RealPath($sDashboardFileRelative, APPROOT)) {
// compatibility with old URL containing absolute path !
return $sDashboardFileRelative;
}
$sDashboardFile = APPROOT.$sDashboardFileRelative;
if (false === utils::RealPath($sDashboardFile, APPROOT)) {
throw new SecurityException('Invalid dashboard file !');
}
return $sDashboardFile;
}
/**
* @param string $sDefinitionFile
*/

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -23,7 +23,7 @@ use Combodo\iTop\Application\UI\Base\Layout\Dashboard\DashboardRow;
/**
* Dashboard presentation
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
abstract class DashboardLayout

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2012-2021 Combodo SARL
// Copyright (C) 2012-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -29,7 +29,7 @@ require_once(APPROOT.'application/forms.class.inc.php');
/**
* Base class for all 'dashlets' (i.e. widgets to be inserted into a dashboard)
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
abstract class Dashlet
@@ -869,7 +869,7 @@ class DashletPlainText extends Dashlet
public function Render($oPage, $bEditMode = false, $aExtraParams = array())
{
$sText = $this->aProperties['text'];
$sText = utils::EscapeHtml($sText);
$sText = utils::EscapeHtml(Dict::S($sText));
$sText = str_replace(array("\r\n", "\n", "\r"), "<br/>", $sText);
$sId = 'plaintext_'.($bEditMode ? 'edit_' : '').$this->sId;

View File

@@ -55,9 +55,9 @@
<menus>
<menu id="WelcomeMenu" xsi:type="MenuGroup" _delta="define">
<rank>10</rank>
<style>
<decoration_classes>fas fa-home</decoration_classes>
</style>
<style>
<decoration_classes>fas fa-home</decoration_classes>
</style>
</menu>
<menu id="WelcomeMenuPage" xsi:type="DashboardMenuNode" _delta="define">
<rank>10</rank>
@@ -100,11 +100,20 @@
<enable_class>URP_Profiles</enable_class>
<enable_action>UR_ACTION_MODIFY</enable_action>
</menu>
<menu id="AuditCategories" xsi:type="OQLMenuNode" _delta="define">
<menu id="AuditCategories" xsi:type="DashboardMenuNode" _delta="define">
<rank>20</rank>
<parent>AdminTools</parent>
<oql><![CDATA[SELECT AuditCategory]]></oql>
<do_search>1</do_search>
<definition>
<layout>DashboardLayoutOneCol</layout>
<title>Menu:WelcomeMenuPage</title>
<cells>
<cell id="0">
<rank>0</rank>
<dashlets>
</dashlets>
</cell>
</cells>
</definition>
<enable_class>AuditCategory</enable_class>
<enable_action>UR_ACTION_MODIFY</enable_action>
</menu>
@@ -151,9 +160,9 @@
</menu>
<menu id="ConfigurationTools" xsi:type="MenuGroup" _delta="define_if_not_exists">
<rank>90</rank>
<style>
<decoration_classes>fas fa-cog</decoration_classes>
</style>
<style>
<decoration_classes>fas fa-cog</decoration_classes>
</style>
</menu>
<menu id="DataSources" xsi:type="OQLMenuNode" _delta="define">
<rank>20</rank>
@@ -172,19 +181,372 @@
</menu>
<menu id="AdminTools" xsi:type="MenuGroup" _delta="define">
<rank>80</rank>
<style>
<decoration_classes>fas fa-tools</decoration_classes>
</style>
<style>
<decoration_classes>fas fa-tools</decoration_classes>
</style>
</menu>
<menu id="SystemTools" xsi:type="MenuGroup" _delta="define">
<rank>100</rank>
<enable_class>ResourceSystemMenu</enable_class>
<enable_action>UR_ACTION_MODIFY</enable_action>
<style>
<decoration_classes>fas fa-terminal</decoration_classes>
</style>
<style>
<decoration_classes>fas fa-terminal</decoration_classes>
</style>
</menu>
</menus>
<events>
<event id="EVENT_DB_BEFORE_WRITE" _delta="define">
<description>An object is about to be written into the database. The object can be modified.</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<replaces>DBObject::OnInsert</replaces>
<event_data>
<event_datum id="object">
<description>The object inserted</description>
<type>DBObject</type>
</event_datum>
<event_datum id="is_new">
<description>Creation flag</description>
<type>boolean</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_CHECK_TO_WRITE" _delta="define">
<description>Check an object before it is written into the database (no change possible). Call DBObject::AddCheckIssue() to signal an issue</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<replaces>cmdbAbstractObject::DoCheckToWrite</replaces>
<event_data>
<event_datum id="object">
<description>The object to check</description>
<type>DBObject</type>
</event_datum>
<event_datum id="is_new">
<description>Creation flag</description>
<type>boolean</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_AFTER_WRITE" _delta="define">
<description>An object has been written into the database. The modifications can be propagated to other objects.</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<replaces>DBObject::AfterInsert</replaces>
<event_data>
<event_datum id="object">
<description>The object inserted</description>
<type>DBObject</type>
</event_datum>
<event_datum id="is_new">
<description>Creation flag</description>
<type>boolean</type>
</event_datum>
<event_datum id="changes">
<description>For updates, the list of changes done during this operation</description>
<type>array</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_CHECK_TO_DELETE" _delta="define">
<description>Check an object before it is deleted from the database. Call DBObject::AddDeleteIssue() to signal an issue</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<replaces>cmdbAbstractObject::DoCheckToDelete</replaces>
<event_data>
<event_datum id="object">
<description>The object to check</description>
<type>DBObject</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_AFTER_DELETE" _delta="define">
<description>An object has been deleted into the database</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<replaces>DBObject::AfterDelete</replaces>
<event_data>
<event_datum id="object">
<description>The object deleted</description>
<type>DBObject</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_BEFORE_APPLY_STIMULUS" _delta="define">
<description>A stimulus is about to be applied to an object</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<event_data>
<event_datum id="object">
<description>The object where the stimulus is targeted</description>
<type>DBObject</type>
</event_datum>
<event_datum id="stimulus">
<description>Current stimulus applied</description>
<type>string</type>
</event_datum>
<event_datum id="previous_state">
<description>Object previous state</description>
<type>string</type>
</event_datum>
<event_datum id="new_state">
<description>Object new state</description>
<type>string</type>
</event_datum>
<event_datum id="save_object">
<description>The object must be saved in the database</description>
<type>boolean</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_AFTER_APPLY_STIMULUS" _delta="define">
<description>A stimulus has been applied to an object</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<event_data>
<event_datum id="object">
<description>The object where the stimulus is targeted</description>
<type>DBObject</type>
</event_datum>
<event_datum id="stimulus">
<description>Current stimulus applied</description>
<type>string</type>
</event_datum>
<event_datum id="previous_state">
<description>Object previous state</description>
<type>string</type>
</event_datum>
<event_datum id="new_state">
<description>Object new state</description>
<type>string</type>
</event_datum>
<event_datum id="save_object">
<description>The object is asked to be saved in the database</description>
<type>boolean</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_APPLY_STIMULUS_FAILED" _delta="define">
<description>A stimulus has failed</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<event_data>
<event_datum id="action">
<description>The action that failed to apply the stimulus</description>
<type>string</type>
</event_datum>
<event_datum id="object">
<description>The object where the stimulus is targeted</description>
<type>DBObject</type>
</event_datum>
<event_datum id="stimulus">
<description>Current stimulus applied</description>
<type>string</type>
</event_datum>
<event_datum id="previous_state">
<description>Object previous state</description>
<type>string</type>
</event_datum>
<event_datum id="new_state">
<description>Object new state</description>
<type>string</type>
</event_datum>
<event_datum id="save_object">
<description>The object must be saved in the database</description>
<type>boolean</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_LINKS_CHANGED" _delta="define">
<description>At least one link class was changed</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<event_data>
<event_datum id="object">
<description>The object where the link is or was pointing to</description>
<type>DBObject</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_OBJECT_RELOAD" _delta="define">
<description>An object has been re-loaded from the database</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<event_data>
<event_datum id="object">
<description>The object re-loaded</description>
<type>DBObject</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_COMPUTE_VALUES" _delta="define">
<description>An object needs to be recomputed after changes</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<replaces>DBObject::ComputeValues</replaces>
<event_data>
<event_datum id="object">
<description>The object inserted</description>
<type>DBObject</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_ARCHIVE" _delta="define">
<description>An object has been archived</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<event_data>
<event_datum id="object">
<description>The object archived</description>
<type>DBObject</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_UNARCHIVE" _delta="define">
<description>An object has been unarchived</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<event_data>
<event_datum id="object">
<description>The object unarchived</description>
<type>DBObject</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_SET_ATTRIBUTES_FLAGS" _delta="define">
<description>Set object attributes flags. Call cmdbAbstractObject::AddAttributeFlags() for all the attributes to be set for this target state.</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<event_data>
<event_datum id="object">
<description>The current object</description>
<type>DBObject</type>
</event_datum>
<event_datum id="target_state">
<description>The target state in which to evaluate the flags</description>
<type>array</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DB_SET_INITIAL_ATTRIBUTES_FLAGS" _delta="define">
<description>Set object initial attributes flags. Call cmdbAbstractObject::AddInitialAttributeFlags() for all the initial attributes to be set initially.</description>
<sources>
<source id="cmdbAbstractObject">cmdbAbstractObject</source>
</sources>
<event_data>
<event_datum id="object">
<description>The current object</description>
<type>DBObject</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_DOWNLOAD_DOCUMENT" _delta="define">
<description>A document has been downloaded from the GUI</description>
<sources>
<source id="Document">Document</source>
</sources>
<event_data>
<event_datum id="object">
<description>The object containing the document</description>
<type>DBObject</type>
</event_datum>
<event_datum id="document">
<description>The document downloaded</description>
<type>ormDocument</type>
</event_datum>
<event_datum id="debug_info">
<description>Debug string</description>
<type>string</type>
</event_datum>
</event_data>
</event>
<event id="EVENT_LOGIN" _delta="define">
<description>Inform the listeners about the connection states</description>
<event_data>
<event_datum id="code">
<description>The login step result code (LoginWebPage::EXIT_CODE_...) </description>
<type>integer</type>
</event_datum>
<event_datum id="state">
<description>Current login state (LoginWebPage::LOGIN_STATE_CONNECTED...)</description>
<type>string</type>
</event_datum>
</event_data>
</event>
</events>
<meta>
<classes>
<class id="cmdbAbstractObject" _delta="define">

View File

@@ -3,7 +3,7 @@
use Combodo\iTop\Renderer\Console\ConsoleBlockRenderer;
/**
* Copyright (C) 2013-2021 Combodo SARL
* Copyright (C) 2013-2023 Combodo SARL
*
* This file is part of iTop.
*
@@ -386,7 +386,7 @@ EOF;
if (!$oPage->IsPrintableVersion())
{
$sMenuTitle = Dict::S('UI:ConfigureThisList');
$sHtml = '<div class="itop_popup toolkit_menu" id="tk_'.$this->iListId.'"><ul><li><i class="fas fa-tools"></i><i class="fas fa-caret-down"></i><ul>';
$sHtml = '<div class="itop_popup toolkit_menu" id="tk_'.$this->iListId.'"><ul><li aria-label="'.Dict::S('UI:Menu:Toolkit').'"><i class="fas fa-tools"></i><i class="fas fa-caret-down"></i><ul>';
$oMenuItem1 = new JSPopupMenuItem('iTop::ConfigureList', $sMenuTitle, "$('#datatable_dlg_".$this->iListId."').dialog('open');");
$aActions = array(

File diff suppressed because it is too large Load Diff

View File

@@ -2,7 +2,7 @@
/**
* @deprecated will be removed in 3.1.0 - moved to sources/Application/WebPage/ErrorPage.php, now loadable using autoloader
* @license http://opensource.org/licenses/AGPL-3.0
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
*/
DeprecatedCallsLog::NotifyDeprecatedFile('moved to sources/Application/WebPage/ErrorPage.php, now loadable using autoloader');

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -48,7 +48,7 @@ class CoreCannotSaveObjectException extends CoreException
if (count($this->aIssues) == 1) {
$sIssue = reset($this->aIssues);
$sContent .= " <span>".utils::HtmlEntities($sIssue)."</span>";
$sContent .= "&nbsp;<span>".utils::HtmlEntities($sIssue)."</span>";
} else {
$sContent .= '<ul>';
foreach ($this->aIssues as $sError) {

View File

@@ -1,11 +1,15 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
class CoreException extends Exception
{
protected $m_sIssue;
protected $m_sImpact;
protected $m_aContextData;
/**
* CoreException constructor.
*

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/**
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -0,0 +1,10 @@
<?php
/*
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
class iTopXmlException extends CoreException
{
}

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -0,0 +1,13 @@
<?php
/*
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
/**
* @since 2.7.8 3.0.3 3.1.0 N°5538
*/
class MySQLTransactionNotClosedException extends MySQLException
{
}

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/**
* Copyright (C) 2013-2020 Combodo SARL
* Copyright (C) 2013-2023 Combodo SARL
*
* This file is part of iTop.
*

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -20,7 +20,7 @@
* Helper class to build interactive forms to be used either in stand-alone
* modal dialog or in "property-sheet" panes.
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
class DesignerForm
@@ -60,7 +60,7 @@ class DesignerForm
$this->sHierarchySelector = '';
$this->StartFieldSet($this->sCurrentFieldSet);
$this->bDisplayed = true;
$this->aDefaultvalues = array();
$this->aDefaultValues = array();
}
public function AddField(DesignerFormField $oField)

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -20,7 +20,7 @@
/**
* Persistent class InputOutputTask
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -2,7 +2,7 @@
/**
* @deprecated will be removed in 3.1.0 - moved to sources/Application/WebPage/iTopWebPage.php, now loadable using autoloader
* @license http://opensource.org/licenses/AGPL-3.0
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
*/
// cannot notify depreciation for now as this is still MASSIVELY used in iTop core !

View File

@@ -2,7 +2,7 @@
/**
* @deprecated will be removed in 3.1.0 - moved to sources/Application/WebPage/iTopWizardWebPage.php, now loadable using autoloader
* @license http://opensource.org/licenses/AGPL-3.0
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
*/
DeprecatedCallsLog::NotifyDeprecatedFile('moved to sources/Application/WebPage/iTopWizardWebPage.php, now loadable using autoloader');

View File

@@ -5,7 +5,7 @@ use Combodo\iTop\Application\Helper\Session;
/**
* Class LoginBasic
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -80,6 +80,11 @@ class LoginBasic extends AbstractLoginFSMExtension
{
if (Session::Get('login_mode') == 'basic')
{
$iOnExit = LoginWebPage::getIOnExit();
if ($iOnExit === LoginWebPage::EXIT_RETURN)
{
return LoginWebPage::LOGIN_FSM_RETURN; // Error, exit FSM
}
LoginWebPage::HTTP401Error();
}
return LoginWebPage::LOGIN_FSM_CONTINUE;

View File

@@ -1,6 +1,6 @@
<?php
/**
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -79,7 +79,7 @@ class LoginDefaultAfter extends AbstractLoginFSMExtension implements iLogoutExte
{
self::ResetLoginSession();
$iOnExit = LoginWebPage::getIOnExit();
if ($iOnExit == LoginWebPage::EXIT_RETURN)
if ($iOnExit === LoginWebPage::EXIT_RETURN)
{
return LoginWebPage::LOGIN_FSM_RETURN; // Error, exit FSM
}
@@ -95,6 +95,12 @@ class LoginDefaultAfter extends AbstractLoginFSMExtension implements iLogoutExte
{
if (!Session::IsSet('login_mode'))
{
// N°6358 - if EXIT_RETURN was asked, send an error
if (LoginWebPage::getIOnExit() === LoginWebPage::EXIT_RETURN) {
$iErrorCode = LoginWebPage::EXIT_CODE_WRONGCREDENTIALS;
return LoginWebPage::LOGIN_FSM_ERROR;
}
// If no plugin validated the user, exit
self::ResetLoginSession();
exit();

View File

@@ -5,7 +5,7 @@ use Combodo\iTop\Application\Helper\Session;
/**
* Class LoginExternal
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -73,6 +73,11 @@ class LoginExternal extends AbstractLoginFSMExtension
{
if (Session::Get('login_mode') == 'external')
{
$iOnExit = LoginWebPage::getIOnExit();
if ($iOnExit === LoginWebPage::EXIT_RETURN)
{
return LoginWebPage::LOGIN_FSM_RETURN; // Error, exit FSM
}
LoginWebPage::HTTP401Error();
}
return LoginWebPage::LOGIN_FSM_CONTINUE;
@@ -88,4 +93,4 @@ class LoginExternal extends AbstractLoginFSMExtension
/** @var string $sAuthUser */
return $sAuthUser; // Retrieve the value
}
}
}

View File

@@ -1,7 +1,7 @@
<?php
/**
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -44,6 +44,10 @@ class LoginForm extends AbstractLoginFSMExtension implements iLoginUIExtension
exit;
}
if (LoginWebPage::getIOnExit() === LoginWebPage::EXIT_RETURN) {
return LoginWebPage::LOGIN_FSM_CONTINUE;
}
// No credentials yet, display the form
$oPage = LoginWebPage::NewLoginWebPage();
$oPage->DisplayLoginForm($this->bForceFormOnError);

View File

@@ -2,7 +2,7 @@
/**
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -5,7 +5,7 @@ use Combodo\iTop\Application\Helper\Session;
/**
* Class LoginURL
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -92,4 +92,4 @@ class LoginURL extends AbstractLoginFSMExtension
}
return LoginWebPage::LOGIN_FSM_CONTINUE;
}
}
}

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -20,12 +20,14 @@
/**
* Class LoginWebPage
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
use Combodo\iTop\Application\Branding;
use Combodo\iTop\Application\Helper\Session;
use Combodo\iTop\Service\Events\EventData;
use Combodo\iTop\Service\Events\EventService;
/**
* Web page used for displaying the login form
@@ -389,6 +391,11 @@ class LoginWebPage extends NiceWebPage
Session::Unset('can_logoff');
Session::Unset('archive_mode');
Session::Unset('impersonate_user');
Session::Unset('PluginProperties');
Session::Unset('UrlMakerClass');
Session::Unset('itop_env');
Session::Unset('obj_messages');
Session::Unset('profile_list');
UserRights::_ResetSessionCache();
// If it's desired to kill the session, also delete the session cookie.
// Note: This will destroy the session, and not just the session data!
@@ -479,11 +486,13 @@ class LoginWebPage extends NiceWebPage
$iResponse = $oLoginFSMExtensionInstance->LoginAction($sLoginState, $iErrorCode);
if ($iResponse == self::LOGIN_FSM_RETURN)
{
EventService::FireEvent(new EventData(EVENT_LOGIN, null, ['code' => $iErrorCode, 'state' => $sLoginState]));
Session::WriteClose();
return $iErrorCode; // Asked to exit FSM, generally login OK
}
if ($iResponse == self::LOGIN_FSM_ERROR)
{
EventService::FireEvent(new EventData(EVENT_LOGIN, null, ['code' => $iErrorCode, 'state' => $sLoginState]));
$sLoginState = self::LOGIN_STATE_SET_ERROR; // Next state will be error
// An error was detected, skip the other plugins turn
break;
@@ -497,6 +506,7 @@ class LoginWebPage extends NiceWebPage
}
catch (Exception $e)
{
EventService::FireEvent(new EventData(EVENT_LOGIN, null, ['state' => $_SESSION['login_state']]));
IssueLog::Error($e->getTraceAsString());
static::ResetSession();
die($e->getMessage());

View File

@@ -1,6 +1,6 @@
<?php
/**
* Copyright (C) 2013-2021 Combodo SARL
* Copyright (C) 2013-2023 Combodo SARL
*
* This file is part of iTop.
*

View File

@@ -1,6 +1,6 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
@@ -291,7 +291,17 @@ class ApplicationMenu
* @param string $sMenuGroupIdx
* @param array $aExtraParams
*
* @return array
* @return array{
* array{
* sId: string,
* sTitle: string,
* sLabel: string,
* bHasCount: boolean,
* sUrl: string,
* bOpenInNewWindow: boolean,
* aSubMenuNodes: array
* }
* } The aSubMenuNodes key contains the same structure recursively
* @throws \DictExceptionMissingString
* @throws \Exception
* @since 3.0.0
@@ -320,12 +330,13 @@ class ApplicationMenu
}
$aSubMenuNodes[] = [
'sId' => $oSubMenuNode->GetMenuId(),
'sTitle' => $oSubMenuNode->GetTitle(),
'bHasCount' => $oSubMenuNode->HasCount(),
'sUrl' => $oSubMenuNode->GetHyperlink($aExtraParams),
'sId' => $oSubMenuNode->GetMenuId(),
'sTitle' => $oSubMenuNode->GetTitle(),
'sLabel' => $oSubMenuNode->GetLabel(),
'bHasCount' => $oSubMenuNode->HasCount(),
'sUrl' => $oSubMenuNode->GetHyperlink($aExtraParams),
'bOpenInNewWindow' => $oSubMenuNode->IsHyperLinkInNewWindow(),
'aSubMenuNodes' => static::GetSubMenuNodes($sSubMenuItemIdx, $aExtraParams),
'aSubMenuNodes' => static::GetSubMenuNodes($sSubMenuItemIdx, $aExtraParams),
];
}
@@ -746,7 +757,7 @@ abstract class MenuNode
}
/**
* @return string
* @return string The "+" dictionary entry for this menu if exists, otherwise the Title (if we have a parent title, will output parentTitle / currentTitle)
*/
public function GetLabel()
{
@@ -758,7 +769,6 @@ abstract class MenuNode
} else {
$sRet = $this->GetTitle();
}
//$sRet = $this->GetTitle();
}
return $sRet;
}
@@ -1101,6 +1111,7 @@ class OQLMenuNode extends MenuNode
*/
public function RenderContent(WebPage $oPage, $aExtraParams = array())
{
ContextTag::AddContext(ContextTag::TAG_OBJECT_SEARCH);
ApplicationMenu::CheckMenuIdEnabled($this->GetMenuId());
OQLMenuNode::RenderOQLSearch
(

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//

View File

@@ -2,7 +2,7 @@
/**
* @deprecated will be removed in 3.1.0 - moved to sources/Application/WebPage/NiceWebPage.php, now loadable using autoloader
* @license http://opensource.org/licenses/AGPL-3.0
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
*/
DeprecatedCallsLog::NotifyDeprecatedFile('moved to sources/Application/WebPage/NiceWebPage.php, now loadable using autoloader');

View File

@@ -2,7 +2,7 @@
/**
* @deprecated will be removed in 3.1.0 - moved to sources/Application/WebPage/PDFPage.php, now loadable using autoloader
* @license http://opensource.org/licenses/AGPL-3.0
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
*/
DeprecatedCallsLog::NotifyDeprecatedFile('moved to sources/Application/WebPage/PDFPage.php, now loadable using autoloader');

View File

@@ -1,6 +1,6 @@
<?php
/*
* Copyright (C) 2010-2021 Combodo SARL
* Copyright (C) 2010-2023 Combodo SARL
*
* This file is part of iTop.
*
@@ -156,6 +156,7 @@ abstract class Query extends cmdbAbstractObject
// last export information
$this->Set('export_last_date', date(AttributeDateTime::GetSQLFormat()));
$this->Set('export_last_user_id', UserRights::GetUserObject());
$this->AllowWrite(true);
$this->DBUpdate();
// increment usage counter

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -22,7 +22,7 @@ use Combodo\iTop\Application\UI\Base\Component\DataTable\DataTableSettings;
* Persistent class Shortcut and derived
* Shortcuts of any kind
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -17,16 +17,17 @@
// along with iTop. If not, see <http://www.gnu.org/licenses/>
use Combodo\iTop\Application\Helper\Session;
require_once(APPROOT.'/core/cmdbobject.class.inc.php');
require_once(APPROOT.'/application/utils.inc.php');
require_once(APPROOT.'/core/contexttag.class.inc.php');
require_once(APPROOT.'/core/kpi.class.inc.php');
require_once(APPROOT.'core/cmdbobject.class.inc.php');
require_once(APPROOT.'application/utils.inc.php');
require_once(APPROOT.'core/contexttag.class.inc.php');
require_once(APPROOT.'core/kpi.class.inc.php');
require_once(APPROOT.'setup/setuputils.class.inc.php');
/**
* File to include to initialize the datamodel in memory
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,6 +1,6 @@
<?php
/**
* Copyright (C) 2013-2021 Combodo SARL
* Copyright (C) 2013-2023 Combodo SARL
*
* This file is part of iTop.
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Copyright (C) 2013-2021 Combodo SARL
* Copyright (C) 2013-2023 Combodo SARL
*
* This file is part of iTop.
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Copyright (C) 2013-2020 Combodo SARL
* Copyright (C) 2013-2023 Combodo SARL
*
* This file is part of iTop.
*

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -24,7 +24,7 @@ use Combodo\iTop\Application\Helper\Session;
* which choice is configured via the parameter 'transaction_storage'
*
* @package iTop
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
class privUITransaction

View File

@@ -111,23 +111,6 @@ class TwigExtension
return utils::IsDevelopmentEnvironment();
}));
// Function to get configuration parameter
// Usage in twig: {{ get_config_parameter('foo') }}
$oTwigEnv->addFunction(new TwigFunction('get_config_parameter', function ($sParamName) {
$oConfig = MetaModel::GetConfig();
return $oConfig->Get($sParamName);
}));
// Function to get a module setting
// Usage in twig: {{ get_module_setting(<MODULE_CODE>, <PROPERTY_CODE> [, <DEFAULT_VALUE>]) }}
// since 3.0.0, but see N°4034 for upcoming evolutions in the 3.1
$oTwigEnv->addFunction(new TwigFunction('get_module_setting', function (string $sModuleCode, string $sPropertyCode, $defaultValue = null) {
$oConfig = MetaModel::GetConfig();
return $oConfig->GetModuleSetting($sModuleCode, $sPropertyCode, $defaultValue);
}));
// Function to get the URL of a static page in a module
// Usage in twig: {{ get_static_page_module_url('itop-my-module', 'path-to-my-page') }}
$oTwigEnv->addFunction(new TwigFunction('get_static_page_module_url', function ($sModuleName, $sPage) {

View File

@@ -1,9 +1,10 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
use Combodo\iTop\Application\Helper\FormHelper;
use Combodo\iTop\Application\UI\Base\Component\Form\FormUIBlockFactory;
use Combodo\iTop\Application\UI\Base\Layout\UIContentBlockUIBlockFactory;
use Combodo\iTop\Core\MetaModel\FriendlyNameType;
@@ -323,12 +324,12 @@ EOF
EOF
);
$sHTMLValue .= "<div class=\"ibo-input-select--action-buttons\">";
$sHTMLValue .= " <div class=\"ibo-input-select--action-button ibo-input-select--action-button--clear ibo-is-hidden\" id=\"mini_clear_{$this->iId}\" onClick=\"oACWidget_{$this->iId}.Clear();\" data-tooltip-content='".Dict::S('UI:Button:Clear')."'><i class=\"fas fa-times\"></i></div>";
$sHTMLValue .= " <a href=\"#\" class=\"ibo-input-select--action-button ibo-input-select--action-button--clear ibo-is-hidden\" id=\"mini_clear_{$this->iId}\" onClick=\"oACWidget_{$this->iId}.Clear();\" data-tooltip-content='".Dict::S('UI:Button:Clear')."'><i class=\"fas fa-times\"></i></a>";
}
if ($bCreate && $bExtensions) {
$sCallbackName = (MetaModel::IsAbstract($this->sTargetClass)) ? 'SelectObjectClass' : 'CreateObject';
$sHTMLValue .= "<div class=\"ibo-input-select--action-button ibo-input-select--action-button--create\" id=\"mini_add_{$this->iId}\" onClick=\"oACWidget_{$this->iId}.{$sCallbackName}();\" data-tooltip-content='".Dict::S('UI:Button:Create')."'><i class=\"fas fa-plus\"></i></div>";
$sHTMLValue .= "<a href=\"#\" class=\"ibo-input-select--action-button ibo-input-select--action-button--create\" id=\"mini_add_{$this->iId}\" onClick=\"oACWidget_{$this->iId}.{$sCallbackName}();\" data-tooltip-content='".Dict::S('UI:Button:Create')."'><i class=\"fas fa-plus\"></i></a>";
$oPage->add_ready_script(
<<<JS
if ($('#ajax_{$this->iId}').length == 0)
@@ -339,7 +340,7 @@ JS
);
}
if ($bExtensions && MetaModel::IsHierarchicalClass($this->sTargetClass) !== false) {
$sHTMLValue .= "<div class=\"ibo-input-select--action-button ibo-input-select--action-button--hierarchy\" id=\"mini_tree_{$this->iId}\" onClick=\"oACWidget_{$this->iId}.HKDisplay();\" data-tooltip-content='".Dict::S('UI:Button:SearchInHierarchy')."'><i class=\"fas fa-sitemap\"></i></div>";
$sHTMLValue .= "<a href=\"#\" class=\"ibo-input-select--action-button ibo-input-select--action-button--hierarchy\" id=\"mini_tree_{$this->iId}\" onClick=\"oACWidget_{$this->iId}.HKDisplay();\" data-tooltip-content='".Dict::S('UI:Button:SearchInHierarchy')."'><i class=\"fas fa-sitemap\"></i></a>";
$oPage->add_ready_script(
<<<JS
if ($('#ac_tree_{$this->iId}').length == 0)
@@ -350,7 +351,7 @@ JS
);
}
if ($oAllowedValues->CountExceeds($iMaxComboLength)) {
$sHTMLValue .= " <div class=\"ibo-input-select--action-button ibo-input-select--action-button--search\" id=\"mini_search_{$this->iId}\" onClick=\"oACWidget_{$this->iId}.Search();\" data-tooltip-content='".Dict::S('UI:Button:Search')."'><i class=\"fas fa-search\"></i></div>";
$sHTMLValue .= " <a href=\"#\" class=\"ibo-input-select--action-button ibo-input-select--action-button--search\" id=\"mini_search_{$this->iId}\" onClick=\"oACWidget_{$this->iId}.Search();\" data-tooltip-content='".Dict::S('UI:Button:Search')."'><i class=\"fas fa-search\"></i></a>";
}
$sHTMLValue .= "</div>";
$sHTMLValue .= "</div>";
@@ -685,15 +686,15 @@ JS
}
$oFilter->SetModifierProperty('UserRightsGetSelectFilter', 'bSearchMode', $this->bSearchMode);
$oBlock = new DisplayBlock($oFilter, 'search', false, $aParams);
$oPage->AddUiBlock($oBlock->GetDisplay($oPage, $this->iId,
$oPage->AddUiBlock($oBlock->GetDisplay($oPage, 'dtc_'.$this->iId,
array(
'menu' => false,
'currentId' => $this->iId,
'table_id' => "dr_{$this->iId}",
'menu' => false,
'currentId' => $this->iId,
'table_id' => "dr_{$this->iId}",
'table_inner_id' => "{$this->iId}_results",
'selection_mode' => true,
'selection_type' => 'single',
'cssCount' => '#count_'.$this->iId.'_results',
'cssCount' => '#count_'.$this->iId.'_results',
)
));
$sCancel = Dict::S('UI:Button:Cancel');
@@ -904,7 +905,7 @@ JS
{
// For security reasons: check that the "proposed" class is actually a subclass of the linked class
// and that the current user is allowed to create objects of this class
$aSubClasses = MetaModel::EnumChildClasses($this->sTargetClass);
$aSubClasses = MetaModel::EnumChildClasses($this->sTargetClass, ENUM_CHILD_CLASSES_ALL);
$aPossibleClasses = array();
foreach($aSubClasses as $sCandidateClass)
{
@@ -924,6 +925,7 @@ JS
$sDialogTitleEscaped = addslashes($sDialogTitle);
$oPage->add_ready_script("$('#ac_create_$this->iId').dialog({ width: 'auto', height: 'auto', maxHeight: $(window).height() - 50, autoOpen: false, modal: true, title: '$sDialogTitleEscaped'});\n");
$oPage->add_ready_script("$('#ac_create_{$this->iId} form').removeAttr('onsubmit');");
$oPage->add_ready_script("$('#ac_create_{$this->iId} form').find('select').attr('id', 'ac_create_{$this->iId}_select');");
$oPage->add_ready_script("$('#ac_create_{$this->iId} form').on('submit.uilinksWizard', oACWidget_{$this->iId}.DoSelectObjectClass);");
}
@@ -966,15 +968,16 @@ JS
<div id="dcr_{$this->iId}">
HTML
);
$aFieldsFlags = array();
$aFieldsComments = array();
foreach (MetaModel::ListAttributeDefs($this->sTargetClass) as $sAttCode => $oAttDef) {
if (($oAttDef instanceof AttributeBlob) || (false)) {
$aFieldsFlags[$sAttCode] = OPT_ATT_READONLY;
$aFieldsComments[$sAttCode] = '&nbsp;<img src="../images/transp-lock.png" style="vertical-align:middle" title="'.utils::EscapeHtml(Dict::S('UI:UploadNotSupportedInThisMode')).'"/>';
}
}
cmdbAbstractObject::DisplayCreationForm($oPage, $this->sTargetClass, $oNewObj, array(), array('formPrefix' => $this->iId, 'noRelations' => true, 'fieldsFlags' => $aFieldsFlags, 'fieldsComments' => $aFieldsComments));
$aFormExtraParams = array(
'formPrefix' => $this->iId,
'noRelations' => true,
);
// Remove blob edition from creation form @see N°5863 to allow blob edition in modal context
FormHelper::DisableAttributeBlobInputs($this->sTargetClass, $aFormExtraParams);
cmdbAbstractObject::DisplayCreationForm($oPage, $this->sTargetClass, $oNewObj, array(), $aFormExtraParams);
$oPage->add(<<<HTML
</div>
</div>

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -22,7 +22,7 @@ use Combodo\iTop\Application\Helper\WebResourcesHelper;
* UI wdiget for displaying and editing one-way encrypted passwords
*
* @author Romain Quetiez
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,16 +1,17 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
use Combodo\iTop\Application\UI\Base\Component\DataTable\DataTableUIBlockFactory;
use Combodo\iTop\Application\UI\Base\Layout\UIContentBlockUIBlockFactory;
use Combodo\iTop\Application\Helper\FormHelper;
use Combodo\iTop\Application\UI\Links\Direct\BlockDirectLinkSetEditTable;
use Combodo\iTop\Renderer\Console\ConsoleBlockRenderer;
/**
* Class UILinksWidgetDirect
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
class UILinksWidgetDirect
@@ -19,10 +20,12 @@ class UILinksWidgetDirect
protected $sAttCode;
protected $sInputid;
protected $sNameSuffix;
protected $aZlist;
protected $sLinkedClass;
/**
* UILinksWidgetDirect constructor.
*
* @param string $sClass
* @param string $sAttCode
* @param string $sInputId
@@ -80,97 +83,10 @@ class UILinksWidgetDirect
*/
public function Display(WebPage $oPage, $oValue, $aArgs, $sFormPrefix, $oCurrentObj)
{
if (empty($aArgs)) {
$aArgs = [];
}
$oBlock = new BlockDirectLinkSetEditTable($this, $this->sInputid);
$oBlock->InitTable($oPage, $oValue, $sFormPrefix, $oCurrentObj);
$oLinksetDef = MetaModel::GetAttributeDef($this->sClass, $this->sAttCode);
switch($oLinksetDef->GetEditMode())
{
case LINKSET_EDITMODE_NONE: // The linkset is read-only
$this->DisplayAsBlock($oPage, $oValue, $aArgs = array(), $sFormPrefix, $oCurrentObj, false /* bDisplayMenu*/);
break;
case LINKSET_EDITMODE_ADDONLY: // The only possible action is to open (in a new window) the form to create a new object
if ($oCurrentObj && !$oCurrentObj->IsNew())
{
$sTargetClass = $oLinksetDef->GetLinkedClass();
$sExtKeyToMe = $oLinksetDef->GetExtKeyToMe();
$sDefault = "default[$sExtKeyToMe]=".$oCurrentObj->GetKey();
$oAppContext = new ApplicationContext();
$sParams = $oAppContext->GetForLink();
$oPage->p("<a target=\"_blank\" href=\"".utils::GetAbsoluteUrlAppRoot()."pages/UI.php?operation=new&class=$sTargetClass&$sParams&{$sDefault}\">".Dict::Format('UI:ClickToCreateNew', Metamodel::GetName($sTargetClass))."</a>\n");
}
$this->DisplayAsBlock($oPage, $oValue, $aArgs = array(), $sFormPrefix, $oCurrentObj, false /* bDisplayMenu*/);
break;
case LINKSET_EDITMODE_INPLACE: // The whole linkset can be edited 'in-place'
$this->DisplayEditInPlace($oPage, $oValue, $aArgs, $sFormPrefix, $oCurrentObj);
break;
case LINKSET_EDITMODE_ADDREMOVE: // The whole linkset can be edited 'in-place'
$sTargetClass = $oLinksetDef->GetLinkedClass();
$sExtKeyToMe = $oLinksetDef->GetExtKeyToMe();
$oExtKeyDef = MetaModel::GetAttributeDef($sTargetClass, $sExtKeyToMe);
$aButtons = array('add');
if ($oExtKeyDef->IsNullAllowed())
{
$aButtons = array('add', 'remove');
}
$this->DisplayEditInPlace($oPage, $oValue, $aArgs, $sFormPrefix, $oCurrentObj, $aButtons);
break;
case LINKSET_EDITMODE_ACTIONS:
default:
$this->DisplayAsBlock($oPage, $oValue, $aArgs = array(), $sFormPrefix, $oCurrentObj, true /* bDisplayMenu*/);
}
}
/**
* @param WebPage $oPage
* @param DBObjectSet $oValue
* @param array $aArgs
* @param string $sFormPrefix
* @param DBObject $oCurrentObj
* @param bool $bDisplayMenu
*
* @since 2.7.7 3.0.1 3.1.0 N°3129 Remove default value for $aArgs for PHP 8.0 compatibility (protected method, always called with default value)
*/
protected function DisplayAsBlock(WebPage $oPage, $oValue, $aArgs, $sFormPrefix, $oCurrentObj, $bDisplayMenu)
{
$oLinksetDef = MetaModel::GetAttributeDef($this->sClass, $this->sAttCode);
$sTargetClass = $oLinksetDef->GetLinkedClass();
if ($oCurrentObj && $oCurrentObj->IsNew() && $bDisplayMenu)
{
$oPage->p(Dict::Format('UI:BeforeAdding_Class_ObjectsSaveThisObject', MetaModel::GetName($sTargetClass)));
}
else
{
$oFilter = new DBObjectSearch($sTargetClass);
$oFilter->AddCondition($oLinksetDef->GetExtKeyToMe(), $oCurrentObj->GetKey(),'=');
$aDefaults = array($oLinksetDef->GetExtKeyToMe() => $oCurrentObj->GetKey());
$oAppContext = new ApplicationContext();
foreach($oAppContext->GetNames() as $sKey)
{
// The linked object inherits the parent's value for the context
if (MetaModel::IsValidAttCode($this->sClass, $sKey) && $oCurrentObj)
{
$aDefaults[$sKey] = $oCurrentObj->Get($sKey);
}
}
$aParams = array(
'target_attr' => $oLinksetDef->GetExtKeyToMe(),
'object_id' => $oCurrentObj ? $oCurrentObj->GetKey() : null,
'menu' => $bDisplayMenu,
'menu_actions_target' => '_blank',
'default' => $aDefaults,
'table_id' => $this->sClass.'_'.$this->sAttCode,
);
$oBlock = new DisplayBlock($oFilter, 'list', false);
$oBlock->Display($oPage, $this->sInputid, $aParams);
}
return ConsoleBlockRenderer::RenderBlockTemplateInPage($oPage, $oBlock);
}
/**
@@ -203,15 +119,32 @@ class UILinksWidgetDirect
$sRealClass = $aKeys[0];
}
if ($sRealClass != '')
{
if ($sRealClass != '') {
$oLinksetDef = MetaModel::GetAttributeDef($this->sClass, $this->sAttCode);
$sExtKeyToMe = $oLinksetDef->GetExtKeyToMe();
$aFieldFlags = array( $sExtKeyToMe => OPT_ATT_HIDDEN);
$aFieldsFlags = array($sExtKeyToMe => OPT_ATT_HIDDEN);
$oObj = DBObject::MakeDefaultInstance($sRealClass);
$aPrefillParam = array('source_obj' => $oSourceObj);
$oObj->PrefillForm('creation_from_editinplace', $aPrefillParam);
cmdbAbstractObject::DisplayCreationForm($oPage, $sRealClass, $oObj, array(), array('formPrefix' => $this->sInputid, 'noRelations' => true, 'fieldsFlags' => $aFieldFlags));
$aFormExtraParams = array(
'formPrefix' => $this->sInputid,
'noRelations' => true,
'fieldsFlags' => $aFieldsFlags,
'js_handlers' => [
'cancel_button_on_click' =>
<<<JS
function() {
// Do nothing, already handled by linksdirectwidget.js
};
JS
,
],
);
// Remove blob edition from creation form @see N°5863 to allow blob edition in modal context
FormHelper::DisableAttributeBlobInputs($sRealClass, $aFormExtraParams);
cmdbAbstractObject::DisplayCreationForm($oPage, $sRealClass, $oObj, array(), $aFormExtraParams);
}
else
{
@@ -229,55 +162,6 @@ class UILinksWidgetDirect
$oPage->add('</div></div>');
}
/**
* @param WebPage $oPage
* @param DBObjectSet $oValue
* @param array $aArgs
* @param string $sFormPrefix
* @param DBObject $oCurrentObj
* @param array $aButtons
*
* @since 2.7.7 3.0.1 3.1.0 N°3129 Remove default value for $aArgs for PHP 8.0 compatibility (protected method, caller already handles it)
*/
protected function DisplayEditInPlace(WebPage $oPage, $oValue, $aArgs, $sFormPrefix, $oCurrentObj, $aButtons = array('create', 'delete'))
{
$aAttribs = $this->GetTableConfig();
$oValue->Rewind();
$aData = array();
while ($oLinkObj = $oValue->Fetch()) {
$aRow = array();
$aRow['form::select'] = '<input type="checkbox" class="selectList'.$this->sInputid.'" value="'.$oLinkObj->GetKey().'"/>';
foreach ($this->aZlist as $sLinkedAttCode) {
$aRow[$sLinkedAttCode] = $oLinkObj->GetAsHTML($sLinkedAttCode);
}
$aData[] = $aRow;
}
$oDiv = UIContentBlockUIBlockFactory::MakeStandard($this->sInputid, ['listContainer']);
$oPage->AddSubBlock($oDiv);
$oDatatable = DataTableUIBlockFactory::MakeForForm($this->sInputid, $aAttribs, $aData);
$oDatatable->SetOptions(['select_mode' => 'custom', 'disable_hyperlinks' => true]);
$oDiv->AddSubBlock($oDatatable);
$sInputName = $sFormPrefix.'attr_'.$this->sAttCode;
$aLabels = array(
'delete' => Dict::S('UI:Button:Delete'),
// 'modify' => 'Modify...' ,
'creation_title' => Dict::Format('UI:CreationTitle_Class', MetaModel::GetName($this->sLinkedClass)),
'create' => Dict::Format('UI:ClickToCreateNew', MetaModel::GetName($this->sLinkedClass)),
'remove' => Dict::S('UI:Button:Remove'),
'add' => Dict::Format('UI:AddAnExisting_Class', MetaModel::GetName($this->sLinkedClass)),
'selection_title' => Dict::Format('UI:SelectionOf_Class', MetaModel::GetName($this->sLinkedClass)),
);
$oContext = new ApplicationContext();
$sSubmitUrl = utils::GetAbsoluteUrlAppRoot().'pages/ajax.render.php?'.$oContext->GetForLink();
$sJSONLabels = json_encode($aLabels);
$sJSONButtons = json_encode($aButtons);
$sWizHelper = 'oWizardHelper'.$sFormPrefix;
// Don't automatically launch the search if the table is huge
$bDoSearch = !utils::IsHighCardinality($this->sLinkedClass);
$sJSDoSearch = $bDoSearch ? 'true' : 'false';
$oPage->add_ready_script("$('#{$this->sInputid}').directlinks({class_name: '$this->sClass', att_code: '$this->sAttCode', input_name:'$sInputName', labels: $sJSONLabels, submit_to: '$sSubmitUrl', buttons: $sJSONButtons, oWizardHelper: $sWizHelper, do_search: $sJSDoSearch});");
}
/**
* @param WebPage $oPage
* @param DBObject $oCurrentObj
@@ -433,18 +317,21 @@ HTML
{
}
protected function GetTableConfig()
public function GetTableConfig()
{
$aAttribs = array();
$aAttribs['form::select'] = array('label' => "<input type=\"checkbox\" onClick=\"CheckAll('.selectList{$this->sInputid}:not(:disabled)', this.checked);\" class=\"checkAll\"></input>", 'description' => Dict::S('UI:SelectAllToggle+'));
$aAttribs['form::select'] = array(
'label' => "<input type=\"checkbox\" onClick=\"CheckAll('.selectList{$this->sInputid}:not(:disabled)', this.checked);oWidget".$this->sInputid.".directlinks('instance')._onSelectChange();\" class=\"checkAll\"></input>",
'description' => Dict::S('UI:SelectAllToggle+'),
);
foreach($this->aZlist as $sLinkedAttCode)
{
foreach ($this->aZlist as $sLinkedAttCode) {
$oAttDef = MetaModel::GetAttributeDef($this->sLinkedClass, $sLinkedAttCode);
$aAttribs[$sLinkedAttCode] = array('label' => MetaModel::GetLabel($this->sLinkedClass, $sLinkedAttCode), 'description' => $oAttDef->GetOrderByHint());
}
return $aAttribs;
return $aAttribs;
}
/**
@@ -543,12 +430,43 @@ HTML
{
$sAttCode = call_user_func($aCallSpec, $key); // Returns null when there is no mapping for this parameter
}
if (MetaModel::IsValidAttCode($sDestClass, $sAttCode) && !empty($defaultValue))
{
if (MetaModel::IsValidAttCode($sDestClass, $sAttCode) && !empty($defaultValue)) {
$oSearch->AddCondition($sAttCode, $defaultValue);
}
}
}
}
public function GetClass(): string
{
return $this->sClass;
}
public function GetLinkedClass(): string
{
return $this->sLinkedClass;
}
public function GetAttCode(): string
{
return $this->sAttCode;
}
public function GetInputId(): string
{
return $this->sInputid;
}
public function GetNameSuffix(): string
{
return $this->sNameSuffix;
}
public function GetZList(): array
{
return $this->aZlist;
}
}

View File

@@ -1,23 +1,23 @@
<?php
/*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
use Combodo\iTop\Application\UI\Base\Component\DataTable\DataTableUIBlockFactory;
use Combodo\iTop\Application\UI\Base\Component\DataTable\StaticTable\FormTableRow\FormTableRow;
use Combodo\iTop\Application\UI\Links\Indirect\BlockIndirectLinksEdit\BlockIndirectLinksEdit;
use Combodo\iTop\Application\UI\Links\Indirect\BlockObjectPickerDialog\BlockObjectPickerDialog;
use Combodo\iTop\Application\UI\Links\Indirect\BlockIndirectLinkSetEditTable;
use Combodo\iTop\Application\UI\Links\Indirect\BlockObjectPickerDialog;
use Combodo\iTop\Renderer\Console\ConsoleBlockRenderer;
require_once(APPROOT.'application/displayblock.class.inc.php');
class UILinksWidget
class UILinksWidget
{
protected $m_sClass;
protected $m_sAttCode;
protected $m_sNameSuffix;
protected $m_iInputId;
protected $m_sInputId;
protected $m_aAttributes;
protected $m_sExtKeyToRemote;
protected $m_sExtKeyToMe;
@@ -33,7 +33,7 @@ class UILinksWidget
*
* @param string $sClass
* @param string $sAttCode AttributeLinkedSetIndirect attcode
* @param int $iInputId
* @param string $sInputId
* @param string $sNameSuffix
* @param bool $bDuplicatesAllowed
*
@@ -41,13 +41,14 @@ class UILinksWidget
* @throws \DictExceptionMissingString
* @throws \Exception
*/
public function __construct($sClass, $sAttCode, $iInputId, $sNameSuffix = '', $bDuplicatesAllowed = false)
public function __construct($sClass, $sAttCode, $sInputId, $sNameSuffix = '', $bDuplicatesAllowed = false)
{
$this->m_sClass = $sClass;
$this->m_sAttCode = $sAttCode;
$this->m_sInputId = $sInputId;
$this->m_sNameSuffix = $sNameSuffix;
$this->m_iInputId = $iInputId;
$this->m_bDuplicatesAllowed = $bDuplicatesAllowed;
$this->m_aEditableFields = array();
/** @var AttributeLinkedSetIndirect $oAttDef */
@@ -63,7 +64,7 @@ class UILinksWidget
$this->m_aEditableFields = array();
$this->m_aTableConfig = array();
$this->m_aTableConfig['form::checkbox'] = array(
'label' => "<input class=\"select_all\" type=\"checkbox\" value=\"1\" onClick=\"CheckAll('#linkedset_{$this->m_sAttCode}{$this->m_sNameSuffix} .selection', this.checked); oWidget".$this->m_iInputId.".OnSelectChange();\">",
'label' => "<input class=\"select_all\" type=\"checkbox\" value=\"1\" onClick=\"CheckAll('#linkedset_{$this->m_sAttCode}{$this->m_sNameSuffix} .selection', this.checked); oWidget".$this->m_sInputId.".OnSelectChange();\">",
'description' => Dict::S('UI:SelectAllToggle+'),
);
@@ -91,234 +92,13 @@ class UILinksWidget
}
}
/**
* A one-row form for editing a link record
*
* @param WebPage $oP Web page used for the ouput
* @param DBObject $oLinkedObj Remote object
* @param DBObject|int $linkObjOrId Either the lnk object or a unique number for new link records to add
* @param array $aArgs Extra context arguments
* @param DBObject $oCurrentObj The object to which all the elements of the linked set refer to
* @param int $iUniqueId A unique identifier of new links
* @param boolean $bReadOnly Display link as editable or read-only. Default is false (editable)
*
* @return array The HTML fragment of the one-row form
* @throws \ArchivedObjectException
* @throws \CoreException
* @throws \CoreUnexpectedValue
* @throws \Exception
*/
protected function GetFormRow(WebPage $oP, DBObject $oLinkedObj, $linkObjOrId, $aArgs, $oCurrentObj, $iUniqueId, $bReadOnly = false)
{
$sPrefix = "$this->m_sAttCode{$this->m_sNameSuffix}";
$aRow = array();
$aFieldsMap = array();
$iKey = 0;
if (is_object($linkObjOrId) && (!$linkObjOrId->IsNew()))
{
$iKey = $linkObjOrId->GetKey();
$iRemoteObjKey = $linkObjOrId->Get($this->m_sExtKeyToRemote);
$sPrefix .= "[$iKey][";
$sNameSuffix = "]"; // To make a tabular form
$aArgs['prefix'] = $sPrefix;
$aArgs['wizHelper'] = "oWizardHelper{$this->m_iInputId}{$iKey}";
$aArgs['this'] = $linkObjOrId;
if ($bReadOnly)
{
$aRow['form::checkbox'] = "";
foreach ($this->m_aEditableFields as $sFieldCode)
{
$sDisplayValue = $linkObjOrId->GetEditValue($sFieldCode);
$aRow[$sFieldCode] = $sDisplayValue;
}
}
else
{
$aRow['form::checkbox'] = "<input class=\"selection\" data-remote-id=\"$iRemoteObjKey\" data-link-id=\"$iKey\" data-unique-id=\"$iUniqueId\" type=\"checkbox\" onClick=\"oWidget".$this->m_iInputId.".OnSelectChange();\" value=\"$iKey\">";
foreach ($this->m_aEditableFields as $sFieldCode)
{
$sSafeFieldId = $this->GetFieldId($linkObjOrId->GetKey(), $sFieldCode);
$this->AddRowForFieldCode($aRow, $sFieldCode, $aArgs, $linkObjOrId, $oP, $sNameSuffix, $sSafeFieldId);
$aFieldsMap[$sFieldCode] = $sSafeFieldId;
}
}
$sState = $linkObjOrId->GetState();
$sRemoteKeySafeFieldId = $this->GetFieldId($aArgs['this']->GetKey(), $this->m_sExtKeyToRemote);;
}
else
{
// form for creating a new record
if (is_object($linkObjOrId))
{
// New link existing only in memory
$oNewLinkObj = $linkObjOrId;
$iRemoteObjKey = $oNewLinkObj->Get($this->m_sExtKeyToRemote);
$oNewLinkObj->Set($this->m_sExtKeyToMe,
$oCurrentObj); // Setting the extkey with the object also fills the related external fields
}
else
{
$iRemoteObjKey = $linkObjOrId;
$oNewLinkObj = MetaModel::NewObject($this->m_sLinkedClass);
$oRemoteObj = MetaModel::GetObject($this->m_sRemoteClass, $iRemoteObjKey);
$oNewLinkObj->Set($this->m_sExtKeyToRemote,
$oRemoteObj); // Setting the extkey with the object alsoo fills the related external fields
$oNewLinkObj->Set($this->m_sExtKeyToMe,
$oCurrentObj); // Setting the extkey with the object also fills the related external fields
}
$sPrefix .= "[-$iUniqueId][";
$sNameSuffix = "]"; // To make a tabular form
$aArgs['prefix'] = $sPrefix;
$aArgs['wizHelper'] = "oWizardHelper{$this->m_iInputId}_".($iUniqueId < 0 ? -$iUniqueId : $iUniqueId);
$aArgs['this'] = $oNewLinkObj;
$sInputValue = $iUniqueId > 0 ? "-$iUniqueId" : "$iUniqueId";
$aRow['form::checkbox'] = "<input class=\"selection\" data-remote-id=\"$iRemoteObjKey\" data-link-id=\"0\" data-unique-id=\"$iUniqueId\" type=\"checkbox\" onClick=\"oWidget".$this->m_iInputId.".OnSelectChange();\" value=\"$sInputValue\">";
if ($iUniqueId > 0)
{
// Rows created with ajax call need OnLinkAdded call.
//
$oP->add_ready_script(
<<<EOF
PrepareWidgets();
oWidget{$this->m_iInputId}.OnLinkAdded($iUniqueId, $iRemoteObjKey);
EOF
);
}
else
{
// Rows added before loading the form don't have to call OnLinkAdded.
// Listeners are already present and DOM is not recreated
$iPositiveUniqueId = -$iUniqueId;
$oP->add_ready_script(<<<EOF
oWidget{$this->m_iInputId}.AddLink($iPositiveUniqueId, $iRemoteObjKey);
EOF
);
}
foreach($this->m_aEditableFields as $sFieldCode)
{
$sSafeFieldId = $this->GetFieldId($iUniqueId, $sFieldCode);
$this->AddRowForFieldCode($aRow, $sFieldCode, $aArgs, $oNewLinkObj, $oP, $sNameSuffix, $sSafeFieldId);
$aFieldsMap[$sFieldCode] = $sSafeFieldId;
$sValue = $oNewLinkObj->Get($sFieldCode);
$oP->add_ready_script(
<<<JS
oWidget{$this->m_iInputId}.OnValueChange($iKey, $iUniqueId, '$sFieldCode', '$sValue');
JS
);
}
$sState = '';
$sRemoteKeySafeFieldId = $this->GetFieldId($iUniqueId, $this->m_sExtKeyToRemote);
}
if (!$bReadOnly)
{
$sExtKeyToMeId = utils::GetSafeId($sPrefix.$this->m_sExtKeyToMe);
$aFieldsMap[$this->m_sExtKeyToMe] = $sExtKeyToMeId;
$aRow['form::checkbox'] .= "<input type=\"hidden\" id=\"$sExtKeyToMeId\" value=\"".$oCurrentObj->GetKey()."\">";
$sExtKeyToRemoteId = utils::GetSafeId($sPrefix.$this->m_sExtKeyToRemote);
$aFieldsMap[$this->m_sExtKeyToRemote] = $sExtKeyToRemoteId;
$aRow['form::checkbox'] .= "<input type=\"hidden\" id=\"$sExtKeyToRemoteId\" value=\"$iRemoteObjKey\">";
}
// Adding fields from remote class
// all fields are embedded in a span + added to $aFieldsMap array so that we can refresh them after extkey change
$aRemoteFieldsMap = [];
foreach (MetaModel::GetZListItems($this->m_sRemoteClass, 'list') as $sFieldCode)
{
$sSafeFieldId = $this->GetFieldId($aArgs['this']->GetKey(), $sFieldCode);
$aRow['static::'.$sFieldCode] = "<span id='field_$sSafeFieldId'>".$oLinkedObj->GetAsHTML($sFieldCode).'</span>';
$aRemoteFieldsMap[$sFieldCode] = $sSafeFieldId;
}
// id field is needed so that remote object could be load server side
$aRemoteFieldsMap['id'] = $sRemoteKeySafeFieldId;
// Generate WizardHelper to update dependant fields
$this->AddWizardHelperInit($oP, $aArgs['wizHelper'], $this->m_sLinkedClass, $sState, $aFieldsMap);
//instantiate specific WizarHelper instance for remote class fields refresh
$bHasExtKeyUpdatingRemoteClassFields = (
array_key_exists('replaceDependenciesByRemoteClassFields', $aArgs)
&& ($aArgs['replaceDependenciesByRemoteClassFields'])
);
if ($bHasExtKeyUpdatingRemoteClassFields)
{
$this->AddWizardHelperInit($oP, $aArgs['wizHelperRemote'], $this->m_sRemoteClass, $sState, $aRemoteFieldsMap);
}
return $aRow;
}
private function AddRowForFieldCode(&$aRow, $sFieldCode, &$aArgs, $oLnk, $oP, $sNameSuffix, $sSafeFieldId): void
{
if (($sFieldCode === $this->m_sExtKeyToRemote))
{
// current field is the lnk extkey to the remote class
$aArgs['replaceDependenciesByRemoteClassFields'] = true;
$sRowFieldCode = 'static::key';
$aArgs['wizHelperRemote'] = $aArgs['wizHelper'].'_remote';
$aRemoteAttDefs = MetaModel::GetZListAttDefsFilteredForIndirectRemoteClass($this->m_sRemoteClass);
$aRemoteCodes = array_map(
function ($value) {
return $value->GetCode();
},
$aRemoteAttDefs
);
$aArgs['remoteCodes'] = $aRemoteCodes;
}
else
{
$aArgs['replaceDependenciesByRemoteClassFields'] = false;
$sRowFieldCode = $sFieldCode;
}
$sValue = $oLnk->Get($sFieldCode);
$sDisplayValue = $oLnk->GetEditValue($sFieldCode);
$oAttDef = MetaModel::GetAttributeDef($this->m_sLinkedClass, $sFieldCode);
$aRow[$sRowFieldCode] = '<div class="field_container" style="border:none;"><div class="field_data"><div class="field_value">'
.cmdbAbstractObject::GetFormElementForField(
$oP,
$this->m_sLinkedClass,
$sFieldCode,
$oAttDef,
$sValue,
$sDisplayValue,
$sSafeFieldId,
$sNameSuffix,
0,
$aArgs
)
.'</div></div></div>';
}
private function GetFieldId($iLnkId, $sFieldCode, $bSafe = true)
{
$sFieldId = $this->m_iInputId.'_'.$sFieldCode.'['.$iLnkId.']';
$sFieldId = $this->m_sInputId.'_'.$sFieldCode.'['.$iLnkId.']';
return ($bSafe) ? utils::GetSafeId($sFieldId) : $sFieldId;
}
private function AddWizardHelperInit($oP, $sWizardHelperVarName, $sWizardHelperClass, $sState, $aFieldsMap): void
{
$iFieldsCount = count($aFieldsMap);
$sJsonFieldsMap = json_encode($aFieldsMap);
$oP->add_script(
<<<JS
var $sWizardHelperVarName = new WizardHelper('$sWizardHelperClass', '', '$sState');
$sWizardHelperVarName.SetFieldsMap($sJsonFieldsMap);
$sWizardHelperVarName.SetFieldsCount($iFieldsCount);
$sWizardHelperVarName.SetReturnNotEditableFields(true);
$sWizardHelperVarName.SetWizHelperJsVarName('$sWizardHelperVarName');
JS
);
}
/**
* Display the table with the form for editing all the links at once
@@ -356,92 +136,12 @@ JS
*/
public function Display(WebPage $oPage, $oValue, $aArgs, $sFormPrefix, $oCurrentObj): string
{
$sLinkedSetId = "{$this->m_sAttCode}{$this->m_sNameSuffix}";
$oBlock = new BlockIndirectLinksEdit("linkedset_{$sLinkedSetId}", ["ibo-block-indirect-links--edit"]);
$oBlock->sLinkedSetId = $sLinkedSetId;
$oBlock->sClass = $this->m_sClass;
$oBlock->sAttCode = $this->m_sAttCode;
$oBlock->iInputId = $this->m_iInputId;
$oBlock->sNameSuffix = $this->m_sNameSuffix;
$oBlock->bDuplicates = ($this->m_bDuplicatesAllowed) ? 'true' : 'false';
$oBlock->oWizHelper = 'oWizardHelper'.$sFormPrefix;
$oBlock->sExtKeyToRemote = $this->m_sExtKeyToRemote;
// Don't automatically launch the search if the table is huge
$oBlock->bJSDoSearch = utils::IsHighCardinality($this->m_sRemoteClass) ? 'false' : 'true';
$oBlock->sFormPrefix = $sFormPrefix;
$oBlock->sRemoteClass = $this->m_sRemoteClass;
$oValue->Rewind();
$aForm = array();
$iMaxAddedId = 0;
$iAddedId = -1; // Unique id for new links
$oBlock->aRemoved = json_decode(utils::ReadPostedParam("attr_{$sFormPrefix}{$this->m_sAttCode}_tbd", '[]', 'raw_data'));
while ($oCurrentLink = $oValue->Fetch()) {
// We try to retrieve the remote object as usual
if (!in_array($oCurrentLink->GetKey(), $oBlock->aRemoved)) {
$oLinkedObj = MetaModel::GetObject($this->m_sRemoteClass, $oCurrentLink->Get($this->m_sExtKeyToRemote), false /* Must not be found */);
// If successful, it means that we can edit its link
if ($oLinkedObj !== null) {
$bReadOnly = false;
} // Else we retrieve it without restrictions (silos) and will display its link as readonly
else {
$bReadOnly = true;
$oLinkedObj = MetaModel::GetObject($this->m_sRemoteClass, $oCurrentLink->Get($this->m_sExtKeyToRemote), false /* Must not be found */, true);
}
if ($oCurrentLink->IsNew()) {
$key = $iAddedId--;
} else {
$key = $oCurrentLink->GetKey();
}
$iMaxAddedId = max($iMaxAddedId, $key);
$aForm[$key] = $this->GetFormRow($oPage, $oLinkedObj, $oCurrentLink, $aArgs, $oCurrentObj, $key, $bReadOnly);
}
}
$oBlock->iMaxAddedId = (int)$iMaxAddedId;
$oDataTable = DataTableUIBlockFactory::MakeForForm("{$this->m_sAttCode}{$this->m_sNameSuffix}", $this->m_aTableConfig, $aForm);
$oDataTable->SetOptions(['select_mode' => 'custom', 'disable_hyperlinks' => true]);
$oBlock->AddSubBlock($oDataTable);
$oBlock->AddControls();
$oBlock = new BlockIndirectLinkSetEditTable($this);
$oBlock->InitTable($oPage, $oValue, $aArgs, $sFormPrefix, $oCurrentObj, $this->m_aTableConfig);
return ConsoleBlockRenderer::RenderBlockTemplateInPage($oPage, $oBlock);
}
/**
* @param string $sClass
* @param string $sAttCode
*
* @return string
* @throws \Exception
*/
protected static function GetTargetClass($sClass, $sAttCode)
{
/** @var AttributeLinkedSet $oAttDef */
$oAttDef = MetaModel::GetAttributeDef($sClass, $sAttCode);
$sLinkedClass = $oAttDef->GetLinkedClass();
$sTargetClass = '';
switch(get_class($oAttDef))
{
case 'AttributeLinkedSetIndirect':
/** @var AttributeExternalKey $oLinkingAttDef */
/** @var AttributeLinkedSetIndirect $oAttDef */
$oLinkingAttDef = MetaModel::GetAttributeDef($sLinkedClass, $oAttDef->GetExtKeyToRemote());
$sTargetClass = $oLinkingAttDef->GetTargetClass();
break;
case 'AttributeLinkedSet':
$sTargetClass = $sLinkedClass;
break;
}
return $sTargetClass;
}
/**
* @param WebPage $oPage
* @param DBObject $oCurrentObj
@@ -471,15 +171,10 @@ JS
$oCurrentObj->PrefillForm('search', $aPrefillFormParam);
}
$sLinkedSetId = "{$this->m_sAttCode}{$this->m_sNameSuffix}";
$oBlock = new BlockObjectPickerDialog();
$oBlock = new BlockObjectPickerDialog($this);
$oPage->AddUiBlock($oBlock);
$oBlock->sLinkedSetId = $sLinkedSetId;
$oBlock->iInputId = $this->m_iInputId;
$oBlock->sLinkedClassName = MetaModel::GetName($this->m_sLinkedClass);
$oBlock->sClassName = MetaModel::GetName($this->m_sClass);
$sLinkedSetId = $oBlock->oUILinksWidget->GetLinkedSetId();
$oDisplayBlock = new DisplayBlock($oFilter, 'search', false);
$oBlock->AddSubBlock($oDisplayBlock->GetDisplay($oPage, "SearchFormToAdd_{$sLinkedSetId}",
@@ -548,7 +243,8 @@ JS
foreach ($aLinkedObjectIds as $iObjectId) {
$oLinkedObj = MetaModel::GetObject($this->m_sRemoteClass, $iObjectId, false);
if (is_object($oLinkedObj)) {
$aRow = $this->GetFormRow($oP, $oLinkedObj, $iObjectId, array(), $oCurrentObj, $iAdditionId); // Not yet created link get negative Ids
$oBlock = new BlockIndirectLinkSetEditTable($this);
$aRow = $oBlock->GetFormRow($oP, $oLinkedObj, $iObjectId, array(), $oCurrentObj, $iAdditionId); // Not yet created link get negative Ids
$oRow = new FormTableRow("{$this->m_sAttCode}{$this->m_sNameSuffix}", $this->m_aTableConfig, $aRow, -$iAdditionId);
$oP->AddUiBlock($oRow);
$iAdditionId++;
@@ -572,10 +268,12 @@ JS
$aLinkedObjectIds = utils::ReadMultipleSelection($oFullSetFilter);
$iAdditionId = $iMaxAddedId + 1;
$bAllowRemoteExtKeyEdit = count($aLinkedObjectIds) <= utils::GetConfig()->Get('link_set_max_edit_ext_key');
foreach ($aLinkedObjectIds as $iObjectId) {
$oLinkedObj = MetaModel::GetObject($this->m_sRemoteClass, $iObjectId, false);
if (is_object($oLinkedObj)) {
$aRow = $this->GetFormRow($oP, $oLinkedObj, $iObjectId, array(), $oCurrentObj, $iAdditionId); // Not yet created link get negative Ids
$oBlock = new BlockIndirectLinkSetEditTable($this);
$aRow = $oBlock->GetFormRow($oP, $oLinkedObj, $iObjectId, array(), $oCurrentObj, $iAdditionId, false /* Default value */, $bAllowRemoteExtKeyEdit); // Not yet created link get negative Ids
$aData = [];
foreach ($aRow as $item) {
$aData[] = $item;
@@ -636,24 +334,77 @@ JS
/** @var AttributeExternalKey $oAttDef */
$sTargetClass = $oAttDef->GetTargetClass();
$sHierarchicalKeyCode = MetaModel::IsHierarchicalClass($sTargetClass);
if ($sHierarchicalKeyCode !== false)
{
if ($sHierarchicalKeyCode !== false) {
$oFilter = new DBObjectSearch($sTargetClass);
$oFilter->AddCondition('id', $defaultValue);
$oHKFilter = new DBObjectSearch($sTargetClass);
$oHKFilter->AddCondition_PointingTo($oFilter, $sHierarchicalKeyCode, TREE_OPERATOR_BELOW);
$oSearch->AddCondition_PointingTo($oHKFilter, $sAttCode);
}
} catch (Exception $e)
{
}
}
else
{
catch (Exception $e) {
}
} else {
$oSearch->AddCondition($sAttCode, $defaultValue);
}
}
}
}
}
public function GetLinkedSetId(): string
{
return "{$this->m_sAttCode}{$this->m_sNameSuffix}";
}
public function GetClass(): string
{
return $this->m_sClass;
}
public function GetLinkedClass(): string
{
return $this->m_sLinkedClass;
}
public function GetAttCode(): string
{
return $this->m_sAttCode;
}
public function GetInputId(): string
{
return $this->m_sInputId;
}
public function GetNameSuffix(): string
{
return $this->m_sNameSuffix;
}
public function IsDuplicatesAllowed(): bool
{
return $this->m_bDuplicatesAllowed;
}
public function GetExternalKeyToRemote(): string
{
return $this->m_sExtKeyToRemote;
}
public function GetExternalKeyToMe(): string
{
return $this->m_sExtKeyToMe;
}
public function GetRemoteClass(): string
{
return $this->m_sRemoteClass;
}
public function GetEditableFields(): array
{
return $this->m_aEditableFields;
}
}

View File

@@ -1,5 +1,5 @@
<?php
// Copyright (C) 2010-2021 Combodo SARL
// Copyright (C) 2010-2023 Combodo SARL
//
// This file is part of iTop.
//
@@ -20,7 +20,7 @@
* Class UIPasswordWidget
* UI wdiget for displaying and editing one-way encrypted passwords
*
* @copyright Copyright (C) 2010-2021 Combodo SARL
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/

View File

@@ -1,7 +1,7 @@
<?php
/**
*
* Copyright (C) 2010-2021 Combodo SARL
* Copyright (C) 2010-2023 Combodo SARL
*
* This file is part of iTop.
*
@@ -60,7 +60,7 @@ class UISearchFormForeignKeys
$oPage->add(<<<HTML
<form id="ObjectsAddForm_{$this->m_iInputId}">
<div id="SearchResultsToAdd_{$this->m_iInputId}" style="vertical-align:top;background: #fff;height:100%;overflow:auto;padding:0;border:0;">
<div id="SearchResultsToAdd_{$this->m_iInputId}" style="vertical-align:top;height:100%;overflow:auto;padding:0;border:0;">
<div style="background: #fff; border:0; text-align:center; vertical-align:middle;"><p>{$sEmptyList}</p></div>
</div>
<input type="hidden" id="count_{$this->m_iInputId}" value="0"/>

Some files were not shown because too many files have changed in this diff Show More