增加操作日志功能
This commit is contained in:
@@ -5,6 +5,7 @@ import com.epri.fx.client.model.GroupDataModel;
|
||||
import com.epri.fx.client.request.Request;
|
||||
import com.epri.fx.client.request.feign.admin.GroupTypeFeign;
|
||||
import com.epri.fx.server.vo.GroupTypeVO;
|
||||
import com.jfoenix.controls.JFXSpinner;
|
||||
import com.jfoenix.controls.JFXTabPane;
|
||||
import io.datafx.controller.ViewController;
|
||||
import io.datafx.controller.flow.Flow;
|
||||
@@ -40,13 +41,15 @@ public class GroupManagementController {
|
||||
private StackPane rootPane;
|
||||
@Inject
|
||||
private GroupDataModel groupDataModel;
|
||||
@FXML
|
||||
private JFXSpinner viewSpinner;
|
||||
|
||||
@PostConstruct
|
||||
private void init() {
|
||||
|
||||
TextField textField = new TextField();
|
||||
textField.setStyle("");
|
||||
|
||||
viewSpinner.visibleProperty().bind(tabPane.disableProperty());
|
||||
tabPane.getSelectionModel().selectedItemProperty().addListener(new ChangeListener<Tab>() {
|
||||
@Override
|
||||
public void changed(ObservableValue<? extends Tab> observable, Tab oldValue, Tab newValue) {
|
||||
@@ -60,6 +63,7 @@ public class GroupManagementController {
|
||||
private void initData() {
|
||||
ProcessChain.create().addRunnableInPlatformThread(() -> {
|
||||
tabPane.getTabs().clear();
|
||||
tabPane.setDisable(true);
|
||||
})
|
||||
.addSupplierInExecutor(() -> Request.connector(GroupTypeFeign.class).getAllGroupTypes())
|
||||
.addConsumerInPlatformThread(rel -> {
|
||||
@@ -76,7 +80,9 @@ public class GroupManagementController {
|
||||
}
|
||||
tabPane.getTabs().add(tab);
|
||||
}
|
||||
}).onException(e -> e.printStackTrace())
|
||||
}).onException(e -> e.printStackTrace()).withFinal(() -> {
|
||||
tabPane.setDisable(false);
|
||||
})
|
||||
.run();
|
||||
}
|
||||
|
||||
|
||||
@@ -24,6 +24,7 @@ import javafx.scene.control.*;
|
||||
import javafx.scene.control.cell.PropertyValueFactory;
|
||||
import javafx.scene.layout.HBox;
|
||||
import javafx.scene.layout.StackPane;
|
||||
import javafx.scene.layout.VBox;
|
||||
import javafx.stage.Modality;
|
||||
import javafx.stage.Stage;
|
||||
import javafx.util.Callback;
|
||||
@@ -46,9 +47,13 @@ public class GroupTypeManagementController {
|
||||
@FXMLViewFlowContext
|
||||
private ViewFlowContext viewFlowContext;
|
||||
|
||||
@FXML
|
||||
private VBox contentPane;
|
||||
@FXML
|
||||
private StackPane rootPane;
|
||||
@FXML
|
||||
private JFXSpinner viewSpinner;
|
||||
@FXML
|
||||
private JFXProgressBar progressBar;
|
||||
@FXML
|
||||
private JFXDialog dialog;
|
||||
@@ -100,9 +105,13 @@ public class GroupTypeManagementController {
|
||||
|
||||
progressBar.visibleProperty().bind(dialog.disableProperty());
|
||||
progressBar.managedProperty().bind(progressBar.visibleProperty());
|
||||
|
||||
updateButton.visibleProperty().bind(saveButton.visibleProperty().not());
|
||||
updateButton.managedProperty().bind(updateButton.visibleProperty());
|
||||
saveButton.managedProperty().bind(saveButton.visibleProperty());
|
||||
|
||||
cancelButton.disableProperty().bind(saveButton.disableProperty().or(updateButton.disableProperty()));
|
||||
viewSpinner.visibleProperty().bind(contentPane.disableProperty());
|
||||
|
||||
serialNumberColumn.setCellFactory((col) -> {
|
||||
TableCell<GroupTypeVO, String> cell = new TableCell<GroupTypeVO, String>() {
|
||||
@@ -202,11 +211,16 @@ public class GroupTypeManagementController {
|
||||
}
|
||||
|
||||
private void loadingTableData() {
|
||||
ProcessChain.create()
|
||||
ProcessChain.create().addRunnableInPlatformThread(() -> {
|
||||
contentPane.setDisable(true);
|
||||
})
|
||||
.addSupplierInExecutor(() -> Request.connector(GroupTypeFeign.class).getAllGroupTypes())
|
||||
.addConsumerInPlatformThread(rel -> {
|
||||
groupTypeDataModel.getGroupTypes().clear();
|
||||
groupTypeDataModel.getGroupTypes().addAll(rel);})
|
||||
groupTypeDataModel.getGroupTypes().addAll(rel);
|
||||
}).withFinal(() -> {
|
||||
contentPane.setDisable(false);
|
||||
})
|
||||
.run();
|
||||
}
|
||||
|
||||
@@ -236,7 +250,7 @@ public class GroupTypeManagementController {
|
||||
ProcessChain.create().addRunnableInPlatformThread(() -> dialog.setDisable(true))
|
||||
.addSupplierInExecutor(() -> Request.connector(GroupTypeFeign.class).addGroupType(groupTypeVO))
|
||||
.addConsumerInPlatformThread(rel -> {
|
||||
if (rel >=0) {
|
||||
if (rel >= 0) {
|
||||
loadingTableData();
|
||||
}
|
||||
}).withFinal(() -> {
|
||||
|
||||
@@ -0,0 +1,269 @@
|
||||
package com.epri.fx.client.gui.uicomponents.admin.log;
|
||||
|
||||
import com.epri.fx.client.gui.feature.FeatureResourceConsumer;
|
||||
import com.epri.fx.client.gui.feature.HideByFeature;
|
||||
import com.epri.fx.client.gui.uicomponents.admin.user.components.UserAddController;
|
||||
import com.epri.fx.client.gui.uicomponents.admin.user.components.UserEditController;
|
||||
import com.epri.fx.client.model.LogDataModel;
|
||||
import com.epri.fx.client.model.UserDataModel;
|
||||
import com.epri.fx.client.request.Request;
|
||||
import com.epri.fx.client.request.feign.admin.LogFeign;
|
||||
import com.epri.fx.client.request.feign.admin.UserFeign;
|
||||
import com.epri.fx.client.request.feign.login.LoginFeign;
|
||||
import com.epri.fx.client.store.ApplicatonStore;
|
||||
import com.epri.fx.client.utils.Pinyin4jUtil;
|
||||
import com.epri.fx.server.entity.User;
|
||||
import com.epri.fx.server.entity.log.GateLog;
|
||||
import com.epri.fx.server.entity.log.LogInfo;
|
||||
import com.epri.fx.server.util.DateUtils;
|
||||
import com.epri.fx.server.vo.UserVO;
|
||||
import com.jfoenix.controls.JFXAlert;
|
||||
import com.jfoenix.controls.JFXButton;
|
||||
import com.jfoenix.controls.JFXDialogLayout;
|
||||
import com.jfoenix.svg.SVGGlyphLoader;
|
||||
import io.datafx.controller.ViewController;
|
||||
import io.datafx.controller.flow.FlowException;
|
||||
import io.datafx.controller.flow.action.ActionMethod;
|
||||
import io.datafx.controller.flow.action.ActionTrigger;
|
||||
import io.datafx.controller.flow.context.ActionHandler;
|
||||
import io.datafx.controller.flow.context.FlowActionHandler;
|
||||
import io.datafx.controller.util.VetoException;
|
||||
import io.datafx.core.concurrent.ProcessChain;
|
||||
import io.datafx.eventsystem.Event;
|
||||
import io.datafx.eventsystem.OnEvent;
|
||||
import javafx.collections.transformation.FilteredList;
|
||||
import javafx.fxml.FXML;
|
||||
import javafx.geometry.Pos;
|
||||
import javafx.scene.Node;
|
||||
import javafx.scene.control.*;
|
||||
import javafx.scene.control.cell.PropertyValueFactory;
|
||||
import javafx.scene.layout.HBox;
|
||||
import javafx.scene.layout.StackPane;
|
||||
import javafx.scene.layout.VBox;
|
||||
import javafx.stage.Modality;
|
||||
import javafx.stage.Stage;
|
||||
import javafx.util.Callback;
|
||||
|
||||
import javax.annotation.PostConstruct;
|
||||
import javax.annotation.PreDestroy;
|
||||
import javax.inject.Inject;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @description:
|
||||
* @className: UserManagementController
|
||||
* @author: liwen
|
||||
* @date: 2020/3/4 21:05
|
||||
*/
|
||||
@ViewController(value = "/fxml/admin/log/log_management.fxml", title = "操作日志")
|
||||
public class LogManagementController {
|
||||
|
||||
public static final String CONTENT_PANE = "ContentPane";
|
||||
|
||||
|
||||
@FXML
|
||||
private StackPane root;
|
||||
@FXML
|
||||
private VBox centPane;
|
||||
@FXML
|
||||
private StackPane spinnerPane;
|
||||
@FXML
|
||||
private TextField searchField;
|
||||
@FXML
|
||||
private TextField userNameTextField;
|
||||
@FXML
|
||||
private TextField accountTextField;
|
||||
@FXML
|
||||
private TextField pwdTextField;
|
||||
@FXML
|
||||
private TextArea descTextArea;
|
||||
@FXML
|
||||
private ComboBox genderCombobox;
|
||||
@FXML
|
||||
@ActionTrigger("search")
|
||||
private Button searchBut;
|
||||
|
||||
@FXML
|
||||
private Pagination pagination;
|
||||
|
||||
|
||||
@FXML
|
||||
private TableView<GateLog> tableView;
|
||||
@FXML
|
||||
private TableColumn<GateLog, String> serialNumberColumn;
|
||||
@FXML
|
||||
private TableColumn<GateLog, String> idColumn;
|
||||
@FXML
|
||||
private TableColumn<GateLog, String> menuColumn;
|
||||
@FXML
|
||||
private TableColumn<GateLog, String> optColumn;
|
||||
@FXML
|
||||
private TableColumn<GateLog, String> urlColumn;
|
||||
@FXML
|
||||
private TableColumn<GateLog, String> optTimeColumn;
|
||||
@FXML
|
||||
private TableColumn<GateLog, String> optUserIdColumn;
|
||||
@FXML
|
||||
private TableColumn<GateLog, String> optUserColumn;
|
||||
@FXML
|
||||
private TableColumn<GateLog, String> optIpColumn;
|
||||
@FXML
|
||||
private TableColumn<GateLog, String> requetDataColumn;
|
||||
|
||||
@ActionHandler
|
||||
private FlowActionHandler actionHandler;
|
||||
|
||||
@Inject
|
||||
private LogDataModel logDataModel;
|
||||
|
||||
@Inject
|
||||
private FeatureResourceConsumer featureResourceConsumer;
|
||||
|
||||
@PostConstruct
|
||||
public void init() {
|
||||
featureResourceConsumer.consumeResource(this);
|
||||
spinnerPane.setVisible(false);
|
||||
serialNumberColumn.setCellFactory((col) -> {
|
||||
TableCell<GateLog, String> cell = new TableCell<GateLog, String>() {
|
||||
@Override
|
||||
public void updateItem(String item, boolean empty) {
|
||||
super.updateItem(item, empty);
|
||||
this.setText(null);
|
||||
this.setGraphic(null);
|
||||
|
||||
if (!empty) {
|
||||
int rowIndex = this.getIndex() + 1;
|
||||
this.setText(String.valueOf(rowIndex));
|
||||
}
|
||||
}
|
||||
};
|
||||
return cell;
|
||||
});
|
||||
|
||||
idColumn.setCellValueFactory(new PropertyValueFactory<>("id"));
|
||||
menuColumn.setCellValueFactory(new PropertyValueFactory<>("menu"));
|
||||
optColumn.setCellValueFactory(new PropertyValueFactory<>("opt"));
|
||||
urlColumn.setCellValueFactory(new PropertyValueFactory<>("uri"));
|
||||
optTimeColumn.setCellValueFactory(new PropertyValueFactory<>("crtTime"));
|
||||
optUserIdColumn.setCellValueFactory(new PropertyValueFactory<>("crtUser"));
|
||||
optUserColumn.setCellValueFactory(new PropertyValueFactory<>("crtName"));
|
||||
optIpColumn.setCellValueFactory(new PropertyValueFactory<>("crtHost"));
|
||||
requetDataColumn.setCellValueFactory(new PropertyValueFactory<>("body"));
|
||||
|
||||
|
||||
FilteredList<GateLog> filteredData = new FilteredList<>(logDataModel.getGateLogs(), p -> true);
|
||||
tableView.setItems(filteredData);
|
||||
searchField.textProperty().addListener((o, oldVal, newVal) -> {
|
||||
filteredData.setPredicate(elementProp -> {
|
||||
if (newVal == null || newVal.isEmpty()) {
|
||||
return true;
|
||||
}
|
||||
String val = Pinyin4jUtil.toPinYinLowercase(newVal);
|
||||
return Pinyin4jUtil.toPinYinLowercase(elementProp.getMenu()).contains(val)
|
||||
|| Pinyin4jUtil.toPinYinLowercase(elementProp.getCrtName()).contains(val)
|
||||
|| elementProp.getCrtHost().toLowerCase().contains(val);
|
||||
});
|
||||
});
|
||||
|
||||
logDataModel.selectedPersonIndexProperty().bind(tableView.getSelectionModel().selectedIndexProperty());
|
||||
pagination.pageCountProperty().bind(logDataModel.pageCountProperty());
|
||||
pagination.setPageFactory(new Callback<Integer, Node>() {
|
||||
@Override
|
||||
public Node call(Integer param) {
|
||||
showPage(param + 1);
|
||||
return tableView;
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
private void delete() {
|
||||
GateLog gateLog = logDataModel.getGateLogs().get(logDataModel.getSelectedPersonIndex());
|
||||
|
||||
JFXAlert alert = new JFXAlert((Stage) root.getScene().getWindow());
|
||||
alert.initModality(Modality.APPLICATION_MODAL);
|
||||
alert.setOverlayClose(false);
|
||||
JFXDialogLayout layout = new JFXDialogLayout();
|
||||
layout.setHeading(new Label("消息提示"));
|
||||
layout.setBody(new Label("确实删除【" + gateLog.getId() + "】吗?"));
|
||||
JFXButton closeButton = new JFXButton("取消");
|
||||
closeButton.setOnAction(event -> alert.hideWithAnimation());
|
||||
JFXButton determineButton = new JFXButton("确定");
|
||||
determineButton.setOnAction(event -> {
|
||||
alert.hideWithAnimation();
|
||||
ProcessChain.create()
|
||||
.addSupplierInExecutor(() -> Request.connector(UserFeign.class).delete(gateLog.getId()))
|
||||
.addConsumerInPlatformThread(result -> {
|
||||
if (result.isRel()) {
|
||||
logDataModel.getGateLogs().remove(logDataModel.getSelectedPersonIndex());
|
||||
}
|
||||
}).onException(e -> e.printStackTrace()).run();
|
||||
});
|
||||
layout.setActions(closeButton, determineButton);
|
||||
alert.setContent(layout);
|
||||
alert.show();
|
||||
|
||||
}
|
||||
|
||||
|
||||
private void showPage(Integer page) {
|
||||
Map<String, Object> queryMap = new HashMap<>();
|
||||
queryMap.put("keyId", searchField.getText());
|
||||
queryMap.put("page", page);
|
||||
query(queryMap);
|
||||
|
||||
}
|
||||
|
||||
@ActionMethod("search")
|
||||
private void search() {
|
||||
Map<String, Object> queryMap = new HashMap<>();
|
||||
queryMap.put("keyId", searchField.getText());
|
||||
query(queryMap);
|
||||
|
||||
}
|
||||
|
||||
private void query(Map<String, Object> queryMap) {
|
||||
|
||||
ProcessChain.create()
|
||||
.addRunnableInPlatformThread(() -> {
|
||||
spinnerPane.setVisible(true);
|
||||
centPane.setDisable(true);
|
||||
})
|
||||
.addSupplierInExecutor(() -> Request.connector(LogFeign.class).getPageList(queryMap)
|
||||
)
|
||||
.addConsumerInPlatformThread(result -> {
|
||||
logDataModel.getGateLogs().clear();
|
||||
List<GateLog> gateLogs = result.getDatas();
|
||||
logDataModel.setPageCount((int) result.getTotal());
|
||||
|
||||
for (GateLog gateLog : gateLogs) {
|
||||
logDataModel.getGateLogs().add(gateLog);
|
||||
}
|
||||
})
|
||||
.withFinal(() -> {
|
||||
spinnerPane.setVisible(false);
|
||||
centPane.setDisable(false);
|
||||
})
|
||||
.onException(e -> e.printStackTrace())
|
||||
.run();
|
||||
}
|
||||
|
||||
|
||||
@PreDestroy
|
||||
private void destroy() {
|
||||
System.err.println("destroy " + this);
|
||||
}
|
||||
|
||||
|
||||
@OnEvent("refresh")
|
||||
private void onRefresh(Event<String> e) {
|
||||
System.err.println(this.getClass() + "\t" + e.getContent());
|
||||
|
||||
search();
|
||||
|
||||
}
|
||||
}
|
||||
@@ -48,6 +48,7 @@ import javax.annotation.PostConstruct;
|
||||
import javax.annotation.PreDestroy;
|
||||
import javax.inject.Inject;
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.HashMap;
|
||||
|
||||
/**
|
||||
@@ -120,6 +121,7 @@ public class MainController {
|
||||
private JFXDrawer leftDrawer;
|
||||
|
||||
@FXML
|
||||
@EventTrigger("refresh")
|
||||
private JFXDatePicker datePicker;
|
||||
@Inject
|
||||
private FeatureResourceConsumer featureResourceConsumer;
|
||||
@@ -144,6 +146,9 @@ public class MainController {
|
||||
e.printStackTrace();
|
||||
}
|
||||
datePicker.setEditable(false);
|
||||
datePicker.valueProperty().addListener((observable, oldValue, newValue) ->{
|
||||
refreshButton.fire();
|
||||
});
|
||||
leftDrawer.setSidePane(navigationList);
|
||||
leftDrawer.setOverLayVisible(false);
|
||||
leftDrawer.setResizeContent(true);
|
||||
@@ -226,7 +231,7 @@ public class MainController {
|
||||
|
||||
@EventProducer("refresh")
|
||||
private String refresh() {
|
||||
return "--------=================-----------";
|
||||
return datePicker.getValue().format(DateTimeFormatter.ofPattern("yyyyMMdd"));
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,58 @@
|
||||
package com.epri.fx.client.model;
|
||||
|
||||
import com.epri.fx.server.entity.log.GateLog;
|
||||
import io.datafx.controller.injection.scopes.FlowScoped;
|
||||
import javafx.beans.property.IntegerProperty;
|
||||
import javafx.beans.property.ListProperty;
|
||||
import javafx.beans.property.SimpleIntegerProperty;
|
||||
import javafx.beans.property.SimpleListProperty;
|
||||
import javafx.collections.FXCollections;
|
||||
import javafx.collections.ObservableList;
|
||||
|
||||
@FlowScoped
|
||||
public class LogDataModel {
|
||||
private int counter = 0;
|
||||
private ListProperty<GateLog> gateLogs;
|
||||
|
||||
private IntegerProperty pageCount;
|
||||
private IntegerProperty selectedPersonIndex;
|
||||
|
||||
|
||||
public ListProperty<GateLog> getGateLogs() {
|
||||
if (gateLogs == null) {
|
||||
ObservableList<GateLog> innerList = FXCollections.observableArrayList();
|
||||
gateLogs = new SimpleListProperty<>(innerList);
|
||||
}
|
||||
return gateLogs;
|
||||
}
|
||||
|
||||
public int getSelectedPersonIndex() {
|
||||
return selectedPersonIndexProperty().get();
|
||||
}
|
||||
|
||||
public void setSelectedPersonIndex(int selectedPersonIndex) {
|
||||
this.selectedPersonIndex.set(selectedPersonIndex);
|
||||
}
|
||||
|
||||
public IntegerProperty selectedPersonIndexProperty() {
|
||||
if (selectedPersonIndex == null) {
|
||||
selectedPersonIndex = new SimpleIntegerProperty();
|
||||
}
|
||||
return selectedPersonIndex;
|
||||
}
|
||||
|
||||
public int getPageCount() {
|
||||
return pageCount.get();
|
||||
}
|
||||
|
||||
public IntegerProperty pageCountProperty() {
|
||||
if (pageCount == null) {
|
||||
pageCount = new SimpleIntegerProperty();
|
||||
}
|
||||
return pageCount;
|
||||
}
|
||||
|
||||
public void setPageCount(int pageCount) {
|
||||
this.pageCount.set(pageCount);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
package com.epri.fx.client.request.feign.admin;
|
||||
|
||||
import com.epri.fx.client.request.feign.FeignAPI;
|
||||
import com.epri.fx.server.entity.User;
|
||||
import com.epri.fx.server.entity.log.GateLog;
|
||||
import com.epri.fx.server.entity.log.LogInfo;
|
||||
import com.epri.fx.server.msg.ObjectRestResponse;
|
||||
import com.epri.fx.server.msg.TableResultResponse;
|
||||
import feign.Param;
|
||||
import feign.QueryMap;
|
||||
import feign.RequestLine;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @description:
|
||||
* @className: TestFeign
|
||||
* @author: liwen
|
||||
* @date: 2020/4/1 17:31
|
||||
*/
|
||||
public interface LogFeign extends FeignAPI {
|
||||
@RequestLine("GET /log/page")
|
||||
TableResultResponse<GateLog> getPageList(@QueryMap Map<String, Object> map);
|
||||
|
||||
@RequestLine("DELETE /log/{id}")
|
||||
ObjectRestResponse<Integer> delete(@Param("id") Integer id);
|
||||
|
||||
|
||||
}
|
||||
@@ -4,9 +4,11 @@
|
||||
<?import javafx.scene.layout.StackPane?>
|
||||
|
||||
|
||||
<?import com.jfoenix.controls.JFXSpinner?>
|
||||
<StackPane fx:id="rootPane" prefHeight="400.0" prefWidth="600.0" xmlns="http://javafx.com/javafx/8.0.171"
|
||||
xmlns:fx="http://javafx.com/fxml/1">
|
||||
<children>
|
||||
<JFXTabPane fx:id="tabPane"/>
|
||||
<JFXSpinner fx:id="viewSpinner" radius="18" startingAngle="90" styleClass="blue-spinner" visible="false" />
|
||||
</children>
|
||||
</StackPane>
|
||||
|
||||
@@ -11,9 +11,10 @@
|
||||
<?import javafx.scene.layout.StackPane?>
|
||||
<?import javafx.scene.layout.VBox?>
|
||||
|
||||
<?import com.jfoenix.controls.JFXSpinner?>
|
||||
<StackPane fx:id="rootPane" prefHeight="384.0" prefWidth="585.0" xmlns="http://javafx.com/javafx/8.0.171" xmlns:fx="http://javafx.com/fxml/1">
|
||||
<children>
|
||||
<VBox spacing="7.0">
|
||||
<VBox fx:id="contentPane" spacing="7.0">
|
||||
<children>
|
||||
<HBox alignment="CENTER_RIGHT" spacing="10.0" styleClass="card-pane">
|
||||
<children>
|
||||
@@ -38,6 +39,7 @@
|
||||
</TableView>
|
||||
</children>
|
||||
</VBox>
|
||||
<JFXSpinner fx:id="viewSpinner" radius="18" startingAngle="90" styleClass="blue-spinner" visible="false" />
|
||||
|
||||
<JFXDialog fx:id="dialog" transitionType="TOP">
|
||||
<JFXDialogLayout>
|
||||
|
||||
60
client/src/main/resources/fxml/admin/log/log_management.fxml
Normal file
60
client/src/main/resources/fxml/admin/log/log_management.fxml
Normal file
@@ -0,0 +1,60 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
|
||||
<?import com.jfoenix.controls.JFXButton?>
|
||||
<?import com.jfoenix.controls.JFXSpinner?>
|
||||
<?import com.jfoenix.controls.JFXTextField?>
|
||||
<?import javafx.scene.control.Pagination?>
|
||||
<?import javafx.scene.control.TableColumn?>
|
||||
<?import javafx.scene.control.TableView?>
|
||||
<?import javafx.scene.layout.AnchorPane?>
|
||||
<?import javafx.scene.layout.HBox?>
|
||||
<?import javafx.scene.layout.StackPane?>
|
||||
<?import javafx.scene.layout.VBox?>
|
||||
|
||||
<StackPane fx:id="root" xmlns="http://javafx.com/javafx/8.0.171" xmlns:fx="http://javafx.com/fxml/1">
|
||||
<children>
|
||||
<VBox fx:id="centPane" maxHeight="1.7976931348623157E308" maxWidth="1.7976931348623157E308" spacing="10.0">
|
||||
<children>
|
||||
<HBox alignment="CENTER_RIGHT" maxHeight="-Infinity" prefHeight="45.0" prefWidth="200.0" spacing="10.0" styleClass="card-pane">
|
||||
<children>
|
||||
<JFXTextField fx:id="searchField" promptText="菜单,操作人或操作主机" />
|
||||
<JFXButton fx:id="searchBut" buttonType="RAISED" text="搜索" />
|
||||
</children>
|
||||
</HBox>
|
||||
<AnchorPane VBox.vgrow="ALWAYS">
|
||||
<children>
|
||||
<Pagination fx:id="pagination" cache="true" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0" />
|
||||
<TableView fx:id="tableView" editable="true" tableMenuButtonVisible="false" AnchorPane.bottomAnchor="60.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
|
||||
<columnResizePolicy>
|
||||
<TableView fx:constant="CONSTRAINED_RESIZE_POLICY" />
|
||||
</columnResizePolicy>
|
||||
<columns>
|
||||
<TableColumn fx:id="serialNumberColumn" maxWidth="50.0" minWidth="50.0" prefWidth="50.0" text="序号" />
|
||||
<TableColumn fx:id="idColumn" maxWidth="50.0" minWidth="50.0" prefWidth="50.0" text="id" />
|
||||
<TableColumn fx:id="menuColumn" text="菜单" />
|
||||
<TableColumn fx:id="optColumn" text="操作" />
|
||||
<TableColumn fx:id="urlColumn" text="资源路径" />
|
||||
<TableColumn fx:id="optTimeColumn" text="操作时间" />
|
||||
<TableColumn fx:id="optUserIdColumn" text="操作人id" />
|
||||
<TableColumn fx:id="optUserColumn" maxWidth="120.0" minWidth="120.0" prefWidth="120" text="操作人" />
|
||||
<TableColumn fx:id="optIpColumn" maxWidth="120.0" minWidth="120.0" prefWidth="120" text="操作主机" />
|
||||
<TableColumn fx:id="requetDataColumn" maxWidth="120.0" minWidth="120.0" prefWidth="120" text="请求数据" />
|
||||
|
||||
</columns>
|
||||
</TableView>
|
||||
</children>
|
||||
</AnchorPane>
|
||||
</children>
|
||||
</VBox>
|
||||
<StackPane fx:id="spinnerPane" visible="false">
|
||||
<JFXSpinner startingAngle="-40" styleClass="materialDesign-purple, first-spinner" />
|
||||
<JFXSpinner startingAngle="-90" styleClass="materialDesign-blue, second-spinner" />
|
||||
<JFXSpinner startingAngle="-120" styleClass="materialDesign-cyan, third-spinner" />
|
||||
<JFXSpinner startingAngle="-150" styleClass="materialDesign-green, fourth-spinner" />
|
||||
<JFXSpinner startingAngle="-180" styleClass="materialDesign-yellow, fifth-spinner" />
|
||||
<JFXSpinner startingAngle="-210" styleClass="materialDesign-orange, sixth-spinner" />
|
||||
<JFXSpinner startingAngle="-240" styleClass="materialDesign-red, seventh-spinner" />
|
||||
</StackPane>
|
||||
</children>
|
||||
|
||||
</StackPane>
|
||||
@@ -46,7 +46,7 @@
|
||||
<TreeView fx:id="treeView" VBox.vgrow="ALWAYS" />
|
||||
</children>
|
||||
</VBox>
|
||||
<JFXSpinner fx:id="treeViewSpinner" radius="13" startingAngle="0" styleClass="blue-spinner" visible="false" />
|
||||
<JFXSpinner fx:id="treeViewSpinner" radius="18.0" startingAngle="90.0" styleClass="blue-spinner" visible="false" />
|
||||
</children>
|
||||
</StackPane>
|
||||
</children>
|
||||
|
||||
Reference in New Issue
Block a user