fix: license重新申请差异比较
This commit is contained in:
@@ -24,6 +24,12 @@ const columns = [
|
||||
dataIndex: 'neListMap',
|
||||
key: 'neListMap',
|
||||
customRender: (data: any) => {
|
||||
if (!data.value.old) {
|
||||
data.value.old = [];
|
||||
}
|
||||
if (!data.value.new) {
|
||||
data.value.new = [];
|
||||
}
|
||||
const oldDict = h(DictTagGroup, {
|
||||
type: [
|
||||
DICT_TYPE.LIC_NE_ALL,
|
||||
@@ -34,18 +40,26 @@ const columns = [
|
||||
],
|
||||
value: data.value.old,
|
||||
});
|
||||
if (data.value.new) {
|
||||
const newDict = h(DictTagGroup, {
|
||||
type: [
|
||||
DICT_TYPE.LIC_NE_ALL,
|
||||
DICT_TYPE.LIC_NE_5G,
|
||||
DICT_TYPE.LIC_NE_4G,
|
||||
DICT_TYPE.LIC_NE_23G,
|
||||
DICT_TYPE.LIC_NE_ADD,
|
||||
],
|
||||
color: 'red',
|
||||
value: data.value.new,
|
||||
});
|
||||
function arrayEquals(arr1: any[], arr2: any[]) {
|
||||
if (arr1.length !== arr2.length) {
|
||||
return false;
|
||||
}
|
||||
return arr1.some((item) => arr2.includes(item));
|
||||
}
|
||||
if (!arrayEquals(data.value.old, data.value.new)) {
|
||||
const newDict = data.value.new
|
||||
? h(DictTagGroup, {
|
||||
type: [
|
||||
DICT_TYPE.LIC_NE_ALL,
|
||||
DICT_TYPE.LIC_NE_5G,
|
||||
DICT_TYPE.LIC_NE_4G,
|
||||
DICT_TYPE.LIC_NE_23G,
|
||||
DICT_TYPE.LIC_NE_ADD,
|
||||
],
|
||||
color: 'red',
|
||||
value: data.value.new,
|
||||
})
|
||||
: '';
|
||||
const after = h(
|
||||
'span',
|
||||
{
|
||||
@@ -65,7 +79,10 @@ const columns = [
|
||||
dataIndex: 'activationCodeMap',
|
||||
key: 'activationCodeMap',
|
||||
customRender: (data: any) => {
|
||||
if (data.value.new) {
|
||||
if (!data.value.new) {
|
||||
data.value.new = '';
|
||||
}
|
||||
if (data.value.old !== data.value.new) {
|
||||
const after = h(
|
||||
'span',
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user