saving new visualizer done
This commit is contained in:
@@ -258,4 +258,39 @@ class AdminModel extends Model
|
||||
->get();
|
||||
return $i;
|
||||
}
|
||||
|
||||
function saveNewVisualizer($data){
|
||||
$i = DB::table('templates')->insert($data);
|
||||
$id = DB::getPdo()->lastInsertId();
|
||||
|
||||
return array(
|
||||
'i' => $i,
|
||||
'lastId' => $id
|
||||
);
|
||||
}
|
||||
|
||||
function updateVisualizer($id, $data){
|
||||
|
||||
$i = DB::table('templates')
|
||||
->where("Id", $id)
|
||||
->update($data);
|
||||
return $i;
|
||||
}
|
||||
|
||||
function saveVisualizerDefaultBodyColor($data){
|
||||
$i = DB::table('template_body_colors')->insert($data);
|
||||
|
||||
return $i;
|
||||
}
|
||||
|
||||
function saveVisualizerDefaultTrimColor($data){
|
||||
$i = DB::table('template_trim_colors')->insert($data);
|
||||
return $i;
|
||||
}
|
||||
|
||||
function saveVisualizerPath($data){
|
||||
$i = DB::table('template_paths')->insert($data);
|
||||
return $i;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user