Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Os 2 #148

Open
wants to merge 26 commits into
base: os-2
Choose a base branch
from
Open

Os 2 #148

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
1505674
script structured
Arindam2002 Mar 27, 2023
aa2e579
Server Url updated
AgPriyanshu18 Nov 17, 2023
838008a
Merge pull request #137 from AgPriyanshu18/main
Shivkant-Chauhan Nov 17, 2023
8a6125c
21bcs246
vishwajeettoppo Feb 23, 2024
d586c4b
21bcs246
vishwajeettoppo Feb 23, 2024
e48b669
Merge pull request #1 from vishwajeettoppo/21bcs246
yadavpritesh Feb 23, 2024
b29ba13
21bcs247
yadavpritesh Feb 23, 2024
48f7645
Merge branch 'main' of https://github.com/FusionIIIT/Fusion-mobile in…
yadavpritesh Feb 23, 2024
a994f29
Merge branch '21bcs246' of https://github.com/yadavpritesh/Fusion-mob…
yadavpritesh Feb 23, 2024
fd5d4aa
21bcs246
vishwajeettoppo Feb 23, 2024
a497ebe
Merge pull request #2 from vishwajeettoppo/21bcs246
yadavpritesh Feb 23, 2024
fb925da
Merge branch '21bcs246' of https://github.com/yadavpritesh/Fusion-mob…
yadavpritesh Feb 23, 2024
1e78792
Ui Changes and Added functionality of designation
TusharGupta03 Apr 7, 2024
c53fcbe
Updated kserverLink,kAuthUrl and gradle ver (7.4.2)
TusharGupta03 Apr 12, 2024
0b76078
new feature
yadavpritesh Apr 16, 2024
6c565d6
Merge pull request #158 from TusharGupta03/gad-5
PraneGIT Apr 17, 2024
a94c865
Merge branch 'gad-5' of https://github.com/FusionIIIT/Fusion-mobile i…
yadavpritesh Apr 18, 2024
d21369b
Revert "new feature"
yadavpritesh Apr 20, 2024
b286246
updated schedule for doctors
yadavpritesh Apr 20, 2024
b9ee9a0
Merge branch 'gad-5' into curr
pratham534 Apr 21, 2024
8cd1645
merged gad-5
pratham534 Apr 21, 2024
d7b45cf
added api url compounder view
pratham534 Apr 21, 2024
2e96043
corrected issues realted to naming of announcement tables
pratham534 Apr 21, 2024
7f33d8b
implemented conditional rendering for Compounder
pratham534 Apr 21, 2024
47adcdf
updated gad-5 changes in module phc
pratham534 Apr 21, 2024
289459d
update
yadavpritesh Apr 22, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 45 additions & 0 deletions .metadata
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# This file tracks properties of this Flutter project.
# Used by Flutter tool to assess capabilities and perform upgrades etc.
#
# This file should be version controlled and should not be manually edited.

version:
revision: "d211f42860350d914a5ad8102f9ec32764dc6d06"
channel: "stable"

project_type: app

# Tracks metadata for the flutter migrate command
migration:
platforms:
- platform: root
create_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
base_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
- platform: android
create_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
base_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
- platform: ios
create_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
base_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
- platform: linux
create_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
base_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
- platform: macos
create_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
base_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
- platform: web
create_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
base_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
- platform: windows
create_revision: d211f42860350d914a5ad8102f9ec32764dc6d06
base_revision: d211f42860350d914a5ad8102f9ec32764dc6d06

# User provided section

# List of Local paths (relative to this file) that should be
# ignored by the migrate tool.
#
# Files that are not part of the templates will be ignored by default.
unmanaged_files:
- 'lib/main.dart'
- 'ios/Runner.xcodeproj/project.pbxproj'
28 changes: 28 additions & 0 deletions analysis_options.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# This file configures the analyzer, which statically analyzes Dart code to
# check for errors, warnings, and lints.
#
# The issues identified by the analyzer are surfaced in the UI of Dart-enabled
# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
# invoked from the command line by running `flutter analyze`.

# The following line activates a set of recommended lints for Flutter apps,
# packages, and plugins designed to encourage good coding practices.
include: package:flutter_lints/flutter.yaml

linter:
# The lint rules applied to this project can be customized in the
# section below to disable rules from the `package:flutter_lints/flutter.yaml`
# included above or to enable additional rules. A list of all available lints
# and their documentation is published at https://dart.dev/lints.
#
# Instead of disabling a lint rule for the entire project in the
# section below, it can also be suppressed for a single line of code
# or a specific dart file by using the `// ignore: name_of_lint` and
# `// ignore_for_file: name_of_lint` syntax on the line or in the file
# producing the lint.
rules:
# avoid_print: false # Uncomment to disable the `avoid_print` rule
# prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule

# Additional information about this file can be found at
# https://dart.dev/guides/language/analysis-options
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
package com.fusionIIIT.fusion_mobile

import io.flutter.embedding.android.FlutterActivity

class MainActivity: FlutterActivity() {
}
12 changes: 12 additions & 0 deletions android/app/src/main/res/drawable-v21/launch_background.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Modify this file to customize your launch splash screen -->
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="?android:colorBackground" />

<!-- You can insert your own image assets here -->
<!-- <item>
<bitmap
android:gravity="center"
android:src="@mipmap/launch_image" />
</item> -->
</layer-list>
18 changes: 18 additions & 0 deletions android/app/src/main/res/values-night/styles.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!-- Theme applied to the Android Window while the process is starting when the OS's Dark Mode setting is on -->
<style name="LaunchTheme" parent="@android:style/Theme.Black.NoTitleBar">
<!-- Show a splash screen on the activity. Automatically removed when
the Flutter engine draws its first frame -->
<item name="android:windowBackground">@drawable/launch_background</item>
</style>
<!-- Theme applied to the Android Window as soon as the process has started.
This theme determines the color of the Android Window while your
Flutter UI initializes, as well as behind your Flutter UI while its
running.
This Theme is only used starting with V2 of Flutter's Android embedding. -->
<style name="NormalTheme" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">?android:colorBackground</item>
</style>
</resources>
6 changes: 3 additions & 3 deletions android/build.gradle
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
buildscript {
ext.kotlin_version = '1.6.10'
ext.kotlin_version = '1.8.21'
repositories {
google()
jcenter()
}

dependencies {
classpath 'com.android.tools.build:gradle:4.2.2'
classpath 'com.android.tools.build:gradle:7.4.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
Expand All @@ -26,6 +26,6 @@ subprojects {
project.evaluationDependsOn(':app')
}

task clean(type: Delete) {
tasks.register("clean", Delete) {
delete rootProject.buildDir
}
2 changes: 1 addition & 1 deletion android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-all.zip
13 changes: 0 additions & 13 deletions clone.sh

This file was deleted.

12 changes: 12 additions & 0 deletions ios/RunnerTests/RunnerTests.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import Flutter
import UIKit
import XCTest

class RunnerTests: XCTestCase {

func testExample() {
// If you add code to the Runner application, consider adding tests here.
// See https://developer.apple.com/documentation/xctest for more information about using XCTest.
}

}
106 changes: 106 additions & 0 deletions lib/Components/appBar2.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
import 'package:flutter/material.dart';
import 'package:fusion/constants.dart';
import 'package:fusion/services/service_locator.dart';
import 'package:fusion/services/storage_service.dart';

class CustomAppBar extends StatefulWidget implements PreferredSizeWidget {
final String curr_desig;
final String headerTitle;

final ValueChanged<String> onDesignationChanged;

const CustomAppBar({
Key? key,
required this.curr_desig,
required this.headerTitle,

required this.onDesignationChanged,
}) : super(key: key);

@override
_CustomAppBarState createState() => _CustomAppBarState();

@override
Size get preferredSize => Size.fromHeight(kToolbarHeight);
}

class _CustomAppBarState extends State<CustomAppBar> {
late List<String> designations;
late String current;
var service = locator<StorageService>();

@override
void initState() {
super.initState();
designations = (service!.getFromDisk('designations') as List<dynamic>)
.map((dynamic item) => item.toString())
.toList();

current = service!.getFromDisk(
'Current_designation'); // Ensure designations is not null before accessing index 0
}

@override
Widget build(BuildContext context) {
return AppBar(
iconTheme: IconThemeData(color: Colors.white),
backgroundColor: kPrimaryColor,
title: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Flexible(
child: Padding(
padding: EdgeInsets.only(right: 20.0), // Add some right padding to ensure space for the dropdown
child: Text(
widget.headerTitle, // Example of a long title
overflow: TextOverflow.ellipsis, // Prevents overflow by adding ellipsis
style: TextStyle(
color: Colors.white,
fontSize: 20,
fontWeight: FontWeight.bold,
),
),
),
),
DropdownButtonHideUnderline(
child: DropdownButton<String>(
padding: const EdgeInsets.all(15),
borderRadius: BorderRadius.circular(5),
value: current,
icon: Icon(Icons.arrow_drop_down, color: Colors.white),
iconSize: 24,
style: TextStyle(color: Colors.white, fontSize: 18),
dropdownColor:
kPrimaryColor, // Set the dropdown background color to orange
onChanged: (String? newValue) {
widget.onDesignationChanged(newValue!);
setState(() {
current = newValue!;
service!.saveToDisk('Current_designation', current);
});
},
items: designations.map<DropdownMenuItem<String>>((String value) {
return DropdownMenuItem<String>(
value: value,
child: Text(
value,
style: TextStyle(
color: Colors.white), // Set the text color to white
),
);
}).toList(),
onTap: () {
// Find the index of the selected value
int index = designations.indexOf(current);
// Scroll the dropdown to the selected value
Scrollable.ensureVisible(context,
alignment: 0.5, duration: Duration(milliseconds: 300));
},
),
),
],
),
actions: <Widget>[],
);
}
}
Loading