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

GAD-4: added screens #134

Open
wants to merge 2 commits into
base: test
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
6 changes: 5 additions & 1 deletion lib/Components/side_drawer.dart
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,11 @@ class _SideDrawerState extends State<SideDrawer> {
ModulesPadding(line: 'Leave Module'),
ModulesPadding(line: 'Placement Module'),
ModulesPadding(line: 'Visitors Hostel Module'),
ModulesPadding(line: 'File Tracking Module'),
ModulesPadding(
line: 'File Tracking Module',
pageMover: '/compose_file',
isActive: true,
),
],
),
)
Expand Down
7 changes: 5 additions & 2 deletions lib/api.dart
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
//Server and local links
String klocalLink = "127.0.0.1:8000";
String kserverLink = "172.27.16.215:80";
String kserverLink = "172.27.16.214:80";

//Login Service
String kAuthUrl = "172.27.16.215:80";
String kAuthUrl = "172.27.16.214:80";
String kAuthLogin = "/api/auth/login/";

//Profile Service
Expand All @@ -29,6 +29,9 @@ const kGymkhanaMemberRecords = '/api/gymkhana/members_record';
//HealthCentre
String kHealthCentreStudent = "/healthcenter/api/student";

//FileTracking
const kFileTracking = '/filetracking/';

//------------Screens------------

//screens/Academic/Current_Semester
Expand Down
5 changes: 4 additions & 1 deletion lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ import 'package:fusion/screens/Healthcenter/viewschedule.dart';
import 'package:fusion/screens/Healthcenter/history.dart';
import 'package:fusion/screens/Healthcenter/HealthCenter.dart';
import 'package:fusion/services/service_locator.dart';
import 'package:fusion/screens/File_Tracking/compose_file.dart';

void main() {
WidgetsFlutterBinding.ensureInitialized();
Expand All @@ -60,7 +61,7 @@ class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
MediaQueryData windowData =
MediaQueryData.fromWindow(WidgetsBinding.instance.window);
MediaQueryData.fromWindow(WidgetsBinding.instance.window);
windowData = windowData.copyWith(
textScaleFactor: 1,
);
Expand All @@ -71,6 +72,7 @@ class MyApp extends StatelessWidget {
title: 'Fusion',
debugShowCheckedModeBanner: false,
theme: ThemeData(

// primarySwatch: Colors.blueGrey,
// colorSchemeSeed: Color(0xFF2085D0),
colorSchemeSeed: Color(0xFFF36C35),
Expand Down Expand Up @@ -127,6 +129,7 @@ class MyApp extends StatelessWidget {
'/health_center/feedback': (context) => FeedBack(),
'/health_center/viewschedule': (context) => ViewSchedule(),
'/health_center/history': (context) => History(),
'/compose_file': (context) => ComposeFile(),
},
),
);
Expand Down
47 changes: 47 additions & 0 deletions lib/models/file_tracking.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';

class File {
late final String id;
late final String subject;
late final String description;
late final String upload_date;
late final String upload_file;
late final String is_read;
late final String designation_id;
late final String uploader_id;

File(
{required this.id,
required this.subject,
required this.description,
required this.upload_date,
required this.upload_file,
required this.is_read,
required this.designation_id,
required this.uploader_id});

factory File.fromJson(Map<String, dynamic> json) {
return File(
id: json['id'],
subject: json['subject'],
description: json['description'],
upload_date: json['upload_date'],
upload_file: json['upload_file'],
is_read: json['is_read'],
designation_id: json['designation_id'],
uploader_id: json['uploader_id'],
);
}

dynamic toJson() => {
'id': id,
'subject': subject,
'description': description,
'upload_date': upload_date,
'upload_file': upload_file,
'is_read': is_read,
'designation_id': designation_id,
'uploader_id': uploader_id
};
}
Loading