feat--下拉框提示内容可自定义

This commit is contained in:
qianming
2023-12-21 10:35:42 +08:00
parent 2ac91df681
commit 4ca85f5b2f
2 changed files with 12 additions and 2 deletions

View File

@@ -22,6 +22,14 @@ export const widgetSelect = {
placeholder: '',
value: '下拉框',
},
{
type: 'el-input-text',
label: '提示内容',
name: 'select_text',
require: false,
placeholder: '',
value: '请选择'
},
{
type: 'vue-color',
label: '字体颜色',

View File

@@ -2,6 +2,7 @@
<anji-select
ref="select"
:style="styleObj"
:placeholder="placeholder"
v-model="selectValue"
:localOptions="options"
label="label"
@@ -35,7 +36,6 @@ export default {
},
computed: {
styleObj() {
console.log(this.optionsSetup);
return {
position: this.ispreview ? "absolute" : "static",
width: this.optionsStyle.width + "px",
@@ -46,6 +46,9 @@ export default {
color: this.optionsSetup.select_color,
};
},
placeholder(){
return this.optionsSetup.select_text;
},
eventChange() {
return "change";
},
@@ -74,7 +77,6 @@ export default {
},
methods: {
change(event, item) {
console.log(item);
originWidgetLinkageLogic(this, true, {
currentData: item,
}); // 联动-源组件逻辑