forked from VaibhavNerd/AKGECconnect
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c4f35e6
commit c7fdd21
Showing
12 changed files
with
577 additions
and
10 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
82 changes: 82 additions & 0 deletions
82
app/src/main/java/com/vaibhav/AKGECchat/Screens/TimeTable.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
package com.vaibhav.AKGECchat.Screens; | ||
|
||
import androidx.annotation.NonNull; | ||
import androidx.appcompat.app.AppCompatActivity; | ||
|
||
import android.os.Bundle; | ||
import android.text.format.Time; | ||
import android.util.Log; | ||
|
||
import com.bumptech.glide.Glide; | ||
import com.bumptech.glide.load.engine.DiskCacheStrategy; | ||
import com.github.chrisbanes.photoview.PhotoView; | ||
import com.google.firebase.auth.FirebaseAuth; | ||
import com.google.firebase.database.DataSnapshot; | ||
import com.google.firebase.database.DatabaseError; | ||
import com.google.firebase.database.DatabaseReference; | ||
import com.google.firebase.database.FirebaseDatabase; | ||
import com.google.firebase.database.ValueEventListener; | ||
import com.google.firebase.firestore.FirebaseFirestore; | ||
import com.google.firebase.storage.FirebaseStorage; | ||
import com.vaibhav.AKGECchat.R; | ||
import com.vaibhav.AKGECchat.databinding.ActivityProfileBinding; | ||
import com.vaibhav.AKGECchat.databinding.ActivityTimeTableBinding; | ||
|
||
public class TimeTable extends AppCompatActivity { | ||
|
||
FirebaseStorage storage; | ||
DatabaseReference database; | ||
ActivityTimeTableBinding binding; | ||
FirebaseAuth fAuth; | ||
FirebaseFirestore fStore; | ||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
super.onCreate(savedInstanceState); | ||
binding = ActivityTimeTableBinding.inflate(getLayoutInflater()); | ||
setContentView(binding.getRoot()); | ||
// setContentView(R.layout.activity_time_table); | ||
|
||
fAuth = FirebaseAuth.getInstance(); | ||
fAuth.getCurrentUser(); | ||
// setSupportActionBar(binding.toolbar); | ||
|
||
database = FirebaseDatabase.getInstance().getReference(); | ||
storage = FirebaseStorage.getInstance(); | ||
|
||
PhotoView photoView = (PhotoView) | ||
binding.photoView; | ||
|
||
|
||
database | ||
|
||
.addValueEventListener(new ValueEventListener() { | ||
@Override | ||
public void onDataChange(@NonNull DataSnapshot snapshot) { | ||
if(snapshot.exists()) { | ||
|
||
String TimeTable = snapshot.child("TimeTable").getValue(String.class); | ||
Glide.with(TimeTable.this).load(TimeTable) | ||
.placeholder(R.drawable.avatar) | ||
.fitCenter() | ||
|
||
.into(binding.photoView); | ||
Log.d("myTag", TimeTable); | ||
|
||
} else { | ||
|
||
} | ||
|
||
|
||
|
||
|
||
} | ||
|
||
@Override | ||
public void onCancelled(@NonNull DatabaseError databaseError) { | ||
|
||
} | ||
|
||
}); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package com.vaibhav.AKGECchat; | ||
|
||
import androidx.appcompat.app.AppCompatActivity; | ||
|
||
import android.os.Bundle; | ||
|
||
public class subjects extends AppCompatActivity { | ||
|
||
@Override | ||
protected void onCreate(Bundle savedInstanceState) { | ||
super.onCreate(savedInstanceState); | ||
setContentView(R.layout.activity_subjects); | ||
} | ||
} |
Oops, something went wrong.