Memperbaiki tipe data respon daftar perangkat #18

Merged
rizky_denianto merged 1 commits from pengembangan into main 2026-07-18 01:28:41 +07:00
3 changed files with 7 additions and 9 deletions

No files matched your search

+1 -1
View File
@@ -1,6 +1,6 @@
[package] [package]
name = "tauri-plugin-bluclas" name = "tauri-plugin-bluclas"
version = "0.1.0" version = "0.1.8"
authors = [ "Rizky Denianto" ] authors = [ "Rizky Denianto" ]
description = "" description = ""
edition = "2024" edition = "2024"
+5 -7
View File
@@ -9,12 +9,10 @@ export type SBlueclasResponDaftarPerangkat = {
data: SDaftarPerangkatBlueclasResponDaftarPerangkat[]; data: SDaftarPerangkatBlueclasResponDaftarPerangkat[];
}; };
export async function daftarPerangkat(): Promise< export async function daftarPerangkat(): Promise<SBlueclasResponDaftarPerangkat> {
SBlueclasResponDaftarPerangkat[] return await invoke<SBlueclasResponDaftarPerangkat>(
> {
return await invoke<SBlueclasResponDaftarPerangkat[]>(
"plugin:bluclas|daftar_perangkat", "plugin:bluclas|daftar_perangkat",
).then((res: SBlueclasResponDaftarPerangkat[]) => res); ).then((res: SBlueclasResponDaftarPerangkat) => res);
} }
export type SBlueclasMuatanKirim = { export type SBlueclasMuatanKirim = {
@@ -22,10 +20,10 @@ export type SBlueclasMuatanKirim = {
data: number[]; data: number[];
}; };
export async function kirim(value: SBlueclasMuatanKirim): Promise<null> { export async function kirim(muatan: SBlueclasMuatanKirim): Promise<null> {
return await invoke<null>("plugin:bluclas|kirim", { return await invoke<null>("plugin:bluclas|kirim", {
payload: { payload: {
value, value: muatan,
}, },
}); });
} }
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "@segubi/tauri-plugin-bluclas-api", "name": "@segubi/tauri-plugin-bluclas-api",
"version": "0.1.7", "version": "0.1.8",
"author": "Rizky Denianto", "author": "Rizky Denianto",
"description": "", "description": "",
"type": "module", "type": "module",