华西海圻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.

111 lines
3.1 KiB

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