|
@@ -165,7 +165,7 @@
|
|
import { ref, reactive, onMounted, inject } from "vue";
|
|
import { ref, reactive, onMounted, inject } from "vue";
|
|
import type { ElTable, FormInstance, FormRules, UploadRequestOptions } from 'element-plus'
|
|
import type { ElTable, FormInstance, FormRules, UploadRequestOptions } from 'element-plus'
|
|
import { useRouter, useRoute } from "vue-router";
|
|
import { useRouter, useRoute } from "vue-router";
|
|
-import { GETSYSFILED, MOD, GETPERSONNEL, GETGENERATEFOEM, GETBUSINESSLIST, UPDATEINSET, BUSINESSDETELE, BATCHTRANSFER, MODURL, tableColumn } from './api'
|
|
|
|
|
|
+import { GETSYSFILED, MOD, GETPERSONNEL, GETGENERATEFOEM, GETBUSINESSLIST, UPDATEINSET, BUSINESSDETELE, BATCHTRANSFER, MODURL, tableColumn, BUSIESS_GETSATE } from './api'
|
|
import { GETTABLELIST } from '@/pages/product/api'
|
|
import { GETTABLELIST } from '@/pages/product/api'
|
|
import { post, get, uploadFile } from "@/utils/request";
|
|
import { post, get, uploadFile } from "@/utils/request";
|
|
import { getAllListByCode, getFromValue, resetFromValue, getFirstDayOfMonth, createTaskFromType, formatDate, confirmAction, downloadTemplate, downloadFile } from '@/utils/tools'
|
|
import { getAllListByCode, getFromValue, resetFromValue, getFirstDayOfMonth, createTaskFromType, formatDate, confirmAction, downloadTemplate, downloadFile } from '@/utils/tools'
|
|
@@ -394,15 +394,21 @@ function resetForm() {
|
|
}
|
|
}
|
|
|
|
|
|
async function getSystemField() {
|
|
async function getSystemField() {
|
|
- const systemField = getAllListByCode(['商机阶段'])
|
|
|
|
- for (let i in systemField) {
|
|
|
|
- const { data } = await get(`${GETSYSFILED}?code=${systemField[i]}`)
|
|
|
|
- for (let key of Object.keys(fixedData)) {
|
|
|
|
- if (systemField[i] == key) {
|
|
|
|
- Object.assign(fixedData, { [key]: data })
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
|
|
+ // const systemField = getAllListByCode(['商机阶段'])
|
|
|
|
+ // for (let i in systemField) {
|
|
|
|
+ // const { data } = await get(`${GETSYSFILED}?code=${systemField[i]}`)
|
|
|
|
+ // for (let key of Object.keys(fixedData)) {
|
|
|
|
+ // if (systemField[i] == key) {
|
|
|
|
+ // Object.assign(fixedData, { [key]: data })
|
|
|
|
+ // }
|
|
|
|
+ // }
|
|
|
|
+ // }
|
|
|
|
+
|
|
|
|
+ const row = await post(BUSIESS_GETSATE, {})
|
|
|
|
+ fixedData.BusinessStage = (row.data || []).map((item: any) => {
|
|
|
|
+ const { name, id, seq } = item
|
|
|
|
+ return { name, id, seq }
|
|
|
|
+ }).sort(function (a: any, b: any) {return a.seq - b.seq;});
|
|
|
|
|
|
const { data } = await post(GETPERSONNEL, {})
|
|
const { data } = await post(GETPERSONNEL, {})
|
|
fixedData.Personnel = data.map((item: any) => {
|
|
fixedData.Personnel = data.map((item: any) => {
|