github项目

UML时序图

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
title 时序图
center header
使用类的生命线来描述用例在代码中执行的具体流程
参与者:actorboundary,control,entity,database
参与者支持as别名
生命线: --> <--
消息
endheader

'******* 类声明模块 *******'
actor 巡查员 as patrol
entity 检查记录 as record
control 拍照 as paizhao
database 图库 as imgdb
control 上传器 as uploader
database 请求库 as reqdb
control 任务服务器 as server 
==拍照服务==
patrol --> record:五定拍照指令

record --> paizhao: 五定一
activate paizhao 
paizhao --> imgdb :图片1model数据
activate imgdb
imgdb --> uploader:上传图片
activate uploader
uploader --> imgdb:更新status=2
deactivate uploader
deactivate paizhao
deactivate imgdb

==提交服务==
record --> reqdb:存储suRequest数据

activate record
activate reqdb
reqdb --> imgdb:查询检查项所有的图片状态
activate imgdb
imgdb --> reqdb:更新请求记录
deactivate imgdb
deactivate reqdb
reqdb --> server:提交检查项
activate server
server --> reqdb:清除请求记录
server --> imgdb:清空图片记录
deactivate server
deactivate record

center footer
完成
endfooter

活动图

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
start
:拍照;
if (一景一张) then
    :拍照;
    :上传;
    if(wu) then (yes)
        :提交;
    elseif(dd)
    :tishi;
else(失败)
    :退出;
endif
else if (一景多张)
    fork
    :拍照;
    :上传;
    fork again
    :拍照;
    :上传;
end fork
:commit;
stop
else if (多步多张) then (YES)
    if(第一步) then (yes)
        fork
        :拍照;
        :上传;
        fork again
        :拍照;
        :上传;
    end fork
    :commit;
    stop
else if(第二步) then (yes)
    fork
    :拍照;
    :上传;
    fork again
    :拍照;
    :上传;
end fork
:commit;
stop
else if (第..) then (yes)
    fork
    :拍照;
    :上传;
    fork again
    :拍照;
    :上传;
end fork
:commit;
stop
endif
endif
stop