1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950 |
- import 'base_form_value.dart';
- import 'form_info.dart';
- class PostpartumForm extends BaseFormValueChange {
- static PostpartumForm? _postpartumForm;
- PostpartumForm._internal();
- ///第 1 次产前检查服务记录表的值
- static PostpartumForm get instance {
- _postpartumForm ??= PostpartumForm._internal();
- return _postpartumForm!;
- }
- void initListener() {
- FormInfo.instance.onValueChange.addListener(_onValueChange);
- }
- void dispose() {
- FormInfo.instance.onValueChange.removeListener(_onValueChange);
- }
- void _onValueChange(Object sender, UpdateFormArgs e) {
- String sourceKey = e.sourceKey;
- switch (sourceKey) {
- case "Breasts":
- onValueChange(e, "Breasts_1", "Breasts_2");
- break;
- case "Lochia":
- onValueChange(e, "Lochia_1", "Lochia_2");
- break;
- case "Uterus":
- onValueChange(e, "Uterus_1", "Uterus_2");
- break;
- case "Wound":
- onValueChange(e, "Wound_1", "Wound_2");
- break;
- case "Classification":
- onValueChange(e, "Classification_1", "Classification_2");
- break;
- case "Referral":
- onReferralChange(e);
- break;
- case "Processing":
- onValueChange(e, "Processing_1", "Reason_For_Referral");
- onValueChange(e, "Processing_1", "Institution_And_Department");
- break;
- }
- }
- }
|