# 弹窗

打开过渡表单(相当于PC端的弹窗功能)

  • 支持普通表单、模型表单;

# 1. 普通表单

let config = {
    type: 'form',
    title: '普通表单',
    formData: [
        { name: 'boIds', label: '标签', value: '', type: 'hidden' },
        { name: 'opinion', label: '标签', value: '', formType: 'text', type: 'textarea' },
    ],
    btnList: [{
        id: 'submit',
        loading: false,
        name: '确定',
        click (btnObj) {
        }
    }]
}
this.$showDialog(config)

# 查看支持哪些 formType 值

# 2. 模型表单

let config = {
    type: 'moduleEdit',
    mdCode: 'goods_copy',
    customSetting: {},
    btnList: [{
        id: 'save',
        name: '确定',
        click () {
            this.validate().then(res => {
                console.log(res)
            })
        }
    }],
}
this.$showDialog(config)