Add a column in family table to toggle genealogy feature
This commit is contained in:
		@@ -0,0 +1,3 @@
 | 
			
		||||
-- Remove column to toggle genealogy
 | 
			
		||||
ALTER TABLE public.families
 | 
			
		||||
    DROP COLUMN enable_genealogy;
 | 
			
		||||
@@ -0,0 +1,5 @@
 | 
			
		||||
-- Add column to toggle genealogy
 | 
			
		||||
ALTER TABLE public.families
 | 
			
		||||
    ADD enable_genealogy boolean NOT NULL DEFAULT false;
 | 
			
		||||
COMMENT
 | 
			
		||||
ON COLUMN public.families.enable_genealogy IS 'Specify whether genealogy feature is enabled for the family';
 | 
			
		||||
@@ -65,6 +65,7 @@ pub struct Family {
 | 
			
		||||
    pub name: String,
 | 
			
		||||
    pub invitation_code: String,
 | 
			
		||||
    pub disable_couple_photos: bool,
 | 
			
		||||
    pub enable_genealogy: bool,
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
impl Family {
 | 
			
		||||
 
 | 
			
		||||
@@ -29,6 +29,7 @@ diesel::table! {
 | 
			
		||||
        #[max_length = 7]
 | 
			
		||||
        invitation_code -> Varchar,
 | 
			
		||||
        disable_couple_photos -> Bool,
 | 
			
		||||
        enable_genealogy -> Bool,
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user