Wiki articles tagged with "behavior"

Showing 1-4 of 4 items.
Created 2 years ago by Scott_Huang, updated 2 years ago by Scott_Huang.

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

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: 12 571 times
Version: 2.0
Category: Tutorials
Created 3 years ago by Misbahul D Munir, updated 3 years ago by Misbahul D Munir.

Simple Way to Upload and Save File

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: 24 115 times
Version: 2.0
Category: Tutorials
Created 4 years ago by Kartik V, updated 3 years ago by Kartik V.

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

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
50 followers
Viewed: 127 661 times
Version: 2.0
Category: How-tos
Created 4 years ago by edoardo849, updated 4 years ago by CeBe.

Auto-update denormalized attributes with MongoDb and Yii2

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: 10 527 times
Version: 2.0
Category: Tips