Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide...

19
MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 1 Advanced Content Manager Version: 1.0 Support: [email protected]

Transcript of Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide...

Page 1: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page 1

Advanced Content Manager

Version: 1.0

Support: [email protected]

Page 2: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page 2

Table of Contents 1. Create Content Type: .......................................................................................................................................................... 3

1.1 General Information: .................................................................................................................................................... 4

1.2 Manage Fields: .............................................................................................................................................................. 6

1.3 Page Layout: ................................................................................................................................................................ 11

1.4 Meta Information: ................................................................................................................................................... 11

1.5 Template: ................................................................................................................................................................. 11

.5. Te plate of Adva ced Co te t ........................................................................................................................ 11

.5. Te plate of Custo For : ............................................................................................................................... 14

1.6 Form Information: ....................................................................................................................................................... 14

2. Manage Items: .................................................................................................................................................................. 16

2.1 Item Information ......................................................................................................................................................... 17

2.2 Page Layout ................................................................................................................................................................. 18

2.3 Meta Information ........................................................................................................................................................ 18

2.4 Products ...................................................................................................................................................................... 19

Page 3: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page 3

1. Create Content Type:

In Admin panel > MGS > Manage Content Type [Advanced Content]

Click “Add Content Type” button

1.1 General Information:

Title: Name of content type

Identifier: This is use for router of this content type. Example your domain is http://abc.com and you set

Indentifier is “portfolio”, the url of portfolio content on frontend will be http://abc.com/portfilio. Type: The extension have two type of content “Advanced Content” and “Custom Form”

o Advanced Content: Allow you to create the different content type (example: portofilio,

testimonial...), each content type you can create many items for it. You also can craete different

Page 4: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page 4

fields for each content type. Example you can create field “Project, Skill” for Portfolio content type, or create field “Author” for Testimonial content type.

o Custom Form: Cho phép admin tạo ra các form contact khác nhau để hiển thị ra frontend, mỗi form này có thể tùy chỉnh các input khác nhau để customer có thể nhập vào.

After fill all required content, you can click “Save and Continue Edit” button to create content type. After you click this button, the new menu item will appear on left sidebar menu.

With “Type” is “Advanced Content”:

With “Type” is “Custom Form”:

Page 5: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page 5

1.2 Manage Fields:

Click “Add New Field” to create new field.

Page 6: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page 6

Title: Name of field, it will be use as label of field in form.

Identifier: This filed will auto generate when you endter title of field. It will be use for name of input

tag in the form.

Input Type: Have 11 type of input field.

- Text Field

--------------------------------------------------------------------------------------------------------------------------

- Textarea

--------------------------------------------------------------------------------------------------------------------------

- File

--------------------------------------------------------------------------------------------------------------------------

- Image

Page 7: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page 7

--------------------------------------------------------------------------------------------------------------------------

- Dropdown

--------------------------------------------------------------------------------------------------------------------------

- Radio

--------------------------------------------------------------------------------------------------------------------------

- Checkbox

--------------------------------------------------------------------------------------------------------------------------

- Multiselect

--------------------------------------------------------------------------------------------------------------------------

- Date

--------------------------------------------------------------------------------------------------------------------------

- Store View

Page 8: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page 8

The filed “Store View” will be use when you want create content for each store view, then on frontend, it will be use to filter collection of content by store view.

--------------------------------------------------------------------------------------------------------------------------

- Products

With the field type “Product”, it is use for content type is “Custom Form”, you can create a field for customer can search product and submit it in the form.

Is Required: Set this field is require or not

Show In Grid: Show this field on grid or not.

Page 9: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page 9

Position: This option will be used to order the field in the form. You also can drag and drop to order it.

Some special field have different options.

Text field:

- Note: This is the comment of the field, it will be showed under the field

- Validate: Admin can set validate for different

Textarea:

- Enable WYSIWYG: Use WYSIWYG or not

File, Image:

- Allowed File Extensions: Setting the file extension that can be upload.

- File patch: Setting the path of file upload. It is subfolder of folder pub/media

Radio, Checkbox, Multiselect, Dropdown:

Page 10: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page

10

With radio and checkout field, you can add the options for it.

After fill the info of field, click button “Save & Edit” and choose “Save & Edit” to save the fields.

Generate Template Files” hoặc “Save & Generate Template Email” đối với từng kiểu content:

With content type is “Advanced Content” when you choose “Save & Generate Template Files” the field will be save to database and system will create two files template (.phtml) in:

app/code/MGS/Acm/view/frontend/templates/ advanced_content/identifier_of_content_type/ list_base.phtml app/code/MGS/Acm/view/frontend/templates/ advanced_content/identifier_of_content_type/ view_base.phtml identifier_of_content_type is identifier of this content type (General Information)

Note: To system can create this files, you should chmod folder app/code/MGS/Acm/view/frontend/templates/ advanced_content so apache user have permission to write the file.

With content type is “Custom Form” if you choose “Save & Generate Template Email” the field info will be save to database and the system will create the template email for this form

Page 11: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page

11

1.3 Page Layout:

If content type is “Advanced Content”, this is the pay layout of list page. Example: you create a content type is

“portfolio”, this page layout will be the page to list all porfolio.

If content type is “Custom Form” this is the layout of form page.

1.4 Meta Information:

You can enable or disable the breadcumb for each content type page. You also can add meta keywords and

meta descripton for each content type page.

With content type is “Advanced Content”, if you enable breadcrumbs, it will apply for list page and detail page.

1.5 Template:

This is different setting for each content type

1.5.1 Template of Advanced Content

This include two part:

Page 12: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page

12

List View

This is template of list view. List view is section to show the list item of each content. Example you careate an

advanced content with indentifier is “testimonial”, the list view will have url http://yourdomain/testimonial

The settings:

Number of item perpage: is the number of item showing on one page

Template path for list view: When you create content view and click “Save & Generate Template Files” the system will generate the template file and fill content in this field. The file list_base.phtml is the default file,

each time you click “Save & Generate Template Files”, this file will be updated. If you want create a custom

template file, you can create a new file and copy content of list_base.phtml file, and the put the correct path file

to “Template path for list view” field.

Example if you create content type with indentifier is “testimonial”, then you create the fileds and then click

“Save & Generate Template Files”, the system will generate the file in app/code/MGS/Acm/view/frontend/templates/advanced_content/testimonial/list_base.phml. If you want

create a custom layout, you can duplicate this file, then rename to the name you want, example

“my_list.phtml” and then change the path in field “Template path for list view” to “app/code/MGS/Acm/view/frontend/templates/advanced_content/testimonial/my_list.phtml”.

In the list file, to show content of each field, you can use this code:

<?php echo $item->getData('identifier_of_field') ?> This code should be in:

<?php foreach($itemCollection as $item): ?> <?php endforeach ?>

Example:

<?php foreach($itemCollection as $item): ?> <?php echo $item->getData('name') ?> <?php endforeach ?>

You also can use short code to show the list of items, you can put short code at anywhere (cms page or static

block)

The format of short code as follow:

{{block class="MGS\Acm\Block\ListItem" type_id="id_of_content_type" template="advanced_content/testimonial/list_base.phtml"}}

With id_of_content_type is id of content type (it is different with indentifier), you can see it when you edit the

content type, you can see it on url on address bar, see image bellow

Page 13: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page

13

In this case, the id of content type is 1

template: the path to the template file you use.

Example:

{{block class="MGS\Acm\Block\ListItem" type_id="1" template="advanced_content/testimonial/my_list.phtml"}}

In shortcode, you also can filter content by field identifier, example if your content type have field “Status” and “Category”

Field “Status” with indentifier is “status” and two option Yes and No

Field “Category” with indentifier is “category” and option Category 1, Category 2, Category 3

You can add shortcode like this:

{{block class="MGS\Acm\Block\ListItem" type_id="1" filter="'category':'Category 1','status':'Yes'" template="advanced_content/testimonial/my_list.phtml"}}

This list will show only item in Category 1 and have status is Yes

Notice: When you copy the shortcode, and add to cms page or static block, you should switch editor to html

mode to add the shortcode

Page 14: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page

14

If you create content type have field type “product”, in this setting will have one more setting

This is the setting of template product, this file to show the info of product you assigned when create item. The

system also generate the file advanced_content/product/products_base.phtml, you can also can create your

custom tempate.

Detail View

This is the setting for template file that show the content of item detail page. Same as List View. Same as list

view, when you click “Save & Generate Template Files” the system also generate the default template file, and you also can create the custom tempalte file to use.

To get content of each field in detail page, you can use this code

<?php echo $this->getDataInfo('identifier_of_field') ?>

Example: <?php echo $this->getDataInfo('name') ?>

1.5.2 Template of Custom Form :

With content type “Custom Form”, you also can do same as advanced content template. The default template of form is “forms/form_base.phtml” if you want create custom template, you can create new file and then update the setting of template path.

1.6 Form Information:

This is the setting of form, it only available with content type Form

Page 15: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page

15

Form Action:

- Send Email: The form will only send email for admin when customer submit

- Save Info: The form will only save to database when customer submit

- Send Email & Save Info: The form will save to database and send email for admin

Send Email To: Recipient emails, if have many recipient email, you can separate by comma.

Set field to reply: This is field to set email reply. Example if you create the form and have field “email”. Customer will fill to this field, and you want use this field to set email reply, you can put email field indentifier

here.

Template Email: When you create form and click “Save & Generate Template Email” the system will generate a email template for this form. This template will have all fileds of the form. When the template email

is created succefful, will have a message showing up said that template have created and have a link to where

you can edit the template email. You also can find it in System -> Transactions Email

Page 16: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page

16

Enable Captcha: Enable or Disable captcha

Form Legend, Note:

Success Message: Content of success message when user submit the form

2. Manage Items: After you create a content type, you will see a new menu under MGS menu name “ACM” this is menu to you to

manage the items

When you click to ACM, you will see link to manage the content type you have created

Page 17: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page

17

Click to each content type you want to manage the items.

Page 18: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page

18

2.1 Item Information

2.2 Page Layout

This is config for page layout of detail page for each item, leave blank to use default layout of this content type

Page 19: Advanced Content Manager - marketplace.magento.com€¦ · MGS Advanced Content Manager User Guide Copyright © 2016 Mage Solution. All Rights Reserved. Page 12 List View This is

MGS Advanced Content Manager User Guide

Copyright © 2016 Mage Solution. All Rights Reserved. Page

19

2.3 Meta Information

This is setting meta information for each item

Url Key: Add friendly url for item. If you do not add this, the item detail page url will like this

http://your_domain/acm/index/view/type_id/1/id/72/ In this example, 1 is the id of content type, 72 is the id of item

If you enter the url key, the item detail page url will like this http://your_domain /identifier_of_content_type/url_key

2.4 Products

If the content type have field product, when you add items, you can assign product to this iteam in table

“Related Products”