mirror of
https://github.com/lennart-k/rustical.git
synced 2025-12-13 22:52:22 +00:00
changes around extensions
This commit is contained in:
@@ -13,8 +13,7 @@ use actix_web::web;
|
||||
use actix_web::{web::Data, HttpRequest};
|
||||
use async_trait::async_trait;
|
||||
use derive_more::derive::{From, Into, TryInto};
|
||||
use rustical_dav::extension::BoxedExtension;
|
||||
use rustical_dav::extensions::{CommonPropertiesExtension, CommonPropertiesProp};
|
||||
use rustical_dav::extensions::CommonPropertiesProp;
|
||||
use rustical_dav::privileges::UserPrivilegeSet;
|
||||
use rustical_dav::resource::{InvalidProperty, Resource, ResourceService};
|
||||
use rustical_store::auth::User;
|
||||
@@ -86,7 +85,7 @@ pub enum CalendarProp {
|
||||
#[serde(skip_deserializing, untagged)]
|
||||
#[from]
|
||||
#[try_into]
|
||||
ExtCommonProperties(CommonPropertiesProp<CalendarResource>),
|
||||
ExtCommonProperties(CommonPropertiesProp<Resourcetype>),
|
||||
|
||||
#[serde(untagged)]
|
||||
Invalid,
|
||||
@@ -106,12 +105,7 @@ impl Resource for CalendarResource {
|
||||
type Prop = CalendarProp;
|
||||
type Error = Error;
|
||||
type ResourceType = Resourcetype;
|
||||
|
||||
fn list_extensions() -> Vec<BoxedExtension<Self>> {
|
||||
vec![BoxedExtension::from_ext(CommonPropertiesExtension::<
|
||||
PrincipalResource,
|
||||
>::default())]
|
||||
}
|
||||
type PrincipalResource = PrincipalResource;
|
||||
|
||||
fn get_prop(
|
||||
&self,
|
||||
|
||||
Reference in New Issue
Block a user