Обучение. Начало Frontend части
This commit is contained in:
@@ -5,7 +5,24 @@ use DarksLight2\Training\TrainingManager;
|
||||
$short_name = 'first_step';
|
||||
|
||||
$manager = TrainingManager::getInstance();
|
||||
$step = $manager->$short_name;
|
||||
$button_text = 'Продолжить';
|
||||
if(!$manager) {
|
||||
$button_text = '';
|
||||
}
|
||||
?>
|
||||
|
||||
var_dump($manager->$short_name->progress);
|
||||
<script>
|
||||
const training_data = () => {
|
||||
return {
|
||||
content: `<?=$step->message?>`,
|
||||
title: `<?=$step->title?>`,
|
||||
button_text: `<?=$button_text?>`
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<script src="/js/training/modal.js"></script>
|
||||
|
||||
echo 'it\'s work';
|
||||
<script>
|
||||
modal.show()
|
||||
</script>
|
||||
Reference in New Issue
Block a user