protected function generatePDF($content, $filename, $config = []) {
        unset($config['contentBefore'], $config['contentAfter']);
        $config = array_replace_recursive([
            // set to use core fonts only
            'mode' => Pdf::MODE_UTF8,
            // set mPDF properties on the fly
            'options' => [
                'autoLangToFont' => true,
                'autoScriptToLang' => true,
                'autoVietnamese' => true,
                'autoArabic' => true,
            ],
            // call mPDF methods on the fly
            'methods' => [
                'SetFooter' => ['{PAGENO}'],
            ]
                ], $config);
        $config['filename'] = $filename;
        $config['methods']['SetAuthor'] = ['CCIZA LTD.'];
        $config['methods']['SetCreator'] = ['CZA Extension'];
        $config['content'] = $content;
        $pdf = new Pdf($config);
        echo $pdf->render();
    }