Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Table 01 (options)
op-id name
---------------
1 name 1
2 name 2
3 name 3
Table 2 (license)
lic-id name
---------------
1 test 1
2 test 2
Table 3 (options-licenses)
lic-id op-id
--------------------
1 2
1 3
2 1
<?php
//edit license 1
$options = Options::find()->all();
foreach ($options as $value) {
echo $form->field($value, 'op-id')->checkBox(['label' =>$value['name']]);
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.