cell-stock-out.vue 1.2 KB
<template>
    <div class="cell-stock-out">
        <p class="row">
            缺货<span class="num">
                <Input number @on-change="change"></Input>
            </span>
        </p>
        <p class="row">缺货数:{{lackNum}}</p>
        <p class="row">
            <Button type="error" @click="upload">上传确认缺货</Button>
        </p>
        <UploadStockOut ref="stockOut"></UploadStockOut>
    </div>
</template>

<script>
    import { UploadStockOut } from 'components/modal'

    export default {
        name: 'CellDeliver',
        props: {
            lackNum: {
                type: [String, Number]
            }
        },
        data() {
            return {
            }
        },
        methods: {
            upload(){
                this.$refs.stockOut.show();
            },
            change(val){
                this.$emit('num-change', val)
            }
        },
        components: {
            UploadStockOut
        }
    }
</script>

<style lang="scss" scoped>
    .cell-stock-out {
        text-align: left;

    .row {
        margin: 10px 0;
    }

    .num {
        display: inline-block;
        width: 50px;
        padding-left: 5px;
    }
    }

</style>