08f9e5e4f91f343d3d2922e4b79d7032a9026ad3.svn-base 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. <template>
  2. <el-form :model="examineForm" label-width="100px">
  3. <el-form-item label="工程名称">
  4. <el-input type="text" placeholder="请输入内容" v-model="examineForm.objName" readonly>
  5. </el-input>
  6. </el-form-item>
  7. <el-form-item label="阶段信息" style="text-align:left">
  8. <el-input type="text" placeholder="请输入内容" v-model="planProcessName" readonly>
  9. </el-input>
  10. </el-form-item>
  11. <el-form-item label="是否通过审定" style="text-align:left">
  12. <el-radio v-model="examineForm.stageStatus" label="1">是</el-radio>
  13. <el-radio v-model="examineForm.stageStatus" label="2">否</el-radio>
  14. </el-form-item>
  15. <el-form-item label="审定意见">
  16. <el-input type="textarea" :rows="2" placeholder="请输入内容" v-model="examineForm.stageStatusReson">
  17. </el-input>
  18. </el-form-item>
  19. <el-form-item style="margin-top: 50px">
  20. <el-button type="primary" @click="examineVisible">保存</el-button>
  21. <el-button @click="examineVisiblefalse">取消</el-button>
  22. </el-form-item>
  23. </el-form>
  24. </template>
  25. <script>
  26. import request from '@util/gw_ajax_request.js'
  27. export default {
  28. props: ['rgstrId', 'planProcessId','planProcessName'],
  29. data() {
  30. return {
  31. examineForm: {
  32. objName:"",
  33. rgstrId:"",
  34. planProcessId:"",
  35. stageStatusReson:"",
  36. stageStatus:""
  37. },
  38. }
  39. },
  40. mounted() {
  41. this.getByExamine()
  42. },
  43. methods: {
  44. getByExamine() {
  45. let data = {
  46. rgstrId: this.rgstrId,
  47. planProcessId: this.planProcessId
  48. };
  49. request.post(`/tac/province/examine/getBy`,data).then(res => {
  50. if (res.success) {
  51. this.examineForm=res.data;
  52. } else {
  53. this.$message.error(res.message)
  54. }
  55. })
  56. },
  57. examineVisible(){
  58. var _self = this;
  59. _self.examineForm.planProcessId=_self.planProcessId;
  60. _self.examineForm.rgstrId=_self.rgstrId;
  61. if (_self.rgstrId&&_self.planProcessId) {
  62. request.post(`/tac/province/examRecord/insertExamine`,_self.examineForm).then(res => {
  63. if (res.success) {
  64. _self.$message.success('审定提交成功')
  65. this.$emit('dialogClose');
  66. } else {
  67. _self.$message.error(res.message)
  68. }
  69. }).catch((err) => {
  70. this.$message.error(err)
  71. });
  72. } else {
  73. this.$message.warning('项目名称以及阶段不能为空')
  74. }
  75. },
  76. examineVisiblefalse(){
  77. this.$emit('dialogClose')
  78. }
  79. },
  80. watch: {
  81. rgstrId() {
  82. this.getByExamine()
  83. },
  84. planProcessId() {
  85. this.getByExamine()
  86. }
  87. }
  88. }
  89. </script>
  90. <style lang="scss">
  91. </style>