<template>
    <div style="width: 100%">
        <Container>
        <Select v-model="value" style="width:96.5%;" clearable>
            <Option v-for="item in optionsData" :value="item.value||''" :key="item.value">{{ item.key }}</Option>
        </Select>
    </Container>
    </div>
</template>

<script>
import * as components from './style';
import {PropertyMixin} from '../../service/main-tool-editor-type-mixin';
export default {
    components: {
        ...components
    },
    mixins: [PropertyMixin],
    position: 'mainToolEditorTypeAttachFileTypeSelect',
    name: 'main-tool-editor-type-attachFileTypeSelect',
    data () {
        return {
            propArr:[]
        };
    },
    props: {
        instanceInfo: Object,
        editor: Object
    },
    computed: {
        applicationState () {
            return this.$store.state.application;
        },
        viewportState () {
            return this.$store.state.viewport;
        },
        optionsData () {
            let _data = this.propArr || [];
            return _data;
        }
    },
    methods: {
        // change_status(val){  // 筛选状态
        //
        //     console.log(this.val);
        //     this.val=val;
        //     this.setInstanceProps(this.val);
        // },
        handleChange () {

        }
    },
    mounted(){

        let _this=this;
         this.propArr=configPageIde.attachFileType;
        this.initCurrtField();
      /*  this.$http.get('/static/data/page-ide/attachFileType.json').then((response) => {
            _this.propArr=response.propArr;
            _this.initCurrtField();
        });*/
    },
    watch: {
        value (n, o) {
            if (n === o) {
                return;
            }
            this.setInstanceProps(n);
        }
    }
};
</script>

<style>

</style>
