parent
d3943fc0b2
commit
d44bb62187
3 changed files with 31 additions and 30 deletions
|
@ -1,16 +1,16 @@
|
|||
<script setup lang='ts'>
|
||||
import { ref } from 'vue'
|
||||
import { ref, type PropType } from 'vue'
|
||||
import { resourceServer } from '@/main'
|
||||
|
||||
const props = defineProps({
|
||||
const props: { [key: string]: String} = defineProps({
|
||||
resourceName: String,
|
||||
resourceId: String,
|
||||
})
|
||||
|
||||
let _class: String = ref("")
|
||||
let _title: String = ref("")
|
||||
let _class = ref<string>("")
|
||||
let _title = ref<string>("")
|
||||
|
||||
const init = async (props) => {
|
||||
const init = async (props: { [id: string]: any}) => {
|
||||
const url = props.resourceId ? `${props.resourceName}/${props.resourceId}` : props.resourceName
|
||||
await resourceServer.get(url).then(
|
||||
resp => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue