Commit 4e0d53b9 authored by 何虹's avatar 何虹 💬

参照

parent a4aa6a49
<template> <template>
<div class="hello"> <div style="width:500px">
<hsInput></hsInput> <hsSelectPlus
<hsTable></hsTable> ref='select'
:allSourceData='allSourceData'
></hsSelectPlus>
<el-button @click="change1">change1</el-button>
<el-button @click="change2">change2</el-button>
</div> </div>
</template>
</template>
<script> <script>
export default { export default {
name: 'HelloWorld', data() {
props: { return {
msg: String allSourceData: {
config: {
url: "",
proxyTag: "commonUtilAPI",
ref: {
const_id: "0",
table_name: "im_store_group",
columns: "id,name",
remote_condition: "",
displayfield: "",
writebackfield: []
},
dyncQueryParms: {},
multiple: false,
disabled: false,
size: "mini",
clearable: true,
title: "标题",
placeholder: "请选择",
value: "id",
label: "name",
is_computed: false
},
sourceData: []
},
show: false,
config: {
url: "",
proxyTag: "commonUtilAPI",
ref: {
const_id: "0",
table_name: "im_store_group",
columns: "id,name",
remote_condition: "",
displayfield: "",
writebackfield: []
},
dyncQueryParms: {},
multiple: false,
disabled: false,
size: "mini",
clearable: true,
title: "标题",
placeholder: "请选择",
value: "id",
label: "name",
is_computed: false
}
};
},
mounted() {
this.init();
},
methods: {
change1(){
this.allSourceData.sourceData=[{value:1,label:2}]
},
change2(){
this.allSourceData.sourceData=[{value:2,label:3}]
},
init() {
// this.getData();
},
async getData() {
const data = await this.get_options(this.config);
//this.allSourceData.config=this.config
this.allSourceData.sourceData=data
} }
} }
};
</script> </script>
\ No newline at end of file
<!-- Add "scoped" attribute to limit CSS to this component only -->
<style scoped>
h3 {
margin: 40px 0 0;
}
ul {
list-style-type: none;
padding: 0;
}
li {
display: inline-block;
margin: 0 10px;
}
a {
color: #42b983;
}
</style>
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment