承接 aldaflux/ical-bundle 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

aldaflux/ical-bundle

最新稳定版本:v1.0.10

Composer 安装命令:

composer require aldaflux/ical-bundle

包简介

Symfony Bundle to manage .ics iCal file (creating and eventually reading), forked for synfony 6

README 文档

README

Build Status Packagist Packagist GitHub license

Symfony Bundle to manage .ics iCal file (creating and eventually reading)

use of the library: https://github.com/jasvrcek/ICS

Setup

Add bundle to your project:

#composer require welp/ical-bundle
composer require aldaflux/ical-bundle

Configuration

In your config.yml:

aldaflux_ical:
    default_timezone: "Europe/Paris"
    default_prodid: "-//WelpIcalBundle//Calendar App//FR"

Usage

<?php

    ...


	use Aldaflux\IcalBundle\Factory\Factory;

    /**
     * Generate calendar event ICAL for welpAction
     * @Config\Route("/ical", name="app_ical")
     */
    public function icalAction(Factory $icalFactory)
    {

        //Create a calendar
        $calendar = $icalFactory->createCalendar();

        //Create an event
        $eventOne = $icalFactory->createCalendarEvent();
        $eventOne->setStart(new \DateTime())
            ->setSummary('Family reunion')
            ->setUid('event-uid');

        //add an Attendee
        $attendee = $icalFactory->createAttendee();
        $attendee->setValue('moe@example.com')
            ->setName('Moe Smith');
        $eventOne->addAttendee($attendee);

        //set the Organizer
        $organizer = $icalFactory->createOrganizer();
        $organizer->setValue('titouan@welp.fr')
            ->setName('Titouan BENOIT')
            ->setLanguage('fr');
        $eventOne->setOrganizer($organizer);

        //new event
        $eventTwo = $icalFactory->createCalendarEvent();
        $eventTwo->setStart(new \DateTime())
            ->setSummary('Dentist Appointment')
            ->setUid('event-uid');

        $calendar
            ->addEvent($eventOne)
            ->addEvent($eventTwo);

        $headers = array();
        $calendarResponse = new Aldaflux\IcalBundle\Response\CalendarResponse($calendar, 200, $headers);

        return $calendarResponse;

    }

统计信息

  • 总下载量: 3.06k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 13
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-12-04