Skip to content

Commit

Permalink
Merge pull request #146 from velis74/fix-imports
Browse files Browse the repository at this point in the history
Fix imports
  • Loading branch information
velis74 authored Oct 13, 2023
2 parents a30d0f6 + 184c4f7 commit 639645d
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
6 changes: 3 additions & 3 deletions vue/components/notifications-editor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import {
APIConsumer,
ComponentDisplay,
ConsumerLogicApi, FormConsumerApiOneShot, gettext,
ConsumerLogicApi, FormConsumerOneShotApi, gettext,
useActionHandler,
} from '@velis/dynamicforms';
import { onMounted, onUnmounted, ref } from 'vue';
Expand Down Expand Up @@ -49,12 +49,12 @@ const notificationLogic = ref(new ConsumerLogicApi(
notificationLogic.value.getFullDefinition();
const actionViewLicense = async (): Promise<boolean> => {
await FormConsumerApiOneShot({ url: licenseConsumerUrl, trailingSlash: licenseConsumerUrlTrailingSlash, pk: 'new' });
await FormConsumerOneShotApi({ url: licenseConsumerUrl, trailingSlash: licenseConsumerUrlTrailingSlash, pk: 'new' });
return true;
};
const actionAddNotification = async (): Promise<boolean> => {
await FormConsumerApiOneShot({
await FormConsumerOneShotApi({
url: consumerUrl,
trailingSlash: consumerTrailingSlash,
pk: 'new',
Expand Down
4 changes: 2 additions & 2 deletions vue/components/user-session/login.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import {
ConsumerLogicApi, dfModal as dfModalApi,
dfModal, DialogSize,
DisplayMode,
FilteredActions, FormConsumerApiOneShot,
FilteredActions, FormConsumerOneShotApi,
FormPayload,
gettext,
} from '@velis/dynamicforms';
Expand Down Expand Up @@ -221,7 +221,7 @@ function useLogin() {
socialAuth.value = formDef.payload.social_auth_providers;
}

const openRegistration = async () => FormConsumerApiOneShot(
const openRegistration = async () => FormConsumerOneShotApi(
{ url: '/account/profile/register', trailingSlash: false },
);

Expand Down
4 changes: 2 additions & 2 deletions vue/components/user-session/project-list.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import {
Action,
apiClient,
dfModal,
FormConsumerApiOneShot,
FormConsumerOneShotApi,
FormPayload,
} from '@velis/dynamicforms';
import slugify from 'slugify';
Expand Down Expand Up @@ -59,7 +59,7 @@ async function addNewProject() {
}
return false;
};
const addProjectModal = await FormConsumerApiOneShot(
const addProjectModal = await FormConsumerOneShotApi(
{
url: '/project',
trailingSlash: false,
Expand Down
8 changes: 4 additions & 4 deletions vue/components/user-session/user-profile.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import { Action, dfModal, DialogSize, FilteredActions, FormConsumerApiOneShot, gettext } from '@velis/dynamicforms';
import { Action, dfModal, DialogSize, FilteredActions, FormConsumerOneShotApi, gettext } from '@velis/dynamicforms';
import axios, { AxiosRequestConfig } from 'axios';
import _ from 'lodash';
import { computed, h, onMounted, reactive, watch } from 'vue';
Expand Down Expand Up @@ -83,7 +83,7 @@ async function verifyEmailChanged(userData: UserDataJSON) {
}
async function changePassword() {
await FormConsumerApiOneShot({ url: '/account/change-password/', trailingSlash: true, pk: 'new' });
await FormConsumerOneShotApi({ url: '/account/change-password/', trailingSlash: true, pk: 'new' });
}
async function checkResetPassword() {
Expand Down Expand Up @@ -122,7 +122,7 @@ watch(() => userSession.impersonated, () => window.location.reload());
onMounted(() => loadData());
async function showImpersonateLogin() {
await FormConsumerApiOneShot({ url: '/account/impersonate', trailingSlash: false });
await FormConsumerOneShotApi({ url: '/account/impersonate', trailingSlash: false });
await userSession.checkLogin(false);
}
Expand All @@ -132,7 +132,7 @@ async function stopImpersonation() {
}
async function userProfile() {
const savedData = await FormConsumerApiOneShot({ url: '/account/profile/current', trailingSlash: false });
const savedData = await FormConsumerOneShotApi({ url: '/account/profile/current', trailingSlash: false });
await userSession.checkLogin(false);
await verifyEmailChanged(savedData);
}
Expand Down

0 comments on commit 639645d

Please sign in to comment.