|
|
@@ -0,0 +1,96 @@
|
|
|
+<!--
|
|
|
+ * @Author: wanglj 471442253@qq.com
|
|
|
+ * @Date: 2022-12-26 14:34:34
|
|
|
+ * @LastEditors: wanglj
|
|
|
+ * @LastEditTime: 2023-01-13 09:41:38
|
|
|
+ * @Description: file content
|
|
|
+ * @FilePath: \opms_frontend\src\views\customer\components\allocate.vue
|
|
|
+-->
|
|
|
+<template>
|
|
|
+ <el-dialog title="提交审核" :visible.sync="visible" width="50%" @close="handleClose">
|
|
|
+ <el-form ref="form" label-width="150px" :model="form" :rules="rules">
|
|
|
+ <el-form-item label="合同模板" prop="contractModel">
|
|
|
+ <el-radio-group v-model="form.contractModel">
|
|
|
+ <el-radio label="大数模板" />
|
|
|
+ <el-radio label="客户模板" />
|
|
|
+ </el-radio-group>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="条款情况" prop="terms">
|
|
|
+ <el-radio-group v-model="form.terms">
|
|
|
+ <el-radio label="接纳全部条款" />
|
|
|
+ <el-radio label="不接纳全部条款" />
|
|
|
+ </el-radio-group>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="付款条件" prop="payTerms">
|
|
|
+ <el-input
|
|
|
+ v-model="form.payTerms"
|
|
|
+ maxlength="500"
|
|
|
+ placeholder="请输入付款条件"
|
|
|
+ resize="none"
|
|
|
+ :rows="5"
|
|
|
+ show-word-limit
|
|
|
+ type="textarea" />
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ <span slot="footer">
|
|
|
+ <el-button size="mini" type="primary" @click="handleSubmit">确定</el-button>
|
|
|
+ <el-button size="mini" @click="visible = false">取消</el-button>
|
|
|
+ </span>
|
|
|
+ </el-dialog>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+ import contractApi from '@/api/contract'
|
|
|
+ import to from 'await-to-js'
|
|
|
+ export default {
|
|
|
+ components: {},
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ visible: false,
|
|
|
+ form: {
|
|
|
+ id: 0,
|
|
|
+ contractModel: '',
|
|
|
+ terms: '',
|
|
|
+ payTerms: '',
|
|
|
+ file: [
|
|
|
+ // {
|
|
|
+ // spaceId: '',
|
|
|
+ // fileId: '',
|
|
|
+ // fileName: '',
|
|
|
+ // fileSize: 0,
|
|
|
+ // fileType: '',
|
|
|
+ // },
|
|
|
+ ],
|
|
|
+ },
|
|
|
+ rules: {
|
|
|
+ contractModel: [{ required: true, trigger: 'blur', message: '请选择合同模板' }],
|
|
|
+ terms: [{ required: true, trigger: 'blur', message: '请选择条款情况' }],
|
|
|
+ payTerms: [{ required: true, trigger: 'blur', message: '请选择付款条件' }],
|
|
|
+ },
|
|
|
+ }
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ handleClose() {
|
|
|
+ this.form = {
|
|
|
+ id: 0,
|
|
|
+ contractModel: '',
|
|
|
+ terms: '',
|
|
|
+ payTerms: '',
|
|
|
+ file: [],
|
|
|
+ }
|
|
|
+ },
|
|
|
+ async handleSubmit() {
|
|
|
+ const [valid] = await to(this.$refs.form.validate())
|
|
|
+ if (valid == false) return
|
|
|
+ if (this.form.file.length == 0) return this.$message.warning('附件不能为空')
|
|
|
+ const [err, res] = await to(contractApi.commit(this.form))
|
|
|
+ if (err) return
|
|
|
+ this.$message.success(res.msg)
|
|
|
+ this.visible = false
|
|
|
+ this.$emit('refresh')
|
|
|
+ },
|
|
|
+ },
|
|
|
+ }
|
|
|
+</script>
|
|
|
+
|
|
|
+<style></style>
|