|
@@ -23,7 +23,7 @@
|
|
|
defineOptions({ name: 'resumeAnalysis-avatar'})
|
|
|
import { getUserAvatar } from '@/utils/avatar'
|
|
|
// import { blobToJson } from '@/utils'
|
|
|
-import { ref } from 'vue'
|
|
|
+import { ref, watch } from 'vue'
|
|
|
const props = defineProps({
|
|
|
id: {
|
|
|
type: String,
|
|
@@ -63,7 +63,15 @@ const handleUploadFile = async (e) => {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-const avatarResult = ref(props.data)
|
|
|
+const avatarResult = ref('')
|
|
|
+
|
|
|
+watch(
|
|
|
+ () => props.data,
|
|
|
+ (newVal) => {
|
|
|
+ avatarResult.value = newVal
|
|
|
+ },
|
|
|
+ { immediate: true },
|
|
|
+)
|
|
|
|
|
|
// 图片裁剪
|
|
|
const handleHideCopper = async (res) => {
|