Articles tagged with "model"X
Displaying 1-10 of 22 result(s).

Multiple Delete in Yii

Created a day ago by ruderbytesHow-tos0 comments – viewed 472 times – ( -1 ) – version 1.1
Hello i'm Fahmi Azain... i want to share wiki about multiple delete in yii framework. okay let's do it. the first create the the table and form like in the bellow and paste this code in your view

Expert's model generation with Gii

Created 4 days ago by le_topTips0 comments – viewed 785 times – ( +1 ) – version 1.1
Efficient coding with Yii implies efficient use of the code generator. This article shares the personalised Gii templates that were built starting from the standard templates proposed by AweGen.

Sort and save order of model-elements drag & drop

Created about a month ago by KonApazTutorials2 comments – viewed 2,163 times – ( +2 ) – version 1.1
Suppose you have Products,Categories and each product belongs in many categories

Model validation for field ranges using yii2-field-range extension

Created 2 months ago by Kartik VTips0 comments – viewed 999 times – ( +26 ) – version 2.0
The yii2-field-range extension enables you to easily setup ActiveField range fields with Bootstrap styling. You basically can setup two attributes joined together like a single field with combined validation error block.

Save or Update Multiple related model values in one Tabular input form

Created 2 months ago by KonApazTutorials4 comments – viewed 1,414 times – ( +1 / -6 ) – version 1.1
In this wiki I will show you how to save/update a model with many related model For example: How to set a product to multiple categories only in one post form ?

Insert a model record using CGridview

Created 2 months ago by KonApazHow-tos0 comments – viewed 1,406 times – ( +1 ) – version 1.1
CGridview displays existent rows of the table (using DataProvider)

Generate CTreeview from database table and update a model

Created 2 months ago by KonApazHow-tos0 comments – viewed 1,179 times – ( +1 ) – version 1.1
Suppose we want to set a category to product (or an item in general term), Also suppose categories has sub-categories (multi-level)

How to store array/widget configuration to the database with config validation rules

Created 2 months ago by Kartik VTutorials0 comments – viewed 1,268 times – ( +26 / -4 ) – version 2.0
You may have scenarios, where you want to store a specific array configuration to the database. A classic example could be saving Yii widget configuration to the database and then retrieving it at runtime, with dynamic parameters set. This wiki discusses one of the approaches to do this. Let's consider you have something like the NavBar configuration below to store in the db:

Update CGridview row separately using ajax request

Created 2 months ago by KonApazHow-tos6 comments – viewed 2,324 times – ( +5 ) – version 1.1
There are cases you want to update a record on CGridview directly

Take more control of CGridview and model searching (related model or another controller)

Created 7 months ago by KonApazHow-tos5 comments – viewed 12,934 times – ( +5 ) – version 1.1
Suppose you have an Application in Yii that manages hotels each one has many customers.