From 3962c2bb0435484b60a3e408e4738d792e249a53 Mon Sep 17 00:00:00 2001
From: buli <137736985@qq.com>
Date: 星期一, 05 六月 2023 11:09:55 +0800
Subject: [PATCH] LEX CommunityNewCmp
---
force-app/main/default/lwc/lexCustomLightningDatatable/lexCustomLightningDatatable.js | 84 ++++++++++++++++++++++++++++++++++++++++++
1 files changed, 84 insertions(+), 0 deletions(-)
diff --git a/force-app/main/default/lwc/lexCustomLightningDatatable/lexCustomLightningDatatable.js b/force-app/main/default/lwc/lexCustomLightningDatatable/lexCustomLightningDatatable.js
new file mode 100644
index 0000000..e82595a
--- /dev/null
+++ b/force-app/main/default/lwc/lexCustomLightningDatatable/lexCustomLightningDatatable.js
@@ -0,0 +1,84 @@
+import LightningDatatable from 'lightning/datatable';
+import customUnitTemplate from './customUnit.html';
+import customShipmentNumberTemplate from './customShipmentNumber.html';
+import customShippingUnitPriceTemplate from './customShippingUnitPrice.html';
+import customShipmentAmountTemplate from './customShipmentAmount.html';
+import customDiffReasonTemplate from './lexCustomDiffReason.html';
+import attachmentTypeTemplate from './customAttachmentType.html';
+import customTableInputTemplate from './customTableInput.html';
+import customOutputGoodsTemplate from './customOutputGoods.html';
+import customReturnGoodInputTemplate from './customReturnGoodInput.html';
+import customInventoryColorTemplate from './customInventoryColor.html';
+import customTableCellIconTemplate from './customTableCellIcon.html';
+import customOutboundCountTemplate from './customOutboundCount.html';
+import customWeeklyReportTemplate from './customWeeklyReport.html';
+import customAgencyOppInputTemplate from './customAgencyOppInput.html';
+import { loadStyle} from 'lightning/platformResourceLoader';
+import LexCustomDataTable from '@salesforce/resourceUrl/LexCustomDataTable';
+
+export default class LexCustomLightningDatatable extends LightningDatatable {
+ static customTypes = {
+ customUnit: {
+ template: customUnitTemplate,
+ typeAttributes: ['unitValue','unitOptions','recordId','isDisabled'],
+ },
+ customShipment: {
+ template: customShipmentNumberTemplate,
+ typeAttributes: ['shipmentNumber','recordId'],
+ },
+ customShipmentUnitPrice: {
+ template: customShippingUnitPriceTemplate,
+ typeAttributes: ['shippingUnitPrice','recordId'],
+ },
+ customShipmentAmount: {
+ template: customShipmentAmountTemplate,
+ typeAttributes: ['shipmentAmount','recordId'],
+ },
+ customDiffReason : {
+ template: customDiffReasonTemplate,
+ typeAttributes: ['ProdId','boxPiece'],
+ },
+ customAttachmentType: {
+ template: attachmentTypeTemplate,
+ typeAttributes: ['typeValue','typeOptions','recordId','isDisabledAttachment'],
+ },
+ customTableInput: {
+ template: customTableInputTemplate,
+ typeAttributes:['inputValue','recordId','valueType','upperLimit','lowerLimit','allnumber'],
+ },
+ customOutputGood:{
+ template: customOutputGoodsTemplate,
+ typeAttributes:['outputValue','type','recordId'],
+ },
+ customReturnGoodInput:{
+ template: customReturnGoodInputTemplate,
+ typeAttributes:['inputValue','boxPrice','recordId'],
+ },
+ customInventoryColor:{
+ template: customInventoryColorTemplate,
+ typeAttributes:['value','upperlimit','lowerlimit','boxPrice'],
+ },
+ tableCellIcon:{
+ template: customTableCellIconTemplate,
+ typeAttributes:['iconName','recordId'],
+ },
+ outboundCount:{
+ template: customOutboundCountTemplate,
+ typeAttributes:['isDisable','recordId','Count'],
+ },
+ weeklyReport:{
+ template: customWeeklyReportTemplate,
+ typeAttributes:['recordId','hospitalName','isShowButton'],
+ },
+ agencyOppInput:{
+ template: customAgencyOppInputTemplate,
+ typeAttributes:['inputValue','recordId','fieldName','showType'],
+ }
+ };
+ constructor() {
+ super();
+ Promise.all([
+ loadStyle(this, LexCustomDataTable),
+ ]).then(() => {})
+ }
+}
\ No newline at end of file
--
Gitblit v1.9.1