|
|
|
@ -80,7 +80,7 @@ import {guessColInfo} from 'app/common/ValueGuesser';
|
|
|
|
|
import {parseUserAction} from 'app/common/ValueParser';
|
|
|
|
|
import {TEMPLATES_ORG_DOMAIN} from 'app/gen-server/ApiServer';
|
|
|
|
|
import {Document} from 'app/gen-server/entity/Document';
|
|
|
|
|
import {ParseOptions} from 'app/plugin/FileParserAPI';
|
|
|
|
|
import {ParseFileResult, ParseOptions} from 'app/plugin/FileParserAPI';
|
|
|
|
|
import {AccessTokenOptions, AccessTokenResult, GristDocAPI} from 'app/plugin/GristAPI';
|
|
|
|
|
import {compileAclFormula} from 'app/server/lib/ACLFormula';
|
|
|
|
|
import {AssistanceSchemaPromptV1Context} from 'app/server/lib/Assistance';
|
|
|
|
@ -113,7 +113,7 @@ import tmp from 'tmp';
|
|
|
|
|
|
|
|
|
|
import {ActionHistory} from './ActionHistory';
|
|
|
|
|
import {ActionHistoryImpl} from './ActionHistoryImpl';
|
|
|
|
|
import {ActiveDocImport} from './ActiveDocImport';
|
|
|
|
|
import {ActiveDocImport, FileImportOptions} from './ActiveDocImport';
|
|
|
|
|
import {DocClients} from './DocClients';
|
|
|
|
|
import {DocPluginManager} from './DocPluginManager';
|
|
|
|
|
import {
|
|
|
|
@ -773,6 +773,17 @@ export class ActiveDoc extends EventEmitter {
|
|
|
|
|
await this._activeDocImport.oneStepImport(docSession, uploadInfo);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Import data resulting from parsing a file into a new table.
|
|
|
|
|
* In normal circumstances this is only used internally.
|
|
|
|
|
* It's exposed publicly for use by grist-static which doesn't use the plugin system.
|
|
|
|
|
*/
|
|
|
|
|
public async importParsedFileAsNewTable(
|
|
|
|
|
docSession: OptDocSession, optionsAndData: ParseFileResult, importOptions: FileImportOptions
|
|
|
|
|
): Promise<ImportResult> {
|
|
|
|
|
return this._activeDocImport.importParsedFileAsNewTable(docSession, optionsAndData, importOptions);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* This function saves attachments from a given upload and creates an entry for them in the database.
|
|
|
|
|
* It returns the list of rowIds for the rows created in the _grist_Attachments table.
|
|
|
|
|