Giter VIP home page Giter VIP logo

mmx-users's Introduction

Users for MODX 3

This extra is part of MMX initiative - the Modern MODX approach.

Dependencies

This package requires mmxDatabase to work with MODX database using Eloquent models.

The mmx/database dependency will be downloaded automatically by Composer.

Prepare

This package can be installed only with Composer.

If you are still not using Composer with MODX 3, just download the composer.json of your version:

cd /to/modx/root/
wget https://raw.githubusercontent.com/modxcms/revolution/v3.0.5-pl/composer.json

Install

composer require mmx/users --update-no-dev
composer exec mmx-users install

Update

composer update mmx/users --no-dev
composer exec mmx-users install

Remove

composer exec mmx-users remove
composer remove mmx/users

If you don't want to use mmxDatabase, you can also remove it.

composer exec mmx-database remove && composer remove mmx/database

How to use

Just open mmxUsers extra section in MODX manager and enjoy!

System Settings

You can change the extra grids and forms look and feel with system settings. Please read the description and look into default values.

Grid settings

Here you can specify the order and settings for columns.

Available columns are:

  • group-grid-columns
    • regular UserGroup columns, like id, name, description, rand
    • nested options parent UserGroup with the same columns (id, name, etc...)
    • Special column with group users count: members_count
  • user-grid-columns
    • regular User and Profile columns: id, username, fullname, email, etc...
    • values from extended fields: extended.key1, extended.key2 and other. Can't be sortable.
    • values from UserSetting table: setting.key1, setting.key2. Can be sortable!

Supported settings:

  • type - the type of column, supported are:
    • boolean to show yes\no icons
    • text or unset for other values
  • sortable (true | false) to make column sortable.
  • sort (true | false) specify this column as sorted by default
  • dir specify the direction of column sorting (if sort=true)

Tabs settings

Those are very simple - you just specify wich tabs will be visible.

  • group-tabs-create
  • group-tabs-edit
  • user-tabs-create
  • user-tabse-edit

See settings description in MODX manager.

Forms settings

For now you can customize only users form. I see no point to add this feature for user groups form, but feel free to write me about it.

user-form-fields-available - the list of all available fields of form with settings:

  • type:
    • text - just regular text field
    • email - here and next the same text field but with specified type="..." attribute
    • password
    • url
    • tel
    • textarea - you should know what is it, right?
    • checkbox - regular checkbox for boolean values
    • gender - select with gender variants
    • image - this will open MODX browser to pick an uploaded image
    • country - select with countries list
    • select - select with custom options (don't forget to specify options:["option1","option2"] or options:[{"value":1,"text":"Option 1"},{"value": 2,"text":"Option 2"}])
    • user-password - special component with changing user password along with confirmation
  • required (true | false) should this field be required?
  • default - the default value to set when you are creating the new user

user-form-fields-user and user-form-fields-sudo

2 system settings for managers with sudo permission and without.

Here you can specify the order of existing fields by beauty JSON arrays:

[
    ["username", "fullname", ["active", "sudo"]],
    ["email", ["dob", "gender"]]
]

You will get 2 column form with nested fields, some of which are also split into 2 columns. On mobile devices it will be 1 column form.

mmx-users's People

Contributors

bezumkin avatar gpsietzema avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.