华西海圻ELN前端工程
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

126 lines
3.3 KiB

  1. G<template>
  2. <div>
  3. <el-dialog :title="$t('page.business.study.studyFormApply.rybg')" :visible.sync="open" width="500px"
  4. append-to-body :close-on-click-modal="false">
  5. <el-form ref="form" :model="form" :rules="rules" label-width="120px">
  6. <el-row>
  7. <el-col :span="24">
  8. <el-form-item :label="$t('form.qmyy')" prop="qmyy">
  9. <el-input type="text" :value="form.qmyy" maxlength="50" disabled
  10. :placeholder="$t('form.placeholderInput')" />
  11. </el-form-item>
  12. </el-col>
  13. </el-row>
  14. <el-row>
  15. <el-col :span="24">
  16. <el-form-item :label="$t('page.business.study.studyFormApply.reason')" prop="remark">
  17. <el-input type="textarea" v-model="form.remark" :rows="5" maxlength="500"
  18. :placeholder="$t('form.placeholderInput')">
  19. </el-input>
  20. </el-form-item>
  21. </el-col>
  22. </el-row>
  23. <el-row>
  24. <el-col :span="24">
  25. <el-form-item :label="$t('form.signer')">
  26. <el-input type="text" v-model="nickName" maxlength="50" disabled
  27. :placeholder="$t('form.placeholderInput')" />
  28. </el-form-item>
  29. </el-col>
  30. </el-row>
  31. <el-row>
  32. <el-col :span="24">
  33. <el-form-item :label="$t('form.password')" prop="qmrmm">
  34. <el-input type="password" v-model="form.qmrmm" maxlength="20"
  35. :placeholder="$t('form.placeholderInput')" />
  36. </el-form-item>
  37. </el-col>
  38. </el-row>
  39. </el-form>
  40. <div slot="footer" class="dialog-footer">
  41. <el-button type="primary" @click="save">{{ $t('form.confirm') }}</el-button>
  42. <el-button @click="cancel">{{ $t('form.cancel') }}</el-button>
  43. </div>
  44. </el-dialog>
  45. </div>
  46. </template>
  47. <script>
  48. import { studyFormApply_ghgsr } from "@/api/business/study/studyFormApply"
  49. import { mapGetters } from 'vuex'
  50. export default {
  51. name: "Ghgsr",
  52. components: {},
  53. data() {
  54. return {
  55. isBatch: false,
  56. ids: [],
  57. selectList: [],
  58. open: false,
  59. form: {},
  60. rules: {
  61. qmrmm: [{
  62. required: true,
  63. message: ' ',
  64. trigger: 'blur'
  65. }],
  66. remark: [{
  67. required: true,
  68. message: ' ',
  69. trigger: 'blur'
  70. }],
  71. qmyy: [{
  72. required: true,
  73. message: ' ',
  74. trigger: 'blur'
  75. }],
  76. }
  77. }
  78. },
  79. computed: {
  80. ...mapGetters([
  81. 'nickName'
  82. ]),
  83. },
  84. created() {
  85. },
  86. methods: {
  87. cancel() {
  88. this.open = false
  89. },
  90. reset() {
  91. this.form = {
  92. id: null,
  93. qmyy: '更换归属人',
  94. userId: null,
  95. UserMc: null,
  96. remark: null,
  97. qmrmm: null
  98. }
  99. this.resetForm("form")
  100. },
  101. show(row) {
  102. this.reset()
  103. this.form.id = row.id
  104. this.form.userId = row.userId
  105. this.form.userMc = row.userMc
  106. this.open = true
  107. },
  108. save() {
  109. this.$refs["form"].validate(valid => {
  110. if (valid) {
  111. this.$modal.loading()
  112. studyFormApply_ghgsr(this.form).then(response => {
  113. this.open = false
  114. this.$emit('callback')
  115. this.$modal.closeLoading()
  116. }).finally(() => {
  117. this.$modal.closeLoading()
  118. })
  119. }
  120. })
  121. }
  122. }
  123. }
  124. </script>