brotherton-erpnext/erpnext/public/js/hub/components/SearchInput.vue

27 lines
409 B
Vue
Raw Normal View History

2018-08-23 08:22:41 +00:00
<template>
<div class="hub-search-container">
<input
type="text"
class="form-control"
:placeholder="placeholder"
:value="value"
2018-08-26 14:19:20 +00:00
@keydown.enter="on_input">
2018-08-23 08:22:41 +00:00
</div>
</template>
<script>
export default {
props: {
placeholder: String,
value: String,
on_search: Function
},
methods: {
on_input(event) {
this.$emit('input', event.target.value);
this.on_search();
}
}
};
</script>