import { useWeAppAuthStore } from '@/common'
import { getApiLoading } from '@/common/libraries/apiLoading'
import { Apis } from '@/gen/Apis'
import useModel from './model'
const auth = useWeAppAuthStore()
export default {
  getShow(id:  number) {
    getApiLoading(Apis.Msg.MsgPropertyAnnouncements.Show, { id }).then(res => {
      useModel.showData.value = res?.data
      if(!res?.data?.is_read){
        Apis.Msg.MsgPropertyAnnouncements.MarkAsRead({ id })
      }
      console.log(res)
    })
  }
}
