Bläddra i källkod

Merge branch 'master' of http://47.101.159.18:3000/Muchinfo/MTP2.0_WEB

marymelisa 4 år sedan
förälder
incheckning
34179d09ed

+ 1 - 1
public/config/app.config.json

@@ -1,3 +1,3 @@
 {
-    "apiUrl":"http://192.168.31.139:8080/cfg?key=test_139"
+    "apiUrl": "http://103.40.249.123:8280/cfg?key=mtp_20"
 }

BIN
public/qhjLogo.png


BIN
public/qianhaijin.ico


+ 0 - 0
public/favicon1.ico → public/yunrong.ico


+ 2 - 1
src/common/config/projectName.ts

@@ -2,7 +2,8 @@ import { serviceURL } from "@/services/request"
 
 // 获取当前所运行的是哪个项目
 export enum OemType {
-    manager = 'qyfg', // 千海金
+    manager = 'qyfg', // 企业风管
+    qinghaijin = 'qhj', // 千海金
     wrspot = 'yrdz', // 仓单贸易
     pingan = 'pingan' // 平安
 }

+ 66 - 60
src/layout/components/header.vue

@@ -1,74 +1,79 @@
 <template>
-    <!-- 风险管理 -->
+  <!-- 风险管理 -->
 
-    <div v-if="isOemByEnum(OemType.manager)">
-        <img src="../../assets/images/logoHeader.png" />
-        <span>深圳市多元世纪信息技术股份有限公司</span>
-    </div>
-    <!-- 云融 -->
+  <div v-if="isOemByEnum(OemType.manager)">
+    <img src="../../assets/images/logoHeader.png" />
+    <span>{{getCompanyName()}}</span>
+  </div>
+  <!-- 云融 -->
 
-    <div v-else-if="isOemByEnum(OemType.wrspot)">
-        <img src="../../assets/images/headLogo.jpg" />
-        <span>云融</span>
-    </div>
-    <div v-else>
-        <img src="../../assets/images/logoHeader.png" />
-        <span>深圳市多元世纪信息技术股份有限公司</span>
+  <div v-else-if="isOemByEnum(OemType.wrspot)">
+    <img src="../../assets/images/headLogo.jpg" />
+    <span>云融</span>
+  </div>
+  <div v-else>
+    <img src="../../assets/images/logoHeader.png" />
+    <span>{{getCompanyName()}}</span>
+  </div>
+  <div class="m-layout-header-right">
+    <div @click="openDrawer">
+      <span>{{ getUserName() }},您好!</span>
     </div>
-    <div class="m-layout-header-right">
-        <div @click="openDrawer">
-            <span>{{ getUserName() }},您好!</span>
-        </div>
-        <div class="relative">
-            <!-- <a-input-search ref="userNameInput"
+    <div class="relative">
+      <!-- <a-input-search ref="userNameInput"
                           class="searchInput"
                           placeholder="请输入代码/名称"
                           @pressEnter="search">
                           readonly
             </a-input-search>-->
-            <!-- <a-icon type="search" /> -->
-        </div>
-        <div v-if="isOemByEnum(OemType.wrspot)">
-            <a-popover trigger="click" placement="bottom" overlayClassName="friendPopover">
-                <template #content>
-                    <Friend />
-                </template>
-                <span class="friendIcon">
-                    <svg class="icon svg-icon" aria-hidden="true">
-                        <use xlink:href="#icon-pengyou1" />
-                    </svg>
-                </span>
-            </a-popover>
-        </div>
-        <div class="news-container">
-            <a-badge @click="openNotice" :dot="getUnReadNoticeLength() > 0">
-                <svg class="icon svg-icon" aria-hidden="true">
-                    <use xlink:href="#icon-xiaoxi" />
-                </svg>
-            </a-badge>
-        </div>
-        <div>
-            <a-popover v-model:visible="visible" trigger="click" placement="bottomRight">
-                <template #content>
-                    <div
-                        v-for="item in setMenu"
-                        class="popItem"
-                        @click="chooseSetMenu(item.path)"
-                        :key="item.path"
-                    >{{ item.name }}</div>
-                </template>
-                <a-avatar :size="24">
-                    <template #icon>
-                        <SettingFilled />
-                        <!-- <svg class="icon svg-icon" aria-hidden="true">
+      <!-- <a-icon type="search" /> -->
+    </div>
+    <div v-if="isOemByEnum(OemType.wrspot)">
+      <a-popover trigger="click"
+                 placement="bottom"
+                 overlayClassName="friendPopover">
+        <template #content>
+          <Friend />
+        </template>
+        <span class="friendIcon">
+          <svg class="icon svg-icon"
+               aria-hidden="true">
+            <use xlink:href="#icon-pengyou1" />
+          </svg>
+        </span>
+      </a-popover>
+    </div>
+    <div class="news-container">
+      <a-badge @click="openNotice"
+               :dot="getUnReadNoticeLength() > 0">
+        <svg class="icon svg-icon"
+             aria-hidden="true">
+          <use xlink:href="#icon-xiaoxi" />
+        </svg>
+      </a-badge>
+    </div>
+    <div>
+      <a-popover v-model:visible="visible"
+                 trigger="click"
+                 placement="bottomRight">
+        <template #content>
+          <div v-for="item in setMenu"
+               class="popItem"
+               @click="chooseSetMenu(item.path)"
+               :key="item.path">{{ item.name }}</div>
+        </template>
+        <a-avatar :size="24">
+          <template #icon>
+            <SettingFilled />
+            <!-- <svg class="icon svg-icon" aria-hidden="true">
                             <use xlink:href="#icon-yonghu1" />
                         </svg>-->
-                    </template>
-                </a-avatar>
-            </a-popover>
-            <Setting />
-        </div>
+          </template>
+        </a-avatar>
+      </a-popover>
+      <Setting />
     </div>
+  </div>
 </template>
 
 <script lang="ts">
@@ -76,7 +81,7 @@ import { defineComponent, ref, provide } from 'vue';
 import { openModal } from '@/common/setup/modal/index';
 import { UserOutlined, SettingFilled } from '@ant-design/icons-vue';
 import Setting from '@/views/setting/index.vue';
-import { getUserName } from '@/services/bus/user';
+import { getUserName, getCompanyName } from '@/services/bus/user';
 import { logout } from '@/services/bus/login';
 import APP from '@/services';
 import Router from '@/router';
@@ -156,6 +161,7 @@ export default defineComponent({
             ...onSearch(),
             isOemByEnum,
             OemType,
+            getCompanyName,
         };
     },
 });

+ 3 - 1
src/services/bus/index.ts

@@ -71,7 +71,9 @@ function getIco(): string {
     if (isOemByEnum(OemType.manager)) {
         result = 'favicon'
     } else if (isOemByEnum(OemType.wrspot)) {
-        result = 'favicon1'
+        result = 'yunrong'
+    } else if (isOemByEnum(OemType.qinghaijin)) {
+        result = 'qianhaijin'
     }
 
     return `./${result}.ico`

+ 5 - 0
src/services/bus/user.ts

@@ -21,6 +21,11 @@ export function getUserInfo() {
  * @returns
  */
 export function getUserName() {
+    return APP.get('loginAccount').accountname
+}
+
+// 公司名
+export function getCompanyName() {
     return getUserInfo().customername
 }
 

+ 2 - 2
src/services/go/ermcp/account/index.ts

@@ -1,6 +1,6 @@
 /** ================================= 账户管理 ================================**/
 import { getUserId } from "@/services/bus/account";
-import {getAreaUserId, getUserAccountType} from "@/services/bus/user";
+import { getAreaUserId, getUserAccountType } from "@/services/bus/user";
 import { commonSearch_go } from "@/services/go";
 import {
     ErmcpBizGroupEx,
@@ -39,7 +39,7 @@ export function QueryAccMgrTaaccount(): Promise<ErmcpTaAccountEx[]> {
  * @constructor
  */
 export function QueryAccMgrLoginUser(querytype: number): Promise<ErmcpLoginUserEx[]> {
-    const userid = getAreaUserId();
+    const userid = getUserId();
     const usertype = getUserAccountType()
     return commonSearch_go('/Ermcp/QueryAccMgrLoginUser', { userid, usertype, querytype }).catch((err) => {
         throw new Error(`查询账户管理登录账号: ${err}`);

+ 13 - 0
src/views/information/custom/list/normal-use/index.vue

@@ -18,6 +18,11 @@
         <template #expandedRowRender="{  }">
           <BtnList :btnList="forDataBtn" />
         </template>
+
+        <template v-if="isPingAnOem()"
+                  #index="{ index }">
+          <span>{{ index + 1 }}</span>
+        </template>
         <template #userinfotype="{ text }">
           <a>{{ text === 2 ? '企业' : '个人' }}</a>
         </template>
@@ -46,6 +51,9 @@ import { queryTableList, QueryCustomInfoType } from '../index';
 import { getStatusName } from '@/common/constants/enumsName';
 import { getCardTypeEnumItemName } from '@/common/constants/enumsName';
 import Middle from '@/views/information/custom/compoments/controlModal/index.vue';
+import { isPingAnOem } from '@/common/config/projectName';
+import { pingan_custom_column } from '../setup';
+
 export default defineComponent({
     name: 'custom-normal',
     components: {
@@ -68,6 +76,10 @@ export default defineComponent({
             queryTable();
             // 注册表头信息 过滤
             registerColumn('table_pcweb_userinfo', ['userinfotype', 'nickname', 'customername', 'mobile']);
+            // 平安表头
+            if (isPingAnOem()) {
+                columns.value = pingan_custom_column();
+            }
         });
         return {
             columns,
@@ -82,6 +94,7 @@ export default defineComponent({
             getStatusName,
             getCardTypeEnumItemName,
             queryTable,
+            isPingAnOem,
         };
     },
 });

+ 65 - 2
src/views/information/custom/list/setup.ts

@@ -16,5 +16,68 @@ export function queryTableList(type: QueryCustomInfoEnum) {
     return { loading, tableList, queryTable: fn }
 }
 
-
-
+// 平安 客户资料 表头
+export function pingan_custom_column() {
+    return [
+        {
+            key: '9th',
+            dataIndex: 'index',
+            title: '序号',
+            align: 'center',
+            slots: {
+                customRender: 'index',
+            },
+            width: 80
+        },
+        {
+            key: '0th',
+            dataIndex: 'status',
+            title: '状态',
+            align: 'center',
+            slots: {
+                customRender: 'status',
+            },
+            width: 120
+        },
+        {
+            key: '1th',
+            dataIndex: 'userinfotype',
+            title: '客户类型',
+            align: 'center',
+            slots: {
+                customRender: 'userinfotype',
+            },
+            width: 120
+        },
+        {
+            key: '3th',
+            dataIndex: 'customername',
+            title: '客户名称',
+            align: 'center',
+            slots: {
+                customRender: 'customername',
+            },
+            width: 120
+        },
+        {
+            key: '6th',
+            dataIndex: 'contactname',
+            title: '点价联系人',
+            align: 'center',
+            slots: {
+                customRender: 'contactname',
+            },
+            width: 120
+        },
+        {
+            key: '7th',
+            dataIndex: 'mobile',
+            title: '联系人手机号码',
+            align: 'center',
+            slots: {
+                customRender: 'mobile',
+            },
+            width: 120
+        },
+    ]
+}

+ 11 - 0
src/views/information/custom/list/stop-use/index.vue

@@ -18,6 +18,10 @@
         <template #expandedRowRender="{  }">
           <BtnList :btnList="forDataBtn" />
         </template>
+        <template v-if="isPingAnOem()"
+                  #index="{ index }">
+          <span>{{ index + 1 }}</span>
+        </template>
         <template #userinfotype="{ text }">
           <a>{{ text === 2 ? '企业' : '个人' }}</a>
         </template>
@@ -47,6 +51,8 @@ import { queryTableList, QueryCustomInfoType } from '../index';
 import { getStatusName } from '@/common/constants/enumsName';
 import { getCardTypeEnumItemName } from '@/common/constants/enumsName';
 import Middle from '@/views/information/custom/compoments/controlModal/index.vue';
+import { isPingAnOem } from '@/common/config/projectName';
+import { pingan_custom_column } from '../setup';
 
 export default defineComponent({
     name: 'custom-normal',
@@ -70,6 +76,10 @@ export default defineComponent({
             queryTable();
             // 注册表头信息 过滤
             registerColumn('table_pcweb_userinfo', ['userinfotype', 'nickname', 'contactname', 'mobile']);
+            // 平安表头
+            if (isPingAnOem()) {
+                columns.value = pingan_custom_column();
+            }
         });
         return {
             columns,
@@ -84,6 +94,7 @@ export default defineComponent({
             getStatusName,
             getCardTypeEnumItemName,
             queryTable,
+            isPingAnOem,
         };
     },
 });

+ 12 - 1
src/views/information/warehouse-info/list/normal-use/index.vue

@@ -17,10 +17,14 @@
         <!-- 额外的展开行 -->
         <template #expandedRowRender="{ record }">
           <BtnList :selectedData="record"
-          class="btn-list-sticky"
+                   class="btn-list-sticky"
                    :btnList="forDataBtn"
                    @onClick="btnClick" />
         </template>
+        <template v-if="isPingAnOem()"
+                  #index="{ index }">
+          <span>{{ index + 1 }}</span>
+        </template>
         <template #warehousetype="{ text }">
           <span>{{ getWareHouseTypeName(text) }}</span>
         </template>
@@ -48,6 +52,8 @@
 import { defineComponent, initData, getTableColumns, getTableEvent, getBtnList, contextMenu, BtnList } from '@/common/export/table';
 import { filterCustomTable, Add, Disable, Detail, Modify } from '../../compoments';
 import { gerWareHouseStatusName, getWareHouseTypeName, queryTableList, ErmcpWareHouseInfo } from '../index';
+import { isPingAnOem } from '@/common/config/projectName';
+import { pingan_cwarehousecolumn } from '../setup';
 
 export default defineComponent({
     name: 'warehouse-info-normal',
@@ -74,6 +80,10 @@ export default defineComponent({
             queryTable();
             // 注册表头信息 过滤
             registerColumn('table_pcweb_warehouse', ['warehousetype', 'warehousename', 'address']);
+            // 平安表头
+            if (isPingAnOem()) {
+                columns.value = pingan_cwarehousecolumn();
+            }
         });
 
         return {
@@ -91,6 +101,7 @@ export default defineComponent({
             gerWareHouseStatusName,
             queryTable,
             btnClick,
+            isPingAnOem,
         };
     },
 });

+ 59 - 3
src/views/information/warehouse-info/list/setup.ts

@@ -6,8 +6,8 @@ import { ref } from 'vue';
 
 /**
  * 获取表格列表数据
- * @param type 
- * @returns 
+ * @param type
+ * @returns
  */
 export function queryTableList(type: string) {
     // 加载状态
@@ -31,4 +31,60 @@ export function queryTableList(type: string) {
     return { loading, tableList, queryTable }
 }
 
-
+// 平安 仓库信息 表头
+export function pingan_cwarehousecolumn() {
+    return [
+        {
+            key: '9th',
+            dataIndex: 'index',
+            title: '序号',
+            align: 'center',
+            slots: {
+                customRender: 'index',
+            },
+            width: 80
+        },
+        {
+            key: '0th',
+            dataIndex: 'warehousestatus',
+            title: '状态',
+            align: 'center',
+            slots: {
+                customRender: 'warehousestatus',
+            },
+            width: 120,
+        },
+        {
+            key: '1th',
+            dataIndex: 'warehousecode',
+            title: '仓库简称',
+            align: 'center',
+            slots: {
+                customRender: 'warehousecode',
+            },
+            width: 120,
+        },
+        {
+            key: '2th',
+            dataIndex: 'warehousetype',
+            title: '仓库类型',
+            align: 'center',
+            slots: {
+                customRender: 'warehousetype',
+            },
+            width: 120,
+            filteredValue: null,
+        },
+        {
+            key: '3th',
+            dataIndex: 'warehousename',
+            title: '仓库名称',
+            align: 'center',
+            slots: {
+                customRender: 'warehousename',
+            },
+            width: 120,
+            filteredValue: null,
+        },
+    ];
+}

+ 11 - 0
src/views/information/warehouse-info/list/stop-use/index.vue

@@ -17,6 +17,10 @@
         <template #expandedRowRender="{  }">
           <BtnList :btnList="forDataBtn" />
         </template>
+        <template v-if="isPingAnOem()"
+                  #index="{ index }">
+          <span>{{ index + 1 }}</span>
+        </template>
         <template #warehousetype="{ text }">
           <span>{{ getWareHouseTypeName(text) }}</span>
         </template>
@@ -38,6 +42,8 @@
 import { defineComponent, initData, getTableColumns, getTableEvent, getBtnList, contextMenu, BtnList } from '@/common/export/table';
 import { filterCustomTable, Detail, Recover } from '../../compoments';
 import { gerWareHouseStatusName, getWareHouseTypeName, queryTableList, ErmcpWareHouseInfo } from '../index';
+import { isPingAnOem } from '@/common/config/projectName';
+import { pingan_cwarehousecolumn } from '../setup';
 
 export default defineComponent({
     name: 'warehouse-info-stop',
@@ -62,6 +68,10 @@ export default defineComponent({
             queryTable();
             // 注册表头信息 过滤
             registerColumn('table_pcweb_warehouse', ['warehousetype', 'warehousename', 'address']);
+            // 平安表头
+            if (isPingAnOem()) {
+                columns.value = pingan_cwarehousecolumn();
+            }
         });
 
         return {
@@ -78,6 +88,7 @@ export default defineComponent({
             getWareHouseTypeName,
             gerWareHouseStatusName,
             queryTable,
+            isPingAnOem,
         };
     },
 });