对接法规/认证任务计划、设定
This commit is contained in:
@@ -135,7 +135,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getAction, postAction } from '@/api/manage'
|
||||
import { getAction, postAction, putAction } from '@/api/manage'
|
||||
import moment from 'moment'
|
||||
|
||||
export default {
|
||||
@@ -153,19 +153,35 @@
|
||||
mounted() {
|
||||
},
|
||||
methods: {
|
||||
edit(data) {
|
||||
edit() {
|
||||
this.visible = true
|
||||
this.$nextTick(() => {
|
||||
this.ids = data || []
|
||||
this.formInline = {}
|
||||
this.settingQueryForm()
|
||||
},
|
||||
settingQueryForm() {
|
||||
getAction(this.url.settingQueryForm, { projectId: this.$route.query.id }).then((res) => {
|
||||
if (res.success) {
|
||||
this.$nextTick(() => {
|
||||
this.formInline = res.result || {}
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
handleOk() {
|
||||
let query = {
|
||||
...this.formInline
|
||||
...this.formInline,
|
||||
projectId: this.$route.query.id
|
||||
}
|
||||
let url = ''
|
||||
let Action
|
||||
if (this.formInline.id) {
|
||||
url = this.url.editSettingUrl
|
||||
Action = putAction
|
||||
} else {
|
||||
url = this.url.addSettingUrl
|
||||
Action = postAction
|
||||
}
|
||||
this.confirmLoading = true
|
||||
postAction(this.url.editSettingUrl, query).then((res) => {
|
||||
Action(url, query).then((res) => {
|
||||
if (res.success) {
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
this.visible = false
|
||||
|
||||
Reference in New Issue
Block a user