mirror of
				https://github.com/strapi/strapi.git
				synced 2025-11-04 11:54:10 +00:00 
			
		
		
		
	Disable content type properties for ce
Signed-off-by: soupette <cyril.lpz@gmail.com>
This commit is contained in:
		
							parent
							
								
									fb28853848
								
							
						
					
					
						commit
						9f4a19fe3f
					
				@ -2,6 +2,7 @@ import React, { useMemo, useState } from 'react';
 | 
			
		||||
import { get } from 'lodash';
 | 
			
		||||
import PropTypes from 'prop-types';
 | 
			
		||||
import { Flex, Padded } from '@buffetjs/core';
 | 
			
		||||
import IS_DISABLED from 'ee_else_ce/components/Roles/ContentTypeCollapse/Collapse/utils/constants';
 | 
			
		||||
import { usePermissionsDataManager } from '../../../../hooks';
 | 
			
		||||
import { getCheckboxState, removeConditionKeyFromData } from '../../utils';
 | 
			
		||||
import CheckboxWithCondition from '../../CheckboxWithCondition';
 | 
			
		||||
@ -98,7 +99,7 @@ const Collapse = ({
 | 
			
		||||
                return (
 | 
			
		||||
                  <CheckboxWithCondition
 | 
			
		||||
                    key={actionId}
 | 
			
		||||
                    disabled={isFormDisabled}
 | 
			
		||||
                    disabled={isFormDisabled || IS_DISABLED}
 | 
			
		||||
                    hasConditions={hasConditions}
 | 
			
		||||
                    name={checkboxName}
 | 
			
		||||
                    onChange={onChangeParentCheckbox}
 | 
			
		||||
@ -111,7 +112,7 @@ const Collapse = ({
 | 
			
		||||
              return (
 | 
			
		||||
                <CheckboxWithCondition
 | 
			
		||||
                  key={actionId}
 | 
			
		||||
                  disabled={isFormDisabled}
 | 
			
		||||
                  disabled={isFormDisabled || IS_DISABLED}
 | 
			
		||||
                  hasConditions={hasConditions}
 | 
			
		||||
                  name={checkboxName}
 | 
			
		||||
                  onChange={onChangeSimpleCheckbox}
 | 
			
		||||
 | 
			
		||||
@ -0,0 +1,3 @@
 | 
			
		||||
const IS_DISABLED = true;
 | 
			
		||||
 | 
			
		||||
export default IS_DISABLED;
 | 
			
		||||
@ -2,6 +2,7 @@ import React, { memo, useState, useMemo, useCallback } from 'react';
 | 
			
		||||
import PropTypes from 'prop-types';
 | 
			
		||||
import { get } from 'lodash';
 | 
			
		||||
import { Padded, Flex } from '@buffetjs/core';
 | 
			
		||||
import IS_DISABLED from 'ee_else_ce/components/Roles/ContentTypeCollapse/CollapsePropertyMatrix/ActionRow/utils/constants';
 | 
			
		||||
import { usePermissionsDataManager } from '../../../../../hooks';
 | 
			
		||||
import { getCheckboxState } from '../../../utils';
 | 
			
		||||
import CheckboxWithCondition from '../../../CheckboxWithCondition';
 | 
			
		||||
@ -95,7 +96,7 @@ const ActionRow = ({
 | 
			
		||||
                return (
 | 
			
		||||
                  <CheckboxWithCondition
 | 
			
		||||
                    key={actionId}
 | 
			
		||||
                    disabled={isFormDisabled}
 | 
			
		||||
                    disabled={isFormDisabled || IS_DISABLED}
 | 
			
		||||
                    name={checkboxName.join('..')}
 | 
			
		||||
                    onChange={onChangeSimpleCheckbox}
 | 
			
		||||
                    value={checkboxValue}
 | 
			
		||||
@ -110,7 +111,7 @@ const ActionRow = ({
 | 
			
		||||
              return (
 | 
			
		||||
                <CheckboxWithCondition
 | 
			
		||||
                  key={label}
 | 
			
		||||
                  disabled={isFormDisabled}
 | 
			
		||||
                  disabled={isFormDisabled || IS_DISABLED}
 | 
			
		||||
                  name={checkboxName.join('..')}
 | 
			
		||||
                  onChange={onChangeParentCheckbox}
 | 
			
		||||
                  value={hasAllActionsSelected}
 | 
			
		||||
 | 
			
		||||
@ -0,0 +1,3 @@
 | 
			
		||||
const IS_DISABLED = true;
 | 
			
		||||
 | 
			
		||||
export default IS_DISABLED;
 | 
			
		||||
@ -3,6 +3,7 @@ import PropTypes from 'prop-types';
 | 
			
		||||
import { get } from 'lodash';
 | 
			
		||||
import { Flex, Text } from '@buffetjs/core';
 | 
			
		||||
import styled from 'styled-components';
 | 
			
		||||
import IS_DISABLED from 'ee_else_ce/components/Roles/ContentTypeCollapse/CollapsePropertyMatrix/SubActionRow/utils/constants';
 | 
			
		||||
import { usePermissionsDataManager } from '../../../../../hooks';
 | 
			
		||||
import { getCheckboxState } from '../../../utils';
 | 
			
		||||
import CheckboxWithCondition from '../../../CheckboxWithCondition';
 | 
			
		||||
@ -115,7 +116,7 @@ const SubActionRow = ({
 | 
			
		||||
                      return (
 | 
			
		||||
                        <CheckboxWithCondition
 | 
			
		||||
                          key={label}
 | 
			
		||||
                          disabled={isFormDisabled}
 | 
			
		||||
                          disabled={isFormDisabled || IS_DISABLED}
 | 
			
		||||
                          name={checkboxName.join('..')}
 | 
			
		||||
                          onChange={onChangeSimpleCheckbox}
 | 
			
		||||
                          value={checkboxValue}
 | 
			
		||||
@ -130,7 +131,7 @@ const SubActionRow = ({
 | 
			
		||||
                    return (
 | 
			
		||||
                      <CheckboxWithCondition
 | 
			
		||||
                        key={label}
 | 
			
		||||
                        disabled={isFormDisabled}
 | 
			
		||||
                        disabled={isFormDisabled || IS_DISABLED}
 | 
			
		||||
                        name={checkboxName.join('..')}
 | 
			
		||||
                        onChange={onChangeParentCheckbox}
 | 
			
		||||
                        value={hasAllActionsSelected}
 | 
			
		||||
 | 
			
		||||
@ -0,0 +1,3 @@
 | 
			
		||||
const IS_DISABLED = true;
 | 
			
		||||
 | 
			
		||||
export default IS_DISABLED;
 | 
			
		||||
@ -0,0 +1,3 @@
 | 
			
		||||
const IS_DISABLED = false;
 | 
			
		||||
 | 
			
		||||
export default IS_DISABLED;
 | 
			
		||||
@ -0,0 +1,3 @@
 | 
			
		||||
const IS_DISABLED = false;
 | 
			
		||||
 | 
			
		||||
export default IS_DISABLED;
 | 
			
		||||
@ -0,0 +1,3 @@
 | 
			
		||||
const IS_DISABLED = false;
 | 
			
		||||
 | 
			
		||||
export default IS_DISABLED;
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user