This commit is contained in:
zlwu committed 2026-06-04 12:57:59 +08:00
1 parent afd517ce10
commit eec61cb5dd
82 files changed
+16585 -9026

No files matched your search

+47
View File
@@ -38,6 +38,9 @@ export function fetchGetUserInfo() {
username: string
realName: string
phone: string
email?: string
sex?: string
remark?: string
role: string
regionId: string
regionName: string
@@ -50,6 +53,50 @@ export function fetchGetUserInfo() {
})
}
/** 当前用户更新个人信息 */
export function fetchUpdateProfile(data: {
phoneNo?: string
email?: string
sex?: string
remark?: string
avatarUrl?: string
}) {
return request.put<{
id: string
username: string
realName: string
phone: string
email?: string
sex?: string
remark?: string
role: string
regionId: string
regionName: string
avatarUrl?: string | null
}>({
url: '/web/auth/profile',
data,
showSuccessMessage: true
})
}
/** 当前用户上传头像 */
export function fetchUploadProfileAvatar(data: FormData) {
return request.post<{ url: string }>({
url: '/web/auth/upload-avatar',
data
})
}
/** 当前用户修改密码 */
export function fetchChangePassword(data: { oldPassword: string; newPassword: string }) {
return request.post({
url: '/web/auth/change-password',
data,
showSuccessMessage: true
})
}
/**
* 获取当前用户菜单 code 权限
*/
@@ -1,6 +1,7 @@
<!-- 用户菜单 -->
<template>
<ElPopover
<div class="user-menu-root">
<ElPopover
ref="userMenuPopover"
placement="bottom-end"
:width="240"
@@ -13,16 +14,21 @@
>
<template #reference>
<div class="user-avatar-wrapper">
<el-avatar :size="34" :src="avatarDisplayUrl">
{{ userInfo.realName?.charAt(0) || userInfo.username?.charAt(0) || '管' }}
<el-avatar :size="34" :src="avatarDisplayUrl || undefined" :key="avatarDisplayUrl">
<span v-if="showAvatarInitial">{{ avatarInitialText }}</span>
</el-avatar>
</div>
</template>
<template #default>
<div class="pt-3">
<div class="flex-c pb-1 px-0">
<el-avatar :size="40" :src="avatarDisplayUrl" style="margin-right: 12px">
{{ userInfo.realName?.charAt(0) || userInfo.username?.charAt(0) || '管' }}
<el-avatar
:size="40"
:src="avatarDisplayUrl || undefined"
:key="avatarDisplayUrl"
style="margin-right: 12px"
>
<span v-if="showAvatarInitial">{{ avatarInitialText }}</span>
</el-avatar>
<div class="w-[calc(100%-60px)] h-full">
<span class="block text-sm font-medium text-g-800 truncate">
@@ -43,6 +49,15 @@
<span>{{ userInfo.regionName }}</span>
</li>
<div class="w-full h-px my-2 bg-g-300/80"></div>
<li class="btn-item" @click="openProfileDialog">
<ArtSvgIcon icon="edit" />
<span>个人信息</span>
</li>
<li class="btn-item" @click="openPasswordDialog">
<ArtSvgIcon icon="ri:lock-password-line" />
<span>修改密码</span>
</li>
<div class="w-full h-px my-2 bg-g-300/80"></div>
<div class="log-out c-p" @click="loginOut">
{{ $t('topBar.user.logout') }}
</div>
@@ -50,13 +65,23 @@
</div>
</template>
</ElPopover>
<UserProfileDialog v-model:visible="profileDialogVisible" />
<UserPasswordDialog v-model:visible="passwordDialogVisible" />
</div>
</template>
<script setup lang="ts">
import { computed } from 'vue'
import { computed, ref } from 'vue'
import { ElMessageBox } from 'element-plus'
import { useUserStore } from '@/store/modules/user'
import { resolveUserAvatarUrl } from '@/utils/user-avatar'
import {
resolveUserAvatarFromInfo,
pickUserAvatarRaw,
hasCustomUserAvatar
} from '@/utils/user-avatar'
import UserProfileDialog from './UserProfileDialog.vue'
import UserPasswordDialog from './UserPasswordDialog.vue'
defineOptions({ name: 'ArtUserMenu' })
@@ -64,11 +89,31 @@
const { getUserInfo: userInfo } = storeToRefs(userStore)
const avatarDisplayUrl = computed(() =>
resolveUserAvatarUrl(userInfo.value.avatarUrl, userInfo.value.role)
const avatarDisplayUrl = computed(() => resolveUserAvatarFromInfo(userInfo.value))
const showAvatarInitial = computed(() => !hasCustomUserAvatar(pickUserAvatarRaw(userInfo.value)))
const avatarInitialText = computed(
() => userInfo.value.realName?.charAt(0) || userInfo.value.username?.charAt(0) || '管'
)
const userMenuPopover = ref()
const profileDialogVisible = ref(false)
const passwordDialogVisible = ref(false)
function openProfileDialog() {
closeUserMenu()
setTimeout(() => {
profileDialogVisible.value = true
}, 150)
}
function openPasswordDialog() {
closeUserMenu()
setTimeout(() => {
passwordDialogVisible.value = true
}, 150)
}
/**
* 获取角色名称
@@ -0,0 +1,149 @@
<!-- 当前用户修改密码 -->
<template>
<el-dialog
v-model="dialogVisible"
title="修改密码"
width="480px"
class="dialog-form-layout"
align-center
destroy-on-close
:close-on-click-modal="false"
@close="handleClose"
>
<el-form
ref="formRef"
:model="formData"
:rules="formRules"
label-position="top"
scroll-to-error
:scroll-into-view-options="{ behavior: 'smooth', block: 'center' }"
>
<div class="form-grid-2">
<el-form-item label="原密码" prop="oldPassword" class="form-col-span-2">
<el-input
v-model="formData.oldPassword"
type="password"
show-password
placeholder="请输入原密码"
autocomplete="current-password"
/>
</el-form-item>
<el-form-item label="新密码" prop="newPassword" class="form-col-span-2">
<el-input
v-model="formData.newPassword"
type="password"
show-password
placeholder="至少 6 位"
autocomplete="new-password"
/>
</el-form-item>
<el-form-item label="确认新密码" prop="confirmPassword" class="form-col-span-2">
<el-input
v-model="formData.confirmPassword"
type="password"
show-password
placeholder="请再次输入新密码"
autocomplete="new-password"
/>
</el-form-item>
</div>
</el-form>
<template #footer>
<el-button class="btn-ghost" @click="handleClose">
<el-icon><Close /></el-icon>
取消
</el-button>
<el-button class="btn-main" type="primary" :loading="submitting" @click="handleSubmit">
<el-icon><Check /></el-icon>
确定
</el-button>
</template>
</el-dialog>
</template>
<script setup lang="ts">
import { ref, reactive, computed, watch } from 'vue'
import type { FormInstance, FormRules } from 'element-plus'
import { Close, Check } from '@element-plus/icons-vue'
import { fetchChangePassword } from '@/api/auth'
const props = defineProps<{
visible: boolean
}>()
const emit = defineEmits<{
(e: 'update:visible', val: boolean): void
}>()
const formRef = ref<FormInstance>()
const submitting = ref(false)
const formData = reactive({
oldPassword: '',
newPassword: '',
confirmPassword: ''
})
const formRules: FormRules = {
oldPassword: [{ required: true, message: '请输入原密码', trigger: 'blur' }],
newPassword: [
{ required: true, message: '请输入新密码', trigger: 'blur' },
{ min: 6, message: '新密码长度不能少于 6 位', trigger: 'blur' }
],
confirmPassword: [
{ required: true, message: '请再次输入新密码', trigger: 'blur' },
{
validator: (_rule, value, callback) => {
if (value !== formData.newPassword) {
callback(new Error('两次输入的新密码不一致'))
return
}
callback()
},
trigger: 'blur'
}
]
}
const dialogVisible = computed({
get: () => props.visible,
set: (val) => emit('update:visible', val)
})
function resetForm() {
formData.oldPassword = ''
formData.newPassword = ''
formData.confirmPassword = ''
formRef.value?.clearValidate?.()
}
function handleClose() {
dialogVisible.value = false
}
async function handleSubmit() {
if (!formRef.value) return
try {
await formRef.value.validate()
submitting.value = true
await fetchChangePassword({
oldPassword: formData.oldPassword,
newPassword: formData.newPassword
})
dialogVisible.value = false
} catch {
/* 校验或接口错误已由全局处理 */
} finally {
submitting.value = false
}
}
watch(
() => props.visible,
(val) => {
if (val) {
resetForm()
}
}
)
</script>
@@ -0,0 +1,326 @@
<!-- 当前用户个人信息编辑 -->
<template>
<el-dialog
v-model="dialogVisible"
title="个人信息"
width="560px"
class="dialog-form-layout"
align-center
destroy-on-close
:close-on-click-modal="false"
@close="handleClose"
>
<el-form
ref="formRef"
:model="formData"
:rules="formRules"
label-position="top"
scroll-to-error
:scroll-into-view-options="{ behavior: 'smooth', block: 'center' }"
>
<div class="form-grid-2">
<el-form-item label="头像" class="form-col-span-2">
<div class="profile-avatar-row">
<el-avatar
:size="72"
:src="avatarPreviewUrl || undefined"
:key="avatarPreviewKey"
>
<span v-if="showAvatarInitial">{{ avatarInitial }}</span>
</el-avatar>
<div class="profile-avatar-actions">
<div class="profile-avatar-btns">
<el-upload
ref="avatarUploadRef"
accept="image/*"
:show-file-list="false"
:auto-upload="false"
:disabled="avatarUploading"
@change="handleAvatarChange"
>
<el-button class="btn-ghost" :loading="avatarUploading">
<el-icon><Upload /></el-icon>
上传头像
</el-button>
</el-upload>
<el-button
v-if="formData.avatarUrl"
class="btn-ghost"
:disabled="avatarUploading"
@click="handleClearAvatar"
>
<el-icon><Delete /></el-icon>
恢复默认
</el-button>
</div>
<p class="profile-avatar-tip">支持 JPG、PNG 等图片,大小不超过 2MB</p>
</div>
</div>
</el-form-item>
<el-form-item label="手机号" prop="phoneNo">
<el-input v-model="formData.phoneNo" placeholder="选填" maxlength="11" clearable />
</el-form-item>
<el-form-item label="邮箱" prop="email">
<el-input v-model="formData.email" placeholder="选填" maxlength="50" clearable />
</el-form-item>
<el-form-item label="性别" prop="sex">
<el-select v-model="formData.sex" placeholder="请选择" style="width: 100%">
<el-option label="男" value="0" />
<el-option label="女" value="1" />
<el-option label="未知" value="2" />
</el-select>
</el-form-item>
<el-form-item label="备注" class="form-col-span-2">
<el-input
v-model="formData.remark"
type="textarea"
:rows="3"
placeholder="选填"
maxlength="512"
show-word-limit
/>
</el-form-item>
</div>
</el-form>
<template #footer>
<el-button class="btn-ghost" @click="handleClose">
<el-icon><Close /></el-icon>
取消
</el-button>
<el-button class="btn-main" type="primary" :loading="submitting" @click="handleSubmit">
<el-icon><Check /></el-icon>
保存
</el-button>
</template>
</el-dialog>
</template>
<script setup lang="ts">
import { ref, reactive, computed, watch, onBeforeUnmount } from 'vue'
import type { FormInstance, FormRules, UploadFile, UploadInstance } from 'element-plus'
import { Close, Check, Upload, Delete } from '@element-plus/icons-vue'
import { fetchGetUserInfo, fetchUpdateProfile, fetchUploadProfileAvatar } from '@/api/auth'
import { useUserStore } from '@/store/modules/user'
import {
pickUserAvatarRaw,
pickUploadAvatarUrl,
hasCustomUserAvatar,
resolveUserAvatarUrl
} from '@/utils/user-avatar'
const props = defineProps<{
visible: boolean
}>()
const emit = defineEmits<{
(e: 'update:visible', val: boolean): void
}>()
const userStore = useUserStore()
const formRef = ref<FormInstance>()
const avatarUploadRef = ref<UploadInstance>()
const submitting = ref(false)
const avatarUploading = ref(false)
const avatarLocalPreview = ref('')
const displayRole = ref('')
const formData = reactive({
phoneNo: '',
email: '',
sex: '0',
remark: '',
avatarUrl: ''
})
const formRules: FormRules = {
phoneNo: [
{
validator: (_rule, value, callback) => {
const v = (value || '').trim()
if (v && !/^1\d{10}$/.test(v)) {
callback(new Error('请输入正确的手机号'))
return
}
callback()
},
trigger: 'blur'
}
],
email: [
{
validator: (_rule, value, callback) => {
const v = (value || '').trim()
if (v && !/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(v)) {
callback(new Error('请输入正确的邮箱'))
return
}
callback()
},
trigger: 'blur'
}
]
}
const dialogVisible = computed({
get: () => props.visible,
set: (val) => emit('update:visible', val)
})
const avatarPreviewUrl = computed(() => {
if (avatarLocalPreview.value) return avatarLocalPreview.value
return resolveUserAvatarUrl(formData.avatarUrl, displayRole.value)
})
const avatarPreviewKey = computed(
() => avatarLocalPreview.value || formData.avatarUrl || 'default-avatar'
)
const showAvatarInitial = computed(
() => !avatarLocalPreview.value && !hasCustomUserAvatar(formData.avatarUrl)
)
const avatarInitial = computed(() => {
const info = userStore.getUserInfo
return info.realName?.charAt(0) || info.username?.charAt(0) || '管'
})
function revokeAvatarLocalPreview() {
if (avatarLocalPreview.value) {
URL.revokeObjectURL(avatarLocalPreview.value)
avatarLocalPreview.value = ''
}
}
function handleClose() {
dialogVisible.value = false
}
function handleClearAvatar() {
formData.avatarUrl = ''
revokeAvatarLocalPreview()
avatarUploadRef.value?.clearFiles()
}
async function loadProfile() {
const data = await fetchGetUserInfo()
formData.phoneNo = data.phone || ''
formData.email = data.email || ''
formData.sex = data.sex || '0'
formData.remark = data.remark || ''
formData.avatarUrl = pickUserAvatarRaw(data) || pickUserAvatarRaw(userStore.getUserInfo) || ''
displayRole.value = data.role || userStore.getUserInfo.role || ''
revokeAvatarLocalPreview()
avatarUploadRef.value?.clearFiles()
}
async function handleAvatarChange(uploadFile: UploadFile) {
const file = uploadFile.raw
if (!file) return
if (uploadFile.status && uploadFile.status !== 'ready') return
if (!file.type.startsWith('image/')) {
ElMessage.error('仅支持上传图片文件')
avatarUploadRef.value?.clearFiles()
return
}
if (file.size > 2 * 1024 * 1024) {
ElMessage.error('头像大小不能超过 2MB')
avatarUploadRef.value?.clearFiles()
return
}
avatarUploading.value = true
revokeAvatarLocalPreview()
avatarLocalPreview.value = URL.createObjectURL(file)
try {
const fd = new FormData()
fd.append('file', file)
const res = await fetchUploadProfileAvatar(fd)
const stored = pickUploadAvatarUrl(res)
if (!stored) {
ElMessage.error('上传成功但未返回图片地址')
handleClearAvatar()
return
}
formData.avatarUrl = stored
ElMessage.success('头像上传成功')
} catch {
handleClearAvatar()
} finally {
avatarUploading.value = false
avatarUploadRef.value?.clearFiles()
}
}
async function handleSubmit() {
if (!formRef.value) return
try {
await formRef.value.validate()
submitting.value = true
const updated = await fetchUpdateProfile({
phoneNo: formData.phoneNo.trim() || undefined,
email: formData.email.trim() || undefined,
sex: formData.sex,
remark: formData.remark.trim() || undefined,
avatarUrl: formData.avatarUrl || ''
})
userStore.setUserInfo({
phone: updated.phone,
email: updated.email,
sex: updated.sex,
remark: updated.remark,
avatarUrl: pickUserAvatarRaw(updated)
})
dialogVisible.value = false
} catch {
/* 校验或接口错误已由全局处理 */
} finally {
submitting.value = false
}
}
watch(
() => props.visible,
(val) => {
if (val) {
loadProfile().catch(() => {})
formRef.value?.clearValidate?.()
} else {
revokeAvatarLocalPreview()
}
}
)
onBeforeUnmount(() => {
revokeAvatarLocalPreview()
})
</script>
<style scoped lang="scss">
.profile-avatar-row {
display: flex;
gap: 16px;
align-items: center;
}
.profile-avatar-actions {
display: flex;
flex-direction: column;
align-items: flex-start;
gap: 8px;
}
.profile-avatar-btns {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: 8px;
}
.profile-avatar-tip {
margin: 0;
font-size: 12px;
color: var(--mint-text-muted, #64748b);
line-height: 1.5;
}
</style>
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "label": "UserProfileDialog.vue", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L1"}, {"id": "widget_userprofiledialog_revokeavatarlocalpreview", "label": "revokeAvatarLocalPreview()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L168"}, {"id": "widget_userprofiledialog_handleclose", "label": "handleClose()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L175"}, {"id": "widget_userprofiledialog_handleclearavatar", "label": "handleClearAvatar()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L179"}, {"id": "widget_userprofiledialog_loadprofile", "label": "loadProfile()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L185"}, {"id": "widget_userprofiledialog_handleavatarchange", "label": "handleAvatarChange()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L197"}, {"id": "widget_userprofiledialog_handlesubmit", "label": "handleSubmit()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L230"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "element_plus", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L94", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "icons_vue", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L95", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L96", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L97", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L98", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_revokeavatarlocalpreview", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L168", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_handleclose", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L175", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_handleLine truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "label": "user-avatar.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L1"}, {"id": "utils_user_avatar_defaultavatarpathbyrole", "label": "defaultAvatarPathByRole()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L7"}, {"id": "utils_user_avatar_pickuseravatarraw", "label": "pickUserAvatarRaw()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L12"}, {"id": "utils_user_avatar_resolvestoragefileurl", "label": "resolveStorageFileUrl()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L21"}, {"id": "utils_user_avatar_resolveuseravatarurl", "label": "resolveUserAvatarUrl()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L30"}, {"id": "utils_user_avatar_resolveuseravatarfrominfo", "label": "resolveUserAvatarFromInfo()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L40"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_defaultavatarpathbyrole", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L7", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_pickuseravatarraw", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L12", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_resolvestoragefileurl", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L21", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_resolveuseravatarurl", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L30", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_resolveuseravatarfrominfo", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L40", "weight": 1.0}, {"source": "utils_user_avatar_resolveuseravatarurl", "target": "utils_user_avatar_resolvestoragefileurl", "relation": "calls", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L35", "weight": 1.0}, {"source": "utils_user_avatar_resolveuseravatarurl", "target": "utils_user_avatar_defaultavatarpathbyrole", "relation": "calls", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L36", "weight": 1.0}, {"source": "utils_user_avatar_resolveuseravatarfrominfo", "target": "utils_user_avatar_resolveuseravatarurl", "relation": "calls", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L43", "weight": 1.0}, {"source": "utils_user_avatar_resolveuseravatarfrominfo", "target": "utils_user_avatar_pickuseravatarraw", "relation": "calls", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L43", "weight": 1.0}], "raw_calls": [{"caller_nid": "utils_user_avatar_pickuseravatarraw", "callee": "trim", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L17"}, {"caller_nid": "utils_user_avatar_pickuseravatarraw", "callee": "String", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L17"}, {"caller_nid": "utils_user_avatar_resolvestoragefileurl", "callee": "trim", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L22"}, {"caller_nid": "utils_user_avatar_resolvestoragefileurl", "callee": "String", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L22"}, {"caller_nid": "utils_user_avatar_resolvestoragefileurl", "callee": "test", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_loLine truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "label": "UserProfileDialog.vue", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L1"}, {"id": "widget_userprofiledialog_revokeavatarlocalpreview", "label": "revokeAvatarLocalPreview()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L187"}, {"id": "widget_userprofiledialog_handleclose", "label": "handleClose()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L194"}, {"id": "widget_userprofiledialog_handleclearavatar", "label": "handleClearAvatar()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L198"}, {"id": "widget_userprofiledialog_loadprofile", "label": "loadProfile()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L204"}, {"id": "widget_userprofiledialog_handleavatarchange", "label": "handleAvatarChange()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L216"}, {"id": "widget_userprofiledialog_handlesubmit", "label": "handleSubmit()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L255"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "element_plus", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L100", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "icons_vue", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L101", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L102", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L103", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L104", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_revokeavatarlocalpreview", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L187", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_handleclose", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L194", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_hLine truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_types_import_components_d_ts", "label": "components.d.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/types/import/components.d.ts", "source_location": "L1"}], "edges": [], "raw_calls": []}
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "label": "auth.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L1"}, {"id": "api_auth_fetchlogin", "label": "fetchLogin()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L9"}, {"id": "api_auth_fetchgetuserinfo", "label": "fetchGetUserInfo()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L35"}, {"id": "api_auth_fetchupdateprofile", "label": "fetchUpdateProfile()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L57"}, {"id": "api_auth_fetchuploadprofileavatar", "label": "fetchUploadProfileAvatar()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L84"}, {"id": "api_auth_fetchchangepassword", "label": "fetchChangePassword()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L92"}, {"id": "api_auth_fetchgetmenucodes", "label": "fetchGetMenuCodes()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L103"}, {"id": "api_auth_fetchrefreshtoken", "label": "fetchRefreshToken()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L118"}, {"id": "api_auth_fetchlogout", "label": "fetchLogout()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L132"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_http", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L1", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_loginrsa", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L2", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchlogin", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L9", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchgetuserinfo", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L35", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchupdateprofile", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L57", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchuploadprofileavatar", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L84", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchchangepassword", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L92", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchgetmenucodes", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L103", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchrefreshtoken", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L118", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchlogout", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L132", "weight": 1.0}], "raw_calls": [{"caller_nid": "api_auth_fetchlogin", "callee": "buildWebEncryptedLoginBody", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L10"}, {"caller_nid": "api_auth_fetchlogin", "callee": "post", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "Line truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "label": "UserProfileDialog.vue", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L1"}, {"id": "widget_userprofiledialog_handleclose", "label": "handleClose()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L120"}, {"id": "widget_userprofiledialog_loadprofile", "label": "loadProfile()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L124"}, {"id": "widget_userprofiledialog_handlesubmit", "label": "handleSubmit()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L132"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "element_plus", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L62", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "icons_vue", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L63", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L64", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L65", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_handleclose", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L120", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_loadprofile", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L124", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_handlesubmit", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L132", "weight": 1.0}], "raw_calls": [{"caller_nid": "widget_userprofiledialog_loadprofile", "callee": "fetchGetUserInfo", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L125"}, {"caller_nid": "widget_userprofiledialog_handlesubmit", "callee": "validate", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L135"}, {"caller_nid": "widget_userprofiledialog_handlesubmit", "callee": "fetchUpdateProfile", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L137"}, {"caller_nid": "widget_userprofiledialog_handlesubmit", "callee": "trim", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L138"}, {"caller_nid": "widget_userprofiledialog_handLine truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "label": "user-avatar.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L1"}, {"id": "utils_user_avatar_joinpublicasset", "label": "joinPublicAsset()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L2"}, {"id": "utils_user_avatar_defaultavatarpathbyrole", "label": "defaultAvatarPathByRole()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L14"}, {"id": "utils_user_avatar_normalizeavatarstoragekey", "label": "normalizeAvatarStorageKey()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L22"}, {"id": "utils_user_avatar_pickuseravatarraw", "label": "pickUserAvatarRaw()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L44"}, {"id": "utils_user_avatar_hascustomuseravatar", "label": "hasCustomUserAvatar()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L53"}, {"id": "utils_user_avatar_pickuploadavatarurl", "label": "pickUploadAvatarUrl()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L58"}, {"id": "utils_user_avatar_resolvestoragefileurl", "label": "resolveStorageFileUrl()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L69"}, {"id": "utils_user_avatar_resolveuseravatarurl", "label": "resolveUserAvatarUrl()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L78"}, {"id": "utils_user_avatar_resolveuseravatarfrominfo", "label": "resolveUserAvatarFromInfo()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L88"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_joinpublicasset", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L2", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_defaultavatarpathbyrole", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L14", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_normalizeavatarstoragekey", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L22", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_pickuseravatarraw", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L44", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_hascustomuseravatar", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L53", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_pickuploadavatarurl", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L58", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_resolvestoragefileurl", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L69", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_resolveuseravatarurl", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L78", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_resolveuseravatarfrominfo", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "sLine truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "label": "ProtocolFormDialog.vue", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1"}, {"id": "protocol_protocolformdialog_fmtmoney", "label": "fmtMoney()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1218"}, {"id": "protocol_protocolformdialog_createemptytransport", "label": "createEmptyTransport()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1290"}, {"id": "protocol_protocolformdialog_fullfileurl", "label": "fullFileUrl()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1310"}, {"id": "protocol_protocolformdialog_loadethnicoptions", "label": "loadEthnicOptions()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1317"}, {"id": "protocol_protocolformdialog_ensureethnicoptioninlist", "label": "ensureEthnicOptionInList()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1328"}, {"id": "protocol_protocolformdialog_expressname", "label": "expressName()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1356"}, {"id": "protocol_protocolformdialog_for", "label": "for()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L2131"}, {"id": "protocol_protocolformdialog_if", "label": "if()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L2668"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "element_plus", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1152", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "icons_vue", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1153", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_collection_protocol", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1165", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_business", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1171", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_download_attachment", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1172", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_admin", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1173", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_ethnic", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1185", "weight": 1.0}, {"source":Line truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_types_import_components_d_ts", "label": "components.d.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/types/import/components.d.ts", "source_location": "L1"}], "edges": [], "raw_calls": []}
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_fq_params_change_ts", "label": "protocol-fq-params-change.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L1"}, {"id": "utils_protocol_fq_params_change_formatmoneysummary", "label": "formatMoneySummary()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L26"}, {"id": "utils_protocol_fq_params_change_countbystatus", "label": "countByStatus()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L30"}, {"id": "utils_protocol_fq_params_change_fqparamssnapshot", "label": "fqParamsSnapshot()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L34"}, {"id": "utils_protocol_fq_params_change_issamefqparams", "label": "isSameFqParams()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L42"}, {"id": "utils_protocol_fq_params_change_getpaidinstallmentrows", "label": "getPaidInstallmentRows()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L50"}, {"id": "utils_protocol_fq_params_change_maxpaidinstallmentno", "label": "maxPaidInstallmentNo()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L56"}, {"id": "utils_protocol_fq_params_change_evaluatefqparamschange", "label": "evaluateFqParamsChange()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L63"}, {"id": "utils_protocol_fq_params_change_applyfqparamschange", "label": "applyFqParamsChange()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L143"}, {"id": "utils_protocol_fq_params_change_generateinitialfqdetails", "label": "generateInitialFqDetails()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L182"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_fq_params_change_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L6", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_fq_params_change_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_pay_mode_switch", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L11", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_fq_params_change_ts", "target": "utils_protocol_fq_params_change_formatmoneysummary", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L26", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_fq_params_change_ts", "target": "utils_protocol_fq_params_change_countbystatus", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L30", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_fq_params_change_ts", "target": "utils_protocol_fq_params_change_fqparamssnapshot", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L34", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_fq_params_change_ts", "target": "utils_protocol_fq_params_change_issamefqparams", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L42", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_fq_params_change_ts", "target": "utils_protocol_fq_params_change_getpaidinstallmentrows", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-fq-params-change.ts", "source_location": "L50", "wLine truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_types_import_components_d_ts", "label": "components.d.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/types/import/components.d.ts", "source_location": "L1"}], "edges": [], "raw_calls": []}
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "label": "ArtUserMenu.vue", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L1"}, {"id": "widget_artusermenu_openprofiledialog", "label": "openProfileDialog()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L91"}, {"id": "widget_artusermenu_openpassworddialog", "label": "openPasswordDialog()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L98"}, {"id": "widget_artusermenu_getrolename", "label": "getRoleName()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L108"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "target": "widget_artusermenu_openprofiledialog", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L91", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "target": "widget_artusermenu_openpassworddialog", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L98", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "target": "widget_artusermenu_getrolename", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L108", "weight": 1.0}], "raw_calls": [{"caller_nid": "widget_artusermenu_openprofiledialog", "callee": "closeUserMenu", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L92"}, {"caller_nid": "widget_artusermenu_openprofiledialog", "callee": "setTimeout", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L93"}, {"caller_nid": "widget_artusermenu_openpassworddialog", "callee": "closeUserMenu", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L99"}, {"caller_nid": "widget_artusermenu_openpassworddialog", "callee": "setTimeout", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L100"}]}
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "label": "user-avatar.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L1"}, {"id": "utils_user_avatar_joinpublicasset", "label": "joinPublicAsset()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L2"}, {"id": "utils_user_avatar_defaultavatarpathbyrole", "label": "defaultAvatarPathByRole()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L14"}, {"id": "utils_user_avatar_pickuseravatarraw", "label": "pickUserAvatarRaw()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L19"}, {"id": "utils_user_avatar_hascustomuseravatar", "label": "hasCustomUserAvatar()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L28"}, {"id": "utils_user_avatar_pickuploadavatarurl", "label": "pickUploadAvatarUrl()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L33"}, {"id": "utils_user_avatar_resolvestoragefileurl", "label": "resolveStorageFileUrl()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L44"}, {"id": "utils_user_avatar_resolveuseravatarurl", "label": "resolveUserAvatarUrl()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L53"}, {"id": "utils_user_avatar_resolveuseravatarfrominfo", "label": "resolveUserAvatarFromInfo()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L63"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_joinpublicasset", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L2", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_defaultavatarpathbyrole", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L14", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_pickuseravatarraw", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L19", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_hascustomuseravatar", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L28", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_pickuploadavatarurl", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L33", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_resolvestoragefileurl", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L44", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_resolveuseravatarurl", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L53", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar_ts", "target": "utils_user_avatar_resolveuseravatarfrominfo", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L63", "weight": 1.0}, {"source": "utils_user_avatar_resolveuseravatarurl", "target": "utils_user_avatar_resolvestoragefileurl", "relation": "calls", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/user-avatar.ts", "source_location": "L58", "weight": 1.0}, {"source": "utils_user_avatar_resolveuseravatarurl", "target": "utils_user_avatar_defaultavatarpathbyrole", "relation": "calls", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utilLine truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "label": "auth.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L1"}, {"id": "api_auth_fetchlogin", "label": "fetchLogin()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L9"}, {"id": "api_auth_fetchgetuserinfo", "label": "fetchGetUserInfo()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L35"}, {"id": "api_auth_fetchupdateprofile", "label": "fetchUpdateProfile()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L57"}, {"id": "api_auth_fetchchangepassword", "label": "fetchChangePassword()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L83"}, {"id": "api_auth_fetchgetmenucodes", "label": "fetchGetMenuCodes()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L94"}, {"id": "api_auth_fetchrefreshtoken", "label": "fetchRefreshToken()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L109"}, {"id": "api_auth_fetchlogout", "label": "fetchLogout()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L123"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_http", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L1", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_loginrsa", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L2", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchlogin", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L9", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchgetuserinfo", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L35", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchupdateprofile", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L57", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchchangepassword", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L83", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchgetmenucodes", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L94", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchrefreshtoken", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L109", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth_ts", "target": "api_auth_fetchlogout", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L123", "weight": 1.0}], "raw_calls": [{"caller_nid": "api_auth_fetchlogin", "callee": "buildWebEncryptedLoginBody", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L10"}, {"caller_nid": "api_auth_fetchlogin", "callee": "post", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L11"}, {"caller_nid": "api_auth_fetchgetuserinfo", "callee": "get", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L36"}, {"caller_nid": "api_auth_fetchupdateprofile", "callee": "put", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts", "source_location": "L63"}, {"caller_nid": "api_auth_fetchchangepassword", "callee": "post", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/api/auth.ts",Line truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "label": "ArtUserMenu.vue", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L1"}, {"id": "widget_artusermenu_openprofiledialog", "label": "openProfileDialog()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L89"}, {"id": "widget_artusermenu_openpassworddialog", "label": "openPasswordDialog()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L96"}, {"id": "widget_artusermenu_getrolename", "label": "getRoleName()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L106"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "target": "widget_artusermenu_openprofiledialog", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L89", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "target": "widget_artusermenu_openpassworddialog", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L96", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "target": "widget_artusermenu_getrolename", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L106", "weight": 1.0}], "raw_calls": [{"caller_nid": "widget_artusermenu_openprofiledialog", "callee": "closeUserMenu", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L90"}, {"caller_nid": "widget_artusermenu_openprofiledialog", "callee": "setTimeout", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L91"}, {"caller_nid": "widget_artusermenu_openpassworddialog", "callee": "closeUserMenu", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L97"}, {"caller_nid": "widget_artusermenu_openpassworddialog", "callee": "setTimeout", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L98"}]}
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_types_api_d_ts", "label": "api.d.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/types/api.d.ts", "source_location": "L1"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_types_api_d_ts", "target": "vue", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/types/api.d.ts", "source_location": "L793", "weight": 1.0}], "raw_calls": []}
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_pay_mode_switch_ts", "label": "protocol-pay-mode-switch.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L1"}, {"id": "utils_protocol_pay_mode_switch_ispaydetaillocked", "label": "isPayDetailLocked()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L30"}, {"id": "utils_protocol_pay_mode_switch_markpaydetaillocks", "label": "markPayDetailLocks()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L35"}, {"id": "utils_protocol_pay_mode_switch_sumpaidamount", "label": "sumPaidAmount()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L41"}, {"id": "utils_protocol_pay_mode_switch_calcremainingamount", "label": "calcRemainingAmount()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L47"}, {"id": "utils_protocol_pay_mode_switch_formatmoneysummary", "label": "formatMoneySummary()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L56"}, {"id": "utils_protocol_pay_mode_switch_activedetails", "label": "activeDetails()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L60"}, {"id": "utils_protocol_pay_mode_switch_hasblockingstatus", "label": "hasBlockingStatus()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L64"}, {"id": "utils_protocol_pay_mode_switch_countbystatus", "label": "countByStatus()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L68"}, {"id": "utils_protocol_pay_mode_switch_createpaymentdetailrow", "label": "createPaymentDetailRow()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L72"}, {"id": "utils_protocol_pay_mode_switch_evaluatepaymodeswitch", "label": "evaluatePayModeSwitch()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L96"}, {"id": "utils_protocol_pay_mode_switch_applypaymodeswitch", "label": "applyPayModeSwitch()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L162"}, {"id": "utils_protocol_pay_mode_switch_canaddpaymentdetail", "label": "canAddPaymentDetail()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L210"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_pay_mode_switch_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L6", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_pay_mode_switch_ts", "target": "utils_protocol_pay_mode_switch_ispaydetaillocked", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L30", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_pay_mode_switch_ts", "target": "utils_protocol_pay_mode_switch_markpaydetaillocks", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L35", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_pay_mode_switch_ts", "target": "utils_protocol_pay_mode_switch_sumpaidamount", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L41", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_pay_mode_switch_ts", "target": "utils_protocol_pay_mode_switch_calcremainingamount", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-pay-mode-switch.ts", "source_location": "L47", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utiLine truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "label": "user.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L1"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "pinia", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L15", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "vue", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L16", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_enums_appenum", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L17", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_router", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L18", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_worktab", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L19", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_types_router", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L20", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_router_guards_beforeeach", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L21", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_menu", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L22", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_storage_storage_config", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L23", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L24", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_router_routesalias", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L25", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_router", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L26", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user_ts", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/store/modules/user.ts", "source_location": "L27", "weight": 1.0}], "raw_calls": []}
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "label": "ArtUserMenu.vue", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L1"}, {"id": "widget_artusermenu_openprofiledialog", "label": "openProfileDialog()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L104"}, {"id": "widget_artusermenu_openpassworddialog", "label": "openPasswordDialog()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L111"}, {"id": "widget_artusermenu_getrolename", "label": "getRoleName()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L121"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "target": "widget_artusermenu_openprofiledialog", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L104", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "target": "widget_artusermenu_openpassworddialog", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L111", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_artusermenu_vue", "target": "widget_artusermenu_getrolename", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L121", "weight": 1.0}], "raw_calls": [{"caller_nid": "widget_artusermenu_openprofiledialog", "callee": "closeUserMenu", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L105"}, {"caller_nid": "widget_artusermenu_openprofiledialog", "callee": "setTimeout", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L106"}, {"caller_nid": "widget_artusermenu_openpassworddialog", "callee": "closeUserMenu", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L112"}, {"caller_nid": "widget_artusermenu_openpassworddialog", "callee": "setTimeout", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/ArtUserMenu.vue", "source_location": "L113"}]}
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "label": "UserProfileDialog.vue", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L1"}, {"id": "widget_userprofiledialog_revokeavatarlocalpreview", "label": "revokeAvatarLocalPreview()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L168"}, {"id": "widget_userprofiledialog_handleclose", "label": "handleClose()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L175"}, {"id": "widget_userprofiledialog_handleclearavatar", "label": "handleClearAvatar()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L179"}, {"id": "widget_userprofiledialog_loadprofile", "label": "loadProfile()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L185"}, {"id": "widget_userprofiledialog_handleavatarchange", "label": "handleAvatarChange()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L197"}, {"id": "widget_userprofiledialog_handlesubmit", "label": "handleSubmit()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L230"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "element_plus", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L94", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "icons_vue", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L95", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_auth", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L96", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_store_modules_user", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L97", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_user_avatar", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L98", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_revokeavatarlocalpreview", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L168", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_handleclose", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/components/core/layouts/art-header-bar/widget/UserProfileDialog.vue", "source_location": "L175", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_components_core_layouts_art_header_bar_widget_userprofiledialog_vue", "target": "widget_userprofiledialog_handleLine truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_types_import_components_d_ts", "label": "components.d.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/types/import/components.d.ts", "source_location": "L1"}], "edges": [], "raw_calls": []}
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment_ts", "label": "protocol-payment-installment.ts", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L1"}, {"id": "utils_protocol_payment_installment_addmonthsymd", "label": "addMonthsYmd()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L5"}, {"id": "utils_protocol_payment_installment_adddaysymd", "label": "addDaysYmd()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L19"}, {"id": "utils_protocol_payment_installment_addintervalmonthsymd", "label": "addIntervalMonthsYmd()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L34"}, {"id": "utils_protocol_payment_installment_calcfqinstallmentduedate", "label": "calcFqInstallmentDueDate()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L55"}, {"id": "utils_protocol_payment_installment_calcinstallmentdueamounts", "label": "calcInstallmentDueAmounts()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L67"}, {"id": "utils_protocol_payment_installment_alignfqpaymentdetailsfordisplay", "label": "alignFqPaymentDetailsForDisplay()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L93"}, {"id": "utils_protocol_payment_installment_sortfqpaymentdetails", "label": "sortFqPaymentDetails()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L160"}, {"id": "utils_protocol_payment_installment_syncfqpaymentdetailrowcount", "label": "syncFqPaymentDetailRowCount()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L170"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment_ts", "target": "utils_protocol_payment_installment_addmonthsymd", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L5", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment_ts", "target": "utils_protocol_payment_installment_adddaysymd", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L19", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment_ts", "target": "utils_protocol_payment_installment_addintervalmonthsymd", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L34", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment_ts", "target": "utils_protocol_payment_installment_calcfqinstallmentduedate", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L55", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment_ts", "target": "utils_protocol_payment_installment_calcinstallmentdueamounts", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L67", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment_ts", "target": "utils_protocol_payment_installment_alignfqpaymentdetailsfordisplay", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L93", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment_ts", "target": "utils_protocol_payment_installment_sortfqpaymentdetails", "relation": "contains", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/utils/protocol-payment-installment.ts", "source_location": "L160", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_protocol_payment_installment_ts", "target": "utLine truncated
@@ -0,0 +1 @@
{"nodes": [{"id": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "label": "ProtocolFormDialog.vue", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1"}, {"id": "protocol_protocolformdialog_fmtmoney", "label": "fmtMoney()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1213"}, {"id": "protocol_protocolformdialog_createemptytransport", "label": "createEmptyTransport()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1278"}, {"id": "protocol_protocolformdialog_fullfileurl", "label": "fullFileUrl()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1298"}, {"id": "protocol_protocolformdialog_loadethnicoptions", "label": "loadEthnicOptions()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1305"}, {"id": "protocol_protocolformdialog_ensureethnicoptioninlist", "label": "ensureEthnicOptionInList()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1316"}, {"id": "protocol_protocolformdialog_expressname", "label": "expressName()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1344"}, {"id": "protocol_protocolformdialog_for", "label": "for()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L2070"}, {"id": "protocol_protocolformdialog_if", "label": "if()", "file_type": "code", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L2607"}], "edges": [{"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "element_plus", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1152", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "icons_vue", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1153", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_collection_protocol", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1165", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_business", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1171", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_utils_download_attachment", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1172", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_admin", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1173", "weight": 1.0}, {"source": "users_wuzilong_work_00code_zkxw_web_admin_src_views_cell_storage_protocol_protocolformdialog_vue", "target": "users_wuzilong_work_00code_zkxw_web_admin_src_api_ethnic", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "/Users/wuzilong/work/00code/zkxw/web-admin/src/views/cell-storage/protocol/ProtocolFormDialog.vue", "source_location": "L1185", "weight": 1.0}, {"source":Line truncated
+6 -3
View File
@@ -24,6 +24,7 @@ import { StorageConfig } from '@/utils/storage/storage-config'
import { fetchLogout } from '@/api/auth'
import { RoutesAlias } from '@/router/routesAlias'
import { resolveSafeRedirectTarget } from '@/utils/router'
import { pickUserAvatarRaw } from '@/utils/user-avatar'
/**
* 用户状态管理
@@ -57,11 +58,13 @@ export const useUserStore = defineStore(
* @param newInfo 新的用户信息
*/
const setUserInfo = (newInfo: Partial<Api.Auth.UserInfo> & Record<string, any>) => {
const merged = { ...(info.value || {}), ...(newInfo || {}) }
const avatarRaw = pickUserAvatarRaw(newInfo) || pickUserAvatarRaw(merged)
info.value = {
...(info.value || {}),
...(newInfo || {}),
...merged,
buttons: newInfo?.buttons ?? info.value?.buttons ?? [],
userName: newInfo?.userName ?? newInfo?.username ?? info.value?.userName ?? ''
userName: newInfo?.userName ?? newInfo?.username ?? info.value?.userName ?? '',
avatarUrl: avatarRaw || undefined
} as Api.Auth.UserInfo
}
+3 -1
View File
@@ -9,10 +9,12 @@ declare namespace Api {
username: string
realName?: string
phone?: string
email?: string
sex?: string
remark?: string
role: string
regionId?: string
regionName?: string
email?: string
roles?: string[]
/** 自定义头像 URL,空则前端使用 `/avatart.jpg` */
avatarUrl?: string | null
@@ -0,0 +1,204 @@
/**
* 分期参数变更(期数 / 间隔 / 开始时间),非缴费模式切换
* 规则见 docs/superpowers/specs/2026-06-04-protocol-pay-mode-switch-design.md §分期参数变更
*/
import {
calcFqInstallmentDueDate,
calcInstallmentDueAmounts,
sortFqPaymentDetails
} from '@/utils/protocol-payment-installment'
import {
calcRemainingAmount,
createPaymentDetailRow,
type DetailLike,
type EvaluateResult
} from '@/utils/protocol-pay-mode-switch'
export interface FqParams {
installmentCount: number | null
installmentIntervalMonths: number | null
installmentStartDate: string
}
const BLOCKING_STATUSES = new Set(['jfqrz', 'tfqrz', 'ytf'])
function formatMoneySummary(v: number): string {
return `¥${v.toFixed(2).replace(/\B(?=(\d{3})+(?!\d))/g, ',')}`
}
function countByStatus(details: DetailLike[], status: string): number {
return details.filter((d) => String(d.payStatus || 'dfj') === status).length
}
export function fqParamsSnapshot(params: FqParams): FqParams {
return {
installmentCount: params.installmentCount,
installmentIntervalMonths: params.installmentIntervalMonths,
installmentStartDate: params.installmentStartDate || ''
}
}
export function isSameFqParams(a: FqParams, b: FqParams): boolean {
return (
Number(a.installmentCount) === Number(b.installmentCount) &&
Number(a.installmentIntervalMonths) === Number(b.installmentIntervalMonths) &&
String(a.installmentStartDate || '') === String(b.installmentStartDate || '')
)
}
export function getPaidInstallmentRows(details: DetailLike[]): DetailLike[] {
return [...details]
.filter((d) => String(d.payStatus) === 'yjf')
.sort((a, b) => Number(a.installmentNo || 0) - Number(b.installmentNo || 0))
}
function maxPaidInstallmentNo(details: DetailLike[]): number {
return getPaidInstallmentRows(details).reduce(
(max, d) => Math.max(max, Number(d.installmentNo || 0)),
0
)
}
export function evaluateFqParamsChange(
_oldParams: FqParams,
newParams: FqParams,
details: DetailLike[],
contractAmount: number | null
): EvaluateResult {
const rows = details.filter((d) => !d._voided)
const newCount = Number(newParams.installmentCount)
const interval = Number(newParams.installmentIntervalMonths)
const startDate = String(newParams.installmentStartDate || '')
if (!newCount || newCount < 1) {
return { action: 'blocked', reason: '请填写有效的分期期数。' }
}
if (!interval || interval <= 0) {
return { action: 'blocked', reason: '请填写有效的每期间隔(月)。' }
}
if (!startDate) {
return { action: 'blocked', reason: '请填写分期开始时间。' }
}
if (rows.some((d) => BLOCKING_STATUSES.has(String(d.payStatus || '')))) {
return {
action: 'blocked',
reason: '存在缴费确认中或退费处理中的明细,请先完成相关流程后再修改分期参数。'
}
}
const paidRows = getPaidInstallmentRows(rows)
const maxPaidNo = maxPaidInstallmentNo(rows)
if (maxPaidNo > 0 && newCount < maxPaidNo) {
return {
action: 'blocked',
reason: `已有第 ${maxPaidNo} 期缴费记录,分期期数不能少于 ${maxPaidNo}。`
}
}
const dfjCount = countByStatus(rows, 'dfj')
if (paidRows.length === 0) {
if (rows.length === 0) {
return { action: 'noop' }
}
return {
action: 'confirm',
summary: `将按新参数(${newCount} 期)重新生成缴费明细,原有 ${rows.length} 条待缴计划将被替换。是否继续?`
}
}
const remaining = calcRemainingAmount(contractAmount, rows)
const newUnpaidCount = newCount - paidRows.length
if (newUnpaidCount < 0) {
return {
action: 'blocked',
reason: `已有 ${paidRows.length} 期缴费记录,分期期数不能少于 ${paidRows.length}。`
}
}
if (remaining <= 0 && dfjCount > 0) {
return { action: 'blocked', reason: '已缴清,无需调整分期计划。' }
}
const countChanged = Number(_oldParams.installmentCount) !== newCount
if (countChanged) {
return {
action: 'confirm',
summary: `将保留 ${paidRows.length} 期已缴记录,作废 ${dfjCount} 期未缴计划,并重新生成 ${newUnpaidCount} 期未缴明细(剩余 ${formatMoneySummary(remaining)})。是否继续?`
}
}
return {
action: 'confirm',
summary: `将保留已缴记录,并更新 ${dfjCount} 期未缴计划的应缴时间与金额(剩余 ${formatMoneySummary(remaining)})。是否继续?`
}
}
/** 按新分期参数重建明细:保留 yjf,作废原 dfj,生成剩余期次 */
export function applyFqParamsChange(
params: FqParams,
details: DetailLike[],
contractAmount: number | null
): DetailLike[] {
const count = Number(params.installmentCount) || 0
const interval = Number(params.installmentIntervalMonths) || 0
const startDate = params.installmentStartDate || ''
if (!count || !interval || !startDate) return details
const paidRows = getPaidInstallmentRows(details).map((d) => ({
...d,
_payModeLocked: true
}))
const remainingCount = count - paidRows.length
const remaining = calcRemainingAmount(contractAmount, paidRows)
const amounts =
remainingCount > 0
? calcInstallmentDueAmounts(remaining, remainingCount)
: []
const result: DetailLike[] = [...paidRows]
for (let i = 0; i < remainingCount; i++) {
const periodIndex = paidRows.length + i
result.push(
createPaymentDetailRow({
dueAmount: amounts[i] ?? null,
installmentNo: periodIndex + 1,
installmentDueDate: calcFqInstallmentDueDate(startDate, periodIndex, interval),
expanded: false
})
)
}
return sortFqPaymentDetails(result)
}
/** 首次填充分期参数时生成明细(无需确认) */
export function generateInitialFqDetails(
params: FqParams,
contractAmount: number | null
): DetailLike[] {
const count = Number(params.installmentCount) || 0
const interval = Number(params.installmentIntervalMonths) || 0
const startDate = params.installmentStartDate || ''
if (!count || !interval || !startDate) return []
const amounts = calcInstallmentDueAmounts(contractAmount, count)
const result: DetailLike[] = []
for (let i = 0; i < count; i++) {
result.push(
createPaymentDetailRow({
dueAmount: amounts[i] ?? null,
installmentNo: i + 1,
installmentDueDate: calcFqInstallmentDueDate(startDate, i, interval),
expanded: i === 0
})
)
}
return result
}
@@ -0,0 +1,216 @@
/**
* 采集协议单 · 缴费模式切换(dj ↔ fq)
* 规则见 docs/superpowers/specs/2026-06-04-protocol-pay-mode-switch-design.md
*/
import {
calcFqInstallmentDueDate,
calcInstallmentDueAmounts
} from '@/utils/protocol-payment-installment'
export type PayMode = 'dj' | 'fq'
export type DetailLike = Record<string, any>
const LOCKED_STATUSES = new Set(['jfqrz', 'yjf', 'tfqrz', 'ytf'])
const BLOCKING_STATUSES = new Set(['jfqrz', 'tfqrz', 'ytf'])
export interface PayModeSwitchContext {
contractAmount: number | null
lumpSumDeadline: string
installmentCount: number | null
installmentIntervalMonths: number | null
installmentStartDate: string
}
export type EvaluateResult =
| { action: 'noop' }
| { action: 'blocked'; reason: string }
| { action: 'confirm'; summary: string }
export function isPayDetailLocked(detail: DetailLike): boolean {
if (detail._payModeLocked) return true
return LOCKED_STATUSES.has(String(detail.payStatus || ''))
}
export function markPayDetailLocks(details: DetailLike[]): void {
for (const d of details) {
d._payModeLocked = isPayDetailLocked(d)
}
}
export function sumPaidAmount(details: DetailLike[]): number {
return details
.filter((d) => String(d.payStatus) === 'yjf')
.reduce((sum, d) => sum + (Number(d.dueAmount) || 0), 0)
}
export function calcRemainingAmount(
contractAmount: number | null,
details: DetailLike[]
): number {
if (contractAmount == null) return 0
const remaining = Number(contractAmount) - sumPaidAmount(details)
return Math.round(remaining * 100) / 100
}
function formatMoneySummary(v: number): string {
return `¥${v.toFixed(2).replace(/\B(?=(\d{3})+(?!\d))/g, ',')}`
}
function activeDetails(details: DetailLike[]): DetailLike[] {
return details.filter((d) => !d._voided)
}
function hasBlockingStatus(details: DetailLike[]): boolean {
return details.some((d) => BLOCKING_STATUSES.has(String(d.payStatus || '')))
}
function countByStatus(details: DetailLike[], status: string): number {
return details.filter((d) => String(d.payStatus || 'dfj') === status).length
}
export function createPaymentDetailRow(options: {
dueAmount: number | null
installmentDueDate?: string
installmentNo?: number | null
payStatus?: string
expanded?: boolean
}): DetailLike {
const now = new Date()
const pad = (n: number) => String(n).padStart(2, '0')
const defaultTime = `${now.getFullYear()}-${pad(now.getMonth() + 1)}-${pad(now.getDate())} ${pad(now.getHours())}:${pad(now.getMinutes())}:${pad(now.getSeconds())}`
return {
transferType: '',
dueAmount: options.dueAmount,
transferAmount: null,
transferTime: defaultTime,
payStatus: options.payStatus ?? 'dfj',
installmentNo: options.installmentNo ?? null,
installmentDueDate: options.installmentDueDate ?? '',
_expanded: options.expanded ?? false,
_payModeLocked: false,
attachments: []
}
}
export function evaluatePayModeSwitch(
fromMode: PayMode,
toMode: PayMode,
details: DetailLike[],
ctx: PayModeSwitchContext
): EvaluateResult {
if (fromMode === toMode) return { action: 'noop' }
const rows = activeDetails(details)
if (hasBlockingStatus(rows)) {
return {
action: 'blocked',
reason: '存在缴费确认中或退费处理中的明细,请先完成相关流程后再切换缴费模式。'
}
}
if (fromMode === 'dj' && toMode === 'fq') {
if (rows.some((d) => isPayDetailLocked(d))) {
return {
action: 'blocked',
reason: '趸交已有缴费记录,无法改为分期。'
}
}
const count = ctx.installmentCount || 6
return {
action: 'confirm',
summary: `将清除当前趸交计划,按 ${count} 期分期重新生成缴费明细。是否继续?`
}
}
if (fromMode === 'fq' && toMode === 'dj') {
const dfjCount = countByStatus(rows, 'dfj')
const yjfCount = countByStatus(rows, 'yjf')
if (yjfCount > 0 && dfjCount === 0) {
return {
action: 'blocked',
reason: '分期已全部缴清,无需改为趸交。'
}
}
const remaining = calcRemainingAmount(ctx.contractAmount, rows)
if (yjfCount > 0 && remaining <= 0) {
return {
action: 'blocked',
reason: '已缴清,无需改为趸交。'
}
}
if (yjfCount > 0) {
return {
action: 'confirm',
summary: `将作废 ${dfjCount} 期未缴计划,保留 ${yjfCount} 期已缴记录,并新增 1 条趸交明细(剩余 ${formatMoneySummary(remaining)})。是否继续?`
}
}
return {
action: 'confirm',
summary: `将作废 ${dfjCount || rows.length} 期分期计划,并合并为 1 条趸交明细。是否继续?`
}
}
return { action: 'noop' }
}
export function applyPayModeSwitch(
fromMode: PayMode,
toMode: PayMode,
details: DetailLike[],
ctx: PayModeSwitchContext
): DetailLike[] {
const rows = activeDetails(details)
if (fromMode === 'dj' && toMode === 'fq') {
const count = Number(ctx.installmentCount) || 6
const interval = Number(ctx.installmentIntervalMonths) || 6
const startDate = ctx.installmentStartDate || ''
const amounts = calcInstallmentDueAmounts(ctx.contractAmount, count)
const result: DetailLike[] = []
for (let i = 0; i < count; i++) {
result.push(
createPaymentDetailRow({
dueAmount: amounts[i] ?? null,
installmentNo: i + 1,
installmentDueDate:
startDate && interval ? calcFqInstallmentDueDate(startDate, i, interval) : '',
expanded: i === 0
})
)
}
return result
}
if (fromMode === 'fq' && toMode === 'dj') {
const yjfRows = rows
.filter((d) => String(d.payStatus) === 'yjf')
.map((d) => ({ ...d, _payModeLocked: true }))
const remaining = calcRemainingAmount(ctx.contractAmount, yjfRows)
const deadline = ctx.lumpSumDeadline || ''
const dueAmount = yjfRows.length ? remaining : ctx.contractAmount
const newDjRow = createPaymentDetailRow({
dueAmount,
installmentNo: null,
installmentDueDate: deadline,
expanded: yjfRows.length === 0
})
return [...yjfRows, newDjRow]
}
return rows
}
/** 趸交模式下是否还可添加待缴明细 */
export function canAddPaymentDetail(payMode: string, details: DetailLike[]): boolean {
if (payMode === 'fq') return true
const dfjCount = details.filter(
(d) => !isPayDetailLocked(d) && String(d.payStatus || 'dfj') === 'dfj'
).length
return dfjCount < 1
}
@@ -1,5 +1,7 @@
/** 分期缴费:期数对齐、应缴日/金额计算(与 ProtocolFormDialog 逻辑一致) */
const DAYS_PER_MONTH = 30
export function addMonthsYmd(dateStr: string, months: number): string {
const compact = String(dateStr || '').replace(/-/g, '')
if (compact.length !== 8) return ''
@@ -28,13 +30,34 @@ export function addDaysYmd(dateStr: string, days: number): string {
return `${yy}${mm}${dd}`
}
/** 分期应缴费时间:第 1 期=开始时间,第 2 期起在按月递增基础上提前 10 天 */
/** 整数部分按日历加月,小数部分按 30 天/月换算为天数 */
export function addIntervalMonthsYmd(dateStr: string, totalMonths: number): string {
const compact = String(dateStr || '').replace(/-/g, '')
if (compact.length !== 8 || !Number.isFinite(totalMonths) || totalMonths === 0) {
return compact.length === 8 ? compact : ''
}
const wholeMonths = Math.trunc(totalMonths)
const fracMonths = totalMonths - wholeMonths
let result = compact
if (wholeMonths !== 0) {
result = addMonthsYmd(result, wholeMonths)
}
if (fracMonths !== 0) {
const days = Math.round(fracMonths * DAYS_PER_MONTH)
if (days !== 0) {
result = addDaysYmd(result, days)
}
}
return result
}
/** 分期应缴费时间:第 1 期=开始时间,第 2 期起在间隔递增基础上提前 10 天 */
export function calcFqInstallmentDueDate(
startDate: string,
index: number,
intervalMonths: number
): string {
const base = addMonthsYmd(startDate, index * intervalMonths)
const base = addIntervalMonthsYmd(startDate, index * intervalMonths)
if (index >= 1) {
return addDaysYmd(base, -10)
}
+80 -5
View File
@@ -1,17 +1,92 @@
/** 未设置头像时使用 `public/avatart.jpg`(根路径 `/avatart.jpg`) */
export const DEFAULT_USER_AVATAR_URL = '/avatart.jpg'
/** 未设置头像时使用 `public/avatart.jpg` */
function joinPublicAsset(path: string): string {
const base = import.meta.env.BASE_URL || '/'
const prefix = base.endsWith('/') ? base : `${base}/`
return `${prefix}${path.replace(/^\//, '')}`
}
export const DEFAULT_USER_AVATAR_URL = joinPublicAsset('avatart.jpg')
/** 本地/部署环境由 .env 配置;docker 默认走 Nginx `/minio/zkxw` 反代 */
const minioBaseUrl = (import.meta.env.VITE_MINIO_BASE_URL || '/minio/zkxw').replace(/\/$/, '')
/** @deprecated 各角色默认已统一为默认头像图,保留参数仅为兼容旧调用 */
export function defaultAvatarPathByRole(_role: string | undefined): string {
return DEFAULT_USER_AVATAR_URL
}
/** 展示用头像:`avatarUrl` 非空则用其值,否则用默认图 */
/**
* 将库中头像值规范为存储相对路径(如 avatar/202606/04/xxx.jpeg)。
* 兼容历史数据里写入的完整 URL(如 https://www.chengyantek.cn/zkxw/avatar/...)。
*/
export function normalizeAvatarStorageKey(raw: string | null | undefined): string {
const u = raw != null ? String(raw).trim() : ''
if (!u) return ''
if (!/^https?:\/\//i.test(u) && !u.startsWith('/')) return u
const marker = '/avatar/'
const lower = u.toLowerCase()
const idx = lower.indexOf(marker)
if (idx >= 0) {
return `avatar/${u.slice(idx + marker.length)}`
}
if (u.startsWith('/')) {
const parts = u.split('/').filter(Boolean)
const avatarIdx = parts.findIndex((p) => p === 'avatar')
if (avatarIdx >= 0) return parts.slice(avatarIdx).join('/')
}
return u
}
/** 从用户信息对象读取原始头像字段(兼容 avatar / avatarUrl) */
export function pickUserAvatarRaw(
source: { avatarUrl?: string | null; avatar?: string | null } | null | undefined
): string {
if (!source) return ''
const raw = source.avatarUrl ?? source.avatar
return normalizeAvatarStorageKey(raw != null ? String(raw).trim() : '')
}
/** 是否已设置自定义头像(非空即视为已设置) */
export function hasCustomUserAvatar(avatarUrl: string | null | undefined): boolean {
return Boolean(normalizeAvatarStorageKey(avatarUrl))
}
/** 解析上传接口返回的图片地址 */
export function pickUploadAvatarUrl(res: unknown): string {
if (res == null) return ''
if (typeof res === 'string') return normalizeAvatarStorageKey(res)
const record = res as Record<string, unknown>
const nested = record.data as Record<string, unknown> | undefined
const raw =
record.url ?? record.fileUrl ?? record.file_url ?? nested?.url ?? nested?.fileUrl
return typeof raw === 'string' ? normalizeAvatarStorageKey(raw) : ''
}
/** MinIO 相对路径或完整 URL → 浏览器可访问地址 */
export function resolveStorageFileUrl(url: string | null | undefined): string {
const key = normalizeAvatarStorageKey(url)
if (!key) return ''
if (/^https?:\/\//i.test(key)) return key
if (key.startsWith('/')) return key
return `${minioBaseUrl}/${key.replace(/^\//, '')}`
}
/** 展示用头像:优先用户表头像,否则默认图 */
export function resolveUserAvatarUrl(
avatarUrl: string | null | undefined,
role: string | undefined
): string {
const u = avatarUrl != null ? String(avatarUrl).trim() : ''
if (u) return u
const key = normalizeAvatarStorageKey(avatarUrl)
if (key) return resolveStorageFileUrl(key)
return defaultAvatarPathByRole(role)
}
/** 从用户对象直接得到展示用头像 URL */
export function resolveUserAvatarFromInfo(
source: { avatarUrl?: string | null; avatar?: string | null; role?: string } | null | undefined
): string {
return resolveUserAvatarUrl(pickUserAvatarRaw(source), source?.role)
}
@@ -758,7 +758,7 @@
step="any"
:min="1"
style="width: 100%"
@change="tryGenerateInstallmentDetails"
@change="handleFqParamsChange"
/>
</el-form-item>
<el-form-item label="每期间隔(月)">
@@ -766,9 +766,9 @@
v-model="formData.installmentIntervalMonths"
type="number"
step="any"
:min="1"
:min="0.1"
style="width: 100%"
@change="tryGenerateInstallmentDetails"
@change="handleFqParamsChange"
/>
</el-form-item>
<el-form-item label="分期开始时间">
@@ -780,7 +780,7 @@
placeholder="选择开始时间"
clearable
style="width: 100%"
@change="tryGenerateInstallmentDetails"
@change="handleFqParamsChange"
/>
</el-form-item>
</template>
@@ -790,7 +790,11 @@
<!-- 缴费明细 -->
<div class="section-subtitle" style="margin-top: 20px">缴费明细</div>
<div style="margin-bottom: 14px">
<el-button type="primary" @click="addPaymentDetail">
<el-button
type="primary"
:disabled="!canAddPaymentDetail(formData.payMode, formData.paymentDetails)"
@click="addPaymentDetail"
>
<el-icon><Plus /></el-icon>
添加明细
</el-button>
@@ -834,6 +838,7 @@
{{ paymentDetailSummary(detail) }}
</span>
<el-button
v-if="!isPayDetailLocked(detail)"
link
type="danger"
size="small"
@@ -872,6 +877,7 @@
<AmountInput
v-model="detail.transferAmount"
:min="0"
:disabled="isPayDetailLocked(detail)"
placeholder="请输入转账金额"
/>
</el-form-item>
@@ -882,6 +888,7 @@
value-format="YYYY-MM-DD HH:mm:ss"
placeholder="选择时间"
clearable
:disabled="isPayDetailLocked(detail)"
style="width: 100%"
/>
</el-form-item>
@@ -889,6 +896,7 @@
<el-select
v-model="detail.payStatus"
placeholder="状态"
:disabled="isPayDetailLocked(detail)"
style="width: 100%"
>
<el-option label="待缴费" value="dfj" />
@@ -906,12 +914,13 @@
format="YYYY-MM-DD"
placeholder="选择应缴费时间"
clearable
:disabled="isPayDetailLocked(detail)"
style="width: 100%"
/>
</el-form-item>
</div>
<!-- 每条明细的附件上传区 -->
<div class="payment-detail-card__attachments">
<div v-if="!isPayDetailLocked(detail)" class="payment-detail-card__attachments">
<div class="attachment-upload">
<div class="attachment-list">
<el-upload
@@ -1175,10 +1184,24 @@
} from '@/api/admin'
import { fetchEthnicList, type EthnicOption } from '@/api/ethnic'
import { useUserStore } from '@/store/modules/user'
import { syncFqPaymentDetailRowCount } from '@/utils/protocol-payment-installment'
import {
calcFqInstallmentDueDate,
syncFqPaymentDetailRowCount
} from '@/utils/protocol-payment-installment'
applyPayModeSwitch,
canAddPaymentDetail,
evaluatePayModeSwitch,
isPayDetailLocked,
markPayDetailLocks,
sumPaidAmount,
type PayMode
} from '@/utils/protocol-pay-mode-switch'
import {
applyFqParamsChange,
evaluateFqParamsChange,
fqParamsSnapshot,
generateInitialFqDetails,
isSameFqParams,
type FqParams
} from '@/utils/protocol-fq-params-change'
import AmountInput from '@/components/common/amount-input/index.vue'
import { formatMoneyDisplay } from '@/utils/money-format'
import {
@@ -1199,6 +1222,16 @@
const userStore = useUserStore()
/** 上次确认生效的缴费模式(用于切换取消/拦截时回滚) */
const lastConfirmedPayMode = ref<PayMode>('dj')
/** 上次确认生效的分期参数(用于编辑时修改期数/间隔/开始时间回滚) */
const lastConfirmedFqParams = ref<FqParams>({
installmentCount: null,
installmentIntervalMonths: null,
installmentStartDate: ''
})
const customerId = ref<string | null>(null)
const customerOptions = ref<
Array<{ id: string; customerName: string; phoneNo: string; idCardNo: string }>
@@ -1544,6 +1577,12 @@
batchTransportVisible.value = false
Object.assign(batchTransport, createEmptyTransport())
activeFormTab.value = 'basic'
lastConfirmedPayMode.value = 'dj'
lastConfirmedFqParams.value = {
installmentCount: null,
installmentIntervalMonths: null,
installmentStartDate: ''
}
}
function scrollToSection(key: string) {
@@ -1627,6 +1666,7 @@
}
function addPaymentDetail() {
if (!canAddPaymentDetail(formData.payMode, formData.paymentDetails)) return
const now = new Date()
const pad = (n: number) => String(n).padStart(2, '0')
const defaultTime = `${now.getFullYear()}-${pad(now.getMonth() + 1)}-${pad(now.getDate())} ${pad(now.getHours())}:${pad(now.getMinutes())}:${pad(now.getSeconds())}`
@@ -1702,77 +1742,180 @@
return Number.isFinite(n) ? Math.trunc(n) : undefined
}
function toFloatOrUndefined(val: unknown): number | undefined {
if (val == null || val === '') return undefined
const n = Number(val)
return Number.isFinite(n) ? n : undefined
}
function fqPaymentContext() {
return {
payMode: formData.payMode,
installmentCount: toIntOrUndefined(formData.installmentCount) ?? null,
contractAmount: formData.contractAmount,
installmentStartDate: formData.installmentStartDate,
installmentIntervalMonths: toIntOrUndefined(formData.installmentIntervalMonths) ?? null
installmentIntervalMonths: toFloatOrUndefined(formData.installmentIntervalMonths) ?? null
}
}
/** 分期模式:三个参数都填好后生成/补齐缴费明细行(已有明细时仅补齐期次,不整表覆盖) */
function tryGenerateInstallmentDetails() {
if (formData.payMode !== 'fq') return
const count = formData.installmentCount
const interval = formData.installmentIntervalMonths
const startDate = formData.installmentStartDate
if (!count || !interval || !startDate) return
function payModeSwitchContext() {
return {
contractAmount: formData.contractAmount,
lumpSumDeadline: formData.lumpSumDeadline,
installmentCount: toIntOrUndefined(formData.installmentCount) ?? null,
installmentIntervalMonths: toFloatOrUndefined(formData.installmentIntervalMonths) ?? null,
installmentStartDate: formData.installmentStartDate
}
}
if (formData.paymentDetails.length) {
syncFqPaymentDetailRowCount(fqPaymentContext(), formData.paymentDetails)
syncPaymentDueAmounts()
formData.paymentDetails.forEach((d, i) => {
d.installmentNo = i + 1
d.installmentDueDate = calcFqInstallmentDueDate(startDate, i, interval)
})
function getFqParamsFromForm(): FqParams {
return {
installmentCount: toIntOrUndefined(formData.installmentCount) ?? null,
installmentIntervalMonths: toFloatOrUndefined(formData.installmentIntervalMonths) ?? null,
installmentStartDate: formData.installmentStartDate || ''
}
}
function restoreFqParams(params: FqParams) {
formData.installmentCount = params.installmentCount
formData.installmentIntervalMonths = params.installmentIntervalMonths
formData.installmentStartDate = params.installmentStartDate || ''
}
function syncLastConfirmedFqParams() {
lastConfirmedFqParams.value = fqParamsSnapshot(getFqParamsFromForm())
}
/**
* 分期参数变更(期数 / 间隔 / 开始时间):校验 → 确认 → 重建未缴期次
* 与缴费模式切换独立;保留 yjf 已缴行,作废原 dfj 后按剩余金额重建。
*/
async function handleFqParamsChange() {
if (formData.payMode !== 'fq') return
const newParams = getFqParamsFromForm()
const oldParams = lastConfirmedFqParams.value
if (isSameFqParams(oldParams, newParams)) return
if (
!newParams.installmentCount ||
!newParams.installmentIntervalMonths ||
!newParams.installmentStartDate
) {
return
}
const dueAmounts = calcInstallmentDueAmounts(formData.contractAmount, count)
const details = []
for (let i = 0; i < count; i++) {
details.push({
transferType: '',
dueAmount: dueAmounts[i] ?? null,
transferAmount: null,
transferTime: '',
payStatus: 'dfj',
installmentNo: i + 1,
installmentDueDate: calcFqInstallmentDueDate(startDate, i, interval),
attachments: [] as Array<{
id?: string
fileName: string
fileUrl: string
fileSize: number
fileSizeDisplay?: string
fileType?: string
_uploading?: boolean
}>
})
if (formData.paymentDetails.length === 0) {
formData.paymentDetails = generateInitialFqDetails(newParams, formData.contractAmount)
initPaymentDetailExpandFlags(formData.paymentDetails)
markPayDetailLocks(formData.paymentDetails)
syncLastConfirmedFqParams()
return
}
initPaymentDetailExpandFlags(details)
formData.paymentDetails = details
const evaluation = evaluateFqParamsChange(
oldParams,
newParams,
formData.paymentDetails,
formData.contractAmount
)
if (evaluation.action === 'noop') {
syncLastConfirmedFqParams()
return
}
if (evaluation.action === 'blocked') {
restoreFqParams(oldParams)
await ElMessageBox.alert(evaluation.reason, '无法修改分期参数', { type: 'warning' })
return
}
if (evaluation.action === 'confirm') {
try {
await ElMessageBox.confirm(evaluation.summary, '修改分期参数', {
confirmButtonText: '确认修改',
cancelButtonText: '取消',
type: 'warning'
})
} catch {
restoreFqParams(oldParams)
return
}
}
formData.paymentDetails = applyFqParamsChange(
newParams,
formData.paymentDetails,
formData.contractAmount
)
initPaymentDetailExpandFlags(formData.paymentDetails)
markPayDetailLocks(formData.paymentDetails)
syncLastConfirmedFqParams()
}
/** 缴费模式切换回调 */
function onPayModeChange(val: string) {
if (val === 'fq') {
applyFqPaymentDefaults({ resetCountInterval: true })
tryGenerateInstallmentDetails()
} else {
// 趸交模式:将趸交截止时间同步到所有明细的应缴费时间
syncPaymentDueAmounts()
/** 缴费模式切换:校验 → 确认 → 变换明细 */
async function onPayModeChange(val: string) {
const toMode = val as PayMode
const fromMode = lastConfirmedPayMode.value
if (toMode === fromMode) return
const evaluation = evaluatePayModeSwitch(
fromMode,
toMode,
formData.paymentDetails,
payModeSwitchContext()
)
if (evaluation.action === 'blocked') {
formData.payMode = fromMode
await ElMessageBox.alert(evaluation.reason, '无法切换缴费模式', { type: 'warning' })
return
}
if (evaluation.action === 'confirm') {
try {
await ElMessageBox.confirm(evaluation.summary, '切换缴费模式', {
confirmButtonText: '确认切换',
cancelButtonText: '取消',
type: 'warning'
})
} catch {
formData.payMode = fromMode
return
}
}
if (toMode === 'fq') {
applyFqPaymentDefaults({ resetCountInterval: false })
}
formData.paymentDetails = applyPayModeSwitch(
fromMode,
toMode,
formData.paymentDetails,
payModeSwitchContext()
)
initPaymentDetailExpandFlags(formData.paymentDetails)
markPayDetailLocks(formData.paymentDetails)
if (toMode === 'dj') {
syncLumpSumDueDate()
}
lastConfirmedPayMode.value = toMode
if (toMode === 'fq') {
syncLastConfirmedFqParams()
}
}
/** 趸交模式:将趸交截止时间同步到所有缴费明细的应缴费时间 */
/** 趸交模式:将趸交截止时间同步到待缴明细的应缴费时间 */
function syncLumpSumDueDate() {
if (formData.payMode !== 'dj') return
const deadline = formData.lumpSumDeadline || ''
formData.paymentDetails.forEach((d) => {
if (isPayDetailLocked(d)) return
d.installmentDueDate = deadline
})
}
@@ -1885,6 +2028,7 @@
formData.installmentStartDate = String(pay.installmentStartDate || '')
if (formData.payMode === 'fq') {
applyFqPaymentDefaults()
syncLastConfirmedFqParams()
}
}
@@ -1896,8 +2040,10 @@
}))
initPaymentDetailExpandFlags(details)
formData.paymentDetails = details
markPayDetailLocks(formData.paymentDetails)
}
syncFqPaymentDetailRowCount(fqPaymentContext(), formData.paymentDetails)
lastConfirmedPayMode.value = (formData.payMode === 'fq' ? 'fq' : 'dj') as PayMode
const pa =
(row as any).protocolAttachments || (bundle.protocol as any)?.protocolAttachments || ''
@@ -2057,11 +2203,13 @@
contractAmount: formData.contractAmount ?? undefined,
lumpSumDeadline: formData.lumpSumDeadline || undefined,
installmentCount: toIntOrUndefined(formData.installmentCount),
installmentIntervalMonths: toIntOrUndefined(formData.installmentIntervalMonths),
installmentIntervalMonths: toFloatOrUndefined(formData.installmentIntervalMonths),
installmentStartDate: formData.installmentStartDate || undefined
},
paymentDetails: formData.paymentDetails.map(({ _expanded, ...d }) => ({
transferType: d.transferType,
paymentDetails: formData.paymentDetails.map(
({ _expanded, _payModeLocked, _voided, ...d }) => ({
id: d.id,
transferType: d.transferType,
dueAmount: d.dueAmount,
transferAmount: d.transferAmount,
transferTime: d.transferTime,
@@ -2087,7 +2235,7 @@
fileSizeDisplay: a.fileSizeDisplay,
fileType: a.fileType
}))
}))
}))
}
if (isEdit.value && editingId.value) {
@@ -2527,21 +2675,29 @@
return amounts
}
/** 按缴费模式同步各明细应缴费金额 */
/** 按缴费模式同步各明细应缴费金额(跳过已锁定明细) */
function syncPaymentDueAmounts() {
const contract = formData.contractAmount
if (contract == null) return
if (formData.payMode === 'dj') {
formData.paymentDetails.forEach((d) => {
d.dueAmount = contract
const paidSum = sumPaidAmount(formData.paymentDetails)
const remaining = Math.round((Number(contract) - paidSum) * 100) / 100
const dfjRows = formData.paymentDetails.filter(
(d) => !isPayDetailLocked(d) && String(d.payStatus || 'dfj') === 'dfj'
)
const targetAmount = paidSum > 0 ? remaining : contract
dfjRows.forEach((d, i) => {
if (i === 0) d.dueAmount = targetAmount
})
return
}
if (formData.payMode === 'fq') {
if (formData.paymentDetails.some((d) => isPayDetailLocked(d))) return
const count = formData.installmentCount || formData.paymentDetails.length
if (!count) return
const amounts = calcInstallmentDueAmounts(Number(contract), count)
const amounts = calcInstallmentDueAmounts(Number(contract), Number(count))
formData.paymentDetails.forEach((d, i) => {
if (isPayDetailLocked(d)) return
if (amounts[i] !== undefined) d.dueAmount = amounts[i]
})
}