代码更新
This commit is contained in:
@@ -32,30 +32,13 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
reactive,
|
||||
ref,
|
||||
watch,
|
||||
onMounted,
|
||||
computed
|
||||
} from 'vue';
|
||||
import {
|
||||
returnSkuSnap,
|
||||
returnTypeEnum,
|
||||
returnCategory
|
||||
} from '@/pageProduct/util.js'
|
||||
import {
|
||||
$tbShopUnit
|
||||
} from '@/http/yskApi/goods.js'
|
||||
import { reactive, ref, watch } from 'vue';
|
||||
|
||||
const props = defineProps({
|
||||
show: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
category: {
|
||||
type: Array,
|
||||
default: () => []
|
||||
},
|
||||
item: {
|
||||
type: Object,
|
||||
default: () => {
|
||||
@@ -64,15 +47,9 @@
|
||||
}
|
||||
})
|
||||
|
||||
function changeShowRecoders(show) {
|
||||
recoders.show = show
|
||||
}
|
||||
|
||||
const data = ref(props.item)
|
||||
const emits = defineEmits(['update:show', 'save'])
|
||||
const form = reactive({
|
||||
note: ''
|
||||
})
|
||||
|
||||
let popShow = ref(props.show)
|
||||
let name=ref('')
|
||||
|
||||
@@ -86,10 +63,7 @@
|
||||
data.value = props.item
|
||||
}
|
||||
})
|
||||
const isSku = computed(() => {
|
||||
// return data.value.typeEnum == '多规格'
|
||||
return false
|
||||
})
|
||||
|
||||
watch(() => popShow.value, (newval) => {
|
||||
emits('update:show', newval)
|
||||
})
|
||||
@@ -103,6 +77,7 @@
|
||||
}
|
||||
|
||||
function save() {
|
||||
console.log(data)
|
||||
emits('save', {
|
||||
...data.value,
|
||||
name:name.value
|
||||
|
||||
Reference in New Issue
Block a user