Add key field to RoomNode

This commit is contained in:
Ramon Wenger 2022-06-27 17:02:14 +02:00
parent 1fe1dbe92d
commit 09899f1c38
3 changed files with 5 additions and 1 deletions

View File

@ -156,7 +156,7 @@ describe('The Room Page', () => {
MeQuery, MeQuery,
RoomsQuery() { RoomsQuery() {
return { return {
rooms rooms,
}; };
}, },
RoomEntriesQuery: { RoomEntriesQuery: {

View File

@ -22,6 +22,9 @@ const typePolicies = {
InstrumentNode: { InstrumentNode: {
keyFields: ['slug'] keyFields: ['slug']
}, },
RoomNode: {
keyFields: ['slug']
},
ModuleNode: { ModuleNode: {
fields: { fields: {
inEditMode: { inEditMode: {

View File

@ -95,6 +95,7 @@ function networkErrorCallback(statusCode) {
router.beforeEach(async (to, from, next) => { router.beforeEach(async (to, from, next) => {
Vue.$log.debug('navigation guard called', to, from); Vue.$log.debug('navigation guard called', to, from);
if (to.path === '/logout') { if (to.path === '/logout') {
Vue.$log.debug('logout', to);
publicApolloClient.resetStore(); publicApolloClient.resetStore();
if (process.env.LOGOUT_REDIRECT_URL) { if (process.env.LOGOUT_REDIRECT_URL) {
location.replace(`https://sso.hep-verlag.ch/logout?return_to=${process.env.LOGOUT_REDIRECT_URL}`); location.replace(`https://sso.hep-verlag.ch/logout?return_to=${process.env.LOGOUT_REDIRECT_URL}`);