`
let appendEventBlock = `
<a href="${eventDetailsUlr}" style="font-size: 16px; color: blue">${scheduledDate}</a>
<br />
<span>@localizator["Executor"]: ${event.executor.firstName} ${event.executor.lastName}</span>
<span class="text-muted text-break">@localizator["Note"]: ${event.note}</span>
`;
document.getElementById(appendEventContainer).innerHTML += appendEventBlock;
<?php
//структуируем
$obj=array();
foreach($data as $item){
$obj[$item['number']][] = array('id'=>$item['id'], 'value'=>$item['value'], 'name'=>$item['name']);
}
//сортировка
foreach($obj as $key => $value){
$val = array_column($obj[$key], 'value');
array_multisort($val, SORT_ASC, $obj[$key]);
}
?>
var jeD=<?php echo json_encode($obj);?>;
var jeD={
"1": [
{
"id": 4,
"value": 22,
"name": "GGU"
},
{
"id": 2,
"value": 43,
"name": "GGP"
}
],
"2": [
{
"id": 56,
"value": 13,
"name": "PLINT"
},
{
"id": 55,
"value": 95,
"name": "PLVAl"
},
{
"id": 59,
"value": 133,
"name": "BARG"
}
]
};