mirror of
https://github.com/Rushilwiz/SkoolOS.git
synced 2025-04-20 20:30:18 -04:00
ff
This commit is contained in:
parent
69e1efafe2
commit
b8c033b71f
|
@ -1 +0,0 @@
|
||||||
Subproject commit 8dca8b78c03fab721e9976a4675e2996802328a7
|
|
|
@ -291,4 +291,4 @@ class Student:
|
||||||
|
|
||||||
data = getStudent("2022rkhondak")
|
data = getStudent("2022rkhondak")
|
||||||
s = Student(data)
|
s = Student(data)
|
||||||
s.update()
|
#s.update()
|
13
CLI/t-git.py
13
CLI/t-git.py
|
@ -373,6 +373,17 @@ class Teacher:
|
||||||
|
|
||||||
#confirmed students
|
#confirmed students
|
||||||
def addStudent(self, student, classes):
|
def addStudent(self, student, classes):
|
||||||
|
for c in self.classes:
|
||||||
|
if(c['name'] == classes):
|
||||||
|
cid = c['id']
|
||||||
|
data = getDB("http://127.0.0.1:8000/classes/" + str(cid))
|
||||||
|
if(student in data['confirmed']):
|
||||||
|
print("Student already added to " + classes)
|
||||||
|
return
|
||||||
|
if(student in data['unconfirmed']):
|
||||||
|
print("Student has been enrolled in " + classes)
|
||||||
|
return
|
||||||
|
|
||||||
cdir = os.getcwd()
|
cdir = os.getcwd()
|
||||||
cpath = self.username + "/" + classes
|
cpath = self.username + "/" + classes
|
||||||
path = self.username + "/Students/" + classes
|
path = self.username + "/Students/" + classes
|
||||||
|
@ -403,5 +414,5 @@ data = getTeacher("mlauerbach")
|
||||||
t = Teacher(data)
|
t = Teacher(data)
|
||||||
t.makeClass("Math5_mlauerbach", ["Week1_HW", "Test1"])
|
t.makeClass("Math5_mlauerbach", ["Week1_HW", "Test1"])
|
||||||
input()
|
input()
|
||||||
t.reqStudent()
|
t.reqStudent("2022rkhondak", "Math5_mlauerbach")
|
||||||
t.addStudent("2022rkhondak", "Math5_mlauerbach")
|
t.addStudent("2022rkhondak", "Math5_mlauerbach")
|
||||||
|
|
16
CLI/test.py
16
CLI/test.py
|
@ -1,16 +0,0 @@
|
||||||
import subprocess
|
|
||||||
import os
|
|
||||||
import time
|
|
||||||
|
|
||||||
def command(command):
|
|
||||||
ar = []
|
|
||||||
command = command.split(" ")
|
|
||||||
for c in command:
|
|
||||||
ar.append(c)
|
|
||||||
process = subprocess.Popen(ar, stdout=subprocess.PIPE,stderr=subprocess.PIPE)
|
|
||||||
p=process.poll()
|
|
||||||
output = process.communicate()[0]
|
|
||||||
print(output)
|
|
||||||
|
|
||||||
command('echo hello')
|
|
||||||
command('python runtest.py')
|
|
|
@ -1 +0,0 @@
|
||||||
Subproject commit ead6265a08327f2cc099d1e61c01030d916e8cd9
|
|
Loading…
Reference in New Issue
Block a user