diff --git a/packages/nc-gui/components/project/appStore.vue b/packages/nc-gui/components/project/appStore.vue
index 82bfdb2efc..28df19a2ec 100644
--- a/packages/nc-gui/components/project/appStore.vue
+++ b/packages/nc-gui/components/project/appStore.vue
@@ -213,15 +213,8 @@ export default {
},
async created() {
await this.loadPluginList()
- this.readPluginDefaults()
},
methods: {
- async readPluginDefaults() {
- try {
- this.defaultConfig = await this.$store.dispatch('sqlMgr/ActSqlOp', [null, 'xcPluginDemoDefaults'])
- } catch (e) {
- }
- },
async confirmResetPlugin() {
try {
await this.$api.plugin.update(this.resetPluginRef.id, {
diff --git a/packages/nc-gui/components/project/spreadsheet/public/xcTable.vue b/packages/nc-gui/components/project/spreadsheet/public/xcTable.vue
index f7d64780d8..5e16438a9b 100644
--- a/packages/nc-gui/components/project/spreadsheet/public/xcTable.vue
+++ b/packages/nc-gui/components/project/spreadsheet/public/xcTable.vue
@@ -22,74 +22,7 @@
class="nc-table-toolbar elevation-0 xc-toolbar xc-border-bottom"
style="z-index: 7;border-radius: 4px"
>
-
-
-
-
-
-
-
-
@@ -223,14 +127,12 @@
import { ErrorMessages } from 'nocodb-sdk'
import spreadsheet from '../mixins/spreadsheet'
import ApiFactory from '../apis/apiFactory'
-// import EditableCell from "../editableCell";
import FieldsMenu from '../components/fieldsMenu'
import SortListMenu from '../components/sortListMenu'
import ColumnFilterMenu from '../components/columnFilterMenu'
import XcGridView from '../views/xcGridView'
import { SqlUI } from '@/helpers/sqlUi'
import CsvExportImport from '~/components/project/spreadsheet/components/moreActions'
-// import ExpandedForm from "../expandedForm";
export default {
name: 'XcTable',
@@ -369,23 +271,6 @@ export default {
edited() {
return this.data && this.data.some(r => r.rowMeta && (r.rowMeta.new || r.rowMeta.changed))
},
- // hasMany() {
- // return this.meta && this.meta.hasMany
- // ? this.meta.hasMany.reduce((hm, o) => {
- // hm[o.rcn] = hm[o.rcn] || []
- // hm[o.rcn].push(o)
- // return hm
- // }, {})
- // : {}
- // },
- // belongsTo() {
- // return this.meta && this.meta.belongsTo
- // ? this.meta.belongsTo.reduce((bt, o) => {
- // bt[o.title] = o
- // return bt
- // }, {})
- // : {}
- // },
table() {
if (this.relationType === 'hm') {
return this.relation.table_name
@@ -426,21 +311,6 @@ export default {
this.searchField = this.primaryValueColumn
},
created() {
- /* if (this.relationType === 'hm') {
- this.filters.push({
- field: this.relation.column_name,
- op: 'is equal',
- value: this.relationIdValue,
- readOnly: true
- })
- } else if (this.relationType === 'bt') {
- this.filters.push({
- field: this.relation.rcn,
- op: 'is equal',
- value: this.relationIdValue,
- readOnly: true
- })
- } */
document.addEventListener('keydown', this.onKeyDown)
},
beforeDestroy() {
@@ -519,7 +389,9 @@ export default {
this.loading = true
try {
this.viewMeta = (await this.$api.public.sharedViewMetaGet(this.$route.params.id, {
- password: this.password
+ headers: {
+ 'xc-password': this.password
+ }
}))
this.meta = this.viewMeta.model
this.metas = this.viewMeta.relatedMetas
@@ -547,26 +419,21 @@ export default {
list,
pageInfo: { totalRows: count }
}
- } = (await this.$api.public.dataList(this.$route.params.id, {
- password: this.password,
- sorts: this.sorts && this.sorts.map(({
+ } = (await this.$api.public.dataList(this.$route.params.id, {}, {
+ sortArrJson: JSON.stringify(this.sorts && this.sorts.map(({
fk_column_id,
direction
}) => ({
direction,
fk_column_id
- })),
- filters: this.filters
- }, this.queryParams
+ }))),
+ filterArrJson: JSON.stringify(this.filters),
+ ...this.queryParams
+ }, {
+ headers: { password: this.password }
+ }
))
- // this.client = client
-
- // this.showFields = queryParams && queryParams.showFields
- // this.meta = meta
- // eslint-disable-next-line camelcase
- // this.modelName = model_name
-
this.count = count
this.data = list.map(row => ({
row,
diff --git a/packages/nocodb-sdk/src/lib/Api.ts b/packages/nocodb-sdk/src/lib/Api.ts
index 898fe65392..eeed576ac6 100644
--- a/packages/nocodb-sdk/src/lib/Api.ts
+++ b/packages/nocodb-sdk/src/lib/Api.ts
@@ -2843,16 +2843,10 @@ export class Api<
* @request POST:/api/v1/db/public/shared-view/{sharedViewUuid}/rows
* @response `200` `any` OK
*/
- sharedViewCreate: (
- sharedViewUuid: string,
- data: { data?: any; password?: string },
- params: RequestParams = {}
- ) =>
+ sharedViewCreate: (sharedViewUuid: string, params: RequestParams = {}) =>
this.request({
path: `/api/v1/db/public/shared-view/${sharedViewUuid}/rows`,
method: 'POST',
- body: data,
- type: ContentType.FormData,
format: 'json',
...params,
}),
@@ -2941,7 +2935,6 @@ export class Api<
dataRelationList: (
sharedViewUuid: string,
columnName: string,
- data: { password?: string },
query?: { limit?: string; offset?: string },
params: RequestParams = {}
) =>
@@ -2949,8 +2942,6 @@ export class Api<
path: `/api/v1/db/public/shared-view/${sharedViewUuid}/rows/nested/${columnName}`,
method: 'POST',
query: query,
- body: data,
- type: ContentType.Json,
format: 'json',
...params,
}),
@@ -2960,19 +2951,13 @@ export class Api<
*
* @tags Public
* @name SharedViewMetaGet
- * @request POST:/api/v1/db/public/shared-view/{sharedViewUuid}/meta
+ * @request GET:/api/v1/db/public/shared-view/{sharedViewUuid}/meta
* @response `200` `object` OK
*/
- sharedViewMetaGet: (
- sharedViewUuid: string,
- data: { password?: string },
- params: RequestParams = {}
- ) =>
+ sharedViewMetaGet: (sharedViewUuid: string, params: RequestParams = {}) =>
this.request