From 44f866419cde0ff12a91d9c1d92daf9e36b063e1 Mon Sep 17 00:00:00 2001
From: buli <137736985@qq.com>
Date: 星期四, 20 四月 2023 13:22:38 +0800
Subject: [PATCH] backup0420
---
force-app/main/default/lwc/lexinventoryViewLWC/lexinventoryViewLWC.js | 81 +++++++++++++++++++++++++---------------
1 files changed, 51 insertions(+), 30 deletions(-)
diff --git a/force-app/main/default/lwc/lexinventoryViewLWC/lexinventoryViewLWC.js b/force-app/main/default/lwc/lexinventoryViewLWC/lexinventoryViewLWC.js
index ac4f146..b24100b 100644
--- a/force-app/main/default/lwc/lexinventoryViewLWC/lexinventoryViewLWC.js
+++ b/force-app/main/default/lwc/lexinventoryViewLWC/lexinventoryViewLWC.js
@@ -9,43 +9,45 @@
fieldName: 'Name__c',
type: 'Name',
sortable: true,
+ initialWidth: 250,
cellAttributes: { alignment: 'left' }
},
{
label: '绗笁鍒嗙被',
fieldName: 'Category3__c',
hideDefaultActions: true,
- sortable: true
+ sortable: true,
+ initialWidth: 90
},
{
label: '绗洓鍒嗙被',
fieldName: 'Category4__c',
hideDefaultActions: true,
- sortable: true
+ sortable: true,
+ initialWidth: 90
},
{
label: '绗簲鍒嗙被',
fieldName: 'Category5__c',
- hideDefaultActions: true
+ hideDefaultActions: true,
+ initialWidth: 90
},
{
label: '瑙勬牸',
fieldName: 'packing_list',
- hideDefaultActions: true,
- initialWidth: 100
+ hideDefaultActions: true
},
{
label: '鍗曚綅',
fieldName: 'BoxPiece',
- hideDefaultActions: true,
- initialWidth: 100
+ hideDefaultActions: true
},
{
label: '娉ㄥ唽璇佺紪鐮佸彿',
fieldName: 'approbation_No',
- hideDefaultActions: true,
- initialWidth: 100
+ initialWidth: 180,
+ hideDefaultActions: true
},
{
label: '娉ㄥ唽鏈夋晥鏈�',
@@ -56,27 +58,33 @@
{
label: 'CFDA鐘舵��',
fieldName: 'SFDA_Status__c',
- hideDefaultActions: true
+ hideDefaultActions: true,
+ initialWidth: 100
},
{
label: '浣跨敤鏈熼檺',
fieldName: 'guaranteeperiod',
- hideDefaultActions: true
+ hideDefaultActions: true,
+ initialWidth: 100
},
{
label: '鏈夋晥鏈熷唴搴撳瓨',
fieldName: 'limitCount',
hideDefaultActions: true,
- sortable: true
+ sortable: true,
+ initialWidth: 100
},
{
label: '杩囨湡搴撳瓨',
fieldName: 'overlimitCount',
- hideDefaultActions: true
+ hideDefaultActions: true,
+ initialWidth: 100
}
];
-export default class LexinventoryViewLWC extends LightningElement {
+export default class LexinventoryViewLWC extends NavigationMixin(
+ LightningElement
+) {
@track pageRecords = [];
@track data = [];
@track message = '';
@@ -90,9 +98,11 @@
@track userWorkLocation;
@track value = '';
@track showTable = false;
- @track optionscatone = [];
- @track options2 = [];
- @track options3 = [];
+ @track hidecheckboxcolumn = true;
+ @track check = false;
+ // @track options1 = [];
+ // @track options2 = [];
+ // @track options3 = [];
columns = columns;
defaultSortDirection = 'asc';
@@ -150,7 +160,7 @@
object['value'] = key;
option1ValueTemp.push(object);
}
- this.optionscatone = option1ValueTemp;
+ this.options1 = option1ValueTemp;
console.log(
' this.optionscatone===>' +
JSON.stringify(this.optionscatone)
@@ -163,12 +173,14 @@
option2ValueTemp.push(object);
}
this.options2 = option2ValueTemp;
+ let option3ValueTemp = [];
for (var key in result.entity.category5OptionMap) {
let object = {};
object['label'] = result.entity.category5OptionMap[key];
object['value'] = key;
- this.options3.push(object);
+ option3ValueTemp.push(object);
}
+ this.options3 = option3ValueTemp;
console.log(' this.data=====>' + this.data);
@@ -196,13 +208,6 @@
.catch((error) => {
console.log('error = ' + JSON.stringify(error));
});
- }
-
- get options2() {
- return this.options2;
- }
- get options3() {
- return this.options3;
}
sortBy(field, reverse, primer) {
const key = primer
@@ -266,12 +271,13 @@
this.showTable = false;
console.log('杩涘叆鎼滅储11111111111111');
console.log('杩涘叆鎼滅储');
- console.log('this.Name = ' + this.Name);
+ console.log('this.CategoryThree = ' + this.CategoryThree);
+ console.log('this.CategoryFive = ' + this.CategoryFive);
searchOrder({
category1: this.Name,
Category3: this.CategoryThree,
- Category4: '',
- Category5: '',
+ Category4: this.CategoryFour,
+ Category5: this.CategoryFive,
orderDetZaikuListLWC: JSON.stringify(this.orderDetZaikuList),
accountName: this.accountName,
agencyProType: this.agencyProType,
@@ -280,6 +286,10 @@
.then((result) => {
result = JSON.parse(JSON.stringify(result));
console.log('result鎼滅储 = ' + JSON.stringify(result));
+ console.log(
+ 'result鎼滅储鍒楄〃= ' +
+ JSON.stringify(result.entity.pageRecords)
+ );
if (result.status == 'Success') {
const evt = new ShowToastEvent({
title: '鎼滅储鎴愬姛',
@@ -287,7 +297,7 @@
variant: 'Success'
});
this.dispatchEvent(evt);
- this.pageRecords = result.entity.pageRecords;
+ this.data = result.entity.pageRecords;
this.showTable = true;
} else {
const evt = new ShowToastEvent({
@@ -304,6 +314,7 @@
console.log('error = ' + JSON.stringify(error));
});
}
+
inventoryCount() {
console.log('111搴撳瓨鐩樼偣');
this[NavigationMixin.Navigate]({
@@ -313,6 +324,16 @@
}
});
}
+
+ handleExpired() {
+ this[NavigationMixin.Navigate]({
+ type: 'standard__webPage',
+ attributes: {
+ url: '/lexOverdueStock'
+ }
+ });
+ }
+
clearAll() {
this.Name = '';
this.value = '鏃�';
--
Gitblit v1.9.1