<vc>
    <hc>
        <button id="add-user" icon="plus" text="{User}" />
        <inputdialog id="input-username" text="{Username}" visible="False" />
        <button id="add-group" icon="plus" text="{Group}" />
        <inputdialog id="input-groupname" text="{Name}" visible="False" />
    </hc>

    <body>
        <pad>
            <tabs>
                <tab title="{Users}">
                    <box width="750" id="passwd-config">
                        <bind:collection bind="users" id="users">
                            <vc>
                                <dt bind="__items" />
                                <bind:template>
                                    <include layout="users:user-list" />
                                </bind:template>
                                <button id="save-users" text="{Save}" icon="ok" />
                            </vc>
                        </bind:collection>
                    </box>
                </tab>

                <tab title="{System Users}">
                    <box width="750" id="passwd-config-system">
                        <bind:collection bind="users" id="system-users">
                            <vc>
                                <dt bind="__items" />
                                <bind:template>
                                    <include layout="users:user-list" />
                                </bind:template>
                                <button id="save-system-users" text="{Save}" icon="ok" />
                            </vc>
                        </bind:collection>
                    </box>
                </tab>

                <tab title="{Groups}">
                    <box width="750" id="group-config">
                        <bind:collection bind="groups" id="groups">
                            <vc>
                                <dt bind="__items" />
                                <bind:template>
                                    <collapserow>
                                        <box>
                                            <right>
                                                <button bind="__delete" icon="remove" style="icon" warning="{Confirm deletion}" />
                                            </right>
                                            <hc>
                                                <icon icon="th-large" />
                                                <label style="bold" bind="name" />
                                                <label bind="gid" />
                                            </hc>   
                                        </box>
                                        
                                        <pad>
                                            <hc>
                                                <vc>
                                                    <formline text="{Name}">
                                                        <textbox bind="name" />
                                                    </formline>
                                                    <formline text="GID">
                                                        <textbox bind="gid" />
                                                    </formline>
                                                </vc>
                                                <vc>
                                                    <formline text="{Members}">
                                                        <combobox id="group-members" separator="," bind="users" />
                                                    </formline>
                                                </vc>
                                            </hc>
                                        </pad>
                                    </collapserow>
                                </bind:template>
                                <button id="save-groups" text="{Save}" icon="ok" />
                            </vc>
                        </bind:collection>
                    </box>
                </tab>
            </tabs>
        </pad>
    </body>
</vc> 