views.d.ts 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367
  1. /**
  2. * views personal
  3. */
  4. type NewInfo = {
  5. title: string;
  6. date: string;
  7. link: string;
  8. };
  9. type Recommend = {
  10. title: string;
  11. msg: string;
  12. icon: string;
  13. bg: string;
  14. iconColor: string;
  15. };
  16. declare type PersonalState = {
  17. newsInfoList: NewInfo[];
  18. recommendList: Recommend[];
  19. personalForm: {
  20. name: string;
  21. email: string;
  22. autograph: string;
  23. occupation: string;
  24. phone: string;
  25. sex: string;
  26. };
  27. };
  28. /**
  29. * views visualizing
  30. */
  31. declare type Demo2State<T = any> = {
  32. time: {
  33. txt: string;
  34. fun: number;
  35. };
  36. dropdownList: T[];
  37. dropdownActive: string;
  38. skyList: T[];
  39. dBtnList: T[];
  40. chartData4Index: number;
  41. dBtnActive: number;
  42. earth3DBtnList: T[];
  43. chartData4List: T[];
  44. myCharts: T[];
  45. };
  46. /**
  47. * views params
  48. */
  49. declare type ParamsState = {
  50. value: string;
  51. tagsViewName: string;
  52. tagsViewNameIsI18n: boolean;
  53. };
  54. /**
  55. * views system
  56. */
  57. // role
  58. declare interface RowRoleType {
  59. roleName: string;
  60. roleSign: string;
  61. describe: string;
  62. sort: number;
  63. status: boolean;
  64. createTime: string;
  65. }
  66. interface SysRoleTableType extends TableType {
  67. data: RowRoleType[];
  68. }
  69. declare interface SysRoleState {
  70. tableData: SysRoleTableType;
  71. }
  72. declare type TreeType = {
  73. id: number;
  74. label: string;
  75. children?: TreeType[];
  76. };
  77. // user
  78. declare type RowUserType<T = any> = {
  79. userName: string;
  80. userNickname: string;
  81. roleSign: string;
  82. department: string[];
  83. phone: string;
  84. email: string;
  85. sex: string;
  86. password: string;
  87. overdueTime: T;
  88. status: boolean;
  89. describe: string;
  90. createTime: T;
  91. };
  92. interface SysUserTableType extends TableType {
  93. data: RowUserType[];
  94. }
  95. declare interface SysUserState {
  96. tableData: SysUserTableType;
  97. }
  98. declare type DeptTreeType = {
  99. deptName: string;
  100. createTime: string;
  101. status: boolean;
  102. sort: number;
  103. describe: string;
  104. id: number | string;
  105. children?: DeptTreeType[];
  106. };
  107. // dept
  108. declare interface RowDeptType extends DeptTreeType {
  109. deptLevel: string[];
  110. person: string;
  111. phone: string;
  112. email: string;
  113. }
  114. interface SysDeptTableType extends TableType {
  115. data: DeptTreeType[];
  116. }
  117. declare interface SysDeptState {
  118. tableData: SysDeptTableType;
  119. }
  120. // dic
  121. type ListType = {
  122. id: number;
  123. label: string;
  124. value: string;
  125. };
  126. declare interface RowDicType {
  127. dicName: string;
  128. fieldName: string;
  129. describe: string;
  130. status: boolean;
  131. createTime: string;
  132. list: ListType[];
  133. }
  134. interface SysDicTableType extends TableType {
  135. data: RowDicType[];
  136. }
  137. declare interface SysDicState {
  138. tableData: SysDicTableType;
  139. }
  140. /**
  141. * views pages
  142. */
  143. // filtering
  144. declare type FilteringChilType = {
  145. id: number | string;
  146. label: string;
  147. active: boolean;
  148. };
  149. declare type FilterListType = {
  150. img: string;
  151. title: string;
  152. evaluate: string;
  153. collection: string;
  154. price: string;
  155. monSales: string;
  156. id: number | string;
  157. loading?: boolean;
  158. };
  159. declare type FilteringRowType = {
  160. title: string;
  161. isMore: boolean;
  162. isShowMore: boolean;
  163. id: number | string;
  164. children: FilteringChilType[];
  165. };
  166. // tableRules
  167. declare type TableRulesHeaderType = {
  168. prop: string;
  169. width: string | number;
  170. label: string;
  171. isRequired?: boolean;
  172. isTooltip?: boolean;
  173. type: string;
  174. };
  175. declare type TableRulesState = {
  176. tableData: {
  177. data: EmptyObjectType[];
  178. header: TableRulesHeaderType[];
  179. option: SelectOptionType[];
  180. };
  181. };
  182. declare type TableRulesOneProps = {
  183. name: string;
  184. email: string;
  185. autograph: string;
  186. occupation: string;
  187. };
  188. // tree
  189. declare type RowTreeType = {
  190. id: number;
  191. label: string;
  192. label1: string;
  193. label2: string;
  194. isShow: boolean;
  195. children?: RowTreeType[];
  196. };
  197. // workflow index
  198. declare type NodeListState = {
  199. id: string | number;
  200. nodeId: string | undefined;
  201. class: HTMLElement | string;
  202. left: number | string;
  203. top: number | string;
  204. icon: string;
  205. name: string;
  206. };
  207. declare type LineListState = {
  208. sourceId: string;
  209. targetId: string;
  210. label: string;
  211. };
  212. declare type XyState = {
  213. x: string | number;
  214. y: string | number;
  215. };
  216. declare type WorkflowState<T = any> = {
  217. leftNavList: T[];
  218. dropdownNode: XyState;
  219. dropdownLine: XyState;
  220. isShow: boolean;
  221. jsPlumb: T;
  222. jsPlumbNodeIndex: null | number;
  223. jsplumbDefaults: T;
  224. jsplumbMakeSource: T;
  225. jsplumbMakeTarget: T;
  226. jsplumbConnect: T;
  227. jsplumbData: {
  228. nodeList: NodeListState[];
  229. lineList: LineListState[];
  230. };
  231. };
  232. // workflow drawer
  233. declare type WorkflowDrawerNodeState<T = any> = {
  234. node: { [key: string]: T };
  235. nodeRules: T;
  236. form: T;
  237. tabsActive: string;
  238. loading: {
  239. extend: boolean;
  240. };
  241. };
  242. declare type WorkflowDrawerLabelType = {
  243. type: string;
  244. label: string;
  245. };
  246. declare type WorkflowDrawerState<T = any> = {
  247. isOpen: boolean;
  248. nodeData: {
  249. type: string;
  250. };
  251. jsplumbConn: T;
  252. };
  253. /**
  254. * views make
  255. */
  256. // tableDemo
  257. declare type TableDemoPageType = {
  258. page: number;
  259. pageSize: number;
  260. };
  261. declare type TableHeaderType = {
  262. key: string;
  263. width: string;
  264. title: string;
  265. type: string | number;
  266. colWidth: string;
  267. width?: string | number;
  268. height?: string | number;
  269. isCheck: boolean;
  270. align: string;
  271. headerAlign: string;
  272. toolTip: boolean;
  273. sortable: boolean;
  274. };
  275. declare type TableSearchType = {
  276. label: string;
  277. prop: string;
  278. placeholder: string;
  279. required: boolean;
  280. type: 'input' | 'date' | 'daterange' | 'monthrange' | 'select' | 'cascader'; // vxe-next-admin 原定义是 string
  281. options?: SelectOptionType[];
  282. cascaderData?: object[];
  283. cascaderProps?: object;
  284. comProps?: object;
  285. change?: (value: any) => {};
  286. };
  287. declare type TableDemoState = {
  288. tableData: {
  289. // data: EmptyObjectType[];
  290. // header: TableHeaderType[];
  291. columns: Object[]; //列设置,同ELTable-Column属性
  292. config: {
  293. // total: number;
  294. // loading: boolean;
  295. isStripe: boolean;
  296. isBorder: boolean;
  297. isSelection: boolean;
  298. showSelection: boolean;
  299. isSerialNo: boolean;
  300. pageSizes?: number[];
  301. pageSize: number;
  302. hideExport?: boolean;
  303. exportFileName?: string;
  304. hidePrint?: boolean;
  305. printName?: string;
  306. hideSet?: boolean;
  307. hideRefresh?: boolean;
  308. hidePagination?: boolean;
  309. // isOperate: boolean;
  310. };
  311. // actions: WorkflowDrawerLabelType[];
  312. search: TableSearchType[];
  313. param: EmptyObjectType;
  314. defaultSort: EmptyObjectType;
  315. };
  316. };
  317. // HTTP 作业消息(字段定义来源 Furion 的 HttpJobMessage)
  318. interface HttpJobMessage {
  319. requestUri?: string | null;
  320. httpMethod?: string | null;
  321. body?: string | null;
  322. }
  323. // 修改记录相关字段定义
  324. declare type ModifyRecord = {
  325. createUserName?: string | null;
  326. createTime?: string | null;
  327. updateUserName?: string | null;
  328. updateTime?: string | null;
  329. remark?: string | null;
  330. };