Bläddra i källkod

Merge branch 'master' of http://47.100.37.243:10191/wutt/manHourHousekeeper

QuYueTing 4 månader sedan
förälder
incheckning
f01e4c7070
27 ändrade filer med 161 tillägg och 92 borttagningar
  1. 2 2
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/moduleList/moduleList.vue
  2. 4 1
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/business/businessInfo.vue
  3. 3 2
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/contacts/contactsInfo.vue
  4. 2 1
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/customer/customerInfo.vue
  5. 2 1
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/order/orderInfo.vue
  6. 2 1
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/product/productInfo.vue
  7. 3 1
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/tasks/detail.vue
  8. 3 2
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/thread/threadInfo.vue
  9. 22 12
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/tabbar/home/component/workbench.vue
  10. 11 2
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/tabbar/news/index.vue
  11. 9 1
      fhKeeper/formulahousekeeper/customerBuler-crm-h5/vite.config.js
  12. 1 1
      fhKeeper/formulahousekeeper/customerBuler-crm/src/components/svgIcon/index.vue
  13. 1 1
      fhKeeper/formulahousekeeper/customerBuler-crm/src/main.ts
  14. 1 0
      fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/analysis/index.vue
  15. 1 1
      fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/business/component/kanbanView.vue
  16. 5 7
      fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/business/index.vue
  17. 23 19
      fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/corpreport/index.vue
  18. 4 3
      fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/customer/index.vue
  19. 15 2
      fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/header/header.vue
  20. 7 1
      fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/login.vue
  21. 2 1
      fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/order/index.vue
  22. 3 1
      fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/team/index.vue
  23. 2 2
      fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/thread/detail/components/information.vue
  24. 2 2
      fhKeeper/formulahousekeeper/customerBuler-crm/src/utils/translationProcessing.ts
  25. 4 0
      fhKeeper/formulahousekeeper/management-crm/src/main/java/com/management/platform/controller/CustomController.java
  26. 4 1
      fhKeeper/formulahousekeeper/management-crm/src/main/java/com/management/platform/service/impl/ExcelExportServiceImpl.java
  27. 23 24
      fhKeeper/formulahousekeeper/management-crm/src/main/java/com/management/platform/service/impl/UserServiceImpl.java

+ 2 - 2
fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/moduleList/moduleList.vue

@@ -81,7 +81,7 @@
                               <div class="text-[#B9B9B9] text-size-small w-2/5 truncate" v-if="item.ownerName">客户:{{
                                 item.customName }}</div>
                               <div class="text-[#B9B9B9] text-size-small w-2/5 truncate text-right" v-if="item.ownerName">负责人:  
-                                <TranslationComponent :openId="item.inchargerName" />
+                                <TranslationComponent :openId="item.ownerName" />
                               </div>
                             </div>
                           </div>
@@ -217,7 +217,7 @@
         @confirm="confirmTransfer" :before-close="dialogCloseBefo">
         <van-cell title="转移至" is-link @click="showSelect = true">
           <template #value>
-            {{ dialogSelection.label }}
+            <TranslationComponent :openId="dialogSelection.label" />
           </template>
         </van-cell>
         <div class="themeTextColor text-size-small pl-4 pt-2 pb-2">转移后,将看不到此{{ queryParameters?.name || '' }}</div>

+ 4 - 1
fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/business/businessInfo.vue

@@ -34,7 +34,7 @@
       :before-close="dialogCloseBefo">
       <van-cell title="转移至" is-link @click="showSelect = true">
         <template #value>
-          {{ dialogSelection.label }}
+          <TranslationComponent :openId="dialogSelection.label" />
         </template>
       </van-cell>
       <div class="themeTextColor text-size-small pl-4 pt-2 pb-2">转移后,将看不到此商机了</div>
@@ -218,6 +218,9 @@ function dialogCloseBefo(val) {
 }
 
 function getAllContactsList() {
+  if(!props.info.customerId) {
+    return
+  }
   requests.get(`${GET_CONTACTS_WITH_MORE_I_DS}?customerId=${props.info.customerId}`).then(({ data = [] }) => {
     let list = data.map(item => {
       return {

+ 3 - 2
fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/contacts/contactsInfo.vue

@@ -25,7 +25,8 @@
       :before-close="dialogCloseBefo">
       <van-cell title="转移至" is-link @click="showSelect = true">
         <template #value>
-          {{ dialogSelection.label }}
+          <!-- {{ dialogSelection.label }} -->
+          <TranslationComponent :openId="dialogSelection.label" />
         </template>
       </van-cell>
       <div class="themeTextColor text-size-small pl-4 pt-2 pb-2">转移后,将看不到此联系人了</div>
@@ -114,7 +115,7 @@ function confirmTransfer() {
     return toastText('请选择要转移的人员')
   }
 
-  requests.post(TRANSFER_CONTACT_PERSON, { ids: props.info.id, ownerId: dialogSelection.value.value }).then((res) => {
+  requests.post(TRANSFER_CONTACT_PERSON, { id: props.info.id, ownerId: dialogSelection.value.value }).then((res) => {
     toastSuccess('转移成功')
     showDialog.value = false
     setTimeout(() => {

+ 2 - 1
fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/customer/customerInfo.vue

@@ -29,7 +29,8 @@
       :before-close="dialogCloseBefo">
       <van-cell title="转移至" is-link @click="showSelect = true">
         <template #value>
-          {{ dialogSelection.label }}
+          <!-- {{ dialogSelection.label }} -->
+          <TranslationComponent :openId="dialogSelection.label" />
         </template>
       </van-cell>
       <div class="themeTextColor text-size-small pl-4 pt-2 pb-2">转移后,将看不到此客户了</div>

+ 2 - 1
fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/order/orderInfo.vue

@@ -57,7 +57,8 @@
       @confirm="confirmTransfer" :before-close="dialogCloseBefo">
       <van-cell title="转移至" is-link @click="showSelect = true">
         <template #value>
-          {{ dialogSelection.label }}
+          <!-- {{ dialogSelection.label }} -->
+          <TranslationComponent :openId="dialogSelection.label" />
         </template>
       </van-cell>
       <div class="themeTextColor text-size-small pl-4 pt-2 pb-2">转移后,将看不到此销售订单了</div>

+ 2 - 1
fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/product/productInfo.vue

@@ -35,7 +35,8 @@
       :before-close="dialogCloseBefo">
       <van-cell title="转移至" is-link @click="showSelect = true">
         <template #value>
-          {{ dialogSelection.label }}
+          <!-- {{ dialogSelection.label }} -->
+          <TranslationComponent :openId="dialogSelection.label" />
         </template>
       </van-cell>
       <div class="themeTextColor text-size-small pl-4 pt-2 pb-2">转移后,将看不到此产品了</div>

+ 3 - 1
fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/tasks/detail.vue

@@ -65,7 +65,7 @@
     </van-popup>
 
     <van-popup v-model:show="showDatePicker" destroy-on-close position="bottom" :style="{ height: '50%' }">
-      <van-date-picker v-model="showDatePickerVal" @confirm="showPickerConfirm" @cancel="showDatePicker = false" />
+      <van-date-picker v-model="showDatePickerVal" @confirm="showPickerConfirm" :min-date="timeJudgment" @cancel="showDatePicker = false" />
     </van-popup>
   </div>
 </template>
@@ -105,6 +105,7 @@ const todaySDate = dayjs(new Date()).format('YYYY-MM-DD')
 const showStartDelayData = ref('');
 const showEndtDelayData = ref('');
 const showDateType = ref('');
+const timeJudgment = ref(new Date())
 
 watch(() => props.info, (newValue) => {
   initializeData(newValue.id)
@@ -126,6 +127,7 @@ function showPickerConfirm({ selectedValues }) {
 function showDatePickerCli(type) {
   showDateType.value = type
   const types = type == 'showStartDelayData' ? showStartDelayData.value : showEndtDelayData.value
+  timeJudgment.value = type == 'showStartDelayData' ? new Date : new Date(showStartDelayData.value)
   showDatePickerVal.value = types.split('-')
   showDatePicker.value = true
 }

+ 3 - 2
fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/pageComponents/thread/threadInfo.vue

@@ -28,7 +28,8 @@
       @confirm="confirmTransfer" :before-close="dialogCloseBefo">
       <van-cell title="转移至" is-link @click="showSelect = true">
         <template #value>
-          {{ dialogSelection.label }}
+          <!-- {{ dialogSelection.label }} -->
+          <TranslationComponent :openId="dialogSelection.label" />
         </template>
       </van-cell>
       <div class="themeTextColor text-size-small pl-4 pt-2 pb-2">转移后,将看不到此线索了</div>
@@ -140,7 +141,7 @@ function confirmTransfer() {
     return toastText('请选择要转移的人员')
   }
 
-  requests.post(TRANSFER_CLUES, { id: props.info.id, inchargerId: dialogSelection.value.value }).then((res) => {
+  requests.post(TRANSFER_CLUES, { ids: props.info.id, inchargerId: dialogSelection.value.value }).then((res) => {
     toastSuccess('转移成功')
     showDialog.value = false
     setTimeout(() => {

+ 22 - 12
fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/tabbar/home/component/workbench.vue

@@ -79,7 +79,8 @@
       <div class="p16 pt-0 pb-0 flex justify-between overflow-x-auto">
         <div class="flex">
           <template v-for="item in commonModulesList">
-            <div class="w80 bg-[#FFA359] h-28 rounded-md flex flex-col items-center justify-center" @click="jumpToAdd(item)">
+            <div class="w80 bg-[#FFA359] h-28 rounded-md flex flex-col items-center justify-center"
+              @click="jumpToAdd(item)">
               <div class="formImage">
                 <img class="w-full h-full" src="/src/assets/image/form.png">
               </div>
@@ -102,16 +103,21 @@
     <div class="mt-3" v-if="displayFrequentlyUsedContacts">
       <div class="text-size-large text-[#000] pl16">常用联系人</div>
       <div class="p16 pt-0 pb-0">
-        <template v-for="item in topContactsList">
-          <div class="flex flex-row items-center rounded-md p-4 bg-white mb-5" @click="toContactDetails(item)">
-            <div class="contactImage">
-              <img class="w-full h-full" src="/src/assets/image/topContacts.png">
-            </div>
-            <div class="flex-1">{{ item.name }}</div>
-            <div class="rightArrow">
-              <van-icon name="arrow" />
+        <template v-if="topContactsList && topContactsList.length > 0">
+          <template v-for="item in topContactsList">
+            <div class="flex flex-row items-center rounded-md p-4 bg-white mb-5" @click="toContactDetails(item)">
+              <div class="contactImage">
+                <img class="w-full h-full" src="/src/assets/image/topContacts.png">
+              </div>
+              <div class="flex-1">{{ item.name }}</div>
+              <div class="rightArrow">
+                <van-icon name="arrow" />
+              </div>
             </div>
-          </div>
+          </template>
+        </template>
+        <template v-else>
+          <van-empty description="暂无常用联系人" />
         </template>
       </div>
     </div>
@@ -219,6 +225,10 @@ function toContactDetails(item) {
 }
 
 function saveCommonlyUsedForms() {
+  if(commonExpressionsHaveBeenAdded.value.map(item => item.id).length <= 0) {
+    toastText(`最少请选择一个常用表单!`)
+    return
+  }
   const moduleIds = commonExpressionsHaveBeenAdded.value.map(item => item.id).join(',')
   requests.post(SAVE_COMMONLY_USED_FORMS, { moduleIds }).then((res) => {
     toastSuccess('保存成功')
@@ -319,8 +329,8 @@ function processForms() {
 }
 
 function getVisitorPlan() {
-  requests.post(GET_VISITOR_PLAN, { 
-    calenderDate: dayjs(dateConditions.value).format('YYYY-MM-DD') 
+  requests.post(GET_VISITOR_PLAN, {
+    calenderDate: dayjs(dateConditions.value).format('YYYY-MM-DD')
   }).then((res) => {
     visitorProgramList.value = res.data || []
   })

+ 11 - 2
fhKeeper/formulahousekeeper/customerBuler-crm-h5/src/pages/tabbar/news/index.vue

@@ -14,7 +14,13 @@
               <img src="/src/assets/image/news.png" alt="">
             </div>
             <div class="flex-1">
-              <div class="text-size-in text-[#000]">{{ item.msg }}</div>
+              <div class="text-size-in text-[#000]">
+                <!-- {{ item.msg }} -->
+                {{ item.msgTextList[0] || '' }}
+                <TranslationComponent :openId="item.msgTextList[1]" v-if="(item.msgTextList || []).length > 1">
+                </TranslationComponent>
+                {{ item.msgTextList[2] || '' }}
+              </div>
               <div class="text-[#B9B9B9]">{{ item.timeStr }}</div>
             </div>
             <van-icon name="arrow" color="#D4D4D4" size="1.2rem" />
@@ -49,9 +55,12 @@ const messageList = ref([]);
 function getMessageList() {
   requests.post(GET_MESSAGE_LIST, {}).then(({ data = [] }) => {
     messageList.value = (data || []).map(item => {
+      let str = item.msg || ''
+      let arr = str.split(/\$|=/).filter((item) => item && item !== 'username');
       return {
         ...item,
-        timeStr: dayjs(item.time).format('YYYY-MM-DD HH:mm')
+        timeStr: dayjs(item.time).format('YYYY-MM-DD HH:mm'),
+        msgTextList: arr || []
       }
     })
     userInfo.updateState({

+ 9 - 1
fhKeeper/formulahousekeeper/customerBuler-crm-h5/vite.config.js

@@ -43,7 +43,15 @@ export default defineConfig({
     }
   },
   build: {
-    chunkSizeWarningLimit: 1600
+    chunkSizeWarningLimit: 1600,
+    rollupOptions: {
+      output: {
+        entryFileNames: `assets/[name].[hash].js`,
+        chunkFileNames: `assets/[name].[hash].js`,
+        assetFileNames: `assets/[name].[hash].[ext]`,
+       
+      }
+    },
   },
   vue: {
     compilerOptions: {

+ 1 - 1
fhKeeper/formulahousekeeper/customerBuler-crm/src/components/svgIcon/index.vue

@@ -8,7 +8,7 @@
 </template>
 
 <script lang="ts" name="svgIcon" setup>
-import 'http://at.alicdn.com/t/c/font_4766628_7ekfe85jxt9.js' // 引入阿里图标库
+import 'https://at.alicdn.com/t/c/font_4766628_7ekfe85jxt9.js' // 引入阿里图标库
 import {computed} from 'vue';
 
 // 定义父组件传过来的值

+ 1 - 1
fhKeeper/formulahousekeeper/customerBuler-crm/src/main.ts

@@ -35,7 +35,7 @@ app.config.globalProperties.$echarts = echarts;
 app
   .use(ElementPlus, {
     locale: zhCn,
-    zIndex: 1600,
+    zIndex: 1200,
   })
   .use(createPinia())
   .use(router)

+ 1 - 0
fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/analysis/index.vue

@@ -331,6 +331,7 @@ watchEffect(() => {
               title="转成交客户"
               unit="个"
               :number="requestData.summary?.customDataSummary.closeDealNum"
+              v-if="false"
             />
           </div>
           <Divider title="商机汇总" />

+ 1 - 1
fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/business/component/kanbanView.vue

@@ -182,7 +182,7 @@ defineExpose({
               </div>
               <div class="flex items-center mt-4">
                 <SvgIcon name="fuzeren" :size="20" color="#606266" class="mr-2" />
-                {{ subItem.inchargerName }}
+                <TextTranslation :translationValue="subItem.inchargerName" :translationTypes="'userName'" />
               </div>
               <div class="flex items-center mt-4">
                 ¥ {{ subItem.amountOfMoney || 0 }}

+ 5 - 7
fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/business/index.vue

@@ -205,14 +205,13 @@
 
 <script lang="ts" setup>
 import { ref, reactive, onMounted, inject } from "vue";
-import type { ElTable, FormInstance, FormRules, UploadRequestOptions } from 'element-plus'
-import { useRouter, useRoute } from "vue-router";
-import { GETSYSFILED, MOD, GETPERSONNEL, GETGENERATEFOEM, GETBUSINESSLIST, UPDATEINSET, BUSINESSDETELE, BATCHTRANSFER, MODURL, tableColumn, BUSIESS_GETSATE, URL_IMPOERBUSINESS, BUSIESS_INFO, URL_EXPORTBUSINESS, TABLE_VIEW, KANBAN_VIEW } from './api'
+import type { ElTable, UploadRequestOptions } from 'element-plus'
+import { useRouter } from "vue-router";
+import { MOD, GETPERSONNEL, GETGENERATEFOEM, GETBUSINESSLIST, UPDATEINSET, BUSINESSDETELE, BATCHTRANSFER, MODURL, tableColumn, BUSIESS_GETSATE, URL_IMPOERBUSINESS, BUSIESS_INFO, URL_EXPORTBUSINESS, TABLE_VIEW, KANBAN_VIEW } from './api'
 import { GETTABLELIST } from '@/pages/product/api'
 import { post, get, uploadFile } from "@/utils/request";
-import { getAllListByCode, getFromValue, resetFromValue, getFirstDayOfMonth, createTaskFromType, formatDate, confirmAction, downloadTemplate, downloadFile, judgmentaAmounteEqual } from '@/utils/tools'
+import { getFromValue, resetFromValue, getFirstDayOfMonth, createTaskFromType, formatDate, confirmAction, downloadTemplate, downloadFile, judgmentaAmounteEqual } from '@/utils/tools'
 import { createTask } from '@/components/TaskModal/taskFunction'
-import { formatDateTime } from '@/utils/times'
 import { GenerateForm } from '@zmjs/form-design';
 import { tableShowOverflowTooltip } from '@/utils/globalVariables'
 import RelatedProducts from '@/components/relatedProducts/relatedProducts.vue'
@@ -223,7 +222,6 @@ import { GETTABLELISTPRODUCT } from "../order/api";
 import personnelSearch from '@/components/translationComponent/personnelSearch/personnelSearch.vue';
 import kanbanView from "./component/kanbanView.vue";
 
-const route = useRoute()
 const router = useRouter()
 const globalPopup = inject<GlobalPopup>('globalPopup')
 const businessTableRef = ref<InstanceType<typeof ElTable>>() // 商机table dom
@@ -521,7 +519,7 @@ function getBusinessTableList() {
     businessTable.value = data.map((item: any) => {
       return {
         ...item,
-        expectedTransactionDate: formatDate(new Date(item.expectedTransactionDate))
+        expectedTransactionDate: item.expectedTransactionDate ? formatDate(new Date(item.expectedTransactionDate)) : ''
       }
     })
     businessTotalTable.value = total

+ 23 - 19
fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/corpreport/index.vue

@@ -100,10 +100,24 @@ const queryOverall = async (payload?: RequestProps) => {
     { type: 'bar', barWidth: 20 },
     { type: 'bar', barWidth: 20, color: '#b91c1c' }
   ];
+
+  if(userInfo && userInfo.value.userNameNeedTranslate == 1) {
+    dealWithTranslation(sourceDataTypes, sourceData).then((res: any) => {
+      // @ts-ignore
+      chartOptions.dataset.dimensions = ['name', '成交客户数', '新增客户数'];
+      // @ts-ignore
+      chartOptions.dataset.source = res
+      chartOptions.legend = {};
+    })
+
+    return
+  }
+
   // @ts-ignore
   chartOptions.dataset.dimensions = ['name', '成交客户数', '新增客户数'];
   // @ts-ignore
-  chartOptions.dataset.source = userInfo.userNameNeedTranslate == 1 ? dealWithTranslation(sourceDataTypes, sourceData) : sourceData
+  // chartOptions.dataset.source = userInfo.userNameNeedTranslate == 1 ? dealWithTranslation(sourceDataTypes, sourceData) : sourceData
+  chartOptions.dataset.source = sourceData
   // chartOptions.dataset.source = data.map((d) => ({
   //   name: form.type === 1 ? d.name : d.departmentName,
   //   ['成交客户数']: d.customerDeal,
@@ -168,12 +182,7 @@ watchEffect(async () => {
       <el-form :model="form" class="flex gap-4">
         <el-form-item>
           <el-select clearable v-model="form.date" style="width: 112px">
-            <el-option
-              v-for="date in dateOptions"
-              :key="date.value"
-              :label="date.label"
-              :value="date.value"
-            />
+            <el-option v-for="date in dateOptions" :key="date.value" :label="date.label" :value="date.value" />
           </el-select>
         </el-form-item>
         <el-form-item>
@@ -213,18 +222,13 @@ watchEffect(async () => {
         </el-form-item>
       </el-form>
 
-      <el-tabs
-        type="card"
-        v-model="dataType"
-        @tab-change="
-          () => {
-            form.date = undefined;
-            form.member = '';
-            form.type = 1;
-            dataSource = [];
-          }
-        "
-      >
+      <el-tabs type="card" v-model="dataType" @tab-change="() => {
+        form.date = undefined;
+        form.member = '';
+        form.type = 1;
+        dataSource = [];
+      }
+        ">
         <el-tab-pane label="客户总量分析" :name="0" />
         <el-tab-pane label="客户转化率分析" :name="1" />
       </el-tabs>

+ 4 - 3
fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/customer/index.vue

@@ -9,7 +9,7 @@
             </el-form-item>
             <el-form-item label="客户来源">
               <el-select v-model="customerCriteriaForm.customSourceId" placeholder="请选择" clearable>
-                <el-option v-for="item in fixedData.ClueSources" :key="item.id" :label="item.name" :value="item.id" />
+                <el-option v-for="item in fixedData.CustomSources" :key="item.id" :label="item.name" :value="item.id" />
               </el-select>
             </el-form-item>
             <el-form-item label="公司号码">
@@ -272,7 +272,7 @@ const allText = reactive({
   exportText: '客户表导出.xlsx'
 })
 const fixedData = reactive({
-  ClueSources: [] as fixedDataInterface[],
+  CustomSources: [] as fixedDataInterface[],
   CustomIndustry: [] as fixedDataInterface[],
   CustomLevel: [] as fixedDataInterface[],
   Personnel: [] as personnelInterface[]
@@ -483,7 +483,8 @@ function getCustomerTable() {
 }
 
 async function getSystemField() {
-  const systemField = getAllListByCode(['线索来源', '客户行业', '客户级别'])
+  const systemField = getAllListByCode(['客户来源', '客户行业', '客户级别'])
+  console.log(systemField, '<==== 123')
   for (let i in systemField) {
     const { data } = await get(`${GETSYSFILED}?code=${systemField[i]}`)
     for (let key of Object.keys(fixedData)) {

+ 15 - 2
fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/header/header.vue

@@ -88,7 +88,13 @@
         <el-table :data="newsDrawerTableData" style="flex1" border>
           <el-table-column prop="msg" label="消息内容">
             <template #default="scope">
-              <el-link type="primary" :underline="false" @click="toDetail(scope.row)">{{ scope.row.msg }}</el-link>
+              <el-link type="primary" :underline="false" @click="toDetail(scope.row)">
+                <!-- {{ scope.row.msg }} -->
+                {{ scope.row.msgTextList[0] || '' }}
+                <TextTranslation translationTypes="userName" :translationValue="scope.row.msgTextList[1]" v-if="(scope.row.msgTextList || []).length > 1">
+                </TextTranslation>
+                {{ scope.row.msgTextList[2] || '' }}
+              </el-link>
             </template>
           </el-table-column>
           <el-table-column prop="checked" label="状态" width="100">
@@ -244,7 +250,14 @@ const getNewsDrawerTableData = () => {
       }
     })
     numberOfLogos.value = (data || []).filter((item: any) => !item.checked).length
-    newsDrawerTableData.value = data
+    newsDrawerTableData.value = (data || []).map((item: any) => {
+      let str = item.msg || ''
+      let arr = str.split(/\$|=/).filter((item: any) => item && item !== 'username');
+      return {
+          ...item,
+          msgTextList: arr || []
+      }
+    })
   }).catch(err => {
     newsDrawerTableData.value = []
     console.log(err)

+ 7 - 1
fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/login.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="loginView w-screen h-screen overflow-hidden flex">
-    <div class="w-96 bg-white m-auto border-t-8 border-[#075985] shadow-xl rounded-md pl-9 pr-9">
+    <div class="w-96 bg-white m-auto border-t-8 border-[#075985] shadow-xl rounded-md pl-9 pr-9" v-if="!isCorpWX">
       <div class="m-auto pt-4">
         <img class="w-1/5 m-auto" :src="loginLogo" alt="">
       </div>
@@ -44,6 +44,10 @@
         </div>
       </el-dialog>
     </div>
+
+    <div v-else class="w-full flex justify-center py-[50px] text-[40px] colo-[#505458]">
+      正在进入系统中...
+    </div>
   </div>
 </template>
 
@@ -64,6 +68,8 @@ const ruleFormRef = ref<FormInstance>();
 const ruleForm = ref({
   username: "18122222222",
   password: "000000",
+  // username: "",
+  // password: "",
 });
 const loginLoading = ref(false);
 const rules = reactive<FormRules<typeof ruleForm>>({

+ 2 - 1
fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/order/index.vue

@@ -196,7 +196,8 @@ const allVisible = reactive({
 })
 const allText = reactive({
   orderEditText: '新建订单',
-  importText: '销售订单表导出.xlsx'
+  // importText: '销售订单表导出.xlsx'
+  importText: '销售订单表导入.xlsx'
 })
 const orderTemplate = ref({
   list: [],

+ 3 - 1
fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/team/index.vue

@@ -44,7 +44,7 @@
           </el-button>
           <template #dropdown>
             <el-dropdown-menu>
-              <el-dropdown-item @click="addPersone(false)" v-permission="['teamAdd']">添加人员</el-dropdown-item>
+              <el-dropdown-item @click="addPersone(false)" v-permission="['teamAdd']" v-if="userInfo.userNameNeedTranslate != 1">添加人员</el-dropdown-item>
               <el-dropdown-item @click="transitionOperation('exportUser', '')" v-permission="['teamExport']">导出人员</el-dropdown-item>
               <el-dropdown-item @click="transitionOperation('importUser', '')" v-permission="['teamImport']">批量导入</el-dropdown-item>
             </el-dropdown-menu>
@@ -262,6 +262,7 @@ import { useStore } from '@/store/index'
 import { GET_DATA_LIST, DETELE_DEPT, MOD, GET_USERINFO, GET_ROUTELIST, DEACTIVEUSER, SETACTIVE, GET_DEPTLIST, BACTHSERROLE, GET_USERLIST, GET_ADDDEPT, ADD_USER, SETRESETPWD, EXPOERTUSER, EDIT_ADDDEPT } from './api'
 import { post, uploadFile } from "@/utils/request";
 import { getFromValue, updateDepTreeData, resetFromValue, confirmAction, downloadFile } from '@/utils/tools'
+import { storeToRefs } from 'pinia';
 
 import personnelSearch from '@/components/translationComponent/personnelSearch/personnelSearch.vue';
 
@@ -272,6 +273,7 @@ import { formatDate } from '@/utils/times';
 import { URL_IMPORTTHREAD } from '../thread/constant';
 
 const { getFunctionList, getUserInfoVal } = useStore()
+const { userInfo } = storeToRefs(useStore());
 const globalPopup = inject<GlobalPopup>('globalPopup')
 
 // 定义类型

+ 2 - 2
fhKeeper/formulahousekeeper/customerBuler-crm/src/pages/thread/detail/components/information.vue

@@ -4,7 +4,7 @@
             <div class="title">基本信息</div>
             <div>
                 <el-button type="primary" v-permission="['threadEdit', userInfo.id == information.inchargerId]"
-                    @click="showVisible('newBusinessisible')">转为商机</el-button>
+                    @click="showVisible('newBusinessisible')" v-if="!information.isBo">转为商机</el-button>
                 <el-button type="primary" @click="claimClues()" v-if="!information.inchargerName">认领</el-button>
                 <el-button type="primary" @click="showVisible('clueDialogVisible')" v-else>转移</el-button>
                 <el-button type="primary" @click="editClue(information)" v-permission="['tasksAdd']">编辑</el-button>
@@ -125,7 +125,7 @@
                 <div class="flex justify-between items-center border-b pb-3 dialog-header">
                     <h4 :id="titleId">{{ allText.businessisText }}</h4>
                     <div>
-                        <el-button type="primary" @click="transferBusiness()"
+                        <el-button type="primary" @click="transferBusiness()" 
                             :loading="allLoading.businessSaveLading">转为商机</el-button>
                         <el-button @click="closeVisible('newBusinessisible')">取消</el-button>
                     </div>

+ 2 - 2
fhKeeper/formulahousekeeper/customerBuler-crm/src/utils/translationProcessing.ts

@@ -1,4 +1,4 @@
-declare var WWOpenData: any; // wx 小程序对象
+declare var WWOpenData: any;
 /**
  * echarts 转译处理
  * @param items 需要转译的数据源
@@ -27,5 +27,5 @@ export function dealWithTranslation(items: { type: 'userName' | 'departmentName'
     return allData
   };
 
-  myFunOne();
+  return myFunOne();
 }

+ 4 - 0
fhKeeper/formulahousekeeper/management-crm/src/main/java/com/management/platform/controller/CustomController.java

@@ -130,6 +130,8 @@ public class CustomController {
     private String path;
     @RequestMapping("/exportData")
     public HttpRespMsg exportData(Custom custom , HttpServletRequest request) throws Exception {
+        System.out.println("========导出客户信息==========");
+        long startTimeSec = System.currentTimeMillis();
         User user = userMapper.selectById(request.getHeader("token"));
         SysForm sysForm = sysFormMapper.selectOne(new LambdaQueryWrapper<SysForm>().eq(SysForm::getCompanyId, user.getCompanyId()).eq(SysForm::getCode, "Customer").eq(SysForm::getIsCurrent, 1));
         WxCorpInfo wxCorpInfo = wxCorpInfoService.getOne(new LambdaQueryWrapper<WxCorpInfo>().eq(WxCorpInfo::getCompanyId, user.getCompanyId()));
@@ -198,6 +200,8 @@ public class CustomController {
             dataList.add(item);
         }
         String fileName="客户表导出_"+ System.currentTimeMillis();
+        long endTimeSec = System.currentTimeMillis();
+        System.out.println("========客户信息导出数据准备结束==========耗时"+(endTimeSec-startTimeSec)+"毫秒");
         return excelExportService.exportGeneralExcelByTitleAndList(wxCorpInfo,fileName,dataList,path);
     }
 

+ 4 - 1
fhKeeper/formulahousekeeper/management-crm/src/main/java/com/management/platform/service/impl/ExcelExportServiceImpl.java

@@ -3,7 +3,6 @@ package com.management.platform.service.impl;
 import com.management.platform.controller.TaskController;
 import com.management.platform.controller.UserController;
 import com.management.platform.entity.CorpwxJobResult;
-import com.management.platform.entity.User;
 import com.management.platform.entity.WxCorpInfo;
 import com.management.platform.mapper.CorpwxJobResultMapper;
 import com.management.platform.mapper.UserMapper;
@@ -77,6 +76,8 @@ public class ExcelExportServiceImpl implements ExcelExportService {
     }
 
     public HttpRespMsg exportGeneralExcelByTitleAndList(WxCorpInfo wxCorpInfo, String title, List<List<String>> list, String downloadPath) throws Exception {
+        long startTimeSec = System.currentTimeMillis();
+        System.out.println("excel导出数据开始");
         HttpRespMsg httpRespMsg = new HttpRespMsg();
         if (title.contains("/")) {
             //文件名不能含有路径,得替换掉
@@ -174,6 +175,8 @@ public class ExcelExportServiceImpl implements ExcelExportService {
         }else {
             httpRespMsg.data = resp;
         }
+        long endTimeSec = System.currentTimeMillis();
+        System.out.println("========excel导出数据结束==========耗时"+(endTimeSec-startTimeSec)+"毫秒");
         return httpRespMsg;
     }
 

+ 23 - 24
fhKeeper/formulahousekeeper/management-crm/src/main/java/com/management/platform/service/impl/UserServiceImpl.java

@@ -1971,10 +1971,9 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
         Integer WXCompanyId = user.getCompanyId();
         WxCorpInfo wxCorpInfo = wxCorpInfoMapper.selectOne(new QueryWrapper<WxCorpInfo>().eq("company_id", WXCompanyId));
 
-        CompanyDingding dingding = companyDingdingMapper.selectOne(new LambdaQueryWrapper<CompanyDingding>().eq(CompanyDingding::getCompanyId, user.getCompanyId()));
-
-        List<User> companyUsers = userMapper.selectList(new QueryWrapper<User>().eq("company_id",user.getCompanyId()));
-        Map<String, User> companyUserMap = companyUsers.stream().collect(Collectors.toMap(User::getId, t -> t));
+//        CompanyDingding dingding = companyDingdingMapper.selectOne(new LambdaQueryWrapper<CompanyDingding>().eq(CompanyDingding::getCompanyId, user.getCompanyId()));
+//        List<User> companyUsers = userMapper.selectList(new QueryWrapper<User>().eq("company_id",user.getCompanyId()));
+//        Map<String, User> companyUserMap = companyUsers.stream().collect(Collectors.toMap(User::getId, t -> t));
         //当企业开启了微信通讯录的情况下
         if (org.apache.commons.lang3.StringUtils.isNotBlank(keyword) && wxCorpInfo!=null && wxCorpInfo.getSaasSyncContact()==1){
             HashMap<String, List> result = wxCorpInfoService.getOpenId(wxCorpInfo.getCorpid(), keyword, cursor,1,200);
@@ -1986,20 +1985,20 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
             if (users.size()!=0){
 //                List<User> realUser = userMapper.selectList(new QueryWrapper<User>().in("corpwx_userid", users));
                 List<Map<String,Object>> realUser = userMapper.selectListSimple(users);
-                for (Map<String, Object> map : realUser) {
-                    if(wxCorpInfo!=null&&wxCorpInfo.getSaasSyncContact()==1){
-                        User tmpUser = companyUserMap.getOrDefault(map.get("value"),null);
-                        if(null != tmpUser){
-                            map.put("label","$username="+tmpUser.getCorpwxUserid()+"$");
-                        }
-                    }
-//                    else if(dingding!=null&&dingding.getContactNeedTranslate()==1){
+//                for (Map<String, Object> map : realUser) {
+//                    if(wxCorpInfo!=null&&wxCorpInfo.getSaasSyncContact()==1){
 //                        User tmpUser = companyUserMap.getOrDefault(map.get("value"),null);
 //                        if(null != tmpUser){
-//                            map.put("label","$username="+tmpUser.getDingdingUserid()+"$");
+//                            map.put("label","$username="+tmpUser.getCorpwxUserid()+"$");
 //                        }
 //                    }
-                }
+////                    else if(dingding!=null&&dingding.getContactNeedTranslate()==1){
+////                        User tmpUser = companyUserMap.getOrDefault(map.get("value"),null);
+////                        if(null != tmpUser){
+////                            map.put("label","$username="+tmpUser.getDingdingUserid()+"$");
+////                        }
+////                    }
+//                }
                 msg.data = realUser;
                 return msg;
             }else {
@@ -2025,20 +2024,20 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
 
 //            List<User> userList = userMapper.selectList(wrapper);
             List<Map<String, Object>> userList=userMapper.getSimpleActiveUserList(hashMap);
-            for (Map<String, Object> map : userList) {
-                if(wxCorpInfo!=null&&wxCorpInfo.getSaasSyncContact()==1){
-                    User tmpUser = companyUserMap.getOrDefault(map.get("value"),null);
-                    if(null != tmpUser){
-                        map.put("label","$username="+tmpUser.getCorpwxUserid()+"$");
-                    }
-                }
-//                else if(dingding!=null&&dingding.getContactNeedTranslate()==1){
+//            for (Map<String, Object> map : userList) {
+//                if(wxCorpInfo!=null&&wxCorpInfo.getSaasSyncContact()==1){
 //                    User tmpUser = companyUserMap.getOrDefault(map.get("value"),null);
 //                    if(null != tmpUser){
-//                        map.put("label","$username="+tmpUser.getDingdingUserid()+"$");
+//                        map.put("label","$username="+tmpUser.getCorpwxUserid()+"$");
 //                    }
 //                }
-            }
+////                else if(dingding!=null&&dingding.getContactNeedTranslate()==1){
+////                    User tmpUser = companyUserMap.getOrDefault(map.get("value"),null);
+////                    if(null != tmpUser){
+////                        map.put("label","$username="+tmpUser.getDingdingUserid()+"$");
+////                    }
+////                }
+//            }
             msg.data = userList;
             return msg;
         }