TiersService :: GetListSalarie
The POST method, is used to retrieve data.
The list of parameters is not mandatory to request:
- Criteria criteria,
- array orders,
- int pageNumber,
- int rowsPerPage.
Returns data as JSON, for use in PHP, you need to convert JSON in StdClass PHP (PHP function: json_decode ()).
Input parameters:
- Criteria
{"criteria":
{
"__type":"CriteriaLogical:http://www.proconsult.lu/WebServices100",
"Operand1":
{
"__type":"CriteriaComparison:http://www.proconsult.lu/WebServices100",
"FieldName": "Pays",
"Operator": "0",
"Value": "Belgique"
},
"Operator":0
}
}
- orders
{"orders":[{"Ville":"Asc"}]}- pageNumber
{pageNumber: 1}- rowsPerPage
{rowsPerPage: 10}
Example:
require (__DIR__ . '/service/Criteria.php');
use services\WebServices100;
use services\Criteria;
// add parameters
$response = new Criteria();
$response->setType('CriteriaLogical:http://www.proconsult.lu/WebServices100');
$response->setFieldName('Pays');
$response->setOperator("0");
$response->setValue("Belgique");
$response->setOperand(
[
'Operand1' => [
'__type' => 'CriteriaComparison:http://www.proconsult.lu/WebServices100',
'FieldName' => 'Pays',
'Operator' => '0',
'Value' => 'Belgique']
);
$url = 'http://<Your ip>:<Your Port>/WebServices100/<Your environment>/TiersService/rest/GetListSalarie';
$data = $response->getResponse();
// Send requests to receive data
$result = WebServices100::getData($url, $data)));
$response = json_decode($result);
Result:
Array
(
[0] => stdClass Object
(
[TypeTiers] => 2
[NumeroTiers] => BRILLE
[NumeroTiersPayeur] => BRILLE
[IdCategorieComptable] => 1
[IdCategorieTarifaire] => 1
[IdConditionLivraison] => 1
[IdModeExpedition] => 1
[IdModeleReglement] => 0
[Intitule] => BRILLE Carmen
[Qualite] =>
[Abrege] => BRILLE Carmen
[Contact] =>
[CompteCollectif] => 421LYON
[Adresse] => 65, Impasse J.LURRY
[Complement] =>
[CodePostal] => 69000
[Ville] => LYON
[Region] =>
[Pays] =>
[Telephone] =>
[Fax] =>
[Email] =>
[SiteWeb] =>
[NumeroSiret] =>
[NumeroTva] =>
[CodeEdi] =>
[CodeNAF] =>
[Commentaire] =>
[Langue] => 0
[EstEnSommeil] =>
[InfosLibres] => Array
(
[0] => stdClass Object
(
[Name] => Date création société
[Type] => 2
[Size] => 0
[EstCalculee] =>
[Value] =>
)
[1] => stdClass Object
(
[Name] => Capital social
[Type] => 3
[Size] => 0
[EstCalculee] =>
[Value] =>
)
[2] => stdClass Object
(
[Name] => Actionnaire Pal
[Type] => 0
[Size] => 69
[EstCalculee] =>
[Value] =>
)
[3] => stdClass Object
(
[Name] => Score Banque de France
[Type] => 0
[Size] => 14
[EstCalculee] =>
[Value] =>
)
[4] => stdClass Object
(
[Name] => Total points fidélité
[Type] => 3
[Size] => 0
[EstCalculee] => 1
[Value] =>
)
[5] => stdClass Object
(
[Name] => Points fidélité restants
[Type] => 3
[Size] => 0
[EstCalculee] => 1
[Value] =>
)
[6] => stdClass Object
(
[Name] => Fin validité carte fidélité
[Type] => 1
[Size] => 0
[EstCalculee] =>
[Value] =>
)
[7] => stdClass Object
(
[Name] => Date négociation règlement
[Type] => 2
[Size] => 0
[EstCalculee] =>
[Value] =>
)
)
)
)