schemas.yaml 96 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386
  1. StringId:
  2. type: string
  3. pattern: '^[0-9]+$'
  4. description: 数据库BIGINT在JSON中的安全十进制字符串表达。
  5. UtcDateTime:
  6. type: string
  7. format: date-time
  8. pattern: 'Z$'
  9. example: '2026-07-23T03:00:00.000Z'
  10. RoleCode:
  11. type: string
  12. enum: [USER, ADMIN]
  13. AllowedModule:
  14. type: string
  15. enum: [DOCUMENT_BROWSER, BACKEND_MANAGEMENT, AUDIT_LOG, ORGANIZATION_USER_MANAGEMENT]
  16. DocumentType:
  17. type: string
  18. enum: [MAIN, SUB_PLAN, ATTACHMENT]
  19. DocumentStatus:
  20. type: string
  21. enum: [DRAFT, PUBLISHED, ARCHIVED]
  22. SecurityLevel:
  23. type: string
  24. enum: [PUBLIC, INTERNAL, SECRET, CONFIDENTIAL, TOP_SECRET]
  25. x-comparison-values:
  26. PUBLIC: 10
  27. INTERNAL: 20
  28. SECRET: 30
  29. CONFIDENTIAL: 40
  30. TOP_SECRET: 50
  31. AttachmentType:
  32. type: string
  33. enum: [SUPPORT_ACHIEVEMENT, TRAINING_MATERIAL, TYPICAL_CASE]
  34. AllowedAction:
  35. type: string
  36. enum:
  37. - VIEW
  38. - DOWNLOAD
  39. - EDIT
  40. - CONFIG_PERMISSION
  41. - DELETE
  42. - BIND_ATTACHMENT
  43. - UNBIND_ATTACHMENT
  44. CategoryType:
  45. type: string
  46. enum: [SCENE, STYLE, SITUATION, VERSION, OTHER]
  47. EnabledStatus:
  48. type: string
  49. enum: [ENABLED, DISABLED]
  50. AuditResult:
  51. type: string
  52. enum: [SUCCESS, FAILURE]
  53. AuditAction:
  54. type: string
  55. enum:
  56. - LOGIN
  57. - LOGOUT
  58. - VIEW_DOCUMENT
  59. - DOWNLOAD_DOCUMENT
  60. - UPLOAD_DOCUMENT
  61. - BATCH_IMPORT
  62. - EDIT_DOCUMENT
  63. - DELETE_DOCUMENT
  64. - CREATE_CATEGORY
  65. - EDIT_CATEGORY
  66. - DELETE_CATEGORY
  67. - CHANGE_PERMISSION
  68. - UPLOAD_PERMISSION_VOUCHER
  69. - DELETE_PERMISSION_VOUCHER
  70. - MOVE_DOCUMENT
  71. - MOVE_ATTACHMENT
  72. - BIND_ATTACHMENT
  73. - UNBIND_ATTACHMENT
  74. - RESTORE_DOCUMENT
  75. - CREATE_ORGANIZATION
  76. - EDIT_ORGANIZATION
  77. - DELETE_ORGANIZATION
  78. - CREATE_USER
  79. - EDIT_USER
  80. - DELETE_USER
  81. - RESET_USER_PASSWORD
  82. - DOCUMENT_PASSWORD_SET
  83. - DOCUMENT_PASSWORD_REMOVE
  84. - CREATE_IP_ENTRY
  85. - EDIT_IP_ENTRY
  86. - DELETE_IP_ENTRY
  87. - ASSIGN_ORG_IP
  88. - BACKUP_CREATE
  89. AuditTarget:
  90. type: string
  91. enum:
  92. - AUTH
  93. - CATEGORY
  94. - DOCUMENT
  95. - ATTACHMENT
  96. - PERMISSION
  97. - ATTACHMENT_BINDING
  98. - ORGANIZATION
  99. - USER
  100. - ROLE
  101. - IP_ENTRY
  102. - BACKUP
  103. PageResult:
  104. type: object
  105. required: [items, page, pageSize, total, totalPages]
  106. properties:
  107. items:
  108. type: array
  109. items: {}
  110. page:
  111. type: integer
  112. minimum: 1
  113. default: 1
  114. pageSize:
  115. type: integer
  116. minimum: 1
  117. maximum: 100
  118. default: 20
  119. total:
  120. type: integer
  121. minimum: 0
  122. totalPages:
  123. type: integer
  124. minimum: 0
  125. HealthData:
  126. type: object
  127. additionalProperties: false
  128. required: [service, status]
  129. properties:
  130. service:
  131. type: string
  132. enum: [dms]
  133. status:
  134. type: string
  135. enum: [UP]
  136. HealthResponse:
  137. type: object
  138. additionalProperties: false
  139. required: [code, message, data, requestId]
  140. properties:
  141. code:
  142. type: string
  143. enum: [OK]
  144. message:
  145. type: string
  146. enum: [success]
  147. data:
  148. $ref: '#/HealthData'
  149. requestId:
  150. type: string
  151. format: uuid
  152. ErrorResponse:
  153. type: object
  154. additionalProperties: false
  155. required: [code, message, details, requestId]
  156. properties:
  157. code:
  158. type: string
  159. enum:
  160. - INVALID_ARGUMENT
  161. - INVALID_CREDENTIALS
  162. - TOKEN_INVALID
  163. - TOKEN_EXPIRED
  164. - USER_DISABLED
  165. - AUTH_VERSION_MISMATCH
  166. - FORBIDDEN
  167. - SECURITY_LEVEL_FORBIDDEN
  168. - DOCUMENT_VIEW_FORBIDDEN
  169. - DOCUMENT_DOWNLOAD_FORBIDDEN
  170. - RESOURCE_NOT_FOUND
  171. - FILE_NOT_FOUND
  172. - UNSUPPORTED_FILE_TYPE
  173. - PREVIEW_UNAVAILABLE
  174. - PAYLOAD_TOO_LARGE
  175. - BATCH_MANIFEST_MISMATCH
  176. - DATA_VERSION_CONFLICT
  177. - DOCUMENT_NAME_CONFLICT
  178. - CATEGORY_IN_USE
  179. - CATEGORY_NOT_LEAF
  180. - MAIN_PLAN_HAS_CHILDREN
  181. - ATTACHMENT_IN_USE
  182. - ATTACHMENT_HAS_NO_ACL
  183. - SUB_PLAN_PERMISSION_INHERITED
  184. - DUPLICATE_PERMISSION_SUBJECT
  185. - MAIN_PLAN_NOT_FOUND
  186. - INTERNAL_ERROR
  187. - DOCUMENT_NOT_DELETED
  188. - FILE_INTEGRITY_MISMATCH
  189. - FILE_PATH_INVALID
  190. - RESTORE_FILE_CHANGED
  191. - RESTORE_CATEGORY_INVALID
  192. - RESTORE_PARENT_INVALID
  193. - RESTORE_RELATION_CONFLICT
  194. - DOCUMENT_NOT_IN_MOVE_SCOPE
  195. - ORGANIZATION_IN_USE
  196. - USER_SELF_PROTECTION
  197. - CATEGORY_FLAT_MODE_CONFLICT
  198. - PREVIEW_CONVERTER_UNAVAILABLE
  199. - PREVIEW_CONVERSION_TIMEOUT
  200. - PREVIEW_CONVERSION_FAILED
  201. - BACKUP_RUNNING
  202. - BACKUP_TARGET_UNAVAILABLE
  203. - BACKUP_TOOL_MISSING
  204. - BACKUP_FAILED
  205. message:
  206. type: string
  207. details:
  208. type: object
  209. nullable: true
  210. additionalProperties: true
  211. requestId:
  212. type: string
  213. format: uuid
  214. UserSummary:
  215. type: object
  216. additionalProperties: false
  217. required:
  218. - id
  219. - username
  220. - realName
  221. - organizationId
  222. - organizationName
  223. - roleCode
  224. - roleId
  225. - roleName
  226. - securityLevel
  227. - status
  228. - allowedModules
  229. - authVersion
  230. - rowVersion
  231. - lastLoginAt
  232. - lastLoginIp
  233. - uiTheme
  234. - permCategoryEdit
  235. - permOrgEdit
  236. - permUserEdit
  237. - permSystemManage
  238. - permAuditLog
  239. - permRoleEdit
  240. - permUpload
  241. - managedOrgId
  242. properties:
  243. id:
  244. $ref: '#/StringId'
  245. username:
  246. type: string
  247. realName:
  248. type: string
  249. organizationId:
  250. allOf:
  251. - $ref: '#/StringId'
  252. nullable: true
  253. organizationName:
  254. type: string
  255. nullable: true
  256. roleCode:
  257. $ref: '#/RoleCode'
  258. roleId:
  259. allOf:
  260. - $ref: '#/StringId'
  261. nullable: true
  262. description: 自定义角色ID;ADMIN恒为空。
  263. roleName:
  264. type: string
  265. nullable: true
  266. description: 自定义角色名称;角色被删除后为null。
  267. securityLevel:
  268. $ref: '#/SecurityLevel'
  269. status:
  270. $ref: '#/EnabledStatus'
  271. allowedModules:
  272. type: array
  273. uniqueItems: true
  274. items:
  275. $ref: '#/AllowedModule'
  276. authVersion:
  277. type: integer
  278. minimum: 0
  279. rowVersion:
  280. type: integer
  281. minimum: 0
  282. lastLoginAt:
  283. allOf:
  284. - $ref: '#/UtcDateTime'
  285. nullable: true
  286. lastLoginIp:
  287. type: string
  288. nullable: true
  289. uiTheme:
  290. type: string
  291. enum: [blue, red, green]
  292. description: 界面主题偏好(契约1.20,账号级漫游);存量与缺省为blue。
  293. permCategoryEdit:
  294. type: boolean
  295. description: 分类编辑管理位;值取自生效角色(显式角色活跃且启用时优先,否则回退默认角色),内置admin恒为true。
  296. permOrgEdit:
  297. type: boolean
  298. description: 机构编辑管理位;值取自生效角色。
  299. permUserEdit:
  300. type: boolean
  301. description: 用户编辑管理位;值取自生效角色。
  302. permSystemManage:
  303. type: boolean
  304. description: 系统管理管理位(契约1.23);值取自生效角色,内置admin恒为true。
  305. permAuditLog:
  306. type: boolean
  307. description: 日志审计管理位(契约1.23);值取自生效角色,内置admin恒为true。
  308. permRoleEdit:
  309. type: boolean
  310. description: 角色编辑管理位(契约1.25);值取自生效角色,内置admin恒为true。
  311. permUpload:
  312. type: boolean
  313. description: 上传位(契约1.31);生效角色方案权限矩阵任一 OWN 行 canUpload 为 true 即为 true,内置admin恒为true;上传/批量导入接口按此判定。
  314. managedOrgId:
  315. type: string
  316. nullable: true
  317. description: 用户级管理范围(契约1.30);为机构ID(固定锚点)、"SELF"(跟随该用户所在机构,落库哨兵0)或null(全局),内置admin恒为null。实际生效范围以生效角色锚点为准,角色锚点为"SELF"(跟随用户设置)时才回落本设置。
  318. LoginRequest:
  319. type: object
  320. additionalProperties: false
  321. required: [username, password, keepSignedIn]
  322. properties:
  323. username:
  324. type: string
  325. minLength: 1
  326. password:
  327. type: string
  328. format: password
  329. minLength: 1
  330. writeOnly: true
  331. keepSignedIn:
  332. type: boolean
  333. captchaId:
  334. type: string
  335. description: 图片验证码标识(安全需求4);DMS_CAPTCHA_ENABLED开启时必填(五键),关闭时不得携带(三键)
  336. captchaCode:
  337. type: string
  338. description: 图片验证码字符(安全需求4,忽略大小写);开关开启时必填
  339. LoginData:
  340. type: object
  341. additionalProperties: false
  342. required: [accessToken, tokenType, expiresIn, idleLogoutMinutes, tokenRotation, user]
  343. properties:
  344. accessToken:
  345. type: string
  346. tokenType:
  347. type: string
  348. enum: [Bearer]
  349. expiresIn:
  350. type: integer
  351. description: 访问令牌有效期秒数;keepSignedIn=false取环境变量DMS_JWT_EXPIRES_SECONDS(缺省3600),keepSignedIn=true固定604800。
  352. idleLogoutMinutes:
  353. type: integer
  354. minimum: 0
  355. description: 页面空闲自动登出分钟数(契约1.29);取环境变量DMS_IDLE_LOGOUT_MINUTES(缺省5),0表示关闭。
  356. tokenRotation:
  357. type: boolean
  358. description: 一次一码轮换开关回显(契约1.38,仅Java版实现);取DMS_TOKEN_ROTATION_ENABLED(缺省true),开启时写操作成功响应经X-DMS-Access-Token头返回轮换新授权码。门户设密完成响应同。
  359. user:
  360. $ref: '#/UserSummary'
  361. LoginResponse:
  362. type: object
  363. additionalProperties: false
  364. required: [code, message, data, requestId]
  365. properties:
  366. code:
  367. type: string
  368. enum: [OK]
  369. message:
  370. type: string
  371. enum: [success]
  372. data:
  373. $ref: '#/LoginData'
  374. requestId:
  375. type: string
  376. format: uuid
  377. UserResponse:
  378. type: object
  379. additionalProperties: false
  380. required: [code, message, data, requestId]
  381. properties:
  382. code:
  383. type: string
  384. enum: [OK]
  385. message:
  386. type: string
  387. enum: [success]
  388. data:
  389. $ref: '#/UserSummary'
  390. requestId:
  391. type: string
  392. format: uuid
  393. OrganizationNode:
  394. type: object
  395. additionalProperties: false
  396. required: [id, parentId, orgCode, orgName, orgPath, sortNo, status, rowVersion, children]
  397. properties:
  398. id:
  399. $ref: '#/StringId'
  400. parentId:
  401. allOf:
  402. - $ref: '#/StringId'
  403. nullable: true
  404. orgCode:
  405. type: string
  406. orgName:
  407. type: string
  408. orgPath:
  409. type: string
  410. sortNo:
  411. type: integer
  412. status:
  413. $ref: '#/EnabledStatus'
  414. rowVersion:
  415. type: integer
  416. minimum: 0
  417. children:
  418. type: array
  419. items:
  420. $ref: '#/OrganizationNode'
  421. OrganizationTreeResponse:
  422. type: object
  423. additionalProperties: false
  424. required: [code, message, data, requestId]
  425. properties:
  426. code:
  427. type: string
  428. enum: [OK]
  429. message:
  430. type: string
  431. enum: [success]
  432. data:
  433. type: array
  434. items:
  435. $ref: '#/OrganizationNode'
  436. requestId:
  437. type: string
  438. format: uuid
  439. UserPage:
  440. type: object
  441. additionalProperties: false
  442. required: [items, page, pageSize, total, totalPages]
  443. properties:
  444. items:
  445. type: array
  446. items:
  447. $ref: '#/UserSummary'
  448. page:
  449. type: integer
  450. minimum: 1
  451. pageSize:
  452. type: integer
  453. minimum: 1
  454. maximum: 100
  455. total:
  456. type: integer
  457. minimum: 0
  458. totalPages:
  459. type: integer
  460. minimum: 0
  461. UserPageResponse:
  462. type: object
  463. additionalProperties: false
  464. required: [code, message, data, requestId]
  465. properties:
  466. code:
  467. type: string
  468. enum: [OK]
  469. message:
  470. type: string
  471. enum: [success]
  472. data:
  473. $ref: '#/UserPage'
  474. requestId:
  475. type: string
  476. format: uuid
  477. EmptySuccessResponse:
  478. type: object
  479. additionalProperties: false
  480. required: [code, message, data, requestId]
  481. properties:
  482. code:
  483. type: string
  484. enum: [OK]
  485. message:
  486. type: string
  487. enum: [success]
  488. data:
  489. type: object
  490. additionalProperties: false
  491. requestId:
  492. type: string
  493. format: uuid
  494. CategoryNode:
  495. type: object
  496. additionalProperties: false
  497. required:
  498. - id
  499. - categoryCode
  500. - categoryName
  501. - categoryType
  502. - parentId
  503. - categoryPath
  504. - sortNo
  505. - documentCount
  506. - rowVersion
  507. - children
  508. properties:
  509. id:
  510. $ref: '#/StringId'
  511. categoryCode:
  512. type: string
  513. maxLength: 64
  514. categoryName:
  515. type: string
  516. maxLength: 128
  517. categoryType:
  518. $ref: '#/CategoryType'
  519. parentId:
  520. allOf:
  521. - $ref: '#/StringId'
  522. nullable: true
  523. categoryPath:
  524. type: string
  525. maxLength: 1000
  526. sortNo:
  527. type: integer
  528. documentCount:
  529. type: integer
  530. minimum: 0
  531. description: 该分类完整有效子树内所有有效MAIN数量(不按当前用户密级/权限过滤,所有登录用户口径一致)。
  532. rowVersion:
  533. type: integer
  534. minimum: 0
  535. children:
  536. type: array
  537. items:
  538. $ref: '#/CategoryNode'
  539. CreateCategoryRequest:
  540. type: object
  541. additionalProperties: false
  542. required: [categoryCode, categoryName, categoryType, parentId, sortNo]
  543. properties:
  544. categoryCode:
  545. type: string
  546. minLength: 1
  547. maxLength: 64
  548. categoryName:
  549. type: string
  550. minLength: 1
  551. maxLength: 128
  552. categoryType:
  553. $ref: '#/CategoryType'
  554. parentId:
  555. allOf:
  556. - $ref: '#/StringId'
  557. nullable: true
  558. sortNo:
  559. type: integer
  560. UpdateCategoryRequest:
  561. type: object
  562. additionalProperties: false
  563. required: [categoryName, categoryType, parentId, sortNo, rowVersion]
  564. properties:
  565. categoryName:
  566. type: string
  567. minLength: 1
  568. maxLength: 128
  569. categoryType:
  570. $ref: '#/CategoryType'
  571. parentId:
  572. allOf:
  573. - $ref: '#/StringId'
  574. nullable: true
  575. sortNo:
  576. type: integer
  577. rowVersion:
  578. type: integer
  579. minimum: 0
  580. CategoryTreeResponse:
  581. type: object
  582. additionalProperties: false
  583. required: [code, message, data, requestId]
  584. properties:
  585. code:
  586. type: string
  587. enum: [OK]
  588. message:
  589. type: string
  590. enum: [success]
  591. data:
  592. type: array
  593. items:
  594. $ref: '#/CategoryNode'
  595. requestId:
  596. type: string
  597. format: uuid
  598. CategoryResponse:
  599. type: object
  600. additionalProperties: false
  601. required: [code, message, data, requestId]
  602. properties:
  603. code:
  604. type: string
  605. enum: [OK]
  606. message:
  607. type: string
  608. enum: [success]
  609. data:
  610. $ref: '#/CategoryNode'
  611. requestId:
  612. type: string
  613. format: uuid
  614. DeleteCategoryData:
  615. type: object
  616. additionalProperties: false
  617. required: [id, deleted]
  618. properties:
  619. id:
  620. $ref: '#/StringId'
  621. deleted:
  622. type: boolean
  623. enum: [true]
  624. DeleteCategoryResponse:
  625. type: object
  626. additionalProperties: false
  627. required: [code, message, data, requestId]
  628. properties:
  629. code:
  630. type: string
  631. enum: [OK]
  632. message:
  633. type: string
  634. enum: [success]
  635. data:
  636. $ref: '#/DeleteCategoryData'
  637. requestId:
  638. type: string
  639. format: uuid
  640. PermissionSummary:
  641. type: object
  642. additionalProperties: false
  643. required: [borrowerCount, inheritedFromMainPlan]
  644. properties:
  645. borrowerCount:
  646. type: integer
  647. minimum: 0
  648. description: 生效(canView且未到期)借阅人数
  649. inheritedFromMainPlan:
  650. type: boolean
  651. DocumentSummary:
  652. type: object
  653. required:
  654. - id
  655. - documentName
  656. - summary
  657. - documentType
  658. - status
  659. - securityLevel
  660. - borrowSummary
  661. - categoryId
  662. - categoryName
  663. - categoryPath
  664. - parentDocumentId
  665. - rootDocumentId
  666. - attachmentType
  667. - fileExtension
  668. - tags
  669. - childCount
  670. - attachmentCount
  671. - viewCount
  672. - downloadCount
  673. - createdByName
  674. - createdAt
  675. - updatedAt
  676. - rowVersion
  677. - allowedActions
  678. - hasPassword
  679. - passwordProtectedActions
  680. - viewLocked
  681. properties:
  682. id:
  683. $ref: '#/StringId'
  684. documentName:
  685. type: string
  686. summary:
  687. type: string
  688. nullable: true
  689. description:
  690. type: string
  691. nullable: true
  692. description: 详细说明:管理员在"查看"对话框维护,供普通用户阅读;不参与全文检索。
  693. documentType:
  694. $ref: '#/DocumentType'
  695. status:
  696. $ref: '#/DocumentStatus'
  697. securityLevel:
  698. $ref: '#/SecurityLevel'
  699. borrowSummary:
  700. type: string
  701. description: 生效借阅人姓名以"、"连接;未配置时为"未配置";无查看权限的列表行返回"-"
  702. categoryId:
  703. allOf:
  704. - $ref: '#/StringId'
  705. nullable: true
  706. categoryName:
  707. type: string
  708. nullable: true
  709. categoryPath:
  710. type: string
  711. nullable: true
  712. parentDocumentId:
  713. allOf:
  714. - $ref: '#/StringId'
  715. nullable: true
  716. rootDocumentId:
  717. allOf:
  718. - $ref: '#/StringId'
  719. nullable: true
  720. attachmentType:
  721. allOf:
  722. - $ref: '#/AttachmentType'
  723. nullable: true
  724. fileExtension:
  725. type: string
  726. tags:
  727. type: array
  728. items:
  729. type: string
  730. childCount:
  731. type: integer
  732. minimum: 0
  733. attachmentCount:
  734. type: integer
  735. minimum: 0
  736. viewCount:
  737. type: integer
  738. minimum: 0
  739. downloadCount:
  740. type: integer
  741. minimum: 0
  742. createdByName:
  743. type: string
  744. nullable: true
  745. createdAt:
  746. $ref: '#/UtcDateTime'
  747. updatedAt:
  748. $ref: '#/UtcDateTime'
  749. rowVersion:
  750. type: integer
  751. minimum: 0
  752. allowedActions:
  753. type: array
  754. uniqueItems: true
  755. items:
  756. $ref: '#/AllowedAction'
  757. hasPassword:
  758. type: boolean
  759. description: 主案是否设置密码锁;仅MAIN可设,其余类型恒false。
  760. passwordProtectedActions:
  761. type: array
  762. uniqueItems: true
  763. items:
  764. $ref: '#/DocumentPasswordAction'
  765. description: 密码锁勾选保护的操作码集合;未设密恒为空数组。
  766. viewLocked:
  767. type: boolean
  768. description: 当前用户查看该文档正文是否需要密码;viewLocked时contentSnippet不返回。
  769. mountedPlanCount:
  770. type: integer
  771. minimum: 0
  772. description: 仅共享附件响应返回。
  773. DocumentDetail:
  774. allOf:
  775. - $ref: '#/DocumentSummary'
  776. - type: object
  777. required:
  778. - originalFileName
  779. - mimeType
  780. - fileSize
  781. - fileHash
  782. - permissionSummary
  783. - viewPasswordVerified
  784. - contentText
  785. properties:
  786. originalFileName:
  787. type: string
  788. mimeType:
  789. type: string
  790. nullable: true
  791. fileSize:
  792. type: integer
  793. minimum: 0
  794. fileHash:
  795. type: string
  796. pattern: '^[0-9a-fA-F]{64}$'
  797. permissionSummary:
  798. $ref: '#/PermissionSummary'
  799. viewPasswordVerified:
  800. type: boolean
  801. description: 查看是否已通过密码验证(未锁定恒true)。
  802. contentText:
  803. type: string
  804. nullable: true
  805. description: 提取的正文文本;viewLocked且请求头密码未验证通过时为null。
  806. contentExtractStatus:
  807. type: string
  808. enum: [SUCCESS, EMPTY, UNSUPPORTED, FAILED]
  809. description: 正文提取状态。仅管理员详情响应返回。
  810. contentExtractError:
  811. type: string
  812. nullable: true
  813. description: 提取失败的脱敏原因(异常类型+首行信息,不含绝对路径)。仅管理员详情响应返回;非FAILED时为null。
  814. contentExtractedAt:
  815. type: string
  816. format: date-time
  817. nullable: true
  818. description: 最近一次正文提取时间(UTC)。仅管理员详情响应返回。
  819. AttachmentBindingSummary:
  820. allOf:
  821. - $ref: '#/DocumentSummary'
  822. - type: object
  823. required: [bindingId, bindingSortNo, mountedPlanCount]
  824. properties:
  825. bindingId:
  826. $ref: '#/StringId'
  827. bindingSortNo:
  828. type: integer
  829. mountedPlanCount:
  830. type: integer
  831. minimum: 0
  832. DocumentPage:
  833. type: object
  834. additionalProperties: false
  835. required: [items, page, pageSize, total, totalPages]
  836. properties:
  837. items:
  838. type: array
  839. items:
  840. $ref: '#/DocumentSummary'
  841. page:
  842. type: integer
  843. minimum: 1
  844. pageSize:
  845. type: integer
  846. minimum: 1
  847. maximum: 100
  848. total:
  849. type: integer
  850. minimum: 0
  851. totalPages:
  852. type: integer
  853. minimum: 0
  854. AttachmentBindingPage:
  855. type: object
  856. additionalProperties: false
  857. required: [items, page, pageSize, total, totalPages]
  858. properties:
  859. items:
  860. type: array
  861. items:
  862. $ref: '#/AttachmentBindingSummary'
  863. page:
  864. type: integer
  865. minimum: 1
  866. pageSize:
  867. type: integer
  868. minimum: 1
  869. maximum: 100
  870. total:
  871. type: integer
  872. minimum: 0
  873. totalPages:
  874. type: integer
  875. minimum: 0
  876. MainPlanBrief:
  877. type: object
  878. additionalProperties: false
  879. required: [id, documentName, categoryName, securityLevel]
  880. properties:
  881. id:
  882. $ref: '#/StringId'
  883. documentName:
  884. type: string
  885. categoryName:
  886. type: string
  887. nullable: true
  888. securityLevel:
  889. $ref: '#/SecurityLevel'
  890. MainPlanBriefCollection:
  891. type: object
  892. additionalProperties: false
  893. required: [items, total]
  894. properties:
  895. items:
  896. type: array
  897. items:
  898. $ref: '#/MainPlanBrief'
  899. total:
  900. type: integer
  901. minimum: 0
  902. DocumentPageResponse:
  903. type: object
  904. additionalProperties: false
  905. required: [code, message, data, requestId]
  906. properties:
  907. code:
  908. type: string
  909. enum: [OK]
  910. message:
  911. type: string
  912. enum: [success]
  913. data:
  914. $ref: '#/DocumentPage'
  915. requestId:
  916. type: string
  917. format: uuid
  918. DocumentDetailResponse:
  919. type: object
  920. additionalProperties: false
  921. required: [code, message, data, requestId]
  922. properties:
  923. code:
  924. type: string
  925. enum: [OK]
  926. message:
  927. type: string
  928. enum: [success]
  929. data:
  930. $ref: '#/DocumentDetail'
  931. requestId:
  932. type: string
  933. format: uuid
  934. AttachmentBindingPageResponse:
  935. type: object
  936. additionalProperties: false
  937. required: [code, message, data, requestId]
  938. properties:
  939. code:
  940. type: string
  941. enum: [OK]
  942. message:
  943. type: string
  944. enum: [success]
  945. data:
  946. $ref: '#/AttachmentBindingPage'
  947. requestId:
  948. type: string
  949. format: uuid
  950. MainPlanBriefCollectionResponse:
  951. type: object
  952. additionalProperties: false
  953. required: [code, message, data, requestId]
  954. properties:
  955. code:
  956. type: string
  957. enum: [OK]
  958. message:
  959. type: string
  960. enum: [success]
  961. data:
  962. $ref: '#/MainPlanBriefCollection'
  963. requestId:
  964. type: string
  965. format: uuid
  966. MainDocumentCreateMetadata:
  967. type: object
  968. additionalProperties: false
  969. required: [documentName, documentType, summary, categoryId, securityLevel, tags]
  970. properties:
  971. documentName: {type: string, minLength: 1, maxLength: 255}
  972. documentType: {type: string, enum: [MAIN]}
  973. summary: {type: string, nullable: true}
  974. categoryId: {$ref: '#/StringId'}
  975. securityLevel: {$ref: '#/SecurityLevel'}
  976. overwriteDocumentId:
  977. allOf: [{$ref: '#/StringId'}]
  978. description: 仅在用户确认覆盖同名主案后提交,并必须与rowVersion同时出现。
  979. rowVersion:
  980. type: integer
  981. minimum: 0
  982. description: 被覆盖文档的当前版本;仅与overwriteDocumentId同时提交。
  983. tags:
  984. type: array
  985. maxItems: 50
  986. items: {type: string, minLength: 1, maxLength: 64}
  987. password:
  988. type: string
  989. minLength: 1
  990. maxLength: 128
  991. description: 可选;仅新增MAIN时允许,与protectedActions必须同时出现;覆盖上传(overwriteDocumentId)时禁止携带。
  992. protectedActions:
  993. type: array
  994. uniqueItems: true
  995. items: {$ref: '#/DocumentPasswordAction'}
  996. description: 可选;密码保护的操作码集合,与password必须同时出现。
  997. SubPlanCreateMetadata:
  998. type: object
  999. additionalProperties: false
  1000. required: [documentName, documentType, summary, parentDocumentId, securityLevel, tags]
  1001. properties:
  1002. documentName: {type: string, minLength: 1, maxLength: 255}
  1003. documentType: {type: string, enum: [SUB_PLAN]}
  1004. summary: {type: string, nullable: true}
  1005. parentDocumentId: {$ref: '#/StringId'}
  1006. securityLevel: {$ref: '#/SecurityLevel'}
  1007. overwriteDocumentId:
  1008. allOf: [{$ref: '#/StringId'}]
  1009. description: 仅在用户确认覆盖同一主案下同名子案后提交,并必须与rowVersion同时出现。
  1010. rowVersion:
  1011. type: integer
  1012. minimum: 0
  1013. description: 被覆盖文档的当前版本;仅与overwriteDocumentId同时提交。
  1014. tags:
  1015. type: array
  1016. maxItems: 50
  1017. items: {type: string, minLength: 1, maxLength: 64}
  1018. DocumentCreateMetadata:
  1019. oneOf:
  1020. - $ref: '#/MainDocumentCreateMetadata'
  1021. - $ref: '#/SubPlanCreateMetadata'
  1022. discriminator:
  1023. propertyName: documentType
  1024. AttachmentCreateMetadata:
  1025. type: object
  1026. additionalProperties: false
  1027. required: [documentName, attachmentType, summary, tags]
  1028. properties:
  1029. documentName: {type: string, minLength: 1, maxLength: 255}
  1030. attachmentType: {$ref: '#/AttachmentType'}
  1031. summary: {type: string, nullable: true}
  1032. tags:
  1033. type: array
  1034. maxItems: 50
  1035. items: {type: string, minLength: 1, maxLength: 64}
  1036. MainDocumentUpdateRequest:
  1037. type: object
  1038. additionalProperties: false
  1039. required: [documentName, summary, categoryId, securityLevel, tags, rowVersion]
  1040. properties:
  1041. documentName: {type: string, minLength: 1, maxLength: 255}
  1042. summary: {type: string, nullable: true}
  1043. categoryId: {$ref: '#/StringId'}
  1044. securityLevel: {$ref: '#/SecurityLevel'}
  1045. tags:
  1046. type: array
  1047. maxItems: 50
  1048. items: {type: string, minLength: 1, maxLength: 64}
  1049. rowVersion: {type: integer, minimum: 0}
  1050. organizationId:
  1051. allOf:
  1052. - $ref: '#/StringId'
  1053. description: 目标归属部门;缺省沿用现有归属,调整到其他部门仅ADMIN。
  1054. SubPlanUpdateRequest:
  1055. type: object
  1056. additionalProperties: false
  1057. required: [documentName, summary, securityLevel, tags, rowVersion]
  1058. properties:
  1059. documentName: {type: string, minLength: 1, maxLength: 255}
  1060. summary: {type: string, nullable: true}
  1061. securityLevel: {$ref: '#/SecurityLevel'}
  1062. tags:
  1063. type: array
  1064. maxItems: 50
  1065. items: {type: string, minLength: 1, maxLength: 64}
  1066. rowVersion: {type: integer, minimum: 0}
  1067. organizationId:
  1068. allOf:
  1069. - $ref: '#/StringId'
  1070. description: 目标归属部门;缺省沿用现有归属,调整到其他部门仅ADMIN。
  1071. UpdateDocumentRequest:
  1072. oneOf:
  1073. - $ref: '#/MainDocumentUpdateRequest'
  1074. - $ref: '#/SubPlanUpdateRequest'
  1075. UpdateDocumentDescriptionRequest:
  1076. type: object
  1077. additionalProperties: false
  1078. required: [description]
  1079. properties:
  1080. description: {type: string, nullable: true, maxLength: 20000}
  1081. DocumentPasswordAction:
  1082. type: string
  1083. description: 主案密码锁可保护的操作码(与权限矩阵7操作对齐)。
  1084. enum:
  1085. - VIEW
  1086. - DOWNLOAD
  1087. - EDIT
  1088. - DELETE
  1089. - CONFIG_PERMISSION
  1090. - BIND_ATTACHMENT
  1091. - UNBIND_ATTACHMENT
  1092. UpdateDocumentPasswordRequest:
  1093. type: object
  1094. additionalProperties: false
  1095. required: [rowVersion]
  1096. properties:
  1097. rowVersion: {type: integer, minimum: 0, description: 主案当前版本,乐观锁。}
  1098. oldPassword:
  1099. type: string
  1100. maxLength: 128
  1101. description: 已设密时修改/清除必须提供且正确;未设密时禁止提供。
  1102. password:
  1103. type: string
  1104. minLength: 1
  1105. maxLength: 128
  1106. description: 新密码;缺省或空表示清除密码锁,此时不得携带protectedActions。
  1107. protectedActions:
  1108. type: array
  1109. uniqueItems: true
  1110. items: {$ref: '#/DocumentPasswordAction'}
  1111. description: 设置/修改密码时的保护操作集合;与password必须同时出现。
  1112. DocumentPasswordSummary:
  1113. type: object
  1114. additionalProperties: false
  1115. required: [id, hasPassword, protectedActions, rowVersion]
  1116. properties:
  1117. id: {$ref: '#/StringId'}
  1118. hasPassword: {type: boolean}
  1119. protectedActions:
  1120. type: array
  1121. uniqueItems: true
  1122. items: {$ref: '#/DocumentPasswordAction'}
  1123. rowVersion: {type: integer, minimum: 0}
  1124. DocumentPasswordResponse:
  1125. type: object
  1126. additionalProperties: false
  1127. required: [code, message, data, requestId]
  1128. properties:
  1129. code:
  1130. type: string
  1131. enum: [OK]
  1132. message:
  1133. type: string
  1134. enum: [success]
  1135. data:
  1136. $ref: '#/DocumentPasswordSummary'
  1137. requestId:
  1138. type: string
  1139. format: uuid
  1140. UpdateAttachmentRequest:
  1141. type: object
  1142. additionalProperties: false
  1143. required: [documentName, attachmentType, summary, tags, rowVersion]
  1144. properties:
  1145. documentName: {type: string, minLength: 1, maxLength: 255}
  1146. attachmentType: {$ref: '#/AttachmentType'}
  1147. summary: {type: string, nullable: true}
  1148. tags:
  1149. type: array
  1150. maxItems: 50
  1151. items: {type: string, minLength: 1, maxLength: 64}
  1152. rowVersion: {type: integer, minimum: 0}
  1153. organizationId:
  1154. allOf:
  1155. - $ref: '#/StringId'
  1156. description: 目标归属部门;缺省沿用现有归属,调整到其他部门仅ADMIN。
  1157. DeleteDocumentData:
  1158. type: object
  1159. additionalProperties: false
  1160. required: [id, deleted]
  1161. properties:
  1162. id: {$ref: '#/StringId'}
  1163. deleted: {type: boolean, enum: [true]}
  1164. DeleteDocumentResponse:
  1165. type: object
  1166. additionalProperties: false
  1167. required: [code, message, data, requestId]
  1168. properties:
  1169. code: {type: string, enum: [OK]}
  1170. message: {type: string, enum: [success]}
  1171. data: {$ref: '#/DeleteDocumentData'}
  1172. requestId: {type: string, format: uuid}
  1173. BatchImportMultipart:
  1174. type: object
  1175. additionalProperties: false
  1176. required: [files, items]
  1177. properties:
  1178. files:
  1179. type: array
  1180. minItems: 1
  1181. items: {type: string, format: binary}
  1182. description: 重复files字段,顺序与items数组严格对应。
  1183. items:
  1184. type: string
  1185. description: 文档或附件metadata对象数组的JSON字符串。
  1186. BatchImportItem:
  1187. type: object
  1188. additionalProperties: false
  1189. required: [index, originalFileName, success]
  1190. properties:
  1191. index: {type: integer, minimum: 0}
  1192. originalFileName: {type: string}
  1193. success: {type: boolean}
  1194. document: {$ref: '#/DocumentDetail'}
  1195. errorCode: {type: string}
  1196. errorMessage: {type: string}
  1197. BatchImportData:
  1198. type: object
  1199. additionalProperties: false
  1200. required: [total, successCount, failureCount, items]
  1201. properties:
  1202. total: {type: integer, minimum: 0}
  1203. successCount: {type: integer, minimum: 0}
  1204. failureCount: {type: integer, minimum: 0}
  1205. items:
  1206. type: array
  1207. items: {$ref: '#/BatchImportItem'}
  1208. BatchImportResponse:
  1209. type: object
  1210. additionalProperties: false
  1211. required: [code, message, data, requestId]
  1212. properties:
  1213. code: {type: string, enum: [OK]}
  1214. message: {type: string, enum: [success]}
  1215. data: {$ref: '#/BatchImportData'}
  1216. requestId: {type: string, format: uuid}
  1217. BindAttachmentsRequest:
  1218. type: object
  1219. additionalProperties: false
  1220. required: [attachmentIds, mainPlanRowVersion]
  1221. properties:
  1222. attachmentIds:
  1223. type: array
  1224. minItems: 1
  1225. items: {$ref: '#/StringId'}
  1226. mainPlanRowVersion:
  1227. type: integer
  1228. minimum: 0
  1229. BindAttachmentsData:
  1230. type: object
  1231. additionalProperties: false
  1232. required: [createdCount, existingCount, attachmentCount, mainPlanRowVersion]
  1233. properties:
  1234. createdCount: {type: integer, minimum: 0}
  1235. existingCount: {type: integer, minimum: 0}
  1236. attachmentCount: {type: integer, minimum: 0}
  1237. mainPlanRowVersion: {type: integer, minimum: 0}
  1238. BindAttachmentsResponse:
  1239. type: object
  1240. additionalProperties: false
  1241. required: [code, message, data, requestId]
  1242. properties:
  1243. code: {type: string, enum: [OK]}
  1244. message: {type: string, enum: [success]}
  1245. data: {$ref: '#/BindAttachmentsData'}
  1246. requestId: {type: string, format: uuid}
  1247. UnbindAttachmentData:
  1248. type: object
  1249. additionalProperties: false
  1250. required: [attachmentCount, mainPlanRowVersion]
  1251. properties:
  1252. attachmentCount: {type: integer, minimum: 0}
  1253. mainPlanRowVersion: {type: integer, minimum: 0}
  1254. UnbindAttachmentResponse:
  1255. type: object
  1256. additionalProperties: false
  1257. required: [code, message, data, requestId]
  1258. properties:
  1259. code: {type: string, enum: [OK]}
  1260. message: {type: string, enum: [success]}
  1261. data: {$ref: '#/UnbindAttachmentData'}
  1262. requestId: {type: string, format: uuid}
  1263. ReorderDocumentsRequest:
  1264. type: object
  1265. additionalProperties: false
  1266. required: [orderedIds]
  1267. properties:
  1268. orderedIds:
  1269. type: array
  1270. minItems: 2
  1271. items: {$ref: '#/StringId'}
  1272. ReorderDocumentsData:
  1273. type: object
  1274. additionalProperties: false
  1275. required: [reorderedCount]
  1276. properties:
  1277. reorderedCount: {type: integer, minimum: 0}
  1278. ReorderDocumentsResponse:
  1279. type: object
  1280. additionalProperties: false
  1281. required: [code, message, data, requestId]
  1282. properties:
  1283. code: {type: string, enum: [OK]}
  1284. message: {type: string, enum: [success]}
  1285. data: {$ref: '#/ReorderDocumentsData'}
  1286. requestId: {type: string, format: uuid}
  1287. ReorderAttachmentsRequest:
  1288. type: object
  1289. additionalProperties: false
  1290. required: [orderedBindingIds, mainPlanRowVersion]
  1291. properties:
  1292. orderedBindingIds:
  1293. type: array
  1294. minItems: 2
  1295. items: {$ref: '#/StringId'}
  1296. mainPlanRowVersion:
  1297. type: integer
  1298. minimum: 0
  1299. ReorderAttachmentsData:
  1300. type: object
  1301. additionalProperties: false
  1302. required: [reorderedCount, mainPlanRowVersion]
  1303. properties:
  1304. reorderedCount: {type: integer, minimum: 0}
  1305. mainPlanRowVersion: {type: integer, minimum: 0}
  1306. ReorderAttachmentsResponse:
  1307. type: object
  1308. additionalProperties: false
  1309. required: [code, message, data, requestId]
  1310. properties:
  1311. code: {type: string, enum: [OK]}
  1312. message: {type: string, enum: [success]}
  1313. data: {$ref: '#/ReorderAttachmentsData'}
  1314. requestId: {type: string, format: uuid}
  1315. ReorderCategoriesRequest:
  1316. type: object
  1317. additionalProperties: false
  1318. required: [parentId, orderedIds]
  1319. properties:
  1320. parentId:
  1321. oneOf:
  1322. - $ref: '#/StringId'
  1323. - type: 'null'
  1324. orderedIds:
  1325. type: array
  1326. minItems: 2
  1327. items: {$ref: '#/StringId'}
  1328. ReorderCategoriesData:
  1329. type: object
  1330. additionalProperties: false
  1331. required: [reorderedCount]
  1332. properties:
  1333. reorderedCount: {type: integer, minimum: 0}
  1334. ReorderCategoriesResponse:
  1335. type: object
  1336. additionalProperties: false
  1337. required: [code, message, data, requestId]
  1338. properties:
  1339. code: {type: string, enum: [OK]}
  1340. message: {type: string, enum: [success]}
  1341. data: {$ref: '#/ReorderCategoriesData'}
  1342. requestId: {type: string, format: uuid}
  1343. ReorderOrganizationsRequest:
  1344. type: object
  1345. additionalProperties: false
  1346. required: [parentId, orderedIds]
  1347. properties:
  1348. parentId:
  1349. oneOf:
  1350. - $ref: '#/StringId'
  1351. - type: 'null'
  1352. orderedIds:
  1353. type: array
  1354. minItems: 2
  1355. items: {$ref: '#/StringId'}
  1356. ReorderByIdsRequest:
  1357. type: object
  1358. additionalProperties: false
  1359. required: [orderedIds]
  1360. properties:
  1361. orderedIds:
  1362. type: array
  1363. minItems: 2
  1364. items: {$ref: '#/StringId'}
  1365. ReorderResultData:
  1366. type: object
  1367. additionalProperties: false
  1368. required: [reorderedCount]
  1369. properties:
  1370. reorderedCount: {type: integer, minimum: 0}
  1371. ReorderResultResponse:
  1372. type: object
  1373. additionalProperties: false
  1374. required: [code, message, data, requestId]
  1375. properties:
  1376. code: {type: string, enum: [OK]}
  1377. message: {type: string, enum: [success]}
  1378. data: {$ref: '#/ReorderResultData'}
  1379. requestId: {type: string, format: uuid}
  1380. PermissionEntry:
  1381. type: object
  1382. additionalProperties: false
  1383. required:
  1384. - id
  1385. - subjectId
  1386. - subjectName
  1387. - canView
  1388. - canDownload
  1389. - expiresAt
  1390. - voucherFileName
  1391. - voucherFileSize
  1392. - voucherUploadedAt
  1393. properties:
  1394. id: {$ref: '#/StringId'}
  1395. subjectId: {$ref: '#/StringId'}
  1396. subjectName: {type: string}
  1397. canView: {type: boolean}
  1398. canDownload: {type: boolean}
  1399. expiresAt: {$ref: '#/UtcDateTime'}
  1400. voucherFileName: {type: string, nullable: true}
  1401. voucherFileSize: {type: integer, minimum: 1, nullable: true}
  1402. voucherUploadedAt:
  1403. allOf:
  1404. - $ref: '#/UtcDateTime'
  1405. nullable: true
  1406. SavePermissionEntry:
  1407. type: object
  1408. additionalProperties: false
  1409. required:
  1410. - subjectId
  1411. - canView
  1412. - canDownload
  1413. - expiresAt
  1414. properties:
  1415. subjectId: {$ref: '#/StringId'}
  1416. canView: {type: boolean}
  1417. canDownload: {type: boolean}
  1418. expiresAt: {$ref: '#/UtcDateTime'}
  1419. SavePermissionsRequest:
  1420. type: object
  1421. additionalProperties: false
  1422. required: [documentRowVersion, entries]
  1423. properties:
  1424. documentRowVersion: {type: integer, minimum: 0}
  1425. entries:
  1426. type: array
  1427. items: {$ref: '#/SavePermissionEntry'}
  1428. description: 借阅授权全集(非增量补丁);仅用户主体,expiresAt必须晚于当前时间且不超过当前时间+7天(服务端含60秒容差);保存不触碰审批单凭证。
  1429. PermissionDetail:
  1430. type: object
  1431. additionalProperties: false
  1432. required:
  1433. - documentId
  1434. - sourceDocumentId
  1435. - inherited
  1436. - documentRowVersion
  1437. - entries
  1438. properties:
  1439. documentId: {$ref: '#/StringId'}
  1440. sourceDocumentId: {$ref: '#/StringId'}
  1441. inherited: {type: boolean}
  1442. documentRowVersion: {type: integer, minimum: 0}
  1443. entries:
  1444. type: array
  1445. items: {$ref: '#/PermissionEntry'}
  1446. description: 按subjectId升序返回全部未删除授权(含已到期条目,由前端标记)。
  1447. PermissionVoucherResult:
  1448. type: object
  1449. additionalProperties: false
  1450. required: [documentId, entryId, voucherFileName, voucherFileSize, voucherUploadedAt]
  1451. properties:
  1452. documentId: {$ref: '#/StringId'}
  1453. entryId: {$ref: '#/StringId'}
  1454. voucherFileName: {type: string}
  1455. voucherFileSize: {type: integer, minimum: 1}
  1456. voucherUploadedAt: {$ref: '#/UtcDateTime'}
  1457. PermissionVoucherResultResponse:
  1458. type: object
  1459. additionalProperties: false
  1460. required: [code, message, data, requestId]
  1461. properties:
  1462. code: {type: string, enum: [OK]}
  1463. message: {type: string, enum: [success]}
  1464. data: {$ref: '#/PermissionVoucherResult'}
  1465. requestId: {type: string, format: uuid}
  1466. PermissionVoucherDeleteResult:
  1467. type: object
  1468. additionalProperties: false
  1469. required: [documentId, entryId]
  1470. properties:
  1471. documentId: {$ref: '#/StringId'}
  1472. entryId: {$ref: '#/StringId'}
  1473. PermissionVoucherDeleteResultResponse:
  1474. type: object
  1475. additionalProperties: false
  1476. required: [code, message, data, requestId]
  1477. properties:
  1478. code: {type: string, enum: [OK]}
  1479. message: {type: string, enum: [success]}
  1480. data: {$ref: '#/PermissionVoucherDeleteResult'}
  1481. requestId: {type: string, format: uuid}
  1482. PermissionDetailResponse:
  1483. type: object
  1484. additionalProperties: false
  1485. required: [code, message, data, requestId]
  1486. properties:
  1487. code: {type: string, enum: [OK]}
  1488. message: {type: string, enum: [success]}
  1489. data: {$ref: '#/PermissionDetail'}
  1490. requestId: {type: string, format: uuid}
  1491. AuditGranularity:
  1492. type: string
  1493. enum: [DAY, WEEK, MONTH]
  1494. AuditLogSummary:
  1495. type: object
  1496. additionalProperties: false
  1497. required:
  1498. - id
  1499. - username
  1500. - realName
  1501. - organizationName
  1502. - actionType
  1503. - targetType
  1504. - targetId
  1505. - targetName
  1506. - operationResult
  1507. - failureReason
  1508. - clientIp
  1509. - requestId
  1510. - createdAt
  1511. properties:
  1512. id: {$ref: '#/StringId'}
  1513. username: {type: string, nullable: true}
  1514. realName: {type: string, nullable: true}
  1515. organizationName: {type: string, nullable: true}
  1516. actionType: {$ref: '#/AuditAction'}
  1517. targetType:
  1518. allOf: [{$ref: '#/AuditTarget'}]
  1519. nullable: true
  1520. targetId:
  1521. allOf: [{$ref: '#/StringId'}]
  1522. nullable: true
  1523. targetName: {type: string, nullable: true}
  1524. operationResult: {$ref: '#/AuditResult'}
  1525. failureReason: {type: string, nullable: true}
  1526. clientIp: {type: string, nullable: true}
  1527. requestId: {type: string, nullable: true}
  1528. createdAt: {$ref: '#/UtcDateTime'}
  1529. AuditLogPage:
  1530. type: object
  1531. additionalProperties: false
  1532. required: [items, page, pageSize, total, totalPages]
  1533. properties:
  1534. items: {type: array, items: {$ref: '#/AuditLogSummary'}}
  1535. page: {type: integer, minimum: 1}
  1536. pageSize: {type: integer, minimum: 1, maximum: 100}
  1537. total: {type: integer, minimum: 0}
  1538. totalPages: {type: integer, minimum: 0}
  1539. AuditLogPageResponse:
  1540. type: object
  1541. additionalProperties: false
  1542. required: [code, message, data, requestId]
  1543. properties:
  1544. code: {type: string, enum: [OK]}
  1545. message: {type: string, enum: [success]}
  1546. data: {$ref: '#/AuditLogPage'}
  1547. requestId: {type: string, format: uuid}
  1548. DocumentStatistics:
  1549. type: object
  1550. additionalProperties: false
  1551. required: [planDocumentCount, mainPlanCount, subPlanCount, attachmentCount, todayViewerCount]
  1552. properties:
  1553. planDocumentCount: {type: integer, minimum: 0}
  1554. mainPlanCount: {type: integer, minimum: 0}
  1555. subPlanCount: {type: integer, minimum: 0}
  1556. attachmentCount: {type: integer, minimum: 0}
  1557. todayViewerCount: {type: integer, minimum: 0}
  1558. DocumentStatisticsResponse:
  1559. type: object
  1560. additionalProperties: false
  1561. required: [code, message, data, requestId]
  1562. properties:
  1563. code: {type: string, enum: [OK]}
  1564. message: {type: string, enum: [success]}
  1565. data: {$ref: '#/DocumentStatistics'}
  1566. requestId: {type: string, format: uuid}
  1567. AuditTrendItem:
  1568. type: object
  1569. additionalProperties: false
  1570. required: [period, operationCount]
  1571. properties:
  1572. period: {type: string}
  1573. operationCount: {type: integer, minimum: 0}
  1574. AuditTrendData:
  1575. type: object
  1576. additionalProperties: false
  1577. required: [items]
  1578. properties:
  1579. items: {type: array, items: {$ref: '#/AuditTrendItem'}}
  1580. AuditTrendResponse:
  1581. type: object
  1582. additionalProperties: false
  1583. required: [code, message, data, requestId]
  1584. properties:
  1585. code: {type: string, enum: [OK]}
  1586. message: {type: string, enum: [success]}
  1587. data: {$ref: '#/AuditTrendData'}
  1588. requestId: {type: string, format: uuid}
  1589. AuditActionStatisticsItem:
  1590. type: object
  1591. additionalProperties: false
  1592. required: [actionType, count]
  1593. properties:
  1594. actionType: {$ref: '#/AuditAction'}
  1595. count: {type: integer, minimum: 0}
  1596. AuditActionStatisticsData:
  1597. type: object
  1598. additionalProperties: false
  1599. required: [items]
  1600. properties:
  1601. items: {type: array, items: {$ref: '#/AuditActionStatisticsItem'}}
  1602. AuditActionStatisticsResponse:
  1603. type: object
  1604. additionalProperties: false
  1605. required: [code, message, data, requestId]
  1606. properties:
  1607. code: {type: string, enum: [OK]}
  1608. message: {type: string, enum: [success]}
  1609. data: {$ref: '#/AuditActionStatisticsData'}
  1610. requestId: {type: string, format: uuid}
  1611. AuditUserStatisticsItem:
  1612. type: object
  1613. additionalProperties: false
  1614. required: [userId, realName, organizationName, operationCount]
  1615. properties:
  1616. userId: {$ref: '#/StringId'}
  1617. realName: {type: string, nullable: true}
  1618. organizationName: {type: string, nullable: true}
  1619. operationCount: {type: integer, minimum: 0}
  1620. AuditUserStatisticsData:
  1621. type: object
  1622. additionalProperties: false
  1623. required: [items]
  1624. properties:
  1625. items: {type: array, items: {$ref: '#/AuditUserStatisticsItem'}}
  1626. AuditUserStatisticsResponse:
  1627. type: object
  1628. additionalProperties: false
  1629. required: [code, message, data, requestId]
  1630. properties:
  1631. code: {type: string, enum: [OK]}
  1632. message: {type: string, enum: [success]}
  1633. data: {$ref: '#/AuditUserStatisticsData'}
  1634. requestId: {type: string, format: uuid}
  1635. DeletedBySnapshot:
  1636. type: object
  1637. additionalProperties: false
  1638. required: [userId, username, realName, organizationName]
  1639. properties:
  1640. userId:
  1641. allOf:
  1642. - $ref: '#/StringId'
  1643. nullable: true
  1644. username: {type: string, nullable: true}
  1645. realName: {type: string, nullable: true}
  1646. organizationName: {type: string, nullable: true}
  1647. RecycleBinDocumentSummary:
  1648. type: object
  1649. additionalProperties: false
  1650. required:
  1651. - id
  1652. - documentName
  1653. - documentType
  1654. - originalFileName
  1655. - categoryId
  1656. - categoryName
  1657. - parentDocumentId
  1658. - securityLevel
  1659. - documentStatus
  1660. - deletedAt
  1661. - updatedBy
  1662. - updatedByName
  1663. - deletedBy
  1664. - rowVersion
  1665. properties:
  1666. id: {$ref: '#/StringId'}
  1667. documentName: {type: string}
  1668. documentType: {$ref: '#/DocumentType'}
  1669. originalFileName: {type: string}
  1670. categoryId:
  1671. allOf:
  1672. - $ref: '#/StringId'
  1673. nullable: true
  1674. categoryName: {type: string, nullable: true}
  1675. parentDocumentId:
  1676. allOf:
  1677. - $ref: '#/StringId'
  1678. nullable: true
  1679. securityLevel: {$ref: '#/SecurityLevel'}
  1680. documentStatus: {$ref: '#/DocumentStatus'}
  1681. deletedAt: {$ref: '#/UtcDateTime'}
  1682. updatedBy:
  1683. allOf:
  1684. - $ref: '#/StringId'
  1685. nullable: true
  1686. updatedByName: {type: string, nullable: true}
  1687. deletedBy:
  1688. allOf:
  1689. - $ref: '#/DeletedBySnapshot'
  1690. nullable: true
  1691. rowVersion: {type: integer, minimum: 0}
  1692. RecycleBinDocumentPage:
  1693. type: object
  1694. additionalProperties: false
  1695. required: [items, page, pageSize, total, totalPages]
  1696. properties:
  1697. items:
  1698. type: array
  1699. items: {$ref: '#/RecycleBinDocumentSummary'}
  1700. page: {type: integer, minimum: 1}
  1701. pageSize: {type: integer, minimum: 1, maximum: 100}
  1702. total: {type: integer, minimum: 0}
  1703. totalPages: {type: integer, minimum: 0}
  1704. RecycleBinDocumentPageResponse:
  1705. type: object
  1706. additionalProperties: false
  1707. required: [code, message, data, requestId]
  1708. properties:
  1709. code: {type: string, enum: [OK]}
  1710. message: {type: string, enum: [success]}
  1711. data: {$ref: '#/RecycleBinDocumentPage'}
  1712. requestId: {type: string, format: uuid}
  1713. RestoreDocumentRequest:
  1714. type: object
  1715. additionalProperties: false
  1716. required: [rowVersion]
  1717. properties:
  1718. rowVersion: {type: integer, minimum: 0}
  1719. RestoredDocument:
  1720. allOf:
  1721. - $ref: '#/DocumentSummary'
  1722. - type: object
  1723. required: [originalFileName, mimeType, fileSize, permissionSummary]
  1724. properties:
  1725. originalFileName: {type: string}
  1726. mimeType: {type: string, nullable: true}
  1727. fileSize: {type: integer, minimum: 0}
  1728. permissionSummary: {$ref: '#/PermissionSummary'}
  1729. mountedPlanCount: {type: integer, minimum: 0}
  1730. RestoreDocumentResult:
  1731. type: object
  1732. additionalProperties: false
  1733. required:
  1734. - document
  1735. - restoredPermissionCount
  1736. - skippedPermissionCount
  1737. - restoredBindingCount
  1738. - skippedBindingCount
  1739. properties:
  1740. document: {$ref: '#/RestoredDocument'}
  1741. restoredPermissionCount: {type: integer, minimum: 0}
  1742. skippedPermissionCount: {type: integer, minimum: 0}
  1743. restoredBindingCount: {type: integer, minimum: 0}
  1744. skippedBindingCount: {type: integer, minimum: 0}
  1745. RestoreDocumentResponse:
  1746. type: object
  1747. additionalProperties: false
  1748. required: [code, message, data, requestId]
  1749. properties:
  1750. code: {type: string, enum: [OK]}
  1751. message: {type: string, enum: [success]}
  1752. data: {$ref: '#/RestoreDocumentResult'}
  1753. requestId: {type: string, format: uuid}
  1754. DictionaryOption:
  1755. type: object
  1756. additionalProperties: false
  1757. required: [code, label, sortNo]
  1758. properties:
  1759. code: {type: string, minLength: 1}
  1760. label: {type: string, minLength: 1}
  1761. sortNo: {type: integer, minimum: 0}
  1762. DictionaryOptionList:
  1763. type: array
  1764. items: {$ref: '#/DictionaryOption'}
  1765. UiDictionaryGroups:
  1766. type: object
  1767. additionalProperties: false
  1768. required:
  1769. - roleCodes
  1770. - allowedModules
  1771. - documentTypes
  1772. - documentStatuses
  1773. - securityLevels
  1774. - attachmentTypes
  1775. - deptScopes
  1776. - allowedActions
  1777. - categoryTypes
  1778. - enabledStatuses
  1779. - auditResults
  1780. - auditActions
  1781. - auditTargets
  1782. properties:
  1783. roleCodes: {$ref: '#/DictionaryOptionList'}
  1784. allowedModules: {$ref: '#/DictionaryOptionList'}
  1785. documentTypes: {$ref: '#/DictionaryOptionList'}
  1786. documentStatuses: {$ref: '#/DictionaryOptionList'}
  1787. securityLevels: {$ref: '#/DictionaryOptionList'}
  1788. attachmentTypes: {$ref: '#/DictionaryOptionList'}
  1789. deptScopes: {$ref: '#/DictionaryOptionList'}
  1790. allowedActions: {$ref: '#/DictionaryOptionList'}
  1791. categoryTypes: {$ref: '#/DictionaryOptionList'}
  1792. enabledStatuses: {$ref: '#/DictionaryOptionList'}
  1793. auditResults: {$ref: '#/DictionaryOptionList'}
  1794. auditActions: {$ref: '#/DictionaryOptionList'}
  1795. auditTargets: {$ref: '#/DictionaryOptionList'}
  1796. UiDictionaries:
  1797. type: object
  1798. additionalProperties: false
  1799. required: [version, locale, dictionaries]
  1800. properties:
  1801. version:
  1802. type: string
  1803. pattern: '^[0-9]{4}\.[0-9]+$'
  1804. example: '2026.1'
  1805. locale:
  1806. type: string
  1807. example: zh-CN
  1808. dictionaries: {$ref: '#/UiDictionaryGroups'}
  1809. UiDictionariesResponse:
  1810. type: object
  1811. additionalProperties: false
  1812. required: [code, message, data, requestId]
  1813. properties:
  1814. code: {type: string, enum: [OK]}
  1815. message: {type: string, enum: [success]}
  1816. data: {$ref: '#/UiDictionaries'}
  1817. requestId: {type: string, format: uuid}
  1818. CreateOrganizationRequest:
  1819. type: object
  1820. additionalProperties: false
  1821. required: [orgCode, orgName, parentId, sortNo, status]
  1822. properties:
  1823. orgCode: {type: string, minLength: 1, maxLength: 64}
  1824. orgName: {type: string, minLength: 1, maxLength: 128}
  1825. parentId:
  1826. allOf: [{$ref: '#/StringId'}]
  1827. nullable: true
  1828. sortNo: {type: integer}
  1829. status: {$ref: '#/EnabledStatus'}
  1830. UpdateOrganizationRequest:
  1831. type: object
  1832. additionalProperties: false
  1833. required: [orgName, parentId, sortNo, status, rowVersion]
  1834. properties:
  1835. orgName: {type: string, minLength: 1, maxLength: 128}
  1836. parentId:
  1837. allOf: [{$ref: '#/StringId'}]
  1838. nullable: true
  1839. sortNo: {type: integer}
  1840. status: {$ref: '#/EnabledStatus'}
  1841. rowVersion: {type: integer, minimum: 0}
  1842. OrganizationResponse:
  1843. type: object
  1844. additionalProperties: false
  1845. required: [code, message, data, requestId]
  1846. properties:
  1847. code: {type: string, enum: [OK]}
  1848. message: {type: string, enum: [success]}
  1849. data:
  1850. allOf: [{$ref: '#/OrganizationNode'}]
  1851. description: 写操作响应中children固定为空数组。
  1852. requestId: {type: string, format: uuid}
  1853. DeleteOrganizationData:
  1854. type: object
  1855. additionalProperties: false
  1856. required: [id, deleted]
  1857. properties:
  1858. id: {$ref: '#/StringId'}
  1859. deleted: {type: boolean, enum: [true]}
  1860. DeleteOrganizationResponse:
  1861. type: object
  1862. additionalProperties: false
  1863. required: [code, message, data, requestId]
  1864. properties:
  1865. code: {type: string, enum: [OK]}
  1866. message: {type: string, enum: [success]}
  1867. data: {$ref: '#/DeleteOrganizationData'}
  1868. requestId: {type: string, format: uuid}
  1869. CreateUserRequest:
  1870. type: object
  1871. additionalProperties: false
  1872. required: [username, realName, initialPassword, organizationId, roleCode, roleId, securityLevel, status]
  1873. properties:
  1874. username: {type: string, minLength: 1, maxLength: 64}
  1875. realName: {type: string, minLength: 1, maxLength: 64}
  1876. initialPassword: {type: string, format: password, minLength: 8, maxLength: 64, writeOnly: true}
  1877. organizationId:
  1878. allOf: [{$ref: '#/StringId'}]
  1879. nullable: true
  1880. roleCode: {$ref: '#/RoleCode'}
  1881. roleId:
  1882. allOf: [{$ref: '#/StringId'}]
  1883. nullable: true
  1884. securityLevel: {$ref: '#/SecurityLevel'}
  1885. status: {$ref: '#/EnabledStatus'}
  1886. managedOrgId:
  1887. type: string
  1888. nullable: true
  1889. description: 用户级管理范围(契约1.30,可选);null=全局、机构ID=固定锚点(须指向未删除机构)。省略或"SELF"时跟随该用户所在机构(落库哨兵0)。
  1890. UpdateUiThemeRequest:
  1891. type: object
  1892. additionalProperties: false
  1893. required: [uiTheme]
  1894. properties:
  1895. uiTheme: {type: string, enum: [blue, red, green]}
  1896. UpdateUserRequest:
  1897. type: object
  1898. additionalProperties: false
  1899. required: [realName, organizationId, roleCode, roleId, securityLevel, status, rowVersion]
  1900. properties:
  1901. realName: {type: string, minLength: 1, maxLength: 64}
  1902. organizationId:
  1903. allOf: [{$ref: '#/StringId'}]
  1904. nullable: true
  1905. roleCode: {$ref: '#/RoleCode'}
  1906. roleId:
  1907. allOf: [{$ref: '#/StringId'}]
  1908. nullable: true
  1909. securityLevel: {$ref: '#/SecurityLevel'}
  1910. status: {$ref: '#/EnabledStatus'}
  1911. managedOrgId:
  1912. type: string
  1913. nullable: true
  1914. description: 用户级管理范围(契约1.30,可选);null=全局、机构ID=固定锚点(须指向未删除机构)、"SELF"=跟随该用户所在机构(落库哨兵0)。省略时保持原值不变。
  1915. rowVersion: {type: integer, minimum: 0}
  1916. DeleteUserData:
  1917. type: object
  1918. additionalProperties: false
  1919. required: [id, deleted]
  1920. properties:
  1921. id: {$ref: '#/StringId'}
  1922. deleted: {type: boolean, enum: [true]}
  1923. DeleteUserResponse:
  1924. type: object
  1925. additionalProperties: false
  1926. required: [code, message, data, requestId]
  1927. properties:
  1928. code: {type: string, enum: [OK]}
  1929. message: {type: string, enum: [success]}
  1930. data: {$ref: '#/DeleteUserData'}
  1931. requestId: {type: string, format: uuid}
  1932. ResetUserPasswordRequest:
  1933. type: object
  1934. additionalProperties: false
  1935. required: [newPassword, rowVersion]
  1936. properties:
  1937. newPassword: {type: string, format: password, minLength: 8, maxLength: 64, writeOnly: true}
  1938. rowVersion: {type: integer, minimum: 0}
  1939. ResetPasswordData:
  1940. type: object
  1941. additionalProperties: false
  1942. required: [id, reset, authVersion]
  1943. properties:
  1944. id: {$ref: '#/StringId'}
  1945. reset: {type: boolean, enum: [true]}
  1946. authVersion: {type: integer, minimum: 0}
  1947. ResetPasswordResponse:
  1948. type: object
  1949. additionalProperties: false
  1950. required: [code, message, data, requestId]
  1951. properties:
  1952. code: {type: string, enum: [OK]}
  1953. message: {type: string, enum: [success]}
  1954. data: {$ref: '#/ResetPasswordData'}
  1955. requestId: {type: string, format: uuid}
  1956. DocumentTagCollection:
  1957. type: object
  1958. additionalProperties: false
  1959. required: [items, total]
  1960. properties:
  1961. items:
  1962. type: array
  1963. items: {type: string}
  1964. description: 当前用户可见的主案标签,按Unicode升序。
  1965. total: {type: integer, minimum: 0}
  1966. DocumentTagsResponse:
  1967. type: object
  1968. additionalProperties: false
  1969. required: [code, message, data, requestId]
  1970. properties:
  1971. code: {type: string, enum: [OK]}
  1972. message: {type: string, enum: [success]}
  1973. data: {$ref: '#/DocumentTagCollection'}
  1974. requestId: {type: string, format: uuid}
  1975. DeptScope:
  1976. type: string
  1977. description: 权限矩阵部门范围:所属部门方案/其他部门方案(其他部门含所属部门子树外全部部门与无归属文档)。
  1978. enum: [OWN, OTHER]
  1979. RoleSummary:
  1980. type: object
  1981. additionalProperties: false
  1982. required: [id, roleName, sortNo, status, remark, isDefault, manageCategoryEdit, manageOrgEdit, manageUserEdit, manageSystemManage, manageAuditLog, manageRoleEdit, managedOrgId, memberCount, rowVersion]
  1983. properties:
  1984. id: {$ref: '#/StringId'}
  1985. roleName: {type: string, maxLength: 64}
  1986. sortNo: {type: integer, minimum: 0, maximum: 999999}
  1987. status: {$ref: '#/EnabledStatus'}
  1988. remark:
  1989. type: string
  1990. nullable: true
  1991. maxLength: 255
  1992. isDefault: {type: boolean}
  1993. manageCategoryEdit: {type: boolean, description: 分类编辑管理位(仅对ADMIN类别用户生效)}
  1994. manageOrgEdit: {type: boolean, description: 机构编辑管理位(仅对ADMIN类别用户生效)}
  1995. manageUserEdit: {type: boolean, description: 用户编辑管理位(仅对ADMIN类别用户生效)}
  1996. manageSystemManage: {type: boolean, description: 系统管理管理位(契约1.23,仅对ADMIN类别用户生效)}
  1997. manageAuditLog: {type: boolean, description: 日志审计管理位(契约1.23,仅对ADMIN类别用户生效)}
  1998. manageRoleEdit: {type: boolean, description: 角色编辑管理位(契约1.25,仅对ADMIN类别用户生效,全局生效不受锚点约束)}
  1999. managedOrgId:
  2000. type: string
  2001. nullable: true
  2002. description: 管理范围锚点(契约1.30);机构ID、"SELF"(跟随用户的管理范围设置,落库哨兵0)或null(全局)。
  2003. memberCount: {type: integer, minimum: 0}
  2004. rowVersion: {type: integer, minimum: 0}
  2005. RolePage:
  2006. type: object
  2007. additionalProperties: false
  2008. required: [items, page, pageSize, total, totalPages]
  2009. properties:
  2010. items:
  2011. type: array
  2012. items:
  2013. $ref: '#/RoleSummary'
  2014. page:
  2015. type: integer
  2016. minimum: 1
  2017. pageSize:
  2018. type: integer
  2019. minimum: 1
  2020. maximum: 100
  2021. total:
  2022. type: integer
  2023. minimum: 0
  2024. totalPages:
  2025. type: integer
  2026. minimum: 0
  2027. RolePageResponse:
  2028. type: object
  2029. additionalProperties: false
  2030. required: [code, message, data, requestId]
  2031. properties:
  2032. code: {type: string, enum: [OK]}
  2033. message: {type: string, enum: [success]}
  2034. data: {$ref: '#/RolePage'}
  2035. requestId: {type: string, format: uuid}
  2036. CreateRoleRequest:
  2037. type: object
  2038. additionalProperties: false
  2039. required: [roleName, sortNo, status, remark, isDefault, manageCategoryEdit, manageOrgEdit, manageUserEdit, manageSystemManage, manageAuditLog, manageRoleEdit, managedOrgId]
  2040. properties:
  2041. roleName: {type: string, minLength: 1, maxLength: 64}
  2042. sortNo: {type: integer, minimum: 0, maximum: 999999}
  2043. status: {$ref: '#/EnabledStatus'}
  2044. remark:
  2045. type: string
  2046. nullable: true
  2047. maxLength: 255
  2048. isDefault: {type: boolean}
  2049. manageCategoryEdit: {type: boolean}
  2050. manageOrgEdit: {type: boolean}
  2051. manageUserEdit: {type: boolean}
  2052. manageSystemManage: {type: boolean}
  2053. manageAuditLog: {type: boolean}
  2054. manageRoleEdit: {type: boolean}
  2055. managedOrgId:
  2056. type: string
  2057. nullable: true
  2058. description: 管理范围锚点(契约1.30);机构ID、"SELF"(跟随用户的管理范围设置,落库哨兵0)或null/空串(全局),机构ID须指向未删除机构。
  2059. UpdateRoleRequest:
  2060. type: object
  2061. additionalProperties: false
  2062. required: [roleName, sortNo, status, remark, isDefault, manageCategoryEdit, manageOrgEdit, manageUserEdit, manageSystemManage, manageAuditLog, manageRoleEdit, managedOrgId, rowVersion]
  2063. properties:
  2064. roleName: {type: string, minLength: 1, maxLength: 64}
  2065. sortNo: {type: integer, minimum: 0, maximum: 999999}
  2066. status: {$ref: '#/EnabledStatus'}
  2067. remark:
  2068. type: string
  2069. nullable: true
  2070. maxLength: 255
  2071. isDefault: {type: boolean}
  2072. manageCategoryEdit: {type: boolean}
  2073. manageOrgEdit: {type: boolean}
  2074. manageUserEdit: {type: boolean}
  2075. manageSystemManage: {type: boolean}
  2076. manageAuditLog: {type: boolean}
  2077. manageRoleEdit: {type: boolean}
  2078. managedOrgId:
  2079. type: string
  2080. nullable: true
  2081. description: 管理范围锚点(契约1.30);机构ID、"SELF"(跟随用户的管理范围设置,落库哨兵0)或null/空串(全局),机构ID须指向未删除机构。
  2082. rowVersion: {type: integer, minimum: 0}
  2083. RoleResponse:
  2084. type: object
  2085. additionalProperties: false
  2086. required: [code, message, data, requestId]
  2087. properties:
  2088. code: {type: string, enum: [OK]}
  2089. message: {type: string, enum: [success]}
  2090. data: {$ref: '#/RoleSummary'}
  2091. requestId: {type: string, format: uuid}
  2092. DeleteRoleData:
  2093. type: object
  2094. additionalProperties: false
  2095. required: [id, deleted]
  2096. properties:
  2097. id: {$ref: '#/StringId'}
  2098. deleted: {type: boolean, enum: [true]}
  2099. DeleteRoleResponse:
  2100. type: object
  2101. additionalProperties: false
  2102. required: [code, message, data, requestId]
  2103. properties:
  2104. code: {type: string, enum: [OK]}
  2105. message: {type: string, enum: [success]}
  2106. data: {$ref: '#/DeleteRoleData'}
  2107. requestId: {type: string, format: uuid}
  2108. RolePermissionRow:
  2109. type: object
  2110. additionalProperties: false
  2111. required: [securityLevel, deptScope, canView, canUpload, canDownload, canEdit, canDelete, canConfigPermission, canBindAttachment, canUnbindAttachment]
  2112. properties:
  2113. securityLevel: {$ref: '#/SecurityLevel'}
  2114. deptScope: {$ref: '#/DeptScope'}
  2115. canView: {type: boolean}
  2116. canUpload:
  2117. type: boolean
  2118. description: 上传位(契约1.31);仅 OWN 行有意义,OTHER 行恒为 false,服务端提交校验拒收 OTHER 行为 true 的载荷。
  2119. canDownload: {type: boolean}
  2120. canEdit: {type: boolean}
  2121. canDelete: {type: boolean}
  2122. canConfigPermission: {type: boolean}
  2123. canBindAttachment: {type: boolean}
  2124. canUnbindAttachment: {type: boolean}
  2125. RoleMatrixListResponse:
  2126. type: object
  2127. additionalProperties: false
  2128. required: [code, message, data, requestId]
  2129. properties:
  2130. code: {type: string, enum: [OK]}
  2131. message: {type: string, enum: [success]}
  2132. data:
  2133. type: array
  2134. minItems: 15
  2135. maxItems: 15
  2136. items:
  2137. $ref: '#/RolePermissionRow'
  2138. requestId: {type: string, format: uuid}
  2139. UpdateRolePermissionsRequest:
  2140. type: object
  2141. additionalProperties: false
  2142. required: [matrix, rowVersion]
  2143. properties:
  2144. matrix:
  2145. type: array
  2146. minItems: 15
  2147. maxItems: 15
  2148. items:
  2149. $ref: '#/RolePermissionRow'
  2150. rowVersion: {type: integer, minimum: 0}
  2151. RolePermissionsData:
  2152. type: object
  2153. additionalProperties: false
  2154. required: [id, matrix, rowVersion]
  2155. properties:
  2156. id: {$ref: '#/StringId'}
  2157. matrix:
  2158. type: array
  2159. minItems: 15
  2160. maxItems: 15
  2161. items:
  2162. $ref: '#/RolePermissionRow'
  2163. rowVersion: {type: integer, minimum: 0}
  2164. RolePermissionsResponse:
  2165. type: object
  2166. additionalProperties: false
  2167. required: [code, message, data, requestId]
  2168. properties:
  2169. code: {type: string, enum: [OK]}
  2170. message: {type: string, enum: [success]}
  2171. data: {$ref: '#/RolePermissionsData'}
  2172. requestId: {type: string, format: uuid}
  2173. RoleUsersData:
  2174. type: object
  2175. additionalProperties: false
  2176. required: [id, userIds]
  2177. properties:
  2178. id: {$ref: '#/StringId'}
  2179. userIds:
  2180. type: array
  2181. items: {$ref: '#/StringId'}
  2182. uniqueItems: true
  2183. rowVersion: {type: integer, minimum: 0}
  2184. RoleUsersResponse:
  2185. type: object
  2186. additionalProperties: false
  2187. required: [code, message, data, requestId]
  2188. properties:
  2189. code: {type: string, enum: [OK]}
  2190. message: {type: string, enum: [success]}
  2191. data: {$ref: '#/RoleUsersData'}
  2192. requestId: {type: string, format: uuid}
  2193. UpdateRoleUsersRequest:
  2194. type: object
  2195. additionalProperties: false
  2196. required: [userIds, rowVersion]
  2197. properties:
  2198. userIds:
  2199. type: array
  2200. items: {$ref: '#/StringId'}
  2201. uniqueItems: true
  2202. rowVersion: {type: integer, minimum: 0}
  2203. DocumentRelationPreset:
  2204. type: object
  2205. additionalProperties: false
  2206. required: [code, label, sortNo]
  2207. properties:
  2208. code: {type: string, minLength: 1, description: 预置类型稳定编码(仅用于前端下拉匹配,不落库)}
  2209. label: {type: string, minLength: 1, description: 预置关系文本(保存时直接写入relation_type)}
  2210. sortNo: {type: integer, minimum: 0}
  2211. DocumentMoveRequest:
  2212. type: object
  2213. additionalProperties: false
  2214. description: targetPosition与target二选一(非法组合返回400);主案可携带scopeCategoryId(分类子树语义),配套方案携带返回400。
  2215. properties:
  2216. targetPosition: {type: integer, minimum: 1}
  2217. target: {type: string, enum: [TOP, BOTTOM]}
  2218. scopeCategoryId: {$ref: '#/StringId'}
  2219. DocumentMoveResult:
  2220. type: object
  2221. additionalProperties: false
  2222. required: [position, total]
  2223. properties:
  2224. position: {type: integer, minimum: 1}
  2225. total: {type: integer, minimum: 0}
  2226. DocumentMoveResponse:
  2227. type: object
  2228. additionalProperties: false
  2229. required: [code, message, data, requestId]
  2230. properties:
  2231. code: {type: string, enum: [OK]}
  2232. message: {type: string, enum: [success]}
  2233. data: {$ref: '#/DocumentMoveResult'}
  2234. requestId: {type: string, format: uuid}
  2235. AttachmentMoveRequest:
  2236. type: object
  2237. additionalProperties: false
  2238. required: [mainPlanRowVersion]
  2239. description: targetPosition与target二选一(非法组合返回400);scopeAttachmentType限定页签类型范围。
  2240. properties:
  2241. mainPlanRowVersion: {type: integer, minimum: 0}
  2242. targetPosition: {type: integer, minimum: 1}
  2243. target: {type: string, enum: [TOP, BOTTOM]}
  2244. scopeAttachmentType: {$ref: '#/AttachmentType'}
  2245. AttachmentMoveResult:
  2246. type: object
  2247. additionalProperties: false
  2248. required: [position, total, mainPlanRowVersion]
  2249. properties:
  2250. position: {type: integer, minimum: 1}
  2251. total: {type: integer, minimum: 0}
  2252. mainPlanRowVersion: {type: integer, minimum: 0}
  2253. AttachmentMoveResponse:
  2254. type: object
  2255. additionalProperties: false
  2256. required: [code, message, data, requestId]
  2257. properties:
  2258. code: {type: string, enum: [OK]}
  2259. message: {type: string, enum: [success]}
  2260. data: {$ref: '#/AttachmentMoveResult'}
  2261. requestId: {type: string, format: uuid}
  2262. DocumentRelationPresetsResponse:
  2263. type: object
  2264. additionalProperties: false
  2265. required: [code, message, data, requestId]
  2266. properties:
  2267. code: {type: string, enum: [OK]}
  2268. message: {type: string, enum: [success]}
  2269. data:
  2270. type: object
  2271. additionalProperties: false
  2272. required: [presets]
  2273. properties:
  2274. presets:
  2275. type: array
  2276. items: {$ref: '#/DocumentRelationPreset'}
  2277. requestId: {type: string, format: uuid}
  2278. DocumentRelationItem:
  2279. type: object
  2280. additionalProperties: false
  2281. required: [relatedDocumentId, relatedDocumentName, relationType]
  2282. properties:
  2283. relatedDocumentId: {$ref: '#/StringId'}
  2284. relatedDocumentName: {type: string, minLength: 1}
  2285. relationType: {type: string, minLength: 1, maxLength: 64, description: 关系文本(预置label或用户自定义)}
  2286. DocumentRelationsResponse:
  2287. type: object
  2288. additionalProperties: false
  2289. required: [code, message, data, requestId]
  2290. properties:
  2291. code: {type: string, enum: [OK]}
  2292. message: {type: string, enum: [success]}
  2293. data:
  2294. type: object
  2295. additionalProperties: false
  2296. required: [items]
  2297. properties:
  2298. items:
  2299. type: array
  2300. items: {$ref: '#/DocumentRelationItem'}
  2301. requestId: {type: string, format: uuid}
  2302. UpdateDocumentRelationsRequest:
  2303. type: object
  2304. additionalProperties: false
  2305. required: [relations, rowVersion]
  2306. properties:
  2307. relations:
  2308. type: array
  2309. maxItems: 50
  2310. items:
  2311. type: object
  2312. additionalProperties: false
  2313. required: [relatedDocumentId, relationType]
  2314. properties:
  2315. relatedDocumentId: {$ref: '#/StringId'}
  2316. relationType: {type: string, minLength: 1, maxLength: 64}
  2317. uniqueItems: true
  2318. rowVersion: {type: integer, minimum: 0}
  2319. DocumentRelationsSaveResponse:
  2320. type: object
  2321. additionalProperties: false
  2322. required: [code, message, data, requestId]
  2323. properties:
  2324. code: {type: string, enum: [OK]}
  2325. message: {type: string, enum: [success]}
  2326. data:
  2327. type: object
  2328. additionalProperties: false
  2329. required: [relations, rowVersion]
  2330. properties:
  2331. relations:
  2332. type: array
  2333. items: {$ref: '#/DocumentRelationItem'}
  2334. rowVersion: {type: integer, minimum: 0}
  2335. requestId: {type: string, format: uuid}
  2336. IpEntrySummary:
  2337. type: object
  2338. additionalProperties: false
  2339. required: [id, ipValue, remark, rowVersion]
  2340. properties:
  2341. id: {$ref: '#/StringId'}
  2342. ipValue:
  2343. type: string
  2344. minLength: 1
  2345. maxLength: 64
  2346. description: 规范化后的精确IP、CIDR网段或IP范围文本(IPv6为压缩形式,网段主机位为0,范围为「起-止」两端同版本且起≤止)。
  2347. remark:
  2348. type: string
  2349. maxLength: 128
  2350. rowVersion: {type: integer, minimum: 0}
  2351. IpEntryPage:
  2352. type: object
  2353. additionalProperties: false
  2354. required: [items, page, pageSize, total, totalPages]
  2355. properties:
  2356. items:
  2357. type: array
  2358. items:
  2359. $ref: '#/IpEntrySummary'
  2360. page:
  2361. type: integer
  2362. minimum: 1
  2363. pageSize:
  2364. type: integer
  2365. minimum: 1
  2366. maximum: 100
  2367. total:
  2368. type: integer
  2369. minimum: 0
  2370. totalPages:
  2371. type: integer
  2372. minimum: 0
  2373. IpEntryPageResponse:
  2374. type: object
  2375. additionalProperties: false
  2376. required: [code, message, data, requestId]
  2377. properties:
  2378. code: {type: string, enum: [OK]}
  2379. message: {type: string, enum: [success]}
  2380. data: {$ref: '#/IpEntryPage'}
  2381. requestId: {type: string, format: uuid}
  2382. CreateIpEntryRequest:
  2383. type: object
  2384. additionalProperties: false
  2385. required: [ipValue, remark]
  2386. properties:
  2387. ipValue: {type: string, minLength: 1, maxLength: 64}
  2388. remark: {type: string, maxLength: 128}
  2389. UpdateIpEntryRequest:
  2390. type: object
  2391. additionalProperties: false
  2392. required: [ipValue, remark, rowVersion]
  2393. properties:
  2394. ipValue: {type: string, minLength: 1, maxLength: 64}
  2395. remark: {type: string, maxLength: 128}
  2396. rowVersion: {type: integer, minimum: 0}
  2397. IpEntryResponse:
  2398. type: object
  2399. additionalProperties: false
  2400. required: [code, message, data, requestId]
  2401. properties:
  2402. code: {type: string, enum: [OK]}
  2403. message: {type: string, enum: [success]}
  2404. data: {$ref: '#/IpEntrySummary'}
  2405. requestId: {type: string, format: uuid}
  2406. DeleteIpEntryData:
  2407. type: object
  2408. additionalProperties: false
  2409. required: [id, deleted]
  2410. properties:
  2411. id: {$ref: '#/StringId'}
  2412. deleted: {type: boolean, enum: [true]}
  2413. DeleteIpEntryResponse:
  2414. type: object
  2415. additionalProperties: false
  2416. required: [code, message, data, requestId]
  2417. properties:
  2418. code: {type: string, enum: [OK]}
  2419. message: {type: string, enum: [success]}
  2420. data: {$ref: '#/DeleteIpEntryData'}
  2421. requestId: {type: string, format: uuid}
  2422. OrgIpAssignmentListData:
  2423. type: object
  2424. additionalProperties: false
  2425. required: [ipEntryIds]
  2426. properties:
  2427. ipEntryIds:
  2428. type: array
  2429. items: {$ref: '#/StringId'}
  2430. uniqueItems: true
  2431. OrgIpAssignmentListResponse:
  2432. type: object
  2433. additionalProperties: false
  2434. required: [code, message, data, requestId]
  2435. properties:
  2436. code: {type: string, enum: [OK]}
  2437. message: {type: string, enum: [success]}
  2438. data: {$ref: '#/OrgIpAssignmentListData'}
  2439. requestId: {type: string, format: uuid}
  2440. UpdateOrgIpAssignmentsRequest:
  2441. type: object
  2442. additionalProperties: false
  2443. required: [ipEntryIds, rowVersion]
  2444. properties:
  2445. ipEntryIds:
  2446. type: array
  2447. items: {$ref: '#/StringId'}
  2448. uniqueItems: true
  2449. rowVersion: {type: integer, minimum: 0}
  2450. OrgIpAssignmentsData:
  2451. type: object
  2452. additionalProperties: false
  2453. required: [id, ipEntryIds, rowVersion]
  2454. properties:
  2455. id: {$ref: '#/StringId'}
  2456. ipEntryIds:
  2457. type: array
  2458. items: {$ref: '#/StringId'}
  2459. uniqueItems: true
  2460. rowVersion: {type: integer, minimum: 0}
  2461. OrgIpAssignmentsResponse:
  2462. type: object
  2463. additionalProperties: false
  2464. required: [code, message, data, requestId]
  2465. properties:
  2466. code: {type: string, enum: [OK]}
  2467. message: {type: string, enum: [success]}
  2468. data: {$ref: '#/OrgIpAssignmentsData'}
  2469. requestId: {type: string, format: uuid}
  2470. BackupTargetMode:
  2471. type: string
  2472. enum: [LOCAL, RSYNC]
  2473. description: 备份目标模式:LOCAL 本机目录(开发/单机),RSYNC rsync守护进程异机传输。
  2474. BackupTypeCode:
  2475. type: string
  2476. enum: [FULL, INCREMENTAL]
  2477. BackupTrigger:
  2478. type: string
  2479. enum: [MANUAL, SCHEDULE]
  2480. BackupPhase:
  2481. type: string
  2482. description: 备份任务阶段;null表示从未运行过任何任务。
  2483. enum: [SCANNING, EXPORTING_DB, COPYING, PUSHING, CLEANING, SUCCESS, FAILED]
  2484. BackupConfigView:
  2485. type: object
  2486. additionalProperties: false
  2487. required: [target_mode, local_path, rsync_url, schedule_enabled, schedule_time, full_interval_days, retain_full_count, rsync_password_set]
  2488. properties:
  2489. target_mode: {$ref: '#/BackupTargetMode'}
  2490. local_path: {type: string, maxLength: 1024, description: LOCAL模式的备份根目录;未配置为空串。}
  2491. rsync_url: {type: string, maxLength: 1024, description: RSYNC模式目标地址 rsync://user@host:873/module/;未配置为空串。}
  2492. schedule_enabled: {type: boolean, description: 定时备份开关。}
  2493. schedule_time: {type: string, pattern: '^([01][0-9]|2[0-3]):[0-5][0-9]$', description: 每日触发时刻(HH:MM,业务时区)。}
  2494. full_interval_days: {type: integer, minimum: 1, maximum: 365, description: 定时任务距最近全量超过该天数时自动升级为全量。}
  2495. retain_full_count: {type: integer, minimum: 1, maximum: 100, description: 保留的完整备份链数量;超出部分从最旧链开始清理。}
  2496. rsync_password_set: {type: boolean, description: rsync密码是否已设置;密码永不回显明文。}
  2497. UpdateBackupConfigRequest:
  2498. type: object
  2499. additionalProperties: false
  2500. required: [target_mode, local_path, rsync_url, rsync_password, schedule_enabled, schedule_time, full_interval_days, retain_full_count]
  2501. properties:
  2502. target_mode: {$ref: '#/BackupTargetMode'}
  2503. local_path: {type: string, nullable: true, maxLength: 1024}
  2504. rsync_url: {type: string, nullable: true, maxLength: 1024}
  2505. rsync_password:
  2506. type: string
  2507. nullable: true
  2508. maxLength: 256
  2509. writeOnly: true
  2510. description: rsync密码;null或空串表示保持已存密码不变(回显永不回明文)。
  2511. schedule_enabled: {type: boolean}
  2512. schedule_time: {type: string, pattern: '^([01][0-9]|2[0-3]):[0-5][0-9]$'}
  2513. full_interval_days: {type: integer, minimum: 1, maximum: 365}
  2514. retain_full_count: {type: integer, minimum: 1, maximum: 100}
  2515. BackupConfigResponse:
  2516. type: object
  2517. additionalProperties: false
  2518. required: [code, message, data, requestId]
  2519. properties:
  2520. code: {type: string, enum: [OK]}
  2521. message: {type: string, enum: [success]}
  2522. data: {$ref: '#/BackupConfigView'}
  2523. requestId: {type: string, format: uuid}
  2524. BackupJobStartRequest:
  2525. type: object
  2526. additionalProperties: false
  2527. required: [type]
  2528. properties:
  2529. type:
  2530. allOf: [{$ref: '#/BackupTypeCode'}]
  2531. description: INCREMENTAL无可用全量链时服务端自动升级为FULL。
  2532. BackupProgress:
  2533. type: object
  2534. additionalProperties: false
  2535. required: [backupId, type, trigger, phase, bytesTotal, bytesCopied, filesTotal, filesCopied, pushPercent, error, startedAt, finishedAt]
  2536. properties:
  2537. backupId:
  2538. type: string
  2539. nullable: true
  2540. description: 备份ID,形如 dms-bak-yyyyMMdd-HHmmss-F/-I;从未运行时为null。
  2541. type:
  2542. allOf: [{$ref: '#/BackupTypeCode'}]
  2543. nullable: true
  2544. trigger:
  2545. allOf: [{$ref: '#/BackupTrigger'}]
  2546. nullable: true
  2547. phase:
  2548. allOf: [{$ref: '#/BackupPhase'}]
  2549. nullable: true
  2550. bytesTotal: {type: integer, minimum: 0, description: 待传输字节总量(扫描/拷贝阶段累计)。}
  2551. bytesCopied: {type: integer, minimum: 0}
  2552. filesTotal: {type: integer, minimum: 0}
  2553. filesCopied: {type: integer, minimum: 0}
  2554. pushPercent:
  2555. type: integer
  2556. minimum: 0
  2557. maximum: 100
  2558. nullable: true
  2559. description: rsync整体推送进度百分比;仅RSYNC模式PUSHING阶段有值。
  2560. error:
  2561. type: string
  2562. nullable: true
  2563. description: 失败原因;仅FAILED阶段非null。
  2564. startedAt:
  2565. type: string
  2566. nullable: true
  2567. description: 开始时间(业务时区本地时间,yyyy-MM-dd HH:mm:ss,非UTC)。
  2568. finishedAt:
  2569. type: string
  2570. nullable: true
  2571. description: 结束时间(业务时区本地时间,yyyy-MM-dd HH:mm:ss,非UTC)。
  2572. BackupJobStartResponse:
  2573. type: object
  2574. additionalProperties: false
  2575. required: [code, message, data, requestId]
  2576. properties:
  2577. code: {type: string, enum: [OK]}
  2578. message: {type: string, enum: [success]}
  2579. data: {$ref: '#/BackupProgress'}
  2580. requestId: {type: string, format: uuid}
  2581. BackupCurrentJob:
  2582. allOf:
  2583. - $ref: '#/BackupProgress'
  2584. - type: object
  2585. required: [running]
  2586. properties:
  2587. running: {type: boolean, description: 当前是否有备份任务在执行。}
  2588. BackupJobCurrentResponse:
  2589. type: object
  2590. additionalProperties: false
  2591. required: [code, message, data, requestId]
  2592. properties:
  2593. code: {type: string, enum: [OK]}
  2594. message: {type: string, enum: [success]}
  2595. data: {$ref: '#/BackupCurrentJob'}
  2596. requestId: {type: string, format: uuid}
  2597. BackupCancelData:
  2598. type: object
  2599. additionalProperties: false
  2600. required: [canceled]
  2601. properties:
  2602. canceled: {type: boolean, description: 请求取消时是否存在运行中的任务。}
  2603. BackupCancelResponse:
  2604. type: object
  2605. additionalProperties: false
  2606. required: [code, message, data, requestId]
  2607. properties:
  2608. code: {type: string, enum: [OK]}
  2609. message: {type: string, enum: [success]}
  2610. data: {$ref: '#/BackupCancelData'}
  2611. requestId: {type: string, format: uuid}
  2612. BackupHistoryEntry:
  2613. type: object
  2614. additionalProperties: false
  2615. required: [id, type, parent, started_at, finished_at, database_file, database_size, transferred_files, transferred_bytes, storage_file_count, storage_total_bytes]
  2616. properties:
  2617. id: {type: string, description: 备份ID dms-bak-yyyyMMdd-HHmmss-F(全量)/-I(增量)。}
  2618. type: {$ref: '#/BackupTypeCode'}
  2619. parent:
  2620. type: string
  2621. nullable: true
  2622. description: 增量备份的前驱备份ID;全量为null。
  2623. started_at: {type: string, description: 开始时间(业务时区本地时间,yyyy-MM-dd HH:mm:ss)。}
  2624. finished_at: {type: string, description: 结束时间(业务时区本地时间,yyyy-MM-dd HH:mm:ss)。}
  2625. database_file: {type: string, description: 数据库导出文件在备份包内的相对路径。}
  2626. database_size: {type: integer, minimum: 0, description: 数据库导出文件字节数。}
  2627. transferred_files: {type: integer, minimum: 0, description: 本次实际传输的存储文件数(全量为全部,增量为差异)。}
  2628. transferred_bytes: {type: integer, minimum: 0}
  2629. storage_file_count: {type: integer, minimum: 0, description: 合并清单中的存储文件总数(链尾累计口径)。}
  2630. storage_total_bytes: {type: integer, minimum: 0}
  2631. BackupHistoryData:
  2632. type: object
  2633. additionalProperties: false
  2634. required: [entries]
  2635. properties:
  2636. entries:
  2637. type: array
  2638. items: {$ref: '#/BackupHistoryEntry'}
  2639. description: 按备份ID升序(即时间升序)排列。
  2640. BackupHistoryResponse:
  2641. type: object
  2642. additionalProperties: false
  2643. required: [code, message, data, requestId]
  2644. properties:
  2645. code: {type: string, enum: [OK]}
  2646. message: {type: string, enum: [success]}
  2647. data: {$ref: '#/BackupHistoryData'}
  2648. requestId: {type: string, format: uuid}
  2649. SystemCpuSnapshot:
  2650. type: object
  2651. additionalProperties: false
  2652. required: [percent, coreCount, loadAvgOneMinute]
  2653. properties:
  2654. percent: {type: number, minimum: 0, maximum: 100, description: CPU 总占用百分比(0.3 秒采样窗口)。}
  2655. coreCount: {type: integer, minimum: 0, description: 逻辑核数。}
  2656. loadAvgOneMinute:
  2657. type: number
  2658. nullable: true
  2659. description: 1 分钟平均负载(仅 POSIX,Windows 为 null)。
  2660. SystemMemorySnapshot:
  2661. type: object
  2662. additionalProperties: false
  2663. required: [totalBytes, usedBytes, availableBytes, usedPercent]
  2664. properties:
  2665. totalBytes: {type: integer, minimum: 0}
  2666. usedBytes: {type: integer, minimum: 0}
  2667. availableBytes: {type: integer, minimum: 0}
  2668. usedPercent: {type: number, minimum: 0, maximum: 100}
  2669. SystemSwapSnapshot:
  2670. type: object
  2671. additionalProperties: false
  2672. required: [totalBytes, usedBytes, usedPercent]
  2673. properties:
  2674. totalBytes: {type: integer, minimum: 0}
  2675. usedBytes: {type: integer, minimum: 0}
  2676. usedPercent: {type: number, minimum: 0, maximum: 100}
  2677. SystemDiskSnapshot:
  2678. type: object
  2679. additionalProperties: false
  2680. required: [device, mountpoint, fstype, totalBytes, usedBytes, freeBytes, usedPercent]
  2681. properties:
  2682. device: {type: string, description: 设备名。}
  2683. mountpoint: {type: string, description: 挂载点。}
  2684. fstype: {type: string, description: 文件系统类型。}
  2685. totalBytes: {type: integer, minimum: 0}
  2686. usedBytes: {type: integer, minimum: 0}
  2687. freeBytes: {type: integer, minimum: 0}
  2688. usedPercent: {type: number, minimum: 0, maximum: 100}
  2689. SystemMetricsCurrentData:
  2690. type: object
  2691. additionalProperties: false
  2692. required: [cpu, memory, swap, disks, bootAt]
  2693. properties:
  2694. cpu: {$ref: '#/SystemCpuSnapshot'}
  2695. memory: {$ref: '#/SystemMemorySnapshot'}
  2696. swap: {$ref: '#/SystemSwapSnapshot'}
  2697. disks:
  2698. type: array
  2699. items: {$ref: '#/SystemDiskSnapshot'}
  2700. description: 物理磁盘分区占用(不可读分区跳过)。
  2701. bootAt: {type: string, description: 开机时间(UTC,毫秒精度 Z 结尾)。}
  2702. SystemMetricsCurrentResponse:
  2703. type: object
  2704. additionalProperties: false
  2705. required: [code, message, data, requestId]
  2706. properties:
  2707. code: {type: string, enum: [OK]}
  2708. message: {type: string, enum: [success]}
  2709. data: {$ref: '#/SystemMetricsCurrentData'}
  2710. requestId: {type: string, format: uuid}
  2711. SystemMetricHistoryEntry:
  2712. type: object
  2713. additionalProperties: false
  2714. required: [sampledAt, cpuPercent, memUsedBytes, memTotalBytes]
  2715. properties:
  2716. sampledAt: {type: string, description: 采样时间(UTC,毫秒精度 Z 结尾)。}
  2717. cpuPercent:
  2718. type: number
  2719. nullable: true
  2720. description: CPU 百分比(采集失败为 null)。
  2721. memUsedBytes: {type: integer, minimum: 0}
  2722. memTotalBytes: {type: integer, minimum: 0}
  2723. SystemMetricHistoryData:
  2724. type: object
  2725. additionalProperties: false
  2726. required: [hours, entries]
  2727. properties:
  2728. hours: {type: integer, minimum: 1, description: 查询窗口小时数。}
  2729. entries:
  2730. type: array
  2731. items: {$ref: '#/SystemMetricHistoryEntry'}
  2732. description: 按时间升序排列。
  2733. SystemMetricHistoryResponse:
  2734. type: object
  2735. additionalProperties: false
  2736. required: [code, message, data, requestId]
  2737. properties:
  2738. code: {type: string, enum: [OK]}
  2739. message: {type: string, enum: [success]}
  2740. data: {$ref: '#/SystemMetricHistoryData'}
  2741. requestId: {type: string, format: uuid}
  2742. SystemProcessData:
  2743. type: object
  2744. additionalProperties: false
  2745. required: [pid, cpuPercent, memoryRssBytes, memoryVmsBytes, threadCount, startedAt, uptimeSeconds, pythonVersion]
  2746. properties:
  2747. pid: {type: integer, minimum: 1}
  2748. cpuPercent: {type: number, description: 进程 CPU 占用(按核数归一后的百分比)。}
  2749. memoryRssBytes: {type: integer, minimum: 0, description: 常驻内存。}
  2750. memoryVmsBytes: {type: integer, minimum: 0, description: 虚拟内存。}
  2751. threadCount: {type: integer, minimum: 1}
  2752. startedAt: {type: string, description: 进程启动时间(UTC,毫秒精度 Z 结尾)。}
  2753. uptimeSeconds: {type: integer, minimum: 0}
  2754. pythonVersion: {type: string, description: 运行时版本(Java 版返回 JDK 版本)。}
  2755. SystemProcessResponse:
  2756. type: object
  2757. additionalProperties: false
  2758. required: [code, message, data, requestId]
  2759. properties:
  2760. code: {type: string, enum: [OK]}
  2761. message: {type: string, enum: [success]}
  2762. data: {$ref: '#/SystemProcessData'}
  2763. requestId: {type: string, format: uuid}
  2764. SystemStorageUsageEntry:
  2765. type: object
  2766. additionalProperties: false
  2767. required: [directory, totalBytes, fileCount]
  2768. properties:
  2769. directory: {type: string, description: 存储子目录名(original/preview/extracted/temporary/quarantine/recycle/voucher)。}
  2770. totalBytes: {type: integer, minimum: 0}
  2771. fileCount: {type: integer, minimum: 0}
  2772. SystemStorageUsageData:
  2773. type: object
  2774. additionalProperties: false
  2775. required: [entries]
  2776. properties:
  2777. entries:
  2778. type: array
  2779. items: {$ref: '#/SystemStorageUsageEntry'}
  2780. SystemStorageUsageResponse:
  2781. type: object
  2782. additionalProperties: false
  2783. required: [code, message, data, requestId]
  2784. properties:
  2785. code: {type: string, enum: [OK]}
  2786. message: {type: string, enum: [success]}
  2787. data: {$ref: '#/SystemStorageUsageData'}
  2788. requestId: {type: string, format: uuid}
  2789. SystemConverterData:
  2790. type: object
  2791. additionalProperties: false
  2792. required: [available, executable, maxConcurrency, inFlight, successCount, failureCount, previewEnabled, timeoutSeconds]
  2793. properties:
  2794. available: {type: boolean, description: 转换器是否可用。}
  2795. executable: {type: string, description: LibreOffice 可执行文件路径。}
  2796. maxConcurrency: {type: integer, minimum: 1, description: 并发上限。}
  2797. inFlight: {type: integer, minimum: 0, description: 进行中的转换数。}
  2798. successCount: {type: integer, minimum: 0, description: 累计成功转换数(进程生命周期内)。}
  2799. failureCount: {type: integer, minimum: 0, description: 累计失败转换数(进程生命周期内)。}
  2800. previewEnabled: {type: boolean, description: 预览转换功能是否启用。}
  2801. timeoutSeconds: {type: integer, minimum: 1, description: 单次转换超时秒数。}
  2802. SystemConverterResponse:
  2803. type: object
  2804. additionalProperties: false
  2805. required: [code, message, data, requestId]
  2806. properties:
  2807. code: {type: string, enum: [OK]}
  2808. message: {type: string, enum: [success]}
  2809. data: {$ref: '#/SystemConverterData'}
  2810. requestId: {type: string, format: uuid}
  2811. SystemHealthItem:
  2812. type: object
  2813. additionalProperties: false
  2814. required: [item, ok, detail]
  2815. properties:
  2816. item:
  2817. type: string
  2818. enum: [DATABASE, STORAGE_WRITABLE, LIBREOFFICE, BACKUP_TARGET, STORAGE_ENCRYPTION]
  2819. ok: {type: boolean}
  2820. detail: {type: string, description: 失败原因或补充说明(成功为空/说明文字)。}
  2821. SystemHealthData:
  2822. type: object
  2823. additionalProperties: false
  2824. required: [items]
  2825. properties:
  2826. items:
  2827. type: array
  2828. items: {$ref: '#/SystemHealthItem'}
  2829. SystemHealthResponse:
  2830. type: object
  2831. additionalProperties: false
  2832. required: [code, message, data, requestId]
  2833. properties:
  2834. code: {type: string, enum: [OK]}
  2835. message: {type: string, enum: [success]}
  2836. data: {$ref: '#/SystemHealthData'}
  2837. requestId: {type: string, format: uuid}
  2838. SystemInfoData:
  2839. type: object
  2840. additionalProperties: false
  2841. required: [contractVersion, backendKind, runtimeVersion, operatingSystem, hostname, machineArch, databaseType, startedAt, uptimeSeconds, workingDirectory, storageRoot, backupConfigPath, envFilePath, logFilePath, monitoringEnabled]
  2842. properties:
  2843. contractVersion: {type: string, description: 接口契约版本(如 1.26.0)。}
  2844. backendKind: {type: string, enum: [PYTHON, JAVA], description: 后端实现类型。}
  2845. runtimeVersion: {type: string, description: 运行时版本(Python/JDK)。}
  2846. operatingSystem: {type: string}
  2847. hostname: {type: string}
  2848. machineArch: {type: string, description: 体系结构(x86_64/aarch64 等)。}
  2849. databaseType: {type: string, description: 数据库类型描述(DM (达梦)/MySQL 等)。}
  2850. startedAt: {type: string, description: 进程启动时间(UTC;psutil 缺失为空串)。}
  2851. uptimeSeconds: {type: integer, minimum: 0}
  2852. workingDirectory: {type: string}
  2853. storageRoot: {type: string}
  2854. backupConfigPath: {type: string}
  2855. envFilePath: {type: string}
  2856. logFilePath: {type: string, description: 运行日志文件路径(未启用为空串)。}
  2857. monitoringEnabled: {type: boolean, description: 监控信息展示开关(DMS_SYSTEM_MONITOR_ENABLED,缺省 false);false 时前端隐藏系统管理页维护操作之上的监控区块。}
  2858. SystemInfoResponse:
  2859. type: object
  2860. additionalProperties: false
  2861. required: [code, message, data, requestId]
  2862. properties:
  2863. code: {type: string, enum: [OK]}
  2864. message: {type: string, enum: [success]}
  2865. data: {$ref: '#/SystemInfoData'}
  2866. requestId: {type: string, format: uuid}
  2867. SystemRuntimeConfigEntry:
  2868. type: object
  2869. additionalProperties: false
  2870. required: [category, key, value, unit]
  2871. properties:
  2872. category: {type: string, description: 分类(认证/存储/上传/业务/转换/安全)。}
  2873. key: {type: string, description: 参数显示名。}
  2874. value:
  2875. description: 参数值(密钥类仅显示 已配置/未配置,永不回明文)。
  2876. unit: {type: string, description: 单位(无单位为空串)。}
  2877. SystemRuntimeConfigData:
  2878. type: object
  2879. additionalProperties: false
  2880. required: [entries]
  2881. properties:
  2882. entries:
  2883. type: array
  2884. items: {$ref: '#/SystemRuntimeConfigEntry'}
  2885. SystemRuntimeConfigResponse:
  2886. type: object
  2887. additionalProperties: false
  2888. required: [code, message, data, requestId]
  2889. properties:
  2890. code: {type: string, enum: [OK]}
  2891. message: {type: string, enum: [success]}
  2892. data: {$ref: '#/SystemRuntimeConfigData'}
  2893. requestId: {type: string, format: uuid}
  2894. SystemLogsData:
  2895. type: object
  2896. additionalProperties: false
  2897. required: [file, lines, truncated]
  2898. properties:
  2899. file: {type: string, description: 日志文件路径(未启用为空串)。}
  2900. lines:
  2901. type: array
  2902. items: {type: string}
  2903. description: 尾部日志行(级别过滤后截尾)。
  2904. truncated: {type: boolean, description: 是否经过截断。}
  2905. error:
  2906. type: string
  2907. description: 读取失败原因(成功时无此字段)。
  2908. SystemLogsResponse:
  2909. type: object
  2910. additionalProperties: false
  2911. required: [code, message, data, requestId]
  2912. properties:
  2913. code: {type: string, enum: [OK]}
  2914. message: {type: string, enum: [success]}
  2915. data: {$ref: '#/SystemLogsData'}
  2916. requestId: {type: string, format: uuid}
  2917. SystemPreviewCacheClearData:
  2918. type: object
  2919. additionalProperties: false
  2920. required: [removedFiles, removedBytes]
  2921. properties:
  2922. removedFiles: {type: integer, minimum: 0, description: 删除的预览文件数。}
  2923. removedBytes: {type: integer, minimum: 0, description: 释放的字节数。}
  2924. SystemPreviewCacheClearResponse:
  2925. type: object
  2926. additionalProperties: false
  2927. required: [code, message, data, requestId]
  2928. properties:
  2929. code: {type: string, enum: [OK]}
  2930. message: {type: string, enum: [success]}
  2931. data: {$ref: '#/SystemPreviewCacheClearData'}
  2932. requestId: {type: string, format: uuid}
  2933. SystemForceOfflineData:
  2934. type: object
  2935. additionalProperties: false
  2936. required: [userId, username, authVersion]
  2937. properties:
  2938. userId: {type: string, description: 目标用户ID(字符串形式)。}
  2939. username: {type: string}
  2940. authVersion: {type: integer, minimum: 1, description: 目标用户当前 auth_version(已 +1)。}
  2941. SystemForceOfflineResponse:
  2942. type: object
  2943. additionalProperties: false
  2944. required: [code, message, data, requestId]
  2945. properties:
  2946. code: {type: string, enum: [OK]}
  2947. message: {type: string, enum: [success]}
  2948. data: {$ref: '#/SystemForceOfflineData'}
  2949. requestId: {type: string, format: uuid}
  2950. BackupTestTargetData:
  2951. type: object
  2952. additionalProperties: false
  2953. required: [ok]
  2954. properties:
  2955. ok: {type: boolean, description: 目标是否可写。}
  2956. target:
  2957. type: string
  2958. description: 目标描述(成功时返回)。
  2959. error:
  2960. type: string
  2961. description: 失败原因(失败时返回)。
  2962. BackupTestTargetResponse:
  2963. type: object
  2964. additionalProperties: false
  2965. required: [code, message, data, requestId]
  2966. properties:
  2967. code: {type: string, enum: [OK]}
  2968. message: {type: string, enum: [success]}
  2969. data: {$ref: '#/BackupTestTargetData'}
  2970. requestId: {type: string, format: uuid}
  2971. NotificationSummary:
  2972. type: object
  2973. additionalProperties: false
  2974. required: [id, title, notifyType, action, status, createdAt]
  2975. properties:
  2976. id: {$ref: '#/StringId'}
  2977. title: {type: string, description: 通知标题。}
  2978. content: {type: string, description: 通知内容说明。}
  2979. notifyType:
  2980. type: string
  2981. enum: [APPROVAL]
  2982. description: 通知类别(APPROVAL=审批待办,后续扩展)。
  2983. bizId:
  2984. allOf:
  2985. - $ref: '#/StringId'
  2986. description: 关联业务ID(1.37新增,APPROVAL待办指向借阅申请单,其余为null)。
  2987. action:
  2988. type: string
  2989. enum: [NONE, PENDING, AGREE, REJECT]
  2990. description: 待办操作(NONE=无需操作,PENDING=待处理,AGREE/REJECT=已同意/已拒绝)。
  2991. status:
  2992. type: string
  2993. enum: [UNREAD, READ]
  2994. description: 已读状态。
  2995. createdAt: {type: string, format: date-time, description: 创建时间(UTC毫秒精度)。}
  2996. handledAt: {type: string, format: date-time, description: 处理时间(同意/拒绝时)。}
  2997. NotificationListData:
  2998. type: object
  2999. additionalProperties: false
  3000. required: [items]
  3001. properties:
  3002. items:
  3003. type: array
  3004. items: {$ref: '#/NotificationSummary'}
  3005. NotificationListResponse:
  3006. type: object
  3007. additionalProperties: false
  3008. required: [code, message, data, requestId]
  3009. properties:
  3010. code: {type: string, enum: [OK]}
  3011. message: {type: string, enum: [success]}
  3012. data: {$ref: '#/NotificationListData'}
  3013. requestId: {type: string, format: uuid}
  3014. NotificationUnreadCountData:
  3015. type: object
  3016. additionalProperties: false
  3017. required: [count]
  3018. properties:
  3019. count: {type: integer, minimum: 0, description: 未读通知条数。}
  3020. NotificationUnreadCountResponse:
  3021. type: object
  3022. additionalProperties: false
  3023. required: [code, message, data, requestId]
  3024. properties:
  3025. code: {type: string, enum: [OK]}
  3026. message: {type: string, enum: [success]}
  3027. data: {$ref: '#/NotificationUnreadCountData'}
  3028. requestId: {type: string, format: uuid}
  3029. NotificationReadAllData:
  3030. type: object
  3031. additionalProperties: false
  3032. required: [updated]
  3033. properties:
  3034. updated: {type: integer, minimum: 0, description: 本次标记已读的条数。}
  3035. NotificationReadAllResponse:
  3036. type: object
  3037. additionalProperties: false
  3038. required: [code, message, data, requestId]
  3039. properties:
  3040. code: {type: string, enum: [OK]}
  3041. message: {type: string, enum: [success]}
  3042. data: {$ref: '#/NotificationReadAllData'}
  3043. requestId: {type: string, format: uuid}
  3044. HandleNotificationRequest:
  3045. type: object
  3046. additionalProperties: false
  3047. required: [action]
  3048. properties:
  3049. action:
  3050. type: string
  3051. enum: [AGREE, REJECT]
  3052. description: 处理动作(同意/拒绝)。
  3053. NotificationResponse:
  3054. type: object
  3055. additionalProperties: false
  3056. required: [code, message, data, requestId]
  3057. properties:
  3058. code: {type: string, enum: [OK]}
  3059. message: {type: string, enum: [success]}
  3060. data: {$ref: '#/NotificationSummary'}
  3061. requestId: {type: string, format: uuid}
  3062. BorrowRequestEntryInput:
  3063. type: object
  3064. additionalProperties: false
  3065. required: [subjectId, canView, canDownload]
  3066. properties:
  3067. subjectId: {$ref: '#/StringId'}
  3068. canView: {type: boolean, description: 借阅人查看位。}
  3069. canDownload: {type: boolean, description: 借阅人下载位(查看与下载至少一项为true)。}
  3070. BorrowRequestCreateRequest:
  3071. type: object
  3072. additionalProperties: false
  3073. required: [entries, expiresAt]
  3074. description: 借阅申请载荷(multipart的request part为该对象的JSON字符串)。
  3075. properties:
  3076. entries:
  3077. type: array
  3078. minItems: 1
  3079. items: {$ref: '#/BorrowRequestEntryInput'}
  3080. expiresAt:
  3081. type: string
  3082. format: date-time
  3083. description: 到期时间(UTC毫秒精度Z结尾,须晚于当前时间,最长7天,服务端60秒容差)。
  3084. BorrowRequestCreateResultData:
  3085. type: object
  3086. additionalProperties: false
  3087. required: [requestId, notified]
  3088. properties:
  3089. requestId: {$ref: '#/StringId'}
  3090. notified: {type: integer, minimum: 0, description: 收到APPROVAL待办通知的审批人数。}
  3091. BorrowRequestCreateResultResponse:
  3092. type: object
  3093. additionalProperties: false
  3094. required: [code, message, data, requestId]
  3095. properties:
  3096. code: {type: string, enum: [OK]}
  3097. message: {type: string, enum: [success]}
  3098. data: {$ref: '#/BorrowRequestCreateResultData'}
  3099. requestId: {type: string, format: uuid}
  3100. BorrowRequestEntry:
  3101. type: object
  3102. additionalProperties: false
  3103. required: [subjectId, subjectName, canView, canDownload]
  3104. properties:
  3105. subjectId: {$ref: '#/StringId'}
  3106. subjectName: {type: string, description: 借阅人姓名。}
  3107. canView: {type: boolean, description: 查看位。}
  3108. canDownload: {type: boolean, description: 下载位。}
  3109. BorrowRequestDetailData:
  3110. type: object
  3111. additionalProperties: false
  3112. required: [requestId, documentId, documentName, requesterId, requesterName, entries, expiresAt, status, createdAt]
  3113. properties:
  3114. requestId: {$ref: '#/StringId'}
  3115. documentId: {$ref: '#/StringId'}
  3116. documentName: {type: string, description: 文档名称。}
  3117. requesterId: {$ref: '#/StringId'}
  3118. requesterName: {type: string, description: 申请人姓名。}
  3119. entries:
  3120. type: array
  3121. items: {$ref: '#/BorrowRequestEntry'}
  3122. expiresAt: {type: string, format: date-time, description: 到期时间(UTC毫秒精度)。}
  3123. voucherFileName: {type: string, description: 审批单文件名(未上传为null)。}
  3124. voucherFileSize: {type: integer, format: int64, description: 审批单字节数(未上传为null)。}
  3125. status:
  3126. type: string
  3127. enum: [PENDING, APPROVED, REJECTED]
  3128. description: 申请状态(任一审批人处理即定)。
  3129. handledById:
  3130. allOf:
  3131. - $ref: '#/StringId'
  3132. description: 处理人ID(未处理为null)。
  3133. handledByName: {type: string, description: 处理人姓名(未处理为null)。}
  3134. handledAt: {type: string, format: date-time, description: 处理时间(未处理为null)。}
  3135. createdAt: {type: string, format: date-time, description: 申请时间(UTC毫秒精度)。}
  3136. BorrowRequestDetailResponse:
  3137. type: object
  3138. additionalProperties: false
  3139. required: [code, message, data, requestId]
  3140. properties:
  3141. code: {type: string, enum: [OK]}
  3142. message: {type: string, enum: [success]}
  3143. data: {$ref: '#/BorrowRequestDetailData'}
  3144. requestId: {type: string, format: uuid}