merge-update-with-lab-changes
haroon amjad 4 years ago
parent 4b1a2d4f3d
commit f55fbd1cc2

@ -114,15 +114,6 @@ class _PharmaciesPageState extends State<PharmaciesPage> {
SizedBox(
height: 2,
),
Text(
TranslationBase.of(context).km+" "+ _location.distanceInKilometers.toString() ?? "",
style: TextStyle(
fontSize: 12,
fontWeight: FontWeight.w600,
color: Color(0xff2E303A),
letterSpacing: -0.56,
),
),
],
),
),

@ -232,14 +232,14 @@ class _LandingPageState extends State<LandingPage> with WidgetsBindingObserver {
pageController = PageController(keepPage: true);
_firebaseMessaging.setAutoInitEnabled(true);
signalRUtil = new SignalRUtil(hubName: "http://192.168.8.101:5001/chatHub", context: context);
// signalRUtil = new SignalRUtil(hubName: "http://192.168.8.101:5001/chatHub", context: context);
locationUtils = new LocationUtils(isShowConfirmDialog: false, context: context);
WidgetsBinding.instance.addPostFrameCallback((_) {
if (projectViewModel.isLogin) {
familyFileProvider.getSharedRecordByStatus();
}
signalRUtil.startSignalRConnection();
// signalRUtil.startSignalRConnection();
});
// HMG (Guest/Internet) Wifi Access [Zohaib Kambrani]
//for now commented to reduce this call will enable it when needed

@ -100,13 +100,15 @@ class PrescriptionDetailsPage extends StatelessWidget {
],
),
SizedBox(height: 12),
Table(children: [
Table(
border: TableBorder(horizontalInside: BorderSide(width: 1, color: Colors.black, style: BorderStyle.solid)),
children: [
TableRow(
children: [
Utils.tableColumnTitle(TranslationBase.of(context).route),
Utils.tableColumnTitle(TranslationBase.of(context).frequency),
Utils.tableColumnTitle(TranslationBase.of(context).dailyDoses),
Utils.tableColumnTitle(TranslationBase.of(context).duration)
Utils.tableColumnTitle(TranslationBase.of(context).route, showDivider: false),
Utils.tableColumnTitle(TranslationBase.of(context).frequency, showDivider: false),
Utils.tableColumnTitle(TranslationBase.of(context).dailyDoses, showDivider: false),
Utils.tableColumnTitle(TranslationBase.of(context).duration, showDivider: false)
],
),
TableRow(

@ -52,7 +52,7 @@ class PrescriptionsHistoryDetailsPage extends StatelessWidget {
Expanded(
child: ListView(
physics: BouncingScrollPhysics(),
padding: EdgeInsets.all(21),
padding: EdgeInsets.all(25),
children: <Widget>[
Container(
decoration: BoxDecoration(
@ -75,8 +75,10 @@ class PrescriptionsHistoryDetailsPage extends StatelessWidget {
color: Colors.white,
border: Border.all(color: Colors.white, width: 1),
borderRadius: BorderRadius.only(
bottomRight: Radius.circular(10.0),
topRight: Radius.circular(10.0),
topLeft:projectViewModel.isArabic? Radius.circular(0.0):Radius.circular(10.0),
bottomLeft:projectViewModel.isArabic? Radius.circular(0.0):Radius.circular(10.0),
topRight:projectViewModel.isArabic? Radius.circular(10.0):Radius.circular(0.0),
bottomRight:projectViewModel.isArabic? Radius.circular(10.0):Radius.circular(0.0),
),
),
child: Column(
@ -162,7 +164,7 @@ class PrescriptionsHistoryDetailsPage extends StatelessWidget {
),
),
Container(
color: Colors.white,
color: Theme.of(context).scaffoldBackgroundColor,
padding: EdgeInsets.only(top: 16, bottom: 16, right: 21, left: 21),
child: DefaultButton(
TranslationBase.of(context).cancelOrder,

@ -82,7 +82,6 @@ class PrescriptionsHistoryPage extends StatelessWidget {
bottomLeft:projectViewModel.isArabic? Radius.circular(0.0):Radius.circular(10.0),
topRight:projectViewModel.isArabic? Radius.circular(10.0):Radius.circular(0.0),
bottomRight:projectViewModel.isArabic? Radius.circular(10.0):Radius.circular(0.0),
),
),
),

@ -136,15 +136,16 @@ class LineChartCurved extends StatelessWidget {
fontWeight: FontWeight.bold,
fontSize: 10,
),
interval: getMaxY() - getMinY() <= 500
? getMaxY() - getMinY() <= 50
? 10
: 50
: getMaxY() - getMinY() <= 1000
? 100
: getMaxY() - getMinY() >= 10000
? 5000
: 200,
interval: 3.0,
// interval: getMaxY() - getMinY() <= 500
// ? getMaxY() - getMinY() <= 50
// ? 10
// : 10
// : getMaxY() - getMinY() <= 1000
// ? 100
// : getMaxY() - getMinY() >= 10000
// ? 5000
// : 200,
margin: 12,
),
),
@ -168,8 +169,8 @@ class LineChartCurved extends StatelessWidget {
),
minX: minX,
maxX: maxX,
maxY: lastY+50,
minY: intialY,
maxY: lastY + 1,
minY: intialY - 0.5,
lineBarsData: getData(context),
);
}
@ -210,6 +211,7 @@ class LineChartCurved extends StatelessWidget {
intialY = 0;
}
print("minY " + intialY.toString());
return intialY.roundToDouble();
}

@ -576,7 +576,7 @@ class Utils {
onTap: () => projectViewModel.havePrivilege(12) ? Navigator.push(context, FadePage(page: HomePrescriptionsPage())) : null,
child: MedicalProfileItem(
title: TranslationBase.of(context).medicines,
imagePath: 'prescription_icon.png',
imagePath: 'medicine_prescription.svg',
subTitle: TranslationBase.of(context).medicinesSubtitle,
isEnable: projectViewModel.havePrivilege(12),
),
@ -621,7 +621,7 @@ class Utils {
return route.runtimeType == equalsTo;
}
static Widget tableColumnTitle(String text) {
static Widget tableColumnTitle(String text, {bool showDivider = true}) {
return Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisSize: MainAxisSize.min,
@ -631,8 +631,8 @@ class Utils {
text,
style: TextStyle(fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xff2E303A), letterSpacing: -0.48, height: 18 / 12),
),
SizedBox(height: 6),
Divider(
SizedBox(height: 5),
if(showDivider) Divider(
height: 1,
color: Color(0xff2E303A),
thickness: 1,

@ -80,7 +80,7 @@ class DoctorHeader extends StatelessWidget {
),
if (headerModel.time != null)
Text(
headerModel.time ?? DateUtil.formatDateToTimeLang(headerModel.date, projectViewModel.isArabic),
headerModel.time ?? DateUtil.formatDateToTime(headerModel.date),
style: TextStyle(fontSize: 14, fontWeight: FontWeight.w600, color: Color(0xff2B353E), letterSpacing: -0.48, height: 18 / 12),
),
if (headerModel?.nationalityFlagURL != null)

@ -1,7 +1,9 @@
import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart';
import 'package:diplomaticquarterapp/extensions/string_extensions.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:expandable/expandable.dart';
import 'package:flutter/material.dart';
import 'package:provider/provider.dart';
/// App Expandable Notifier with animation
/// [headerWidget] widget want to show in the header
@ -23,6 +25,9 @@ class AppExpandableNotifier extends StatefulWidget {
}
class _AppExpandableNotifier extends State<AppExpandableNotifier> {
ProjectViewModel projectViewModel;
@override
void initState() {
setState(() {
@ -36,8 +41,10 @@ class _AppExpandableNotifier extends State<AppExpandableNotifier> {
@override
Widget build(BuildContext context) {
projectViewModel = Provider.of(context);
String _mainTitle = (widget.title ?? TranslationBase.of(context).details);
String _title = _mainTitle.split(" ")[0];
String _title = projectViewModel.isArabic ? _mainTitle.split(" ")[1] : _mainTitle.split(" ")[0];
String _subTitle = _mainTitle.replaceAll(_title, "").trim();
if (_subTitle.length < 1) {

Loading…
Cancel
Save