xm-reverse.vue 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. <template>
  2. <div>
  3. <a-form-model-item label="反向设值域">
  4. <a-input v-model="component.attrFD.formItemProps.inputProps.reverseField"></a-input>
  5. </a-form-model-item>
  6. <a-form-model-item label="字符长度范围">
  7. <sd-range-input
  8. :max.sync="component.attr.maxLength"
  9. :min.sync="component.attr.minLength"
  10. disable-negative
  11. :max-max="2000"
  12. />
  13. </a-form-model-item>
  14. </div>
  15. </template>
  16. <script>
  17. import { Input, Button } from 'ant-design-vue'
  18. import sdRangeInput from '@/form-designer/sd-range-input'
  19. import components from './_import-components/xm-reverse-import'
  20. export const metaInfo = {
  21. caption: '反向设值',
  22. component: {
  23. props: ['designerData'],
  24. render() {
  25. return (
  26. <Div class='xmselinput'>
  27. <Input></Input>
  28. <Button>反向</Button>
  29. </Div>
  30. )
  31. },
  32. },
  33. icon: 'sd-list',
  34. order: 990,
  35. }
  36. export const fieldProps = {
  37. dataType: 'string',
  38. attrFD: {
  39. formItemProps: {
  40. inputProps: {
  41. reverseField: '',
  42. },
  43. },
  44. },
  45. }
  46. export default {
  47. name: 'XmReverse',
  48. components: { sdRangeInput, ...components },
  49. data() {
  50. return {}
  51. },
  52. methods: {},
  53. }
  54. </script>
  55. <style module lang="scss">
  56. @use '@/common/design' as *;
  57. :global(.xmselinput) {
  58. :global .ant-input {
  59. width: 60%;
  60. margin-right: 5px;
  61. }
  62. :global .ant-btn {
  63. padding: 0 5px;
  64. }
  65. }
  66. </style>