适配多商户

This commit is contained in:
gxwebsoft
2024-05-24 14:53:29 +08:00
parent 757822f3ba
commit dea6ae1c23
23 changed files with 1167 additions and 315 deletions

View File

@@ -10,6 +10,7 @@
@update:value="updateValue"
:style="`width: 200px`"
@blur="onBlur"
@change="onChange"
/>
</template>
@@ -20,6 +21,7 @@
const emit = defineEmits<{
(e: 'update:value', value: string, item: any): void;
(e: 'done', item: Merchant): void;
(e: 'blur'): void;
}>();
@@ -48,11 +50,16 @@
emit('blur');
};
const onChange = (item: Merchant) => {
emit('done', item);
};
const reload = () => {
listMerchant({}).then((list) => {
options.value = list.map((d) => {
d.label = d.merchantName;
d.value = d.merchantCode;
d.value = d.merchantId;
d.key = d.merchantCode;
return d;
});
});