Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Privzete konstrukcije #4

Merged
merged 8 commits into from
Sep 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
192 changes: 192 additions & 0 deletions config/TSGKonstrukcije.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,192 @@
[
{
"id": "2.1",
"sifra": "opeka",
"opis": "Mrežasta in votla opeka",
"lambda": 0.61,
"gostota": 1400,
"specificnaToplota": 920,
"difuzijskaUpornost": 6
},
{
"id": "2.2",
"sifra": "termoOpeka",
"opis": "Mrežasta in votla opeka",
"lambda": 0.23,
"gostota": 1400,
"specificnaToplota": 920,
"difuzijskaUpornost": 6
},
{
"id": "21",
"sifra": "cementnoLepilo",
"opis": "Cementna malta",
"lambda": 1.4,
"gostota": 2100,
"specificnaToplota": 1050,
"difuzijskaUpornost": 30
},
{
"id": "22",
"sifra": "estrih",
"opis": "Cementni estrih",
"lambda": 1.4,
"gostota": 2200,
"specificnaToplota": 1050,
"difuzijskaUpornost": 30
},
{
"id": "23",
"sifra": "fasadniSloj",
"opis": "Pigmentna fasadna malta",
"lambda": 0.7,
"gostota": 1850,
"specificnaToplota": 1050,
"difuzijskaUpornost": 15
},
{
"id": "25",
"sifra": "omet",
"opis": "Mavčna in apneno mavčna malta",
"lambda": 0.7,
"gostota": 1050,
"specificnaToplota": 920,
"difuzijskaUpornost": 9
},
{
"id": "37",
"sifra": "tampon",
"opis": "Gramoz, suh",
"lambda": 0.81,
"gostota": 1700,
"specificnaToplota": 840,
"difuzijskaUpornost": 1.4
},
{
"id": "44",
"sifra": "beton",
"opis": "Beton s kamnitimi agregati",
"lambda": 2.04,
"gostota": 2400,
"specificnaToplota": 960,
"difuzijskaUpornost": 60
},
{
"id": "50.1",
"sifra": "MKplosce",
"opis": "Mavčno-kartonske plošče do 15mm",
"lambda": 0.21,
"gostota": 900,
"specificnaToplota": 840,
"difuzijskaUpornost": 12
},
{
"id": "56.2",
"sifra": "keramika",
"opis": "Keramične ploščice, talne, neglazirane",
"lambda": 1.28,
"gostota": 2300,
"specificnaToplota": 920,
"difuzijskaUpornost": 200
},
{
"id": "68.3",
"sifra": "les",
"opis": "Les smreka, bor",
"lambda": 0.14,
"gostota": 550,
"specificnaToplota": 2090,
"difuzijskaUpornost": 70
},
{
"id": "78",
"sifra": "vinil",
"opis": "PVC, homogen",
"lambda": 0.23,
"gostota": 1400,
"specificnaToplota": 960,
"difuzijskaUpornost": 10000
},
{
"id": "85",
"sifra": "PEfolija",
"opis": "Polietilenske folije",
"lambda": 0.19,
"gostota": 1000,
"specificnaToplota": 1250,
"difuzijskaUpornost": 80000
},
{
"id": "91.2",
"sifra": "hidroizolacija",
"opis": "Večplastna bitumenska hidroizolacija",
"lambda": 0.19,
"gostota": 1200,
"specificnaToplota": 1460,
"difuzijskaUpornost": 14000
},
{
"id": "113.4",
"sifra": "EPS100",
"opis": "EPS 100",
"lambda": 0.039,
"gostota": 15,
"specificnaToplota": 1260,
"difuzijskaUpornost": 25
},
{
"id": "114",
"sifra": "EPSNeo",
"opis": "EPS F grafitni",
"lambda": 0.031,
"gostota": 15,
"specificnaToplota": 1260,
"difuzijskaUpornost": 25
},
{
"id": "120.1",
"sifra": "XPS",
"opis": "Ekstrudirani polistiren (XPS)",
"lambda": 0.035,
"gostota": 33,
"specificnaToplota": 1500,
"difuzijskaUpornost": 50
},
{
"id": "126.5",
"sifra": "kamenaVolna",
"opis": "Mineralna kamena volna",
"lambda": 0.034,
"gostota": 80,
"specificnaToplota": 1030,
"difuzijskaUpornost": 1
},

{
"id": "00.1",
"sifra": "paropropustnaFolija",
"opis": "Paropropustna folija",
"lambda": 0.22,
"gostota": 250,
"specificnaToplota": 1700,
"difuzijskaUpornost": 40
},
{
"id": "00.2",
"sifra": "parnaZapora",
"opis": "Parna zapora",
"lambda": 0.19,
"gostota": 964,
"specificnaToplota": 1700,
"difuzijskaUpornost": 526000
},
{
"id": "00.3",
"sifra": "OSB",
"opis": "OSB3 plošča",
"lambda": 0.13,
"gostota": 600,
"specificnaToplota": 2100,
"difuzijskaUpornost": 200
}
]
12 changes: 11 additions & 1 deletion config/app_default.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,17 @@
'className' => \Monolog\Formatter\LineFormatter::class,
'format' => "%message%\n",
],
'file' => /*'php://stderr', */LOGS . 'debug.log',
'file' => 'php://stderr', /*LOGS . 'debug.log',*/
'level' => \Monolog\Logger::INFO,
'cli' => true,
],
'error' => [
'className' => \Monolog\Handler\StreamHandler::class,
'formatter' => [
'className' => \Monolog\Formatter\LineFormatter::class,
'format' => "%datetime% > %level_name% > %message% %context% %extra%\n%context.exception%\n",
],
'file' => LOGS . 'error.log',
'level' => \Monolog\Logger::ERROR,
],
],
Expand Down
7 changes: 4 additions & 3 deletions config/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,19 +28,20 @@

// Display exceptions
function echo_exception_handler($e) {
echo sprintf('Uncaught Exception %s: "%s" at %s line %s', get_class($e), $e->getMessage(), $e->getFile(), $e->getLine());
printf('Uncaught Exception %s: "%s" in %s:%s', get_class($e), $e->getMessage(), $e->getFile(), $e->getLine());
}

if (Configure::read('debug')) {
error_reporting(E_ALL);
ini_set('display_errors', true);
// set_exception_handler('echo_exception_handler');
} else {
set_exception_handler('echo_exception_handler');
}


// Handle php error logs with monolog
$logger = Log::getInstance()->getLogger();
//ErrorHandler::register($logger);
ErrorHandler::register($logger);

/**
* Set server timezone to UTC. You can change it to another timezone of your
Expand Down
5 changes: 5 additions & 0 deletions config/paths.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,8 @@
* Path to the schemas directory.
*/
define('SCHEMAS', ROOT . DS . 'schemas' . DS);

/**
* Path to the resources directory.
*/
define('RESOURCES', ROOT . DS . 'resources' . DS);
43 changes: 28 additions & 15 deletions schemas/netransparentneSchema.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,34 @@
"materiali": {
"type": "array",
"items": {
"type": "object",
"required": ["opis"],
"oneOf": [
{"required": ["Sd"]},
{"required": ["debelina", "difuzijskaUpornost"]}
],
"properties": {
"opis": {"type": "string"},
"debelina": {"type": "number"},
"lambda": {"type": "number"},
"gostota": {"type": "number"},
"specificnaToplota": {"type": "number"},
"difuzijskaUpornost": {"type": "number"},
"Sd": {"type": "number"}
}
"anyOf": [
{
"type": "object",
"required": ["opis"],
"oneOf": [
{"required": ["Sd"]},
{"required": ["debelina", "difuzijskaUpornost"]}
],
"properties": {
"opis": {"type": "string"},
"debelina": {"type": "number"},
"lambda": {"type": "number"},
"gostota": {"type": "number"},
"specificnaToplota": {"type": "number"},
"difuzijskaUpornost": {"type": "number"},
"Sd": {"type": "number"}
}
},
{
"type": "object",
"required": ["sifra"],
"properties": {
"sifra": {"type": "string"},
"debelina": {"type": "number"},
"lambda": {"type": "number"}
}
}
]
}
}
}
Expand Down
Loading