added duplicate store
This commit is contained in:
@@ -496,4 +496,41 @@ class AdminModel extends Model
|
||||
ON t.Id = tx.TeamstoreId");
|
||||
return $i;
|
||||
}
|
||||
|
||||
function selectTeamstoreProducts($field, $value){
|
||||
|
||||
$i = DB::table('teamstore_products')
|
||||
->where($field, $value)
|
||||
->get();
|
||||
return $i;
|
||||
}
|
||||
|
||||
function selectProductThumbnail($id){
|
||||
|
||||
$i = DB::table('teamstore_product_thumbnails')
|
||||
->where('ProductId', $id)
|
||||
->get();
|
||||
return $i;
|
||||
}
|
||||
|
||||
function insertStoreItem($data){
|
||||
|
||||
$i = DB::table('teamstore_products')->insert($data);
|
||||
var_dump($i);
|
||||
$id = DB::getPdo()->lastInsertId();
|
||||
|
||||
return array(
|
||||
'i' => $i,
|
||||
'lastId' => $id
|
||||
);
|
||||
}
|
||||
|
||||
function insertProductThumbnails($data){
|
||||
|
||||
$i = DB::table('teamstore_product_thumbnails')->insert($data);
|
||||
// $id = DB::getPdo()->lastInsertId();
|
||||
|
||||
return $i;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user