eloquent-filemaker icon indicating copy to clipboard operation
eloquent-filemaker copied to clipboard

setModId is not working when updating.

Open seagullmark opened this issue 1 year ago • 3 comments
trafficstars

Dependencies

  • FileMaker Version: 21.0.2.202
  • PHP Version: 8.3.11
  • Laravel Version: 11.24.0
  • Eloquent FileMaker Version: 2.4.4

Description of the issue:

Records are updated even though the modification IDs do not match.

Expected Behavior:

Exceptions is thrown

Steps to reproduce:

public function update(Request $request, Fishing $fishing)
    {
        // dd($request);
        $fishing->fishing_date = $request->fishing_date;
        $fishing->fishing_type = $request->fishing_type;
        $fishing->place = $request->place;
        $fishing->comment = $request->comment;

        $fishing->setModId($request->mod_id);
        // $fishing->save();
        $fishing->update();

Clockwork

Fishing	
UPDATE
Method: patch
URL: https://192.168.3.30/fmi/data/vLatest/databases/anglers/layouts/fishings/records/6
Data: {
    "fieldData": {
        "\u5834\u6240": "\u6b74\u821f"
    }
}

seagullmark avatar Oct 01 '24 02:10 seagullmark