Skip to content

Commit

Permalink
Version 0.51
Browse files Browse the repository at this point in the history
  • Loading branch information
Ronef committed Nov 8, 2021
2 parents f8db333 + 3e320eb commit a7ce175
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 4 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# (MODX)EvolutionCMS.libraries.ddTools changelog


## Version 0.51 (2021-11-08)
* \+ `\DDTools\ObjectTools::convertType`: Added the ability to return `stringQueryFormated`.


## Version 0.50 (2021-05-11)
* \+ `\DDTools\Response`:
* \+ `setMetaData`: The new public method. Setter for `$this->meta` and `$this->data`.
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG_ru.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# (MODX)EvolutionCMS.libraries.ddTools changelog


## Версия 0.51 (2021-11-08)
* \+ `\DDTools\ObjectTools::convertType`: Добавлена возможность конвертировать в `stringQueryFormated`.


## Версия 0.50 (2021-05-11)
* \+ `\DDTools\Response`:
* \+ `setMetaData`: Новый публичный метод. Сеттер для `$this->meta` и `$this->data`.
Expand Down
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ Arrays, [JSON](https://en.wikipedia.org/wiki/JSON) and [Query string](https://en
* `stringJsonArray` — [JSON](https://en.wikipedia.org/wiki/JSON) array
* `stringHjsonObject` — [HJSON](https://hjson.github.io/) object
* `stringHjsonArray` — [HJSON](https://hjson.github.io/) array
* `stringQueryFormated`
* `stringQueryFormated` — [Query string](https://en.wikipedia.org/wiki/Query_string)
* **Required**

* `$params->type`
Expand All @@ -343,6 +343,7 @@ Arrays, [JSON](https://en.wikipedia.org/wiki/JSON) and [Query string](https://en
* `'stringJsonAuto'` — `stringJsonObject` or `stringJsonArray` depends on input object
* `'stringJsonObject'`
* `'stringJsonArray'`
* `'stringQueryFormated'`
* Default value: `'objectAuto'`


Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "dd/evolutioncms-libraries-ddtools",
"type": "modxevo-library-ddtools",
"version": "0.50.0",
"version": "0.51.0",
"description": "A library with various tools facilitating your work.",
"keywords": [
"modx",
Expand Down
2 changes: 1 addition & 1 deletion modx.ddtools.class.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
/**
* EvolutionCMS.libraries.ddTools
* @version 0.50 (2021-05-11)
* @version 0.51 (2021-11-08)
*
* @see README.md
*
Expand Down
5 changes: 4 additions & 1 deletion src/ObjectTools/ObjectTools.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public static function getPropValue($params){

/**
* convertType
* @version 1.1 (2021-03-20)
* @version 1.2 (2021-11-08)
*
* @see README.md
*/
Expand Down Expand Up @@ -166,6 +166,9 @@ public static function convertType($params){
//array
}elseif ($params->type == 'objectarray'){
$result = (array) $result;
//stringQueryFormated
}elseif ($params->type == 'stringqueryformated'){
$result = http_build_query($result);
//stringJson
}elseif(
substr(
Expand Down

0 comments on commit a7ce175

Please sign in to comment.