audit-remind-config.vue 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223
  1. <template>
  2. <!-- <div style="background:#fff;padding-top:10px"> -->
  3. <span :class="$style.remindconfig">
  4. <audit-form-top-banner :handel-save-form="saveForm" @handelSaveForm="saveForm">
  5. <sd-detail-form
  6. ref="docform"
  7. :key="key"
  8. page-id="audit/remindConfig/iamAuditRemindConfig"
  9. :record-id="recordId"
  10. :class="[$style.form]"
  11. @saved="saved"
  12. >
  13. <template v-slot="{ model, fields }">
  14. <table :class="$style.remindTable">
  15. <!-- <tr>
  16. <td
  17. class="ant-form-item-label ant-form-item-label"
  18. :colspan="4"
  19. style="background: none;border: none;font-size: 22px;font-weight: bold;color: #404040;"
  20. >
  21. 《整改计划》提醒规则设置</td
  22. >
  23. </tr> -->
  24. <tr
  25. ><td style="border:none" colspan="4">
  26. <audit-advanced-group
  27. :expand="basicExpand"
  28. :expand-str="'basicExpand'"
  29. :group-label="'《整改计划》提醒规则设置'"
  30. tablestyle="''"
  31. @changedClick="changedClick"
  32. ></audit-advanced-group> </td
  33. ></tr>
  34. <tr v-show="basicExpand">
  35. <!-- 计划到期前天数 -->
  36. <sd-form-item-td name="planTimeLimit" :colspan="3" />
  37. </tr>
  38. <tr v-show="basicExpand">
  39. <!-- 计划提醒对象 -->
  40. <sd-form-item-td name="planRemindObject" :colspan="3" />
  41. </tr>
  42. <tr v-show="basicExpand">
  43. <!-- 计划提醒方式 -->
  44. <sd-form-item-td name="planRemindType" :colspan="3" />
  45. </tr>
  46. <!-- <tr>
  47. <td
  48. class="ant-form-item-label ant-form-item-label"
  49. :colspan="4"
  50. style="background: none;border: none;font-size: 22px;font-weight: bold;color: #404040;"
  51. >
  52. 《整改反馈》提醒规则设置</td
  53. >
  54. </tr> -->
  55. <tr
  56. ><td style="border:none" colspan="4">
  57. <audit-advanced-group
  58. :expand="TxExpand"
  59. :expand-str="'TxExpand'"
  60. :group-label="'《整改反馈》提醒规则设置'"
  61. tablestyle="''"
  62. @changedClick="changedClick"
  63. ></audit-advanced-group> </td
  64. ></tr>
  65. <tr v-show="TxExpand">
  66. <!-- 反馈频率 -->
  67. <sd-form-item-td
  68. name="feedbackFrequency"
  69. :colspan="3"
  70. @change="changeFeedbackFrequency"
  71. />
  72. </tr>
  73. <tr v-show="TxExpand">
  74. <!-- 提醒设置 -->
  75. <sd-form-item-td name="remindSetting" :colspan="3">
  76. <template>
  77. <audit-remind-setting
  78. v-model="model.remindSetting"
  79. :feedback-cycle="model.feedbackFrequency"
  80. />
  81. </template>
  82. </sd-form-item-td>
  83. </tr>
  84. <tr v-show="TxExpand">
  85. <!-- 反馈提醒对象 -->
  86. <sd-form-item-td name="feedbackRemindObject" :colspan="3" />
  87. </tr>
  88. <tr v-show="TxExpand">
  89. <!-- 反馈提醒方式 -->
  90. <sd-form-item-td name="feedbackRemindType" :colspan="3" />
  91. </tr>
  92. <tr
  93. ><td style="border:none" colspan="4">
  94. <audit-advanced-group
  95. :expand="CqtxExpand"
  96. :expand-str="'CqtxExpand'"
  97. :group-label="'《整改超期》提醒规则设置'"
  98. tablestyle="''"
  99. @changedClick="changedClick"
  100. ></audit-advanced-group> </td
  101. ></tr>
  102. <!-- <tr>
  103. <td class="ant-form-item-label ant-form-item-label" :colspan="4">
  104. 《整改超期》提醒规则设置</td
  105. >
  106. </tr> -->
  107. <!-- <tr>
  108. // 整改到期前天数
  109. <sd-form-item-td name="rectificationTimeLimit" :colspan="3" />
  110. </tr> -->
  111. <tr v-show="CqtxExpand">
  112. <!-- 整改提醒对象 -->
  113. <sd-form-item-td name="rectificationRemindObject" :colspan="3" />
  114. </tr>
  115. <tr v-show="CqtxExpand">
  116. <!-- 整改提醒方式 -->
  117. <sd-form-item-td name="rectificationRemindType" :colspan="3" />
  118. <sd-form-item-td :hidden="true" name="orgId" />
  119. </tr>
  120. </table>
  121. </template>
  122. </sd-detail-form>
  123. </audit-form-top-banner>
  124. </span>
  125. <!-- </div> -->
  126. </template>
  127. <script>
  128. import { Message } from 'ant-design-vue'
  129. import axios from '@/common/services/axios-instance'
  130. import auditFormTopBanner from '../../components/audit-form-top-banner'
  131. import auditAdvancedGroupMixins from '../../components/audit-advanced-group-mixins'
  132. import auditAdvancedGroup from '../../components/audit-advanced-group.vue'
  133. import auditRemindConfigService from './audit-remind-config-service'
  134. import auditRemindSetting from './audit-remind-setting'
  135. import components from './_import-components/audit-remind-config-import'
  136. export default {
  137. name: 'AuditRemindConfig',
  138. metaInfo: {
  139. title: '整改提醒',
  140. },
  141. components: {
  142. ...components,
  143. auditFormTopBanner,
  144. auditRemindSetting,
  145. auditAdvancedGroup,
  146. },
  147. mixins: [auditAdvancedGroupMixins],
  148. data() {
  149. return {
  150. recordId: null,
  151. key: 0,
  152. basicExpand: true,
  153. TxExpand: true,
  154. CqtxExpand: true,
  155. }
  156. },
  157. created() {
  158. this.init()
  159. },
  160. methods: {
  161. saved() {
  162. Message.success({ content: '保存成功!' }, 1).then(() => {})
  163. },
  164. // 保存
  165. saveForm() {
  166. this.$refs.docform.saveBtnClick()
  167. },
  168. init() {
  169. axios({
  170. url: `api/xcoa-mobile/v1/iam-audit-frame-item/getAuditOrgId`,
  171. }).then((resMm) => {
  172. if (resMm.data) {
  173. const params = { auditOrgId: resMm.data }
  174. auditRemindConfigService.findIamAuditRemindConfigEntity(params).then((res) => {
  175. if (res.data) {
  176. this.recordId = res.data.id
  177. this.key++
  178. }
  179. })
  180. }
  181. })
  182. },
  183. // 频率
  184. changeFeedbackFrequency(value) {
  185. if (value === 1) {
  186. // 月
  187. } else if (value === 2) {
  188. // 季
  189. } else if (value === 3) {
  190. // 半年
  191. } else if (value === 4) {
  192. // 年
  193. }
  194. },
  195. },
  196. }
  197. </script>
  198. <style module lang="scss">
  199. @use '@/common/design' as *;
  200. @import '@/webflow/sd-flow-form.scss';
  201. .remind-table {
  202. table-layout: auto !important;
  203. :global(.ant-form-item-label) {
  204. width: 15% !important;
  205. }
  206. }
  207. .remindconfig {
  208. :global(.ant-layout) {
  209. background: #fff;
  210. }
  211. :global(.ant-layout-header) {
  212. background: #fff;
  213. }
  214. :global(.close-btn_audit-form-top-banner_product) {
  215. display: none;
  216. }
  217. }
  218. </style>