2017 © Pedro Peláez
 

yii2-extension cm-communication

Common Communication Module for yii2

image

frenzelgmbh/cm-communication

Common Communication Module for yii2

  • Saturday, April 16, 2016
  • by philippfrenzel
  • Repository
  • 1 Watchers
  • 0 Stars
  • 331 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

cm-communication

Common Address Module (Frenzel GmbH 2014) v.0.1, (*1)

Installation

Add the following line to your composer.json require section:, (*2)

"frenzelgmbh/cmcommunication":"*"
php yii migrate --migrationPath=@vendor/frenzelgmbh/cm-communication/migrations

Inside your yii-config, pls. add the following lines to your modules section. As you might see, the gridview needs to be implemented too., (*3)

'communication'=>[
  'class' => 'frenzelgmbh\cmcommunication\Module',
],
'gridview' =>  [
  'class' => '\kartik\grid\Module'
],

After this, you should be able to see the set of build in widgets and options under:, (*4)

http://yourhost/index.php?r=communication/default/test, (*5)

Design

The Address module is use to store address/location informations, that can be linked to any other "module". So in general all modules are referenced by:, (*6)

  • mod_table (which should hold the table name VARCHAR(100))
  • mod_id (which should hold the primarey key of the referenced record INTEGER(11))

Datastructure

This module allows you to store communication data related to any other "record" and "module" you pass by as parameters. It allows you to save 1:n communication records, while one record of communication can be filled with the following fields: * Communication Type (INTEGER) References communication_type table * Phone * Mobile * Fax * EMail Pls. notice, that records aren't deleted in all of our models, they just get marked as deleted!, (*7)

Widgets

The "create"-Button: Will render a button, that will open an modal and lets you add a new communication to the referenced module with the id. E.g. you have a entity "contact" and you want to create a new communication to this entity., (*8)

if(class_exists('\frenzelgmbh\cmcommunication\widgets\CreateCommunicationModal')){
  echo \frenzelgmbh\cmcommunication\widgets\CreateCommunicationModal::widget(array(
    'module'      => 'tbl_test',
    'id'          => 1
  )); 
}

The "update"-Button:, (*9)

if(class_exists('\frenzelgmbh\cmcommunication\widgets\UpdateCommunicationModal')){
  echo \frenzelgmbh\cmcommunication\widgets\UpdateCommunicationModal::widget(array(
    'module'      => 'tbl_test',
    'id'          => 1
  )); 
}

The "related"-Grid:, (*10)

if(class_exists('\frenzelgmbh\cmcommunication\widgets\RelatedCommunicationGrid')){
  echo \frenzelgmbh\cmcommunication\widgets\RelatedCommunicationGrid::widget(array(
    'module'      => 'tbl_test',
    'id'          => 1
  )); 
}

The Versions

16/04 2016

dev-master

9999999-dev

Common Communication Module for yii2

  Sources   Download

MIT

The Requires

 

yii communication frenzel gmbh