- Thunk getDeviceIdByNameThunk entfernt - idLD direkt aus Dropdown gelesen - updatePoiThunk + updatePoiService vollständig eingebunden - Fehlerbehandlung in handleSubmit verbessert - Version erhöht auf 1.1.162
13 lines
458 B
JavaScript
13 lines
458 B
JavaScript
// /redux/thunks/database/getDeviceIdByNameThunk.js
|
|
|
|
import { createAsyncThunk } from "@reduxjs/toolkit";
|
|
import { getDeviceIdByNameService } from "../../../services/database/getDeviceIdByNameService";
|
|
|
|
export const getDeviceIdByNameThunk = createAsyncThunk("devices/getIdByName", async (deviceName, thunkAPI) => {
|
|
try {
|
|
return await getDeviceIdByNameService(deviceName);
|
|
} catch (error) {
|
|
return thunkAPI.rejectWithValue(error.message);
|
|
}
|
|
});
|