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

123 lines
3.5 KiB

  1. G<template>
  2. <div >
  3. <!-- 解锁弹窗 -->
  4. <el-dialog :title="$t('page.business.zykgl.mjy.unlock')" :visible.sync="open" width="500px" 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('page.business.zykgl.mjy.mc')" prop="mc">
  9. <el-input type="text" v-model="form.mc" 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.zykgl.mjy.bh')" prop="glyj">
  17. <el-input type="text" v-model="form.bh" maxlength="50" disabled
  18. :placeholder="$t('form.placeholderInput')" />
  19. </el-form-item>
  20. </el-col>
  21. </el-row>
  22. <el-row>
  23. <el-col :span="24">
  24. <el-form-item :label="$t('form.qmyy')" prop="qmyy">
  25. <el-input type="text" :value="form.qmyy" maxlength="50" disabled
  26. :placeholder="$t('form.placeholderInput')" />
  27. </el-form-item>
  28. </el-col>
  29. </el-row>
  30. <el-row>
  31. <el-col :span="24">
  32. <el-form-item :label="$t('form.remark')" prop="remark">
  33. <el-input type="textarea" v-model="form.remark" :rows="2" maxlength="500"
  34. :placeholder="$t('form.placeholderInput')">
  35. </el-input>
  36. </el-form-item>
  37. </el-col>
  38. </el-row>
  39. <el-row>
  40. <el-col :span="24">
  41. <el-form-item :label="$t('form.signer')">
  42. <el-input type="text" v-model="nickName" maxlength="50" disabled
  43. :placeholder="$t('form.placeholderInput')" />
  44. </el-form-item>
  45. </el-col>
  46. </el-row>
  47. <el-row>
  48. <el-col :span="24">
  49. <el-form-item :label="$t('form.password')" prop="sdrmm">
  50. <el-input type="password" v-model="form.sdrmm" maxlength="20" :placeholder="$t('form.placeholderInput')" />
  51. </el-form-item>
  52. </el-col>
  53. </el-row>
  54. </el-form>
  55. <div slot="footer" class="dialog-footer">
  56. <el-button type="primary" @click="save">{{ $t('form.confirm') }}</el-button>
  57. <el-button @click="cancel">{{ $t('form.cancel') }}</el-button>
  58. </div>
  59. </el-dialog>
  60. </div>
  61. </template>
  62. <script>
  63. import { mjy_js } from "@/api/business/mjy/mjy"
  64. import { mapGetters } from 'vuex'
  65. export default {
  66. name: "MjyJs",
  67. data() {
  68. return {
  69. open: false,
  70. form: {},
  71. rules: {
  72. sdrmm: [{
  73. required: true,
  74. message: ' ',
  75. trigger: 'blur'
  76. }]
  77. }
  78. }
  79. },
  80. computed: {
  81. ...mapGetters([
  82. 'nickName'
  83. ]),
  84. },
  85. created() {
  86. },
  87. methods: {
  88. cancel() {
  89. this.open = false
  90. },
  91. reset() {
  92. this.form = {
  93. id: null,
  94. ids: null,
  95. mc: null,
  96. bh: null,
  97. qmyy: '解锁麻精药',
  98. sdrmm: null
  99. }
  100. this.resetForm("form")
  101. },
  102. show(row) {
  103. this.reset()
  104. this.form.id = row.id
  105. this.form.mc = row.mc
  106. this.form.bh = row.bh
  107. this.open = true
  108. },
  109. save() {
  110. this.$refs["form"].validate(valid => {
  111. if (valid) {
  112. mjy_js(this.form).then(response => {
  113. this.open = false
  114. this.$emit('callback')
  115. })
  116. }
  117. })
  118. }
  119. }
  120. }
  121. </script>