SeoKeywords.data.ts 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251
  1. import { BasicColumn } from "/@/components/Table";
  2. import { FormSchema } from "/@/components/Table";
  3. import { rules } from "/@/utils/helper/validator";
  4. import { render } from "/@/utils/common/renderUtils";
  5. import { getWeekMonthQuarterYear } from "/@/utils";
  6. //列表数据
  7. export const columns: BasicColumn[] = [
  8. {
  9. title: "关键词",
  10. align: "center",
  11. dataIndex: "keywords"
  12. },
  13. {
  14. title: "关键词所在URL",
  15. align: "center",
  16. dataIndex: "positionUrl",
  17. },
  18. {
  19. title: "关键词类型",
  20. align: "center",
  21. dataIndex: "keywordType"
  22. },
  23. {
  24. title: '添加时间',
  25. align: 'left',
  26. dataIndex: 'createTime',
  27. sorter: true,
  28. },
  29. {
  30. title: '最新排名日期',
  31. align: 'left',
  32. dataIndex: 'lastSearchTime',
  33. sorter: true,
  34. },
  35. {
  36. title: '查询日期(定时任务)',
  37. align: 'left',
  38. dataIndex: 'timerLastSearchTime',
  39. },
  40. {
  41. title: '最新排名',
  42. align: 'left',
  43. dataIndex: 'lastRank',
  44. sorter: true,
  45. },
  46. ];
  47. //查询数据
  48. export const searchFormSchema: FormSchema[] = [];
  49. //表单数据
  50. export const formSchema: FormSchema[] = [
  51. {
  52. label: "平台标识",
  53. field: "appKey",
  54. component: "Input",
  55. dynamicRules: ({ model, schema }) => {
  56. return [
  57. { required: true, message: "请输入平台标识!" }
  58. ];
  59. }
  60. },
  61. {
  62. label: "用户标识",
  63. field: "siteCode",
  64. component: "Input",
  65. dynamicRules: ({ model, schema }) => {
  66. return [
  67. { required: true, message: "请输入用户标识!" }
  68. ];
  69. }
  70. },
  71. {
  72. label: "关键词",
  73. field: "keywords",
  74. component: "Input",
  75. dynamicRules: ({ model, schema }) => {
  76. return [
  77. { required: true, message: "请输入关键词!" }
  78. ];
  79. }
  80. },
  81. {
  82. label: "关键词所属域名",
  83. field: "domain",
  84. component: "Input",
  85. dynamicRules: ({ model, schema }) => {
  86. return [
  87. { required: true, message: "请输入关键词所属域名!" }
  88. ];
  89. }
  90. },
  91. {
  92. label: "语种",
  93. field: "lang",
  94. component: "Input"
  95. },
  96. {
  97. label: "最新搜索时间",
  98. field: "lastSearchTime",
  99. component: "DatePicker",
  100. componentProps: {
  101. showTime: true,
  102. valueFormat: "YYYY-MM-DD"
  103. }
  104. },
  105. {
  106. label: "定时器的最新搜索时间",
  107. field: "timerLastSearchTime",
  108. component: "DatePicker",
  109. componentProps: {
  110. showTime: true,
  111. valueFormat: "YYYY-MM-DD"
  112. }
  113. },
  114. {
  115. label: "0删除,1有效,2过期",
  116. field: "status",
  117. component: "InputNumber"
  118. },
  119. {
  120. label: "数据复制源ID",
  121. field: "sourceId",
  122. component: "InputNumber"
  123. },
  124. {
  125. label: "关键词优先级(1:高;2:中;3:低)",
  126. field: "priority",
  127. component: "InputNumber"
  128. },
  129. {
  130. label: "SEO关键词优化完成时间",
  131. field: "finishTime",
  132. component: "DatePicker",
  133. componentProps: {
  134. showTime: true,
  135. valueFormat: "YYYY-MM-DD"
  136. }
  137. },
  138. {
  139. label: "优化进度",
  140. field: "optimizeProcess",
  141. component: "InputNumber"
  142. },
  143. {
  144. label: "优化状态",
  145. field: "optimizeStatus",
  146. component: "InputNumber"
  147. },
  148. {
  149. label: "关键词类型",
  150. field: "keywordType",
  151. component: "InputNumber",
  152. dynamicRules: ({ model, schema }) => {
  153. return [
  154. { required: true, message: "请输入关键词类型(1:指定;2:长尾)!" }
  155. ];
  156. }
  157. },
  158. {
  159. label: "最近一次搜索排名",
  160. field: "lastRank",
  161. component: "InputNumber"
  162. },
  163. {
  164. label: "搜索状态,0为普通状态,1为搜索进行中状态",
  165. field: "searchStatus",
  166. component: "InputNumber"
  167. },
  168. {
  169. label: "关键词所在URL",
  170. field: "positionUrl",
  171. component: "InputTextArea"
  172. },
  173. {
  174. label: "相关关键词关联的关键词的id",
  175. field: "relatedKeywordId",
  176. component: "InputNumber"
  177. },
  178. {
  179. label: "关键词对应套餐的ID",
  180. field: "planId",
  181. component: "Input"
  182. },
  183. {
  184. label: "订购表ID",
  185. field: "subscriptionId",
  186. component: "Input"
  187. },
  188. {
  189. label: "网站表ID",
  190. field: "siteId",
  191. component: "Input"
  192. },
  193. // TODO 主键隐藏字段,目前写死为ID
  194. {
  195. label: "",
  196. field: "id",
  197. component: "Input",
  198. show: false
  199. }
  200. ];
  201. // 高级查询数据
  202. export const superQuerySchema = {
  203. keywords: { title: "关键词", order: 2, view: "text", type: "string" },
  204. lastSearchTime: { title: "最新搜索时间", order: 5, view: "datetime", type: "string" },
  205. timerLastSearchTime: {
  206. title: "定时器的最新搜索时间",
  207. order: 6,
  208. view: "datetime",
  209. type: "string"
  210. },
  211. status: { title: "0删除,1有效,2过期", order: 7, view: "number", type: "number" },
  212. sourceId: { title: "数据复制源ID", order: 8, view: "number", type: "number" },
  213. priority: { title: "关键词优先级(1:高;2:中;3:低)", order: 9, view: "number", type: "number" },
  214. finishTime: { title: "SEO关键词优化完成时间", order: 10, view: "datetime", type: "string" },
  215. optimizeProcess: { title: "优化进度(默认0)", order: 11, view: "number", type: "number" },
  216. optimizeStatus: {
  217. title: "优化状态(0:未完成;1:已完成)",
  218. order: 12,
  219. view: "number",
  220. type: "number"
  221. },
  222. keywordType: { title: "关键词类型(1:指定;2:长尾)", order: 13, view: "number", type: "number" },
  223. lastRank: { title: "最近一次搜索排名", order: 14, view: "number", type: "number" },
  224. searchStatus: {
  225. title: "搜索状态,0为普通状态,1为搜索进行中状态",
  226. order: 15,
  227. view: "number",
  228. type: "number"
  229. },
  230. positionUrl: { title: "关键词所在URL", order: 16, view: "textarea", type: "string" },
  231. relatedKeywordId: {
  232. title: "相关关键词关联的关键词的id",
  233. order: 17,
  234. view: "number",
  235. type: "number"
  236. },
  237. planId: { title: "关键词对应套餐的ID", order: 18, view: "text", type: "string" },
  238. subscriptionId: { title: "订购表ID", order: 19, view: "text", type: "string" },
  239. siteId: { title: "网站表ID", order: 20, view: "text", type: "string" }
  240. };
  241. /**
  242. * 流程表单调用这个方法获取formSchema
  243. * @param param
  244. */
  245. export function getBpmFormSchema(_formData): FormSchema[] {
  246. // 默认和原始表单保持一致 如果流程中配置了权限数据,这里需要单独处理formSchema
  247. return formSchema;
  248. }