// Copyright (c) 2015 Mattermost, Inc. All Rights Reserved. // See License.txt for license information. import React from 'react'; import * as Utils from 'utils/utils.jsx'; import AdminSettings from './admin_settings.jsx'; import BooleanSetting from './boolean_setting.jsx'; import DropdownSetting from './dropdown_setting.jsx'; import {FormattedMessage} from 'react-intl'; import SettingsGroup from './settings_group.jsx'; import TextSetting from './text_setting.jsx'; export default class LogSettings extends AdminSettings { constructor(props) { super(props); this.getConfigFromState = this.getConfigFromState.bind(this); this.renderSettings = this.renderSettings.bind(this); this.state = Object.assign(this.state, { enableConsole: props.config.LogSettings.EnableConsole, consoleLevel: props.config.LogSettings.ConsoleLevel, enableFile: props.config.LogSettings.EnableFile, fileLevel: props.config.LogSettings.FileLevel, fileLocation: props.config.LogSettings.FileLocation, fileFormat: props.config.LogSettings.FileFormat, enableWebhookDebugging: props.config.LogSettings.EnableWebhookDebugging }); } getConfigFromState(config) { config.LogSettings.EnableConsole = this.state.enableConsole; config.LogSettings.ConsoleLevel = this.state.consoleLevel; config.LogSettings.EnableFile = this.state.enableFile; config.LogSettings.FileLevel = this.state.fileLevel; config.LogSettings.FileLocation = this.state.fileLocation; config.LogSettings.FileFormat = this.state.fileFormat; config.LogSettings.EnableWebhookDebugging = this.state.enableWebhookDebugging; return config; } renderTitle() { return (
{'%T'} |
|
{'%D'} |
|
{'%d'} |
|
{'%L'} |
|
{'%S'} |
|
{'%M'} |
|