<template>
    <div class="card">
        <div class="card-header">Pump Settings</div>
        <div class="card-body">

            <div class="mb-3">
                <label class="form-label">Pump On command</label>
                <input v-model="pump.On" type="text" class="form-control form-control-sm">
            </div>

            <div class="mb-3">
                <label class="form-label">Pump Off command</label>
                <input v-model="pump.Off" type="text" class="form-control form-control-sm">
            </div>

            <div class="mb-3">
                <label class="form-label">Output name in GC</label>
                <input v-model="pump.inGC" type="text" class="form-control form-control-sm">
            </div>           

            <div class="row mt-2">
                <div class="col">
                    <button :disabled="loading" class="btn btn-sm btn-outline-secondary" @click="applaySettings()">Applay settings</button>
                </div>
            </div>

        </div>

    </div>
</template>

<script>
    import machineState from '../js/machine_state.js'

    export default {
        mixins: [machineState],
        props: {
            pump: Object,
            loading: Boolean
        },
        methods: {
            applaySettings() {
                this.$emit('applaySettings')
            }
        }
    }
</script>

<style>

</style>
