auto-commit via WEVIA vault_git intent 2026-04-18T14:52:19+00:00
Some checks failed
WEVAL NonReg / nonreg (push) Has been cancelled

This commit is contained in:
opus
2026-04-18 16:52:19 +02:00
parent 55a4cbe800
commit 305c6a7db4
3 changed files with 37 additions and 5 deletions

View File

@@ -0,0 +1,21 @@
<?php
header('Content-Type: application/json');
$host = '10.1.0.3'; $port = '5432'; $db = 'adx_system'; $user = 'admin'; $pass = 'admin123';
$pdo = null;
try {
$pdo = new PDO("pgsql:host=$host;port=$port;dbname=$db", $user, $pass);
$pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
} catch (Exception $e) {
echo json_encode(['ok'=>false,'error'=>$e->getMessage()]); exit;
}
$rows = $pdo->query("SELECT pays, COUNT(*) AS c FROM ethica.medecins_real GROUP BY pays ORDER BY c DESC")->fetchAll(PDO::FETCH_ASSOC);
$total = array_sum(array_column($rows, 'c'));
echo json_encode([
'ok' => true,
'ts' => date('c'),
'table' => 'ethica.medecins_real',
'total_hcps' => (int)$total,
'by_country' => array_map(fn($r)=>['pays'=>$r['pays'] ?: 'UNKNOWN','count'=>(int)$r['c'],'pct'=>round($r['c']*100/max(1,$total),1)], $rows),
'summary' => count($rows) . ' pays'
], JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE);

View File

@@ -1626,5 +1626,17 @@
"status": "PENDING_SECURITY_REVIEW",
"created_at": "2026-04-18T14:51:38+00:00",
"source": "opus4-autowire-early-v2"
},
"130": {
"name": "hcp_par_pays",
"triggers": [
"hcp par pays",
"hcp by country",
"ethica par pays"
],
"cmd": "curl -sk https:\/\/weval-consulting.com\/api\/ethica-hcp-by-country.php",
"status": "PENDING_APPROVAL",
"created_at": "2026-04-18T14:52:18+00:00",
"source": "opus4-autowire-early-v2"
}
}

View File

@@ -5,11 +5,10 @@ return array (
array (
0 => 'hcp par pays',
1 => 'hcp by country',
2 => 'combien hcp par pays',
3 => 'ethica par pays',
2 => 'ethica par pays',
),
'cmd' => 'pgpassword=admin123 psql -u admin -h 10.1.0.3 -d adx_system -c "select country_code, count(*) from ethica.medecins_real group by country_code order by 2 desc"',
'status' => 'PENDING_SECURITY_REVIEW',
'created_at' => '2026-04-18T14:51:38+00:00',
'cmd' => 'curl -sk https://weval-consulting.com/api/ethica-hcp-by-country.php',
'status' => 'PENDING_APPROVAL',
'created_at' => '2026-04-18T14:52:18+00:00',
'source' => 'opus4-autowire-early-v2',
);