package com.zhangmeng.online.exam.ui.api;

import javafx.beans.property.SimpleStringProperty;
import javafx.scene.Parent;
import javafx.scene.control.MenuItem;
import javafx.stage.Stage;

import java.util.Collection;
import java.util.List;
import java.util.Map;

/**
 * @author zm
 * @date 2025/3/14 15:48
 * @version: 1.0
 */
public interface DataLoad {

   public ApiUtils.DataView loadData(Integer pageNum, Integer pageSize);

   public void setForm(Parent view);

   public Parent getForm();

   Map<String, Object> saveForm(Map<String, Object> map);

   public void deleteData(String id);

   public void editData(String s, Stage stage);

   public void updateData(String id, String name, String oldValue, String newValue);

   List<MenuItem> getContextMenu();

   ApiUtils.DataView searchData(Map<String, Object> searchText, int pageNum, int pageSize);
}
