Proyectos de Subversion Iphone Microlearning - Inconcert

Rev

Rev 1 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 1 Rev 17
Línea 12... Línea 12...
12
    @Published var topic = TopicModel()
12
    @Published var topic = TopicModel()
Línea 13... Línea 13...
13
 
13
 
14
 
14
 
15
    public func fetch(topicUuid: String, userUuid : String)
15
    public func fetch(topicUuid: String, userUuid : String)
16
    {
16
    {
17
        let topicDao = TopicDao.sharedInstance
17
        let topicDao = TopicDao()
18
        self.topic = topicDao.selectByUuid(uuid: topicUuid)
18
        self.topic = topicDao.selectByUuid(uuid: topicUuid)
Línea 19... Línea 19...
19
        self.fetchProgress(topicUuid: topicUuid, userUuid: userUuid)
19
        self.fetchProgress(topicUuid: topicUuid, userUuid: userUuid)
20
    }
20
    }
21
    
21
    
22
    public func fetchProgress(topicUuid: String, userUuid : String)
22
    public func fetchProgress(topicUuid: String, userUuid : String)
23
    {
23
    {
24
        let progressDao = ProgressDao.sharedInstance
24
        let progressDao = ProgressDao()
25
        let progress = progressDao.selectByTopicUuidAndUserUuid(topicUuid: topicUuid, userUuid: userUuid)
25
        let progress = progressDao.selectByTopicUuidAndUserUuid(topicUuid: topicUuid, userUuid: userUuid)
26
        if progress.id > 0 {
26
        if progress.id > 0 {