keysoft/dokumentat

Package for using ONLYOFFICE DEVELOPER EDITION for documents

dev-main 2024-04-15 23:06 UTC

This package is auto-updated.

Last update: 2024-05-29 23:43:30 UTC


README

Alt text

ONLYOFFICE DEVELOPER EDITION Package for Laravel with Vue 3 Integration

Overview

This Laravel package enables the integration of ONLYOFFICE DEVELOPER EDITION with Vue 3 applications. It includes controllers, models, and jobs to facilitate the connection with the ONLYOFFICE editor, allowing functionalities like document conversion to PDF among others. The package also includes example files demonstrating best practices and effective usage of ONLYOFFICE within a Laravel environment.

Key Dependencies:

Prerequisites

=== Ensure Laravel Breeze with Inertia.Vue is installed before using this package === 

Installation

You can install the package via composer:

composer require keysoft/dokumentat

You can publish and run the migrations with:

php artisan vendor:publish --tag="dokumentat-migrations"
php artisan migrate

Configuration Notes:

  • The config file sets the local environment IP and handles callbacks for document conversions using ONLYOFFICE's asynchronous approach.
  • Example configurations for local and production environments are provided below.
php artisan vendor:publish --tag="dokumentat-config"

This is the contents of the published config file:

  • Local Environment Config:
return [
    'developer' => 'http://192.168.0.3:82/"',
    'convert' => config('dokumentat.developer').'/ConvertService.ashx',
];
  • Production Environment Config:
return [
    'developer' => 'https://yourdomain.com/"',
    'convert' => config('dokumentat.developer').'/ConvertService.ashx',
];

Usage

After installing Breeze (or Inertia separately) and this package, use the following command to set up the necessary files:

php artisan dokumentat

This command will create a model, controller, a job, add routes, and a Vue document. It will also install the necessary npm packages.

Upcoming Features:

  • Guidelines for setting up a local environment with ONLYOFFICE.
  • Integration examples with PHPWord and PHPExcel.
Further details and use cases will be added soon, including setting up ONLYOFFICE locally and on a server, 
and integrating it with other applications.

Tutorials:

Testing

composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Credits

License

The MIT License (MIT). Please see License File for more information.