You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

48 lines
2.7 KiB

package BaseClassService
import (
"dsBaseWeb/Business/BaseClass/BaseClassProto"
"strings"
)
func PageClassInfo(page int32, limit int32, bureauId string, stageId string, rxnf int32, actionPersonId string, actionIpAddress string) (*BaseClassProto.Reply, error) {
Reply, err := PageBaseClass(BaseClassProto.QueryArg{Page: page, Limit: limit, BureauId: bureauId, StageId: stageId, Rxnf: rxnf, ActionPersonId: actionPersonId, ActionIpAddress: actionIpAddress})
return Reply, err
}
func GetClassInfo(classId string, actionPersonId string, actionIpAddress string) (*BaseClassProto.Reply, error) {
Reply, err := GetBaseClass(BaseClassProto.ModelArg{ClassId: classId, ActionPersonId: actionPersonId, ActionIpAddress: actionIpAddress})
return Reply, err
}
func AddClassInfo(bureauId string, stageId string, schoolingLength int32, rxnf int32, startBh int32, endBh int32, classAlias string, actionPersonId string, actionIpAddress string) (*BaseClassProto.Reply, error) {
Reply, err := AddBaseClass(BaseClassProto.ModelArg{BureauId: bureauId, StageId: stageId, SchoolingLength: schoolingLength, Rxnf: rxnf, StartBh: startBh, EndBh: endBh, ClassAlias: classAlias, ActionPersonId: actionPersonId, ActionIpAddress: actionIpAddress})
return Reply, err
}
func DeleteClassInfo(ids string, actionPersonId string, actionIpAddress string) (*BaseClassProto.Reply, error) {
idsArr := strings.Split(ids, ",")
Reply, err := DeleteBaseClass(BaseClassProto.DeleteIdsArg{Ids: idsArr, ActionPersonId: actionPersonId, ActionIpAddress: actionIpAddress})
return Reply, err
}
func UpdateClassInfo(classId string, classAlias string, actionPersonId string, actionIpAddress string) (*BaseClassProto.Reply, error) {
Reply, err := UpdateBaseClass(BaseClassProto.ModelArg{ClassId: classId, ClassAlias: classAlias, ActionPersonId: actionPersonId, ActionIpAddress: actionIpAddress})
return Reply, err
}
func SetClassTeacher(classId string, teacherId string, actionPersonId string, actionIpAddress string) (*BaseClassProto.Reply, error) {
Reply, err := UpdateBaseClass(BaseClassProto.ModelArg{ClassId: classId, TeacherId: teacherId, ActionPersonId: actionPersonId, ActionIpAddress: actionIpAddress})
return Reply, err
}
func GetStageInfo(bureauId string, actionPersonId string, actionIpAddress string) (*BaseClassProto.Reply, error) {
Reply, err := GetStage(BaseClassProto.ModelArg{BureauId: bureauId, ActionPersonId: actionPersonId, ActionIpAddress: actionIpAddress})
return Reply, err
}
func GetRxnfInfo(bureauId string, stageId string, actionPersonId string, actionIpAddress string) (*BaseClassProto.Reply, error) {
Reply, err := GetRxnf(BaseClassProto.ModelArg{BureauId: bureauId, StageId: stageId, ActionPersonId: actionPersonId, ActionIpAddress: actionIpAddress})
return Reply, err
}