<template>
    <div>
        <div class="container">
            <div class="card">
                <div class="font-size21 font-bold">{{ info.title }}</div>
                <div class="flex flex-x  flex-center2 m-top10 m-bottom10">
                    <van-tag :color="info.expiredFlag?'#EBF1FE':'#F5F5F5'" :text-color="info.expiredFlag?'#3974F6':'#AAAAAA'" size="large">{{
                    info.expiredFlag ? "进行中" : "已结束" }}</van-tag>
                    <div class="font-size13 C1 m-left12">{{ info.data }}</div>

                </div>
                <div class="y66666 font-size15 m-bottom5">享受服务条件：{{ info.resiSearchTagName }}</div>
                <div class="y66666 font-size15 m-bottom5">服务提供方：{{ info.assignText|| '--' }}</div>
                <div class="flex flex-x ">
                    <div class="y66666 font-size15 nowrap">服务时间：{{ info.assignInfo.serviceTimeStart }} 至</br>{{ info.assignInfo.serviceTimeEnd }} </div>
                    <div class="y66666 font-size15">{{ info.serviceData  }} </div>
                </div>
                <van-divider />
                <div  v-html="info.content"></div>
            </div>
        </div>
    </div>
</template>
<script>
import { icServiceWarmRecord } from '@/api/user'
export default {
    data() {
        return {
            info: {
                title: '鞠源社区为退役待就业的军人提供 就业岗位',
                content: '<p>县级以上地方人民政府退役士兵安置工作主管部门组织自主就业的退役士兵参加职业教育</p><p>县级以上地方人民政府退役士兵安置工作主管部门组织自主就业的退役士兵参加职业教育</p>', data: '2024-05-08 09:30'
                , status: 1, condition: '退役军人 40-60岁', provider: 'XXX就业指导中心', serviceData: "2024-05-08 13:00至2024-6-22 13:00"
            }
        }
    },
    created() {
    },
    mounted(){
        if(this.$route.query){
            this.icServiceWarmRecord(this.$route.query.id)
        }
    },
    methods: {
        async icServiceWarmRecord(id){
            let res = await icServiceWarmRecord(id)
            if(res){
                this.info = res;
                if(res.assignFlag === 1){
                    this.info.assignText = res.assignInfo.serviceScopeList.map(item=>item.objectName).join(',')
                }
            }
        }
    },
}
</script>
<style lang="scss" scoped></style>