Browse Source

fix: toast error corrections & cache flush on delete

Signed-off-by: Raju Udava <86527202+dstala@users.noreply.github.com>
pull/1672/head
Raju Udava 3 years ago
parent
commit
309e992bf6
  1. 13
      packages/nc-gui/components/createOrEditProject.vue
  2. 2
      packages/nc-gui/pages/project/xcdb.vue
  3. 4
      packages/nocodb/src/lib/noco-models/Project.ts

13
packages/nc-gui/components/createOrEditProject.vue

@ -87,12 +87,8 @@
:height="20"
:label="$t('placeholder.projName')"
autofocus
>
</v-text-field>
/>
</div>
</v-col>
<v-col
@ -631,11 +627,8 @@
</v-col>
</v-expansion-panel-content>
</v-expansion-panel>
</v-expansion-panels>
</v-col>
</v-row>
</v-container>
</div>
@ -1154,7 +1147,6 @@ export default {
},
selectFile(db, obj, key, index) {
this.$refs[key][index].click()
},
onPanelToggle(panelIndex, envKey) {
this.$nextTick(() => {
@ -1289,7 +1281,6 @@ export default {
},
constructProjectJsonFromProject(project) {
const p = project // JSON.parse(JSON.stringify(project.projectJson));
p.ui = {
@ -1403,6 +1394,7 @@ export default {
this.projectCreated = true
} catch (e) {
this.$toast.error(await this._extractSdkResponseErrorMsg(e)).goAway(3000)
toast.goAway(100)
}
this.projectReloading = false
@ -1882,7 +1874,6 @@ export default {
}
}
}
}
},
beforeMount() {

2
packages/nc-gui/pages/project/xcdb.vue

@ -156,7 +156,7 @@ export default {
}
})
} catch (e) {
this.$toast.error(e.message).goAway(3000)
this.$toast.error(await this._extractSdkResponseErrorMsg(e)).goAway(3000)
}
this.loading = false
} else {

4
packages/nocodb/src/lib/noco-models/Project.ts

@ -184,6 +184,10 @@ export default class Project implements ProjectType {
}
if (o) await NocoCache.del(`${CacheScope.PROJECT}:${projectId}`);
if (o?.title) {
await NocoCache.del(`${CacheScope.PROJECT}:${o.title}`);
}
// remove item in cache list
await NocoCache.deepDel(
CacheScope.PROJECT,

Loading…
Cancel
Save