move template survey files to Survey subdirectory

This commit is contained in:
Keith Grant 2020-03-17 10:19:48 -07:00
parent 9c32cb30d4
commit 3f4e7465a7
12 changed files with 10 additions and 3 deletions

View File

@ -12,6 +12,12 @@ function RoutedTabs(props) {
if (match) {
return match.id;
}
const subpathMatch = tabsArray.find(tab =>
history.location.pathname.startsWith(tab.link)
);
if (subpathMatch) {
return subpathMatch.id;
}
return 0;
};

View File

@ -0,0 +1,3 @@
export { default as SurveyList } from './SurveyList';
export { default as SurveyQuestionAdd } from './SurveyQuestionAdd';
export { default as SurveyQuestionEdit } from './SurveyQuestionEdit';

View File

@ -7,9 +7,7 @@ import ContentError from '@components/ContentError';
import AlertModal from '@components/AlertModal';
import ErrorDetail from '@components/ErrorDetail';
import useRequest, { useDismissableError } from '@util/useRequest';
import SurveyList from './shared/SurveyList';
import SurveyQuestionAdd from './shared/SurveyQuestionAdd';
import SurveyQuestionEdit from './shared/SurveyQuestionEdit';
import { SurveyList, SurveyQuestionAdd, SurveyQuestionEdit } from './Survey';
function TemplateSurvey({ template, i18n }) {
const [surveyEnabled, setSurveyEnabled] = useState(template.survey_enabled);