-
Notifications
You must be signed in to change notification settings - Fork 15
function validatePost
Taufik Firmansyah edited this page Jan 29, 2015
·
1 revision
This function used to filter and form all submited form . you can setting/format all filter form using Form Editor at module management .
Usage
// before insert , validate post submit
$data = $this->validatePost('module_name');
// Insert / update into database
$ID = $this->model->insertRow($data , Input::get('primary_key'));
Function will automate filtering wich post field are allowed to save and format it before inserting into database .
Overide post value You can do before insert . example you need to format password before save it into database .
$data = $this->validatePost('module_name');
// reformat / overide
$data['password'] = md5(Input::get('password'));
// Insert / update into database
$ID = $this->model->insertRow($data , Input::get('primary_key'));
Module Structure
- [controller] (https://github.com/mangopik/Sximo-Laravel/wiki/Controller)
- Model
- views
BaseController
- [Function getDownload()] (https://github.com/mangopik/Sximo-Laravel/wiki/function-getDownload%28%29)
- Function trackUriSegment()
- [Function getComboselect()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-getComboselect)
- [Function validatePost()] (https://github.com/mangopik/Sximo-Laravel/wiki/function-validatePost)
- [Function validateForm()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-validateForm)
- [Function validAccess()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-ValidAccess)
- [Function inputLogs()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-inputLogs)
- [Function buildSearch()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-buildSearch)
- [Function masterDetailParam()] (#)
BaseModel
- [Function makeInfo()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-makeInfo)
- [Function getRows()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-getRows)
- [Function getRow()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-getRow)
- [Function insetRow()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-insertRow)
SiteHelpers
- [Function avatar()] (#)
- [Function alert()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-alert)
- [Function encryptID()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-encryptID)
- [Function gridDisplay()] (#)
- [Function langOption()] (https://github.com/mangopik/Sximo-Laravel/wiki/Function-langOption)