<template>
  <span v-if="_readonly" v-text="value"></span>
  <Spinner
    v-else
    v-bind="_fieldProps"
    v-model="value"
    :disabled="disabled" 
  />
</template>
<script setup>
// 数字输入框
import { inject, useAttrs, defineEmits,onMounted } from 'vue';
import { useFieldBasics } from '../usefieldBasics';
import { Spinner } from '@king-design/vue';
import { useRoute } from 'vue-router';
const route = useRoute();
const $Attrs = useAttrs();
const formInfo = inject('formInfo');
const emit = defineEmits(['change']);

const { value, _readonly, _fieldProps, disabled,onLinkage } = useFieldBasics(
	$Attrs,
	formInfo,
	route,
	emit
);
onMounted(async () => {
	onLinkage();
});
</script>
<style lang="less">
</style>
