li.shaoyi 4 年之前
父节点
当前提交
6f4e185e20

+ 1 - 0
src/assets/styles/index.css

@@ -1025,6 +1025,7 @@
     -moz-border-radius   : 3px 3px 3px 3px;
     -webkit-border-radius: 3px 3px 3px 3px;
     border-radius        : 3px 3px 3px 3px;
+    padding              : 0 15px;
 }
 
 .selectBtn.ant-btn:hover,

+ 1 - 1
src/assets/styles/index.less

@@ -220,7 +220,7 @@ body {
 }
 
 
-.ant-menu-dark,
+.ant-menu.ant-menu-dark,
 .ant-menu-dark {
     background-color: @m-grey18;
 

文件差异内容过多而无法显示
+ 271 - 263
src/assets/styles/mixin.less


文件差异内容过多而无法显示
+ 294 - 293
src/assets/styles/variables.css


+ 2 - 2
src/common/setup/table/button.ts

@@ -266,8 +266,8 @@ export function getButtonList(menuType: EnumRouterName, hasDetail: boolean) {
  * 根据code权限获取按钮列表
  */
 export function getTableButton(codes: string[]): BtnListType[] {
-    const route = useRoute();
-    const auth = route.meta.auth as OperationTabMenuAuth[];
+    const { meta } = useRoute();
+    const auth = meta.auth as OperationTabMenuAuth[];
 
     // 根据code权限获取按钮列表
     return codes.reduce((result, code) => {

+ 1 - 0
src/layout/components/main.vue

@@ -57,6 +57,7 @@ export default defineComponent({
         .flex();
         height: 32px;
         line-height: 32px;
+        text-align: center;
         background: transparent;
         .ant-menu-item {
             min-width: 120px;

+ 1 - 0
src/layout/components/top.vue

@@ -166,6 +166,7 @@ export default defineComponent({
                 padding-left: 10px;
                 padding-right: 16px;
                 .ant-badge {
+                    color: inherit;
                     margin-top: 4px;
                     cursor: pointer;
                     > svg {

+ 12 - 7
src/views/business/plan/list/checkpending/index.vue

@@ -5,7 +5,7 @@
         <a-table :columns="columns" class="srcollYTable" :scroll="{ x: '100%', y: 'calc(100vh - 163px)' }" :pagination="false" :loading="loading" :expandedRowKeys="expandedRowKeys" :customRow="Rowclick" rowKey="key" :data-source="tableList">
             <!-- 额外的展开行 -->
             <template #expandedRowRender="{ record }">
-                <mtp-table-button class="btn-list-sticky" :buttons="buttons" :record="record" @click="openComponent" />
+                <mtp-table-button class="btn-list-sticky" :buttons="buttonList" :record="record" @click="openComponent" />
             </template>
             <template #contracttype="{ text }">
                 <a>{{ getPlanContractType(text) }}</a>
@@ -15,7 +15,7 @@
             </template>
         </a-table>
         <!-- 右键 -->
-        <contextMenu :contextMenu="contextMenu" @cancel="closeContext" :list="buttons"> </contextMenu>
+        <contextMenu :contextMenu="contextMenu" @cancel="closeContext" :list="buttonList"> </contextMenu>
         <component :is="componentId" v-if="componentId" :selectedRow="selectedRow" @cancel="closeComponent"> </component>
     </div>
 </template>
@@ -29,6 +29,7 @@ import { Ermcp3HedgePlan } from '@/services/go/ermcp/plan/interface';
 import { QueryHedgePlan } from '@/services/go/ermcp/plan';
 import { EnumRouterName } from '@/common/constants/enumRouterName';
 import { getTableButton } from '@/common/setup/table/button';
+import { useRoute } from 'vue-router';
 
 export default defineComponent({
     name: EnumRouterName.plan_audit,
@@ -41,11 +42,18 @@ export default defineComponent({
         plan_checkpending_check: defineAsyncComponent(() => import('../../components/audit/index.vue')),
     },
     setup() {
+        const { name: routeName } = useRoute();
+        const hedgeplanstatus = routeName === 'plan_checkpending' ? '1' : '2';
+        const buttons = hedgeplanstatus === '1' ? ['plan_checkpending_check', 'plan_checkpending_cancel', 'detail'] : ['detail']; // 权限按钮
+
+        // 权限按钮
+        const buttonList = getTableButton(buttons);
+
         // 表格列表数据
         const { loading, tableList, queryTable } = queryTableList<Ermcp3HedgePlan>();
 
         // 获取列表数据
-        const queryTableAction = () => queryTable(QueryHedgePlan, '1');
+        const queryTableAction = () => queryTable(QueryHedgePlan, hedgeplanstatus);
 
         // 表格通用逻辑
         const param: ComposeTableParam = {
@@ -56,9 +64,6 @@ export default defineComponent({
             isDetail: true,
         };
 
-        // 权限按钮
-        const buttons = getTableButton(['plan_checkpending_check', 'plan_checkpending_cancel', 'detail']);
-
         return {
             ...handleComposeTable<Ermcp3HedgePlan>(param),
             loading,
@@ -66,7 +71,7 @@ export default defineComponent({
             getPlanStatusName,
             getPlanContractType,
             queryTable,
-            buttons,
+            buttonList,
         };
     },
 });

+ 52 - 71
src/views/information/spot-contract/list/unsubmitted/index.vue

@@ -1,79 +1,60 @@
 <template>
-  <!-- 现货合同: 未提交-->
-  <div class="spot-contract-not-commit"
-       :loading="loading">
-    <filterCustomTable @search="updateColumn">
-      <BtnList :btnList="firstBtn"
-               @click="openComponent" />
-    </filterCustomTable>
-    <a-table :columns="columns"
-             class="topOrderTable"
-             :pagination="false"
-             :expandedRowKeys="expandedRowKeys"
-             :customRow="Rowclick"
-             rowKey="key"
-             :data-source="tableList"
-             :scroll="{ x: '100%', y: 'calc(100vh - 163px)' }">
-      <!-- 额外的展开行 -->
-      <!-- 额外的展开行 -->
-      <template #expandedRowRender="{ record }">
-        <BtnList :btnList="secondBtn"
-                 class="btn-list-sticky"
-                 :record="record"
-                 @click="openComponent" />
-      </template>
-      <template #biztype="{ text }">
-        <a>{{ getBizTypeName(text) }}</a>
-      </template>
+    <!-- 现货合同: 未提交-->
+    <div class="spot-contract-not-commit" :loading="loading">
+        <filterCustomTable @search="updateColumn">
+            <BtnList :btnList="firstBtn" @click="openComponent" />
+        </filterCustomTable>
+        <a-table :columns="columns" class="topOrderTable" :pagination="false" :expandedRowKeys="expandedRowKeys" :customRow="Rowclick" rowKey="key" :data-source="tableList" :scroll="{ x: '100%', y: 'calc(100vh - 163px)' }">
+            <!-- 额外的展开行 -->
+            <!-- 额外的展开行 -->
+            <template #expandedRowRender="{ record }">
+                <BtnList :btnList="secondBtn" class="btn-list-sticky" :record="record" @click="openComponent" />
+            </template>
+            <template #biztype="{ text }">
+                <a>{{ getBizTypeName(text) }}</a>
+            </template>
 
-      <template #pricetype="{ text }">
-        <span>{{ getPriceTypeName(text) }}</span>
-      </template>
+            <template #pricetype="{ text }">
+                <span>{{ getPriceTypeName(text) }}</span>
+            </template>
 
-      <template #contracctstatus="{ text }">
-        <a>{{ getContractStatusName(text) }}</a>
-      </template>
+            <template #contracctstatus="{ text }">
+                <a>{{ getContractStatusName(text) }}</a>
+            </template>
 
-      <template #contracttype="{ text }">
-        <a>{{ getContractTypeName(text) }}</a>
-      </template>
-      <!-- 对手方 -->
-      <template #negative="{ record }">
-        <a>{{ record.contracttype === 1 ? record.sellusername : record.buyusername }}</a>
-      </template>
-      <!-- 点假期 -->
-      <template #startdate="{ record }">
-        <span>{{ formatValue(formatTime(record.startdate, "d") + '--' + formatTime(record.enddate, "d")) }}</span>
-      </template>
-      <!-- 交收期 -->
-      <template #deliverystartdate="{ record }">
-        <span>{{ formatValue(formatTime(record.deliverystartdate, "d") + '--' +
-                        formatTime(record.deliveryenddate, "d")) }}</span>
-      </template>
-      <!-- 业务员 -->
-      <template #saleuserid="{ record }">
-        <span>{{ findManagerName(record.saleuserid) }}</span>
-      </template>
+            <template #contracttype="{ text }">
+                <a>{{ getContractTypeName(text) }}</a>
+            </template>
+            <!-- 对手方 -->
+            <template #negative="{ record }">
+                <a>{{ record.contracttype === 1 ? record.sellusername : record.buyusername }}</a>
+            </template>
+            <!-- 点假期 -->
+            <template #startdate="{ record }">
+                <span>{{ formatValue(formatTime(record.startdate, 'd') + '--' + formatTime(record.enddate, 'd')) }}</span>
+            </template>
+            <!-- 交收期 -->
+            <template #deliverystartdate="{ record }">
+                <span>{{ formatValue(formatTime(record.deliverystartdate, 'd') + '--' + formatTime(record.deliveryenddate, 'd')) }}</span>
+            </template>
+            <!-- 业务员 -->
+            <template #saleuserid="{ record }">
+                <span>{{ findManagerName(record.saleuserid) }}</span>
+            </template>
 
-      <!-- 跟单员 -->
-      <template #meruserid="{ record }">
-        <span>{{ findManagerName(record.meruserid) }}</span>
-      </template>
-      <!-- 合同量 -->
-      <template #qty="{ text, record }">
-        <span>{{ handleEnumdic(text, record) }}</span>
-      </template>
-    </a-table>
-    <!-- 右键 -->
-    <contextMenu :contextMenu="contextMenu"
-                 @cancel="closeContext"
-                 :list="secondBtn">
-    </contextMenu>
-    <component :is="componentId"
-               v-if="componentId"
-               :selectedRow="selectedRow"
-               @cancel="closeComponent"></component>
-  </div>
+            <!-- 跟单员 -->
+            <template #meruserid="{ record }">
+                <span>{{ findManagerName(record.meruserid) }}</span>
+            </template>
+            <!-- 合同量 -->
+            <template #qty="{ text, record }">
+                <span>{{ handleEnumdic(text, record) }}</span>
+            </template>
+        </a-table>
+        <!-- 右键 -->
+        <contextMenu :contextMenu="contextMenu" @cancel="closeContext" :list="secondBtn"> </contextMenu>
+        <component :is="componentId" v-if="componentId" :selectedRow="selectedRow" @cancel="closeComponent"></component>
+    </div>
 </template>
 
 <script lang="ts">

+ 1 - 1
src/views/manage/business-review/list/settlement/checkpending/index.vue

@@ -56,7 +56,7 @@ export default defineComponent({
     },
     setup() {
         // 表格列表数据
-        const { loading, tableList, queryTable } = queryTableList({});
+        const { loading, tableList, queryTable } = queryTableList({ applystatus: '1' });
 
         // 获取列表数据
         const queryTableAction = () => queryTable();

+ 117 - 0
src/views/manage/business-review/list/settlement/performance/index.vue

@@ -0,0 +1,117 @@
+<template>
+    <div style="background: red; color: #fff; padding: 5px 0">待修改-表头</div>
+    <!-- 管理-业务审核-交收 -->
+    <div class="business-review-js" :loading="loading">
+        <Filter @search="updateColumn"></Filter>
+        <a-table :columns="columns" class="topTable" :pagination="false" :expandedRowKeys="expandedRowKeys" :customRow="Rowclick" rowKey="key" :scroll="{ x: '100%', y: 'calc(100vh - 163px)' }" :data-source="tableList">
+            <!-- 额外的展开行 -->
+            <template #expandedRowRender="{ record }">
+                <mtp-table-button class="btn-list-sticky" :buttons="handlePermissionBtn(buttons, record)" :record="record" @click="openComponent" />
+            </template>
+            <template #operateapplytype="{ text }">
+                <a>{{ getPriceTypeName(text) }}</a>
+            </template>
+            <template #contracttype="{ text }">
+                <a>{{ getContractTypeName(text) }}</a>
+            </template>
+            <template #applystatus="{ text }">
+                <a>{{ getApplyStatusName(text) }}</a>
+            </template>
+            <template #buyusernameOrsellusername="{ record }">
+                <a>{{ getAnalogueName(record.contracttype, record.buyusername, record.sellusername) }}</a>
+            </template>
+            <template #addmargin||decmargin="{ record }">
+                <a>{{ record.addmargin !== 0 && record.addmargin !== undefined ? '+' + record.addmargin : record.decmargin === 0 || record.decmargin === undefined ? '' : '-' + record.decmargin }} </a>
+            </template>
+        </a-table>
+        <!-- 右键 -->
+        <contextMenu :contextMenu="contextMenu" @cancel="closeContext" :list="handlePermissionBtn(buttons, selectedRow)"> </contextMenu>
+        <component :is="componentId" v-if="componentId" :selectedRow="selectedRow" @cancel="closeComponent"></component>
+    </div>
+</template>
+
+<script lang="ts">
+import { MtpTableButton, contextMenu, defineAsyncComponent, defineComponent, handleComposeTable, ComposeTableParam } from '@/common/export/commonTable';
+import { initData, getTableColumns, getTableEvent, getBtnList } from '@/common/export/table';
+
+import { SettlementDetail, SettlementAudit, SettlementCancel, Filter } from '../../../components';
+
+import { queryTableList, QryBussinessJsRsp } from '../setup';
+import { invoiceStatusName } from '@/views/manage/finance-review/setup';
+import { Column, ColumnType } from '@/common/setup/table';
+import { getPriceTypeName, getContractTypeName, getApplyStatusName } from '@/common/constants/enumsName';
+import { getAnalogueName } from '@/views/information/spot-contract/setup';
+import { EnumRouterName } from '@/common/constants/enumRouterName';
+import { BtnListType } from '@/common/components/btnList/interface';
+import { getTableButton } from '@/common/setup/table/button';
+
+export default defineComponent({
+    name: 'business-review-js',
+    components: {
+        contextMenu,
+        Filter,
+        MtpTableButton,
+        detail: defineAsyncComponent(() => import('../../../components/settlementDetail/index.vue')),
+    },
+    setup() {
+        // 表格列表数据
+        const { loading, tableList, queryTable } = queryTableList({ applystatus: '2' });
+
+        // 获取列表数据
+        const queryTableAction = () => queryTable();
+        const filtrFn = (e: Column, item: ColumnType, filtered: any) => {
+            if (e.columnfield === 'buyusernameOrsellusername') {
+                item.onFilter = (value: string, record: QryBussinessJsRsp) => {
+                    const { contracttype, buyusername, sellusername } = record;
+                    if (contracttype === 1) {
+                        // 采购
+                        return sellusername.includes(value);
+                    } else {
+                        return buyusername.includes(value);
+                    }
+                };
+                item.filteredValue = filtered.buyusernameOrsellusername || null;
+            }
+        };
+
+        // 表格通用逻辑
+        const param: ComposeTableParam = {
+            queryFn: queryTableAction,
+            menuType: EnumRouterName.business_review_settlement,
+            tableName: 'table_pcweb_business_aduit_js',
+            tableFilterKey: ['contracttype', 'contractno', 'deliverygoodsname'],
+            tableFilterCB: filtrFn,
+            isDetail: true,
+        };
+
+        function handlePermissionBtn(btnList: BtnListType[], item: QryBussinessJsRsp) {
+            if (item) {
+                const { applystatus } = item;
+                if (applystatus === 1) {
+                    return btnList;
+                } else {
+                    return btnList.filter((e) => e.code === 'detail');
+                }
+            } else {
+                return [];
+            }
+        }
+
+        // 权限按钮
+        const buttons = getTableButton(['detail']);
+
+        return {
+            ...handleComposeTable<QryBussinessJsRsp>(param),
+            handlePermissionBtn,
+            getAnalogueName,
+            loading,
+            tableList,
+            getPriceTypeName,
+            getContractTypeName,
+            getApplyStatusName,
+            invoiceStatusName,
+            buttons,
+        };
+    },
+});
+</script>

+ 1 - 1
src/views/manage/business-review/list/someprice/checkpending/index.vue

@@ -54,7 +54,7 @@ export default defineComponent({
     },
     setup() {
         // 表格列表数据
-        const { loading, tableList, queryTable } = queryTableList({});
+        const { loading, tableList, queryTable } = queryTableList({ applystatus: '1' });
 
         // 获取列表数据
         const queryTableAction = () => queryTable();

+ 115 - 0
src/views/manage/business-review/list/someprice/performance/index.vue

@@ -0,0 +1,115 @@
+<template>
+    <div style="background: red; color: #fff; padding: 5px 0">待修改-表头</div>
+    <!-- 管理-业务审核-点价 -->
+    <div class="business-review-dj" :loading="loading">
+        <Filter @search="updateColumn"></Filter>
+        <a-table :columns="columns" class="srcollYTable" :scroll="{ x: '100%', y: 'calc(100vh - 163px)' }" :pagination="false" :expandedRowKeys="expandedRowKeys" :customRow="Rowclick" rowKey="key" :data-source="tableList">
+            <!-- 额外的展开行 -->
+            <template #expandedRowRender="{ record }">
+                <mtp-table-button class="btn-list-sticky" :buttons="handlePermissionBtn(buttons, record)" :record="record" @click="openComponent" />
+            </template>
+            <template #pricetype="{ text }">
+                <a>{{ getPriceTypeName(text) }}</a>
+            </template>
+            <template #applystatus="{ text }">
+                <a>{{ getApplyStatusName(text) }}</a>
+            </template>
+            <template #contracttype="{ text }">
+                <a>{{ getContractTypeName(text) }}</a>
+            </template>
+            <template #contractstatus="{ text }">
+                <a>{{ getContractStatusName(text) }}</a>
+            </template>
+            <template #buyusernameOrsellusername="{ record }">
+                <a>{{ getAnalogueName(record.contracttype, record.buyusername, record.sellusername) }}</a>
+            </template>
+        </a-table>
+        <!-- 右键 -->
+        <contextMenu :contextMenu="contextMenu" @cancel="closeContext" :list="handlePermissionBtn(buttons, selectedRow)"> </contextMenu>
+        <component :is="componentId" v-if="componentId" :selectedRow="selectedRow" @cancel="closeComponent"></component>
+    </div>
+</template>
+
+<script lang="ts">
+import { MtpTableButton, contextMenu, defineAsyncComponent, defineComponent, handleComposeTable, ComposeTableParam } from '@/common/export/commonTable';
+
+import { Filter, SomepriceDetail, SomepriceAudit, SomepriceCancel } from '../../../components';
+import { queryTableList, QryBusinessDjRsp } from '../setup';
+import { getPriceTypeName, getContractStatusName, getContractTypeName, getApplyStatusName } from '@/common/constants/enumsName';
+import { getAnalogueName } from '@/views/information/spot-contract/setup';
+import { Column, ColumnType } from '@/common/setup/table';
+import { ref } from 'vue';
+import { BtnListType } from '@/common/components/btnList/interface';
+import { EnumRouterName } from '@/common/constants/enumRouterName';
+import { getTableButton } from '@/common/setup/table/button';
+
+export default defineComponent({
+    name: 'business-review-dj',
+    components: {
+        contextMenu,
+        Filter,
+        MtpTableButton,
+        detail: defineAsyncComponent(() => import('../../../components/somepriceDetail/index.vue')),
+    },
+    setup() {
+        // 表格列表数据
+        const { loading, tableList, queryTable } = queryTableList({ applystatus: '2' });
+
+        // 获取列表数据
+        const queryTableAction = () => queryTable();
+        const filtrFn = (e: Column, item: ColumnType, filtered: any) => {
+            if (e.columnfield === 'buyusernameOrsellusername') {
+                item.onFilter = (value: string, record: QryBusinessDjRsp) => {
+                    const { contracttype, buyusername, sellusername } = record;
+                    if (contracttype === 1) {
+                        // 采购
+                        return sellusername.includes(value);
+                    } else {
+                        return buyusername.includes(value);
+                    }
+                };
+                item.filteredValue = filtered.buyusernameOrsellusername || null;
+            }
+        };
+
+        // 表格通用逻辑
+        const param: ComposeTableParam = {
+            queryFn: queryTableAction,
+            menuType: EnumRouterName.business_review_someprice,
+            tableName: 'table_pcweb_business_aduit_dj',
+            tableFilterKey: ['contracttype', 'contractno', 'deliverygoodsname'],
+            tableFilterCB: filtrFn,
+            isDetail: true,
+        };
+
+        function handlePermissionBtn(btnList: BtnListType[], item: QryBusinessDjRsp) {
+            if (item) {
+                const { applystatus } = item;
+                if (applystatus === 1) {
+                    return btnList;
+                } else {
+                    return btnList.filter((e) => e.code === 'detail');
+                }
+            } else {
+                return [];
+            }
+        }
+
+        // 权限按钮
+        const buttons = getTableButton(['detail']);
+
+        return {
+            ...handleComposeTable<QryBusinessDjRsp>(param),
+            handlePermissionBtn,
+            loading,
+            tableList,
+            getPriceTypeName,
+            getApplyStatusName,
+            getContractTypeName,
+            getContractStatusName,
+            getAnalogueName,
+            buttons,
+        };
+    },
+});
+</script>

+ 1 - 0
src/views/report/sum_pl_report/components/filterTable/index.vue

@@ -79,6 +79,7 @@ export default defineComponent({
             selectList,
             inputList,
             fixedBtnList,
+            update,
         };
     },
 });

+ 6 - 9
src/views/search/inventory/list/inventory_current/index.vue

@@ -66,9 +66,11 @@ export default defineComponent({
             expandedRowKeys,
             selectedRow,
             Rowclick, // 表格事件
-            tabList,
         } = handleComposeTable_detail<Ermcp3AreaStock>(param);
 
+        // 底部明细标签
+        const tabList = getTableButton(['inventory_manager_inbound_details', 'inventory_manager_outbound_details']);
+
         // 切换明细
         function changeTab(index: number, current: TabList) {
             const { code, lable } = current;
@@ -97,8 +99,8 @@ export default defineComponent({
         }
         watchEffect(() => {
             if (visible.value) {
-                if (tabList.value.length) {
-                    changeTab(0, tabList.value[0]);
+                if (tabList.length) {
+                    changeTab(0, tabList[0]);
                 }
             }
         });
@@ -130,9 +132,4 @@ export default defineComponent({
         };
     },
 });
-</script>
-
-<style lang="less">
-.inventory_current {
-}
-</style>;
+</script>

部分文件因为文件数量过多而无法显示