2017 © Pedro Peláez
 

symfony-bundle fm-rfm-bundle

FMRichfilemanager bundle, adds Richfilemanager file manager to your Symfony project

image

helios-ag/fm-rfm-bundle

FMRichfilemanager bundle, adds Richfilemanager file manager to your Symfony project

  • Saturday, June 30, 2018
  • by helios
  • Repository
  • 1 Watchers
  • 1 Stars
  • 16 Installations
  • PHP
  • 0 Dependents
  • 2 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 0 % Grown

The README.md

FMRFMBundle

RichfileManager integration in Symfony, (*1)

Code Quality Assurance

TravisCI License Version Downloads
Build Status License Latest Stable Version Total Downloads

RichfileManager An open-source file manager. http://fm.devale.pro, (*2)

Table of contents, (*3)

Installation

Step 1: Installation

Add FMRFMBundle to your composer.json, (*4)

{
    "require": {
        "helios-ag/fm-rfm-bundle": "~1"
    }
}

If you want to override default assets directory of Richfilemanager, add next option. By default assets copied to web/assets/richfilemanager or public/assets/richfilemanager depending on Symfony version, (*5)

{
    "config": {
        "rfm-dir": "web/assets/richfilemanager/"
    }
}

Add composer script, (*6)

"FM\\RFMBundle\\Composer\\RFMScriptHandler::copy",, (*7)

to scripts section of composer.json, (*8)

{
  "scripts": {
      "symfony-scripts": [
          "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
          "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap",
          "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::clearCache",
          "FM\\RFMBundle\\Composer\\RFMScriptHandler::copy",
          "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installAssets",
          "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installRequirementsFile",
          "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::prepareDeploymentTarget"
      ]
    }
}

Also you can copy assets manually. Copy dirs: 'config, 'images', 'languages', 'libs', 'src', 'themes' from vendor/servocoder/richfilemanager/ to your public assets directory, (*9)

Now tell composer to download the bundle by running the command:, (*10)

composer update helios-ag/fm-rfm-bundle

Step 2: Enable the bundle

Enable the bundle in the kernel:, (*11)

<?php
// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        // ...
        new FM\RFMBundle\FMRFMBundle(),
    );
}

Step 3: Import FMRFMBundle routing file

``` yaml, (*12)

app/config/routing.yml

rfm: resource: "@FMRFMBundle/Resources/config/routing.yml", (*13)


### Step 4: Configure your application's security.yml Secure RFM with access_control: ``` yaml # app/config/security.yml security: //.... access_control: - { path: ^/rfm_show, role: ROLE_USER } - { path: ^/rfm_run, role: ROLE_USER } - { path: ^/rfm_config.json, role: ROLE_USER } - { path: ^/rfm_config_default.json, role: ROLE_USER }

Basic configuration

Add configuration options to your config.yml

Example below (assumed that richfilemanager assets placed in web/assets/richfilemanager directory), (*14)

fm_rfm:
    instances:
        default:
            options:
                serverRoot: true
                fileRoot: /uploads

You can see the full list of roots options here. To use them, convert camelCased option names to snake_cased names., (*15)

Bundle provides custom form type, RFMType (provides same functionality as in FMElfinderBundle) and integration with CKEditor out of the box., (*16)

The Versions