refactor: update getSDUIForm method to require token parameter, enhance error handling in SDUIFormWidget, and clean up code formatting across various files
This commit is contained in:
@@ -636,7 +636,7 @@ class SDUIFormWidget extends StatelessWidget {
|
||||
iLog('Stack trace: $stackTrace');
|
||||
return Container(
|
||||
padding: EdgeInsets.all(16),
|
||||
color: Colors.green.withOpacity(0.1),
|
||||
color: Colors.green.withAlpha(10),
|
||||
child: Text('Image Picker Error: $e'),
|
||||
);
|
||||
}
|
||||
@@ -712,7 +712,7 @@ class SDUIFormWidget extends StatelessWidget {
|
||||
iLog('Error building page_view child: $e');
|
||||
return Container(
|
||||
padding: EdgeInsets.all(8),
|
||||
color: Colors.yellow.withOpacity(0.1),
|
||||
color: Colors.yellow.withAlpha(10),
|
||||
child: Text('Child Error'),
|
||||
);
|
||||
}
|
||||
@@ -733,7 +733,7 @@ class SDUIFormWidget extends StatelessWidget {
|
||||
iLog('Stack trace: $stackTrace');
|
||||
return Container(
|
||||
padding: EdgeInsets.all(16),
|
||||
color: Colors.blue.withOpacity(0.1),
|
||||
color: Colors.blue.withAlpha(10),
|
||||
child: Text('PageView Error: $e'),
|
||||
);
|
||||
}
|
||||
@@ -1006,8 +1006,6 @@ class SDUIFormWidget extends StatelessWidget {
|
||||
'sdui_form_stepper_${stepperInfo.stepperData.key ?? 'default'}';
|
||||
SDUIFormWidgetController formController;
|
||||
|
||||
fLog('mj ==>build With Stepper Layout');
|
||||
|
||||
try {
|
||||
formController = Get.find<SDUIFormWidgetController>(tag: controllerTag);
|
||||
} catch (_) {
|
||||
@@ -1548,7 +1546,6 @@ class SDUIFormWidget extends StatelessWidget {
|
||||
child: Row(
|
||||
spacing: 10.w,
|
||||
children: [
|
||||
|
||||
Expanded(
|
||||
child: ROutlinedElevated(
|
||||
height: 40.h,
|
||||
@@ -1568,7 +1565,7 @@ class SDUIFormWidget extends StatelessWidget {
|
||||
borderColor: AppColor.blueNormal,
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
Expanded(
|
||||
flex: 2,
|
||||
child: RElevated(
|
||||
height: 40.h,
|
||||
@@ -1590,7 +1587,6 @@ class SDUIFormWidget extends StatelessWidget {
|
||||
backgroundColor: AppColor.blueNormal,
|
||||
),
|
||||
),
|
||||
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
@@ -6,7 +6,7 @@ class SDUIFormWidgetController extends GetxController {
|
||||
String? stepperKey;
|
||||
|
||||
void initializeStepper(int totalSteps, String? key) {
|
||||
this.totalSteps = totalSteps;
|
||||
this.totalSteps = totalSteps;
|
||||
this.stepperKey = key;
|
||||
currentStep.value = 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user