This commit is contained in:
mr
2025-02-21 11:14:46 +01:00
parent 28510d0ba1
commit 863a35b878
34 changed files with 153 additions and 128 deletions

View File

@@ -61,7 +61,6 @@ class SchedulerFormsWidgetState extends State<SchedulerFormsWidget> {
dash.error = "You need to link each processing element to a compute element";
}
}
print("qdjqksdn ${dash.error}");
if (dash.error != null) {
showAlertBanner( context, () {}, AlertAlertBannerChild(text: dash.error.toString()),// <-- Put any widget here you want!
alertBannerLocation: AlertBannerLocation.bottom,);
@@ -71,7 +70,6 @@ class SchedulerFormsWidgetState extends State<SchedulerFormsWidget> {
for (var k in formKeys) {
if (k.currentState != null) {
if (!k.currentState!.validate()) {
print("bwak");
return;
} else { k.currentState!.save();}
}
@@ -84,14 +82,11 @@ class SchedulerFormsWidgetState extends State<SchedulerFormsWidget> {
}
}
Duration durationBefore = widget.schedule.start!.difference(DateTime.now().toUtc()) + Duration(seconds: 5);
print("qdjqksdn ${widget.item.id}");
widget._schedulerService.schedule(context, widget.item.id ?? "", widget.schedule.serialize(), {}).catchError( (e) {
print("THERE2");
setState(() {
widget.error = e.toString();
});
}).then((value) {
print("THERE");
setState(() { widget.valid = true; });
Future.delayed(durationBefore, () {
try {
@@ -222,12 +217,11 @@ class SchedulerFormsWidgetState extends State<SchedulerFormsWidget> {
);
});
} : null,
);
shallow.change =(p0) => Future.delayed( const Duration(seconds: 2), () async {
if (shallow.compare == p0) {
await WorflowService().put(context, widget.item.id ?? "", { "name" : p0 }, {});
} else {
shallow.compare = p0;
);
shallow.change =(p0) => Future.delayed( const Duration(milliseconds: 100), () async {
if (shallow.current == p0) {
dash.name = p0 ?? dash.name;
await WorflowService().put(context, widget.item.id ?? "", { "name" : dash.name }, {});
}
});
return Column( children: [
@@ -243,7 +237,7 @@ class SchedulerFormsWidgetState extends State<SchedulerFormsWidget> {
bottom: const BorderSide(color: Colors.grey))),
child: shallow ),
const SizedBox(height: 20, width: 200 ),
isService ? Text("Warning a processing is a service, if no end execution it will run forever.") : Container(),
isService ? const Text("Warning a processing is a service, if no end execution it will run forever.") : Container(),
Tooltip( message: "start executions",
child: Container( height: 40, margin: const EdgeInsets.only(top: 5),
padding: const EdgeInsets.symmetric(vertical: 5, horizontal: 10),