salix/modules/worker/front/department/index.html

49 lines
1.5 KiB
HTML
Raw Normal View History

2019-03-12 14:04:09 +00:00
<vn-crud-model
vn-id="model"
url="/worker/api/departments/getLeaves"
auto-load="false">
</vn-crud-model>
2019-10-01 13:09:55 +00:00
<div class="content-block" compact>
<form name="form" compact>
2019-03-12 14:04:09 +00:00
<vn-card margin-medium-v pad-medium>
2019-10-02 07:54:52 +00:00
<vn-treeview
vn-id="treeview"
model="model"
2019-03-12 14:04:09 +00:00
on-selection="$ctrl.onSelection(item, value)"
on-create="$ctrl.onCreate(parent)"
on-drop="$ctrl.onDrop(item, dragged, dropped)"
2019-10-02 07:54:52 +00:00
icons="$ctrl.icons">
{{item.name}}
2019-03-12 14:04:09 +00:00
</vn-treeview>
</vn-card>
2019-10-01 13:09:55 +00:00
<vn-button-bar>
<vn-button ui-sref="worker.index" label="Back"></vn-button>
</vn-button-bar>
</form>
</div>
2019-03-12 14:04:09 +00:00
<vn-confirm
vn-id="deleteNode"
on-response="$ctrl.onRemoveResponse(response)"
question="Delete department"
message="Are you sure you want to delete it?">
</vn-confirm>
<!-- Create department dialog -->
<vn-dialog
vn-id="createNode"
on-open="$ctrl.onCreateDialogOpen()"
on-response="$ctrl.onCreateResponse(response)">
<tpl-body>
<h5 pad-small-v translate>New department</h5>
<vn-horizontal>
<vn-textfield vn-one
label="Name"
model="$ctrl.newNode.name">
</vn-textfield>
</vn-horizontal>
</tpl-body>
<tpl-buttons>
<input type="button" response="CANCEL" translate-attr="{value: 'Cancel'}"/>
<button response="ACCEPT" translate>Create</button>
</tpl-buttons>
</vn-dialog>