Wiki articles tagged with "behavior"

Showing 1-4 of 4 items.

Export query content to excel through any of your controllers, also can set cssClass for header/odd/even rows, auto download

Created 9 years ago by Scott_Huang, updated 9 years ago by Scott_Huang.

To generate excel by query content, and download through any controller. You also can bind cssClass to header/odd/even rows. As for header, you even can set cssClass for each column.

$this->export2excel($excel_content,$excel_file);

in your controller.

2 0
2 followers
Viewed: 26 426 times
Version: 2.0
Category: Tutorials

Simple Way to Upload and Save File

Created 10 years ago by Misbahul D Munir, updated 10 years ago by Misbahul D Munir.

This tutorial need extension mdmsoft/yii2-upload-file. Follow the intruction to install. After installation done, create controller and action

0 0
4 followers
Viewed: 39 736 times
Version: 2.0
Category: Tutorials

Save and Display Date/Time Fields in different formats in Yii2

Created 10 years ago by Kartik V, updated 10 years ago by Kartik V.

You would find having such a need in most Yii Projects. Your database needs a specific format to store date fields, while you may want to display it in different formats to the users on forms and other views.

0 0
51 followers
Viewed: 177 915 times
Version: 2.0
Category: How-tos

Auto-update denormalized attributes with MongoDb and Yii2

Created 10 years ago by edoardo849, updated 10 years ago by CeBe.

You have different collections in MongoDb with de-normalized attributes. As you may know, due to its not-join nature, MongoDb tends to encourage repetition of the same value in different collections (de-normalization). In this MongoDb is opposed to a more SQL-like approach where you usually reference only the ID of the value with a foreign key.

1 0
3 followers
Viewed: 18 284 times
Version: 2.0
Category: Tips