|
@@ -14,7 +14,7 @@ export function handlePurchase() {
|
|
|
// ========================loading========================
|
|
// ========================loading========================
|
|
|
const loading = ref<boolean>(false);
|
|
const loading = ref<boolean>(false);
|
|
|
// ========================获取列表数据========================
|
|
// ========================获取列表数据========================
|
|
|
- let purchaseList = ref<Ermcp3SellBuyContract[] | []>([]);
|
|
|
|
|
|
|
+ let customList = ref<Ermcp3SellBuyContract[] | []>([]);
|
|
|
function queryPurchase() {
|
|
function queryPurchase() {
|
|
|
const AreaUserID = APP.get('userAccount').memberuserid; // 所属机构id
|
|
const AreaUserID = APP.get('userAccount').memberuserid; // 所属机构id
|
|
|
const req: SellBuyContractReq = {
|
|
const req: SellBuyContractReq = {
|
|
@@ -24,7 +24,7 @@ export function handlePurchase() {
|
|
|
userid: getUserId(), // 用户ID
|
|
userid: getUserId(), // 用户ID
|
|
|
};
|
|
};
|
|
|
QueryPurchase(req).then((res) => {
|
|
QueryPurchase(req).then((res) => {
|
|
|
- purchaseList.value = res;
|
|
|
|
|
|
|
+ customList.value = res;
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -51,19 +51,24 @@ export function handlePurchase() {
|
|
|
queryPurchase();
|
|
queryPurchase();
|
|
|
getColumns();
|
|
getColumns();
|
|
|
});
|
|
});
|
|
|
- return { loading, purchaseList, columns };
|
|
|
|
|
|
|
+ return { loading, customList, columns };
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
// 按钮权限与功能组件
|
|
// 按钮权限与功能组件
|
|
|
export function btnAndComp() {
|
|
export function btnAndComp() {
|
|
|
- const { hasPermission } = handlePermission('custom_info_normal');
|
|
|
|
|
|
|
+ // 传入父及的code 得到当前1234级的整个权限
|
|
|
|
|
+ const { hasPermission } = handlePermission('purchase_pending');
|
|
|
|
|
+ // 配置右键菜单列表
|
|
|
const contextMenuList = ref<MenuItem[]>([]);
|
|
const contextMenuList = ref<MenuItem[]>([]);
|
|
|
|
|
+ // 打开新增页的弹窗 返回打开弹窗的方法
|
|
|
const { openAction: addAction } = openModal('addCustomInfo');
|
|
const { openAction: addAction } = openModal('addCustomInfo');
|
|
|
|
|
+ // 创建详情页并写入右键菜单列表(每个页面都有,写死)
|
|
|
detailButton('customDetail', contextMenuList);
|
|
detailButton('customDetail', contextMenuList);
|
|
|
- const { action: deleteAction } = permissionButton('deleteCustomInfo', '删除', contextMenuList);
|
|
|
|
|
- const { action: recoverAction } = permissionButton('recoverCustomInfo', '恢复', contextMenuList);
|
|
|
|
|
|
|
+ // 通过code跟弹窗建立联系 返回写入右键的方法
|
|
|
|
|
+ const { action: deleteAction } = permissionButton('purchase_pending_someprice', '点价登记', contextMenuList);
|
|
|
|
|
+
|
|
|
const stop = watchEffect(() => {
|
|
const stop = watchEffect(() => {
|
|
|
- hasPermission('custom_info_btn_recover') && recoverAction();
|
|
|
|
|
|
|
+ // 判断是否有权限 有就写入
|
|
|
hasPermission('custom_info_btn_delete') && deleteAction();
|
|
hasPermission('custom_info_btn_delete') && deleteAction();
|
|
|
});
|
|
});
|
|
|
return {
|
|
return {
|