aa
This commit is contained in:
@@ -6,9 +6,8 @@ use Illuminate\Database\Eloquent\Model;
|
|||||||
|
|
||||||
class Clientegm extends Model
|
class Clientegm extends Model
|
||||||
{
|
{
|
||||||
protected $primaryKey = 'CodClienteInternet'; // Imposta la chiave primaria corretta
|
protected $primaryKey = null;
|
||||||
public $incrementing = true; // Indica che è auto-incrementante
|
public $incrementing = false;
|
||||||
|
|
||||||
//protected $connection = 'mysql_test';
|
//protected $connection = 'mysql_test';
|
||||||
protected $connection = 'sqlsrv_test';
|
protected $connection = 'sqlsrv_test';
|
||||||
protected $table = 'T_WOO_Clienti';
|
protected $table = 'T_WOO_Clienti';
|
||||||
|
|||||||
@@ -2178,8 +2178,8 @@ Route::get('/testcli', function () {
|
|||||||
$cliente->IdNazione = 227; // ITALIA
|
$cliente->IdNazione = 227; // ITALIA
|
||||||
$cliente->IdInternet = 68499;
|
$cliente->IdInternet = 68499;
|
||||||
try {
|
try {
|
||||||
$cliente->save();
|
|
||||||
dd($cliente);
|
dd($cliente);
|
||||||
|
$cliente->save();
|
||||||
} catch (\Throwable $th) {
|
} catch (\Throwable $th) {
|
||||||
dd($th);
|
dd($th);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user