Browse Source

fix/Added pr suggestions

pull/2641/head
Muhammed Mustafa 2 years ago
parent
commit
7c3404cd51
  1. 6
      packages/nc-gui/components/FeedbackForm.vue
  2. 8
      packages/nocodb/src/lib/meta/api/utilApis.ts

6
packages/nc-gui/components/FeedbackForm.vue

@ -1,6 +1,6 @@
<template>
<div v-if="!feedbackFormHidden" class="nc-feedback-form-wrapper">
<v-icon class="nc-close-icon" large @click="feedbackFormHidden = true"> mdi-close-circle-outline </v-icon>
<div v-if="!feedbackIsShown" class="nc-feedback-form-wrapper">
<v-icon class="nc-close-icon" large @click="feedbackIsShown = true"> mdi-close-circle-outline </v-icon>
<iframe :src="feedbackFormUrl" width="100%" height="500" frameborder="0" marginheight="0" marginwidth="0"
>Loading
@ -13,7 +13,7 @@
export default {
name: 'FeedbackForm',
computed: {
feedbackFormHidden: {
feedbackIsShown: {
get() {
return this.$store.state.settings.feedbackForm.isShown;
},

8
packages/nocodb/src/lib/meta/api/utilApis.ts

@ -60,17 +60,17 @@ export async function releaseVersion(_req: Request, res: Response) {
res.json(result);
}
export async function getFeedbackForm(_req: Request, res: Response) {
export async function feedbackFormGet(_req: Request, res: Response) {
axios
.get('https://nocodb.com/api/v1/feedback_form')
.then((response) => {
res.json(response.data);
}).catch((e) => {
})
.catch((e) => {
res.status(500).json({ error: e.message });
});
}
export async function appHealth(_: Request, res: Response) {
res.json({
message: 'OK',
@ -155,5 +155,5 @@ export default (router) => {
router.post('/api/v1/db/meta/axiosRequestMake', catchError(axiosRequestMake));
router.get('/api/v1/version', catchError(releaseVersion));
router.get('/api/v1/health', catchError(appHealth));
router.get('/api/v1/feedback_form', catchError(getFeedbackForm));
router.get('/api/v1/feedback_form', catchError(feedbackFormGet));
};

Loading…
Cancel
Save