Subversion Repositories SmartDukaan

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
73 naveen 1
import utils
71 naveen 2
 
73 naveen 3
print "expSlide=" + `expSlide`
71 naveen 4
 
73 naveen 5
struct = utils.contentModel2Struct(expSlide)
6
print "struct=" + `struct`
7
 
77 naveen 8
score = 0
9
 
10
if struct.has_key("features") :
11
    features = struct.get("features")
12
 
13
    # E-mail Client : 2, 0
14
    if features.has_key("E-mail Client") :
15
        score += 2
16
 
17
if struct.has_key("childrenslides") :
18
    childrenslides = struct.get("childrenslides")
19
 
20
    if childrenslides.has_key("Types") :
21
        types = childrenslides.get("Types")
22
 
23
        if types.has_key("features") :
24
            features = types.get("features")
25
 
26
            # Types > MMS : 2, 0
27
            if features.has_key("MMS") :
28
                score += 2
29
 
30
            # Types > SMS : 2, 0
31
            if features.has_key("SMS") :
32
                score += 2
33
 
34
            # Types > Instant Messaging : 2, 0
35
            if features.has_key("Instant Messaging") :
36
                score += 2
37
 
38
            # Types > Email : 2, 0
39
            if features.has_key("Email") :
40
                score += 2