| | |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="客户名称" prop="customName"> |
| | | <el-form-item label="客户名称" prop="clientId"> |
| | | <div class="custom-name"> |
| | | <el-input v-model="editConfig.infomation.customName"></el-input> |
| | | <el-input v-model="editConfig.infomation.clientId"></el-input> |
| | | <div class="common-select-btn"><i class="el-icon-circle-plus-outline" title="选择"></i></div> |
| | | <div class="common-select-btn"><i class="el-icon-edit" title="编辑"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="工单编号" prop="orderNumber"> |
| | | <el-input v-model="editConfig.infomation.orderNumber"></el-input> |
| | | <el-form-item label="工单编号" prop="number"> |
| | | <el-input v-model="editConfig.infomation.number"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="工单名称" prop="orderName"> |
| | | <el-input v-model="editConfig.infomation.orderName"></el-input> |
| | | <el-form-item label="工单名称" prop="name"> |
| | | <el-input v-model="editConfig.infomation.name"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="工单类型" prop="orderType"> |
| | | <CommonSelectView |
| | | :common-value="editConfig.infomation.orderType" |
| | | :common-options="orderTypeOptions" |
| | | /> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.orderType" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in orderTypeOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系人姓名" prop="contactName"> |
| | | <el-form-item label="联系人姓名" prop="contactId"> |
| | | <div class="custom-name"> |
| | | <el-input v-model="editConfig.infomation.contactName"></el-input> |
| | | <el-input v-model="editConfig.infomation.contactId"></el-input> |
| | | <div class="common-select-btn"><i class="el-icon-circle-plus-outline" title="选择"></i></div> |
| | | <div class="common-select-btn"><i class="el-icon-edit" title="编辑"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="报修来源" prop="repairSource"> |
| | | <CommonSelectView |
| | | :common-value="editConfig.infomation.repairSource" |
| | | :common-options="repairSourceOptions" |
| | | /> |
| | | <el-form-item label="报修来源" prop="reportSourceId"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.reportSourceId" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in reportSourceOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="选择源单" prop="selSourceOrder"> |
| | | <el-select v-model="editConfig.infomation.selSourceOrder" size="mini"> |
| | | <!-- <el-col :span="12"> |
| | | <el-form-item label="选择源单" prop="sourceSheet"> |
| | | <el-select v-model="editConfig.infomation.sourceSheet" size="mini"> |
| | | <el-option |
| | | v-for="item in selSourceOrderOptions" |
| | | v-for="item in sourceSheetOptions" |
| | | :key="item.value" |
| | | :label="item.label" |
| | | :value="item.value" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-col> --> |
| | | </el-row> |
| | | </div> |
| | | <!-- 问题描述 --> |
| | |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item label="问题描述" prop="problemDesc"> |
| | | <el-form-item label="问题描述" prop="problemDescription"> |
| | | <el-input |
| | | type="textarea" |
| | | :autosize="{ minRows: 2, maxRows: 4 }" |
| | | placeholder="请输入内容" |
| | | v-model="editConfig.infomation.problemDesc" |
| | | v-model="editConfig.infomation.problemDescription" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | </el-row> |
| | | </div> |
| | | <!-- 选择审批流程 --> |
| | | <div class="basic-info-title">选择审批流程</div> |
| | | <!-- <div class="basic-info-title">选择审批流程</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="20"> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | </div> --> |
| | | </div> |
| | | </el-form> |
| | | |
| | | <div slot="footer" class="dialog-footer"> |
| | | <el-button type="primary" size="small" @click="editConfig.visible = false">保并提交审批</el-button> |
| | | <el-button type="primary" size="small" @click="editConfig.visible = false">保存</el-button> |
| | | <!-- <el-button type="primary" size="small" @click="editConfig.visible = false">保并提交审批</el-button> --> |
| | | <el-button type="primary" size="small" @click="saveClick('form')">保存</el-button> |
| | | <el-button size="small" @click="editConfig.visible = false">取消</el-button> |
| | | </div> |
| | | </el-dialog> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import CommonSelectView from "@/components/makepager/CommonSelectView" |
| | | import { getAllData } from "@/api/client/client" |
| | | import { getAddSubOrder, getUpdateSubOrder } from "@/api/sales/subOrder" |
| | | import { getAddOrderManage, getUpdateOrderManage } from "@/api/serviceManage/orderManage" |
| | | export default { |
| | | name: "AddOrderManageDialog", |
| | | props: { |
| | |
| | | } |
| | | } |
| | | }, |
| | | components: { CommonSelectView }, |
| | | components: {}, |
| | | computed: { |
| | | searchCommonHeight() { |
| | | return this.$refs.searchCommonView.offsetHeight |
| | |
| | | dialogWidth: "80%", |
| | | editConfig: this.editCommonConfig, |
| | | rules: { |
| | | customName: [{ required: true, message: "请输入客户名称", trigger: "blur" }], |
| | | orderNumber: [{ required: true, message: "请输入工单编号", trigger: "blur" }], |
| | | clientId: [{ required: true, message: "请输入客户名称", trigger: "blur" }], |
| | | number: [{ required: true, message: "请输入工单编号", trigger: "blur" }], |
| | | orderType: [{ required: true, message: "请选择", trigger: "change" }], |
| | | problemDesc: [{ required: true, message: "请输入问题描述", trigger: "blur" }] |
| | | problemDescription: [{ required: true, message: "请输入问题描述", trigger: "blur" }] |
| | | }, |
| | | orderTypeOptions: [], // 工单类型 |
| | | repairSourceOptions: [], // 报修来源 |
| | | selSourceOrderOptions: [ |
| | | orderTypeOptions: [{ id: 1, name: "类型1" }], // 工单类型 |
| | | reportSourceOptions: [], // 报修来源 |
| | | sourceSheetOptions: [ |
| | | { value: "1", label: "销售明细单" }, |
| | | { value: "2", label: "服务合同" } |
| | | ], |
| | |
| | | const params = this.saveParams() |
| | | console.log(params) |
| | | if (this.editConfig.title === "新建") { |
| | | getAddSubOrder(params) |
| | | getAddOrderManage(params) |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.editConfig.visible = false |
| | |
| | | console.log(err) |
| | | }) |
| | | } else { |
| | | getUpdateSubOrder(params) |
| | | getUpdateOrderManage(params) |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.editConfig.visible = false |
| | |
| | | let data = this.editConfig.infomation |
| | | let params = { |
| | | id: this.editConfig.title === "新建" ? 0 : data.id, |
| | | clientId: data.clientId || 0, |
| | | masterOrderId: data.masterOrderId || 0, |
| | | memberId: data.memberId || 0, |
| | | clientId: parseInt(data.clientId) || 0, |
| | | contactId: data.contactId || 0, |
| | | file: data.file || "", |
| | | name: data.name || "", |
| | | number: data.number || "", |
| | | product: [ |
| | | { |
| | | amount: 0, |
| | | desc: "", |
| | | id: 0, |
| | | name: "", |
| | | number: "", |
| | | price: 0, |
| | | total: 0 |
| | | } |
| | | ] |
| | | orderType: data.orderType || 0, |
| | | problemDescription: data.problemDescription || "", |
| | | reportSourceId: data.reportSourceId || 0, |
| | | sourceSheet: data.sourceSheet || 0 |
| | | } |
| | | return params |
| | | }, |
| | |
| | | font-size: 18px; |
| | | } |
| | | } |
| | | .common-select { |
| | | display: flex; |
| | | .common-select-sel { |
| | | width: 270px; |
| | | } |
| | | .common-select-btn { |
| | | margin-left: 5px; |
| | | font-size: 16px; |
| | | cursor: pointer; |
| | | } |
| | | } |
| | | } |
| | | .annex-view { |
| | | display: flex; |