feat: base 优化ticketd

This commit is contained in:
TianyangZhang 2025-11-05 15:54:48 +08:00
parent fbad9178ff
commit 3faf0fd760
2 changed files with 2 additions and 2 deletions

View File

@ -81,7 +81,7 @@ const ticketLog = ref([]);
const ticketId = ref(null); const ticketId = ref(null);
onMounted(() => { onMounted(() => {
// //
if (props.ticket_ && Object.keys(props.ticket_).length > 0) { if (props.ticket_ && props.ticket_.id) {
ticketId.value = props.ticket_.id ticketId.value = props.ticket_.id
getTicketDetail() getTicketDetail()
getTicketLog() getTicketLog()

View File

@ -50,7 +50,7 @@ onMounted(async () => {
const ticketId = ref(null); const ticketId = ref(null);
const actionShow = ref(false); const actionShow = ref(false);
const init = async () => { const init = async () => {
if (props.ticket_ && Object.keys(props.ticket_).length > 0) { if (props.ticket_ && props.ticket_.id) {
const isParticipant = const isParticipant =
(props.ticket_.participant_type === 1 && props.ticket_.participant === currentUser.value) || (props.ticket_.participant_type === 1 && props.ticket_.participant === currentUser.value) ||
(props.ticket_.participant_type === 2 && props.ticket_.participant.includes(currentUser.value)) (props.ticket_.participant_type === 2 && props.ticket_.participant.includes(currentUser.value))