提交 f42f01d7 编写于 作者: ibizdev's avatar ibizdev

chitanda 发布系统代码

上级 a46f7f06
......@@ -64,6 +64,21 @@ export default class CampaignServiceBase extends EntityService {
*/
public async Create(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
let campaignlistsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists'),'undefined')){
campaignlistsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists') as any);
......@@ -94,21 +109,6 @@ export default class CampaignServiceBase extends EntityService {
}
}
masterData.campaigncampaigns = campaigncampaignsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -118,9 +118,9 @@ export default class CampaignServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/campaigns`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(tempContext.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
this.tempStorage.setItem(tempContext.srfsessionkey+'_campaigncampaigns',JSON.stringify(res.data.campaigncampaigns));
this.tempStorage.setItem(tempContext.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
return res;
}
......@@ -135,6 +135,21 @@ export default class CampaignServiceBase extends EntityService {
*/
public async Update(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
let campaignlistsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists'),'undefined')){
campaignlistsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists') as any);
......@@ -165,26 +180,11 @@ export default class CampaignServiceBase extends EntityService {
}
}
masterData.campaigncampaigns = campaigncampaignsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/campaigns/${context.campaign}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
this.tempStorage.setItem(context.srfsessionkey+'_campaigncampaigns',JSON.stringify(res.data.campaigncampaigns));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
return res;
}
......@@ -212,9 +212,9 @@ export default class CampaignServiceBase extends EntityService {
*/
public async Get(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/campaigns/${context.campaign}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
this.tempStorage.setItem(context.srfsessionkey+'_campaigncampaigns',JSON.stringify(res.data.campaigncampaigns));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
return res;
}
......@@ -230,9 +230,9 @@ export default class CampaignServiceBase extends EntityService {
public async GetDraft(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/campaigns/getdraft`,isloading);
res.data.campaign = data.campaign;
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
this.tempStorage.setItem(context.srfsessionkey+'_campaigncampaigns',JSON.stringify(res.data.campaigncampaigns));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
return res;
}
......@@ -275,6 +275,21 @@ export default class CampaignServiceBase extends EntityService {
*/
public async Save(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
let campaignlistsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists'),'undefined')){
campaignlistsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists') as any);
......@@ -305,26 +320,11 @@ export default class CampaignServiceBase extends EntityService {
}
}
masterData.campaigncampaigns = campaigncampaignsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
this.tempStorage.setItem(context.srfsessionkey+'_campaigncampaigns',JSON.stringify(res.data.campaigncampaigns));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
return res;
}
......
......@@ -62,6 +62,21 @@ export default class CompetitorServiceBase extends EntityService {
*/
public async Create(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let opportunitycompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors'),'undefined')){
opportunitycompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors') as any);
if(opportunitycompetitorsData && opportunitycompetitorsData.length && opportunitycompetitorsData.length > 0){
opportunitycompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
let competitorproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_competitorproducts'),'undefined')){
competitorproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_competitorproducts') as any);
......@@ -92,21 +107,6 @@ export default class CompetitorServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
let opportunitycompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors'),'undefined')){
opportunitycompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors') as any);
if(opportunitycompetitorsData && opportunitycompetitorsData.length && opportunitycompetitorsData.length > 0){
opportunitycompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -116,9 +116,9 @@ export default class CompetitorServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/competitors`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_competitorproducts',JSON.stringify(res.data.competitorproducts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
......@@ -133,6 +133,21 @@ export default class CompetitorServiceBase extends EntityService {
*/
public async Update(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let opportunitycompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors'),'undefined')){
opportunitycompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors') as any);
if(opportunitycompetitorsData && opportunitycompetitorsData.length && opportunitycompetitorsData.length > 0){
opportunitycompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
let competitorproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_competitorproducts'),'undefined')){
competitorproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_competitorproducts') as any);
......@@ -163,26 +178,11 @@ export default class CompetitorServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
let opportunitycompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors'),'undefined')){
opportunitycompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors') as any);
if(opportunitycompetitorsData && opportunitycompetitorsData.length && opportunitycompetitorsData.length > 0){
opportunitycompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/competitors/${context.competitor}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_competitorproducts',JSON.stringify(res.data.competitorproducts));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
......@@ -210,9 +210,9 @@ export default class CompetitorServiceBase extends EntityService {
*/
public async Get(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/competitors/${context.competitor}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_competitorproducts',JSON.stringify(res.data.competitorproducts));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
......@@ -228,9 +228,9 @@ export default class CompetitorServiceBase extends EntityService {
public async GetDraft(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/competitors/getdraft`,isloading);
res.data.competitor = data.competitor;
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_competitorproducts',JSON.stringify(res.data.competitorproducts));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
......@@ -258,6 +258,21 @@ export default class CompetitorServiceBase extends EntityService {
*/
public async Save(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let opportunitycompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors'),'undefined')){
opportunitycompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors') as any);
if(opportunitycompetitorsData && opportunitycompetitorsData.length && opportunitycompetitorsData.length > 0){
opportunitycompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
let competitorproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_competitorproducts'),'undefined')){
competitorproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_competitorproducts') as any);
......@@ -288,26 +303,11 @@ export default class CompetitorServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
let opportunitycompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors'),'undefined')){
opportunitycompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunitycompetitors') as any);
if(opportunitycompetitorsData && opportunitycompetitorsData.length && opportunitycompetitorsData.length > 0){
opportunitycompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/competitors/${context.competitor}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_competitorproducts',JSON.stringify(res.data.competitorproducts));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
......
......@@ -68,21 +68,21 @@ export default class ContactServiceBase extends EntityService {
public async Create(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && true){
let masterData:any = {};
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityid = null;
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunities = opportunitiesData;
masterData.leads = leadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
......@@ -98,21 +98,21 @@ export default class ContactServiceBase extends EntityService {
}
}
masterData.listcontacts = listcontactsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
item.opportunityid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
masterData.opportunities = opportunitiesData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -122,27 +122,27 @@ export default class ContactServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
let masterData:any = {};
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityid = null;
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunities = opportunitiesData;
masterData.leads = leadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
......@@ -158,21 +158,21 @@ export default class ContactServiceBase extends EntityService {
}
}
masterData.listcontacts = listcontactsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
item.opportunityid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
masterData.opportunities = opportunitiesData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -182,9 +182,9 @@ export default class ContactServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/contacts`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
......@@ -200,21 +200,21 @@ export default class ContactServiceBase extends EntityService {
public async Update(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact){
let masterData:any = {};
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityid = null;
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunities = opportunitiesData;
masterData.leads = leadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
......@@ -230,44 +230,44 @@ export default class ContactServiceBase extends EntityService {
}
}
masterData.listcontacts = listcontactsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
item.opportunityid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
masterData.opportunities = opportunitiesData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/contacts/${context.contact}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
let masterData:any = {};
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityid = null;
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunities = opportunitiesData;
masterData.leads = leadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
......@@ -283,26 +283,26 @@ export default class ContactServiceBase extends EntityService {
}
}
masterData.listcontacts = listcontactsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
item.opportunityid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
masterData.opportunities = opportunitiesData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/contacts/${context.contact}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
......@@ -334,15 +334,15 @@ export default class ContactServiceBase extends EntityService {
public async Get(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/contacts/${context.contact}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
let res:any = await Http.getInstance().get(`/contacts/${context.contact}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
......@@ -359,16 +359,16 @@ export default class ContactServiceBase extends EntityService {
if(context.account && true){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/contacts/getdraft`,isloading);
res.data.contact = data.contact;
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
let res:any = await Http.getInstance().get(`/contacts/getdraft`,isloading);
res.data.contact = data.contact;
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
......@@ -399,21 +399,21 @@ export default class ContactServiceBase extends EntityService {
public async AddList(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact){
let masterData:any = {};
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityid = null;
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunities = opportunitiesData;
masterData.leads = leadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
......@@ -429,26 +429,26 @@ export default class ContactServiceBase extends EntityService {
}
}
masterData.listcontacts = listcontactsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
item.opportunityid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
masterData.opportunities = opportunitiesData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/addlist`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
return Http.getInstance().post(`/contacts/${context.contact}/addlist`,data,isloading);
......@@ -466,21 +466,21 @@ export default class ContactServiceBase extends EntityService {
public async CheckKey(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact){
let masterData:any = {};
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityid = null;
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunities = opportunitiesData;
masterData.leads = leadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
......@@ -496,26 +496,26 @@ export default class ContactServiceBase extends EntityService {
}
}
masterData.listcontacts = listcontactsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
item.opportunityid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
masterData.opportunities = opportunitiesData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
return Http.getInstance().post(`/contacts/${context.contact}/checkkey`,data,isloading);
......@@ -548,21 +548,21 @@ export default class ContactServiceBase extends EntityService {
public async Save(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact){
let masterData:any = {};
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityid = null;
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunities = opportunitiesData;
masterData.leads = leadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
......@@ -578,44 +578,44 @@ export default class ContactServiceBase extends EntityService {
}
}
masterData.listcontacts = listcontactsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
item.opportunityid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
masterData.opportunities = opportunitiesData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
let masterData:any = {};
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityid = null;
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunities = opportunitiesData;
masterData.leads = leadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
......@@ -631,26 +631,26 @@ export default class ContactServiceBase extends EntityService {
}
}
masterData.listcontacts = listcontactsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
item.opportunityid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
masterData.opportunities = opportunitiesData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
......@@ -666,21 +666,21 @@ export default class ContactServiceBase extends EntityService {
public async SetPrimary(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact){
let masterData:any = {};
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityid = null;
item.leadid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunities = opportunitiesData;
masterData.leads = leadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
......@@ -696,26 +696,26 @@ export default class ContactServiceBase extends EntityService {
}
}
masterData.listcontacts = listcontactsData;
let leadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leads'),'undefined')){
leadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leads') as any);
if(leadsData && leadsData.length && leadsData.length > 0){
leadsData.forEach((item:any) => {
let opportunitiesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunities'),'undefined')){
opportunitiesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunities') as any);
if(opportunitiesData && opportunitiesData.length && opportunitiesData.length > 0){
opportunitiesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.leadid = null;
item.opportunityid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leads = leadsData;
masterData.opportunities = opportunitiesData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/setprimary`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_leads',JSON.stringify(res.data.leads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_opportunities',JSON.stringify(res.data.opportunities));
return res;
}
return Http.getInstance().post(`/contacts/${context.contact}/setprimary`,data,isloading);
......
......@@ -64,11 +64,11 @@ export default class IBizListServiceBase extends EntityService {
*/
public async Create(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let listaccountsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts'),'undefined')){
listaccountsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts') as any);
if(listaccountsData && listaccountsData.length && listaccountsData.length > 0){
listaccountsData.forEach((item:any) => {
let campaignlistsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists'),'undefined')){
campaignlistsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists') as any);
if(campaignlistsData && campaignlistsData.length && campaignlistsData.length > 0){
campaignlistsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -78,12 +78,12 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.listaccounts = listaccountsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
masterData.campaignlists = campaignlistsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
if(listcontactsData && listcontactsData.length && listcontactsData.length > 0){
listcontactsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -93,12 +93,12 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.listleads = listleadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
if(listcontactsData && listcontactsData.length && listcontactsData.length > 0){
listcontactsData.forEach((item:any) => {
masterData.listcontacts = listcontactsData;
let listaccountsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts'),'undefined')){
listaccountsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts') as any);
if(listaccountsData && listaccountsData.length && listaccountsData.length > 0){
listaccountsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -108,12 +108,12 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.listcontacts = listcontactsData;
let campaignlistsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists'),'undefined')){
campaignlistsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists') as any);
if(campaignlistsData && campaignlistsData.length && campaignlistsData.length > 0){
campaignlistsData.forEach((item:any) => {
masterData.listaccounts = listaccountsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -123,7 +123,7 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.campaignlists = campaignlistsData;
masterData.listleads = listleadsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -133,10 +133,10 @@ export default class IBizListServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/ibizlists`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listaccounts',JSON.stringify(res.data.listaccounts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
return res;
}
......@@ -151,11 +151,11 @@ export default class IBizListServiceBase extends EntityService {
*/
public async Update(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let listaccountsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts'),'undefined')){
listaccountsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts') as any);
if(listaccountsData && listaccountsData.length && listaccountsData.length > 0){
listaccountsData.forEach((item:any) => {
let campaignlistsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists'),'undefined')){
campaignlistsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists') as any);
if(campaignlistsData && campaignlistsData.length && campaignlistsData.length > 0){
campaignlistsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -165,12 +165,12 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.listaccounts = listaccountsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
masterData.campaignlists = campaignlistsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
if(listcontactsData && listcontactsData.length && listcontactsData.length > 0){
listcontactsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -180,12 +180,12 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.listleads = listleadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
if(listcontactsData && listcontactsData.length && listcontactsData.length > 0){
listcontactsData.forEach((item:any) => {
masterData.listcontacts = listcontactsData;
let listaccountsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts'),'undefined')){
listaccountsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts') as any);
if(listaccountsData && listaccountsData.length && listaccountsData.length > 0){
listaccountsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -195,12 +195,12 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.listcontacts = listcontactsData;
let campaignlistsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists'),'undefined')){
campaignlistsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists') as any);
if(campaignlistsData && campaignlistsData.length && campaignlistsData.length > 0){
campaignlistsData.forEach((item:any) => {
masterData.listaccounts = listaccountsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -210,13 +210,13 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.campaignlists = campaignlistsData;
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/ibizlists/${context.ibizlist}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_listaccounts',JSON.stringify(res.data.listaccounts));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
return res;
}
......@@ -244,10 +244,10 @@ export default class IBizListServiceBase extends EntityService {
*/
public async Get(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/ibizlists/${context.ibizlist}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_listaccounts',JSON.stringify(res.data.listaccounts));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
return res;
}
......@@ -263,10 +263,10 @@ export default class IBizListServiceBase extends EntityService {
public async GetDraft(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/ibizlists/getdraft`,isloading);
res.data.ibizlist = data.ibizlist;
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_listaccounts',JSON.stringify(res.data.listaccounts));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
return res;
}
......@@ -309,11 +309,11 @@ export default class IBizListServiceBase extends EntityService {
*/
public async Save(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let listaccountsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts'),'undefined')){
listaccountsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts') as any);
if(listaccountsData && listaccountsData.length && listaccountsData.length > 0){
listaccountsData.forEach((item:any) => {
let campaignlistsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists'),'undefined')){
campaignlistsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists') as any);
if(campaignlistsData && campaignlistsData.length && campaignlistsData.length > 0){
campaignlistsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -323,12 +323,12 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.listaccounts = listaccountsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
masterData.campaignlists = campaignlistsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
if(listcontactsData && listcontactsData.length && listcontactsData.length > 0){
listcontactsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -338,12 +338,12 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.listleads = listleadsData;
let listcontactsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts'),'undefined')){
listcontactsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listcontacts') as any);
if(listcontactsData && listcontactsData.length && listcontactsData.length > 0){
listcontactsData.forEach((item:any) => {
masterData.listcontacts = listcontactsData;
let listaccountsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts'),'undefined')){
listaccountsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listaccounts') as any);
if(listaccountsData && listaccountsData.length && listaccountsData.length > 0){
listaccountsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -353,12 +353,12 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.listcontacts = listcontactsData;
let campaignlistsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists'),'undefined')){
campaignlistsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_campaignlists') as any);
if(campaignlistsData && campaignlistsData.length && campaignlistsData.length > 0){
campaignlistsData.forEach((item:any) => {
masterData.listaccounts = listaccountsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -368,13 +368,13 @@ export default class IBizListServiceBase extends EntityService {
});
}
}
masterData.campaignlists = campaignlistsData;
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/ibizlists/${context.ibizlist}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_listaccounts',JSON.stringify(res.data.listaccounts));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_listcontacts',JSON.stringify(res.data.listcontacts));
this.tempStorage.setItem(context.srfsessionkey+'_campaignlists',JSON.stringify(res.data.campaignlists));
return res;
}
......
......@@ -79,11 +79,11 @@ export default class LeadServiceBase extends EntityService {
public async Create(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && true){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -93,12 +93,12 @@ export default class LeadServiceBase extends EntityService {
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -108,7 +108,7 @@ export default class LeadServiceBase extends EntityService {
});
}
}
masterData.listleads = listleadsData;
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -118,17 +118,17 @@ export default class LeadServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.contact && true){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -138,12 +138,12 @@ export default class LeadServiceBase extends EntityService {
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -153,7 +153,7 @@ export default class LeadServiceBase extends EntityService {
});
}
}
masterData.listleads = listleadsData;
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -163,17 +163,17 @@ export default class LeadServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.campaign && true){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -183,12 +183,12 @@ export default class LeadServiceBase extends EntityService {
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -198,7 +198,7 @@ export default class LeadServiceBase extends EntityService {
});
}
}
masterData.listleads = listleadsData;
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -208,17 +208,17 @@ export default class LeadServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.account && true){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -228,12 +228,12 @@ export default class LeadServiceBase extends EntityService {
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -243,7 +243,7 @@ export default class LeadServiceBase extends EntityService {
});
}
}
masterData.listleads = listleadsData;
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -253,16 +253,16 @@ export default class LeadServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/accounts/${context.account}/leads`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -272,12 +272,12 @@ export default class LeadServiceBase extends EntityService {
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
if(listleadsData && listleadsData.length && listleadsData.length > 0){
listleadsData.forEach((item:any) => {
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
......@@ -287,7 +287,7 @@ export default class LeadServiceBase extends EntityService {
});
}
}
masterData.listleads = listleadsData;
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -297,8 +297,8 @@ export default class LeadServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/leads`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(tempContext.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
......@@ -314,21 +314,6 @@ export default class LeadServiceBase extends EntityService {
public async Update(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -344,14 +329,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -367,6 +344,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -382,14 +367,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/contacts/${context.contact}/leads/${context.lead}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -405,6 +382,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/contacts/${context.contact}/leads/${context.lead}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -420,14 +405,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/campaigns/${context.campaign}/leads/${context.lead}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -443,6 +420,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/campaigns/${context.campaign}/leads/${context.lead}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -458,13 +443,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/leads/${context.lead}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -480,6 +458,13 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/leads/${context.lead}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -495,10 +480,25 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/leads/${context.lead}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
......@@ -539,31 +539,31 @@ export default class LeadServiceBase extends EntityService {
public async Get(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.lead){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.contact && context.lead){
let res:any = await Http.getInstance().get(`/contacts/${context.contact}/leads/${context.lead}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.campaign && context.lead){
let res:any = await Http.getInstance().get(`/campaigns/${context.campaign}/leads/${context.lead}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.account && context.lead){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/leads/${context.lead}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
let res:any = await Http.getInstance().get(`/leads/${context.lead}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
......@@ -580,35 +580,35 @@ export default class LeadServiceBase extends EntityService {
if(context.account && context.contact && true){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/contacts/${context.contact}/leads/getdraft`,isloading);
res.data.lead = data.lead;
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.contact && true){
let res:any = await Http.getInstance().get(`/contacts/${context.contact}/leads/getdraft`,isloading);
res.data.lead = data.lead;
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.campaign && true){
let res:any = await Http.getInstance().get(`/campaigns/${context.campaign}/leads/getdraft`,isloading);
res.data.lead = data.lead;
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.account && true){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/leads/getdraft`,isloading);
res.data.lead = data.lead;
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
let res:any = await Http.getInstance().get(`/leads/getdraft`,isloading);
res.data.lead = data.lead;
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
......@@ -624,21 +624,6 @@ export default class LeadServiceBase extends EntityService {
public async Active(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -654,14 +639,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -677,6 +654,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -692,14 +677,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -715,6 +692,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -730,14 +715,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -753,6 +730,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -768,10 +753,25 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/leads/${context.lead}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
return Http.getInstance().post(`/leads/${context.lead}/active`,data,isloading);
......@@ -789,21 +789,6 @@ export default class LeadServiceBase extends EntityService {
public async AddList(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -819,14 +804,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/addlist`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -842,6 +819,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/addlist`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -857,14 +842,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/addlist`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -880,6 +857,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/addlist`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -895,14 +880,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/addlist`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -918,6 +895,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/addlist`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -933,10 +918,25 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/leads/${context.lead}/addlist`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
return Http.getInstance().post(`/leads/${context.lead}/addlist`,data,isloading);
......@@ -969,21 +969,6 @@ export default class LeadServiceBase extends EntityService {
public async CheckKey(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -999,14 +984,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1022,6 +999,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1037,14 +1022,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1060,6 +1037,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1075,14 +1060,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1098,6 +1075,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1113,10 +1098,25 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/leads/${context.lead}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
return Http.getInstance().post(`/leads/${context.lead}/checkkey`,data,isloading);
......@@ -1134,21 +1134,6 @@ export default class LeadServiceBase extends EntityService {
public async DisQualification(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1164,14 +1149,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/disqualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1187,6 +1164,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/disqualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1202,14 +1187,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/disqualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1225,6 +1202,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/disqualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1240,14 +1225,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/disqualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1263,6 +1240,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/disqualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1278,10 +1263,25 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/leads/${context.lead}/disqualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
return Http.getInstance().post(`/leads/${context.lead}/disqualification`,data,isloading);
......@@ -1329,21 +1329,6 @@ export default class LeadServiceBase extends EntityService {
public async Qualification(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1359,14 +1344,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/qualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1382,6 +1359,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/qualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1397,14 +1382,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/qualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1420,6 +1397,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/qualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1435,14 +1420,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/qualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1458,6 +1435,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/qualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1473,10 +1458,25 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/leads/${context.lead}/qualification`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
return Http.getInstance().post(`/leads/${context.lead}/qualification`,data,isloading);
......@@ -1494,21 +1494,6 @@ export default class LeadServiceBase extends EntityService {
public async Save(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1524,14 +1509,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1547,6 +1524,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/leads/${context.lead}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.contact && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1562,14 +1547,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1585,6 +1562,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/leads/${context.lead}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.campaign && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1600,14 +1585,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1623,6 +1600,14 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/campaigns/${context.campaign}/leads/${context.lead}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
if(context.account && context.lead){
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1638,13 +1623,6 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/leads/${context.lead}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
return res;
}
let masterData:any = {};
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
......@@ -1660,6 +1638,13 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/leads/${context.lead}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
let masterData:any = {};
let listleadsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_listleads'),'undefined')){
listleadsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_listleads') as any);
......@@ -1675,10 +1660,25 @@ export default class LeadServiceBase extends EntityService {
}
}
masterData.listleads = listleadsData;
let leadcompetitorsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors'),'undefined')){
leadcompetitorsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_leadcompetitors') as any);
if(leadcompetitorsData && leadcompetitorsData.length && leadcompetitorsData.length > 0){
leadcompetitorsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.leadcompetitors = leadcompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/leads/${context.lead}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_listleads',JSON.stringify(res.data.listleads));
this.tempStorage.setItem(context.srfsessionkey+'_leadcompetitors',JSON.stringify(res.data.leadcompetitors));
return res;
}
......
......@@ -74,6 +74,21 @@ export default class OpportunityServiceBase extends EntityService {
public async Create(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && true){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -104,21 +119,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -128,13 +128,28 @@ export default class OpportunityServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.contact && true){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -165,21 +180,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -189,13 +189,28 @@ export default class OpportunityServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.account && true){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -226,6 +241,21 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -241,21 +271,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -286,21 +301,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -310,9 +310,9 @@ export default class OpportunityServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/opportunities`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(tempContext.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
......@@ -328,6 +328,21 @@ export default class OpportunityServiceBase extends EntityService {
public async Update(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -358,6 +373,15 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
if(context.contact && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -373,15 +397,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.contact && context.opportunity){
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -412,6 +427,15 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/contacts/${context.contact}/opportunities/${context.opportunity}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
if(context.account && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -427,15 +451,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/contacts/${context.contact}/opportunities/${context.opportunity}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.account && context.opportunity){
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -466,6 +481,14 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/opportunities/${context.opportunity}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -481,14 +504,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/opportunities/${context.opportunity}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -519,26 +534,11 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/opportunities/${context.opportunity}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
......@@ -576,29 +576,29 @@ export default class OpportunityServiceBase extends EntityService {
public async Get(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.contact && context.opportunity){
let res:any = await Http.getInstance().get(`/contacts/${context.contact}/opportunities/${context.opportunity}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.account && context.opportunity){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/opportunities/${context.opportunity}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
let res:any = await Http.getInstance().get(`/opportunities/${context.opportunity}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
......@@ -615,32 +615,32 @@ export default class OpportunityServiceBase extends EntityService {
if(context.account && context.contact && true){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/contacts/${context.contact}/opportunities/getdraft`,isloading);
res.data.opportunity = data.opportunity;
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.contact && true){
let res:any = await Http.getInstance().get(`/contacts/${context.contact}/opportunities/getdraft`,isloading);
res.data.opportunity = data.opportunity;
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.account && true){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/opportunities/getdraft`,isloading);
res.data.opportunity = data.opportunity;
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
let res:any = await Http.getInstance().get(`/opportunities/getdraft`,isloading);
res.data.opportunity = data.opportunity;
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
......@@ -656,6 +656,21 @@ export default class OpportunityServiceBase extends EntityService {
public async Active(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -686,6 +701,15 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
if(context.contact && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -701,15 +725,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.contact && context.opportunity){
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -740,6 +755,15 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
if(context.account && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -755,15 +779,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.account && context.opportunity){
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -794,26 +809,11 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/active`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
return Http.getInstance().post(`/opportunities/${context.opportunity}/active`,data,isloading);
......@@ -831,6 +831,21 @@ export default class OpportunityServiceBase extends EntityService {
public async CheckKey(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -861,6 +876,15 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
if(context.contact && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -876,15 +900,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.contact && context.opportunity){
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -915,6 +930,15 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
if(context.account && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -930,15 +954,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.account && context.opportunity){
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -969,26 +984,11 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
return Http.getInstance().post(`/opportunities/${context.opportunity}/checkkey`,data,isloading);
......@@ -1021,6 +1021,21 @@ export default class OpportunityServiceBase extends EntityService {
public async Save(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -1051,6 +1066,15 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
if(context.contact && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -1066,15 +1090,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.contact && context.opportunity){
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -1105,6 +1120,15 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
if(context.account && context.opportunity){
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -1120,15 +1144,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
if(context.account && context.opportunity){
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -1159,6 +1174,14 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
return res;
}
let masterData:any = {};
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
......@@ -1174,14 +1197,6 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
let masterData:any = {};
let quotesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotes'),'undefined')){
quotesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotes') as any);
......@@ -1212,26 +1227,11 @@ export default class OpportunityServiceBase extends EntityService {
}
}
masterData.opportunitycompetitors = opportunitycompetitorsData;
let opportunityproductsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts'),'undefined')){
opportunityproductsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_opportunityproducts') as any);
if(opportunityproductsData && opportunityproductsData.length && opportunityproductsData.length > 0){
opportunityproductsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.opportunityproductid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.opportunityproducts = opportunityproductsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/opportunities/${context.opportunity}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
this.tempStorage.setItem(context.srfsessionkey+'_quotes',JSON.stringify(res.data.quotes));
this.tempStorage.setItem(context.srfsessionkey+'_opportunitycompetitors',JSON.stringify(res.data.opportunitycompetitors));
this.tempStorage.setItem(context.srfsessionkey+'_opportunityproducts',JSON.stringify(res.data.opportunityproducts));
return res;
}
......
......@@ -65,36 +65,36 @@ export default class ProductServiceBase extends EntityService {
*/
public async Create(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let productsubstitutesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes'),'undefined')){
productsubstitutesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes') as any);
if(productsubstitutesData && productsubstitutesData.length && productsubstitutesData.length > 0){
productsubstitutesData.forEach((item:any) => {
let productpricelevelsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels'),'undefined')){
productpricelevelsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels') as any);
if(productpricelevelsData && productpricelevelsData.length && productpricelevelsData.length > 0){
productpricelevelsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.productsubstituteid = null;
item.productpricelevelid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.productsubstitutes = productsubstitutesData;
let productpricelevelsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels'),'undefined')){
productpricelevelsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels') as any);
if(productpricelevelsData && productpricelevelsData.length && productpricelevelsData.length > 0){
productpricelevelsData.forEach((item:any) => {
masterData.productpricelevels = productpricelevelsData;
let productsubstitutesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes'),'undefined')){
productsubstitutesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes') as any);
if(productsubstitutesData && productsubstitutesData.length && productsubstitutesData.length > 0){
productsubstitutesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.productpricelevelid = null;
item.productsubstituteid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.productpricelevels = productpricelevelsData;
masterData.productsubstitutes = productsubstitutesData;
let productassociationsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productassociations'),'undefined')){
productassociationsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productassociations') as any);
......@@ -119,8 +119,8 @@ export default class ProductServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/products`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_productsubstitutes',JSON.stringify(res.data.productsubstitutes));
this.tempStorage.setItem(tempContext.srfsessionkey+'_productpricelevels',JSON.stringify(res.data.productpricelevels));
this.tempStorage.setItem(tempContext.srfsessionkey+'_productsubstitutes',JSON.stringify(res.data.productsubstitutes));
this.tempStorage.setItem(tempContext.srfsessionkey+'_productassociations',JSON.stringify(res.data.productassociations));
return res;
}
......@@ -136,36 +136,36 @@ export default class ProductServiceBase extends EntityService {
*/
public async Update(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let productsubstitutesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes'),'undefined')){
productsubstitutesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes') as any);
if(productsubstitutesData && productsubstitutesData.length && productsubstitutesData.length > 0){
productsubstitutesData.forEach((item:any) => {
let productpricelevelsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels'),'undefined')){
productpricelevelsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels') as any);
if(productpricelevelsData && productpricelevelsData.length && productpricelevelsData.length > 0){
productpricelevelsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.productsubstituteid = null;
item.productpricelevelid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.productsubstitutes = productsubstitutesData;
let productpricelevelsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels'),'undefined')){
productpricelevelsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels') as any);
if(productpricelevelsData && productpricelevelsData.length && productpricelevelsData.length > 0){
productpricelevelsData.forEach((item:any) => {
masterData.productpricelevels = productpricelevelsData;
let productsubstitutesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes'),'undefined')){
productsubstitutesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes') as any);
if(productsubstitutesData && productsubstitutesData.length && productsubstitutesData.length > 0){
productsubstitutesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.productpricelevelid = null;
item.productsubstituteid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.productpricelevels = productpricelevelsData;
masterData.productsubstitutes = productsubstitutesData;
let productassociationsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productassociations'),'undefined')){
productassociationsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productassociations') as any);
......@@ -183,8 +183,8 @@ export default class ProductServiceBase extends EntityService {
masterData.productassociations = productassociationsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/products/${context.product}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_productsubstitutes',JSON.stringify(res.data.productsubstitutes));
this.tempStorage.setItem(context.srfsessionkey+'_productpricelevels',JSON.stringify(res.data.productpricelevels));
this.tempStorage.setItem(context.srfsessionkey+'_productsubstitutes',JSON.stringify(res.data.productsubstitutes));
this.tempStorage.setItem(context.srfsessionkey+'_productassociations',JSON.stringify(res.data.productassociations));
return res;
}
......@@ -213,8 +213,8 @@ export default class ProductServiceBase extends EntityService {
*/
public async Get(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/products/${context.product}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_productsubstitutes',JSON.stringify(res.data.productsubstitutes));
this.tempStorage.setItem(context.srfsessionkey+'_productpricelevels',JSON.stringify(res.data.productpricelevels));
this.tempStorage.setItem(context.srfsessionkey+'_productsubstitutes',JSON.stringify(res.data.productsubstitutes));
this.tempStorage.setItem(context.srfsessionkey+'_productassociations',JSON.stringify(res.data.productassociations));
return res;
}
......@@ -231,8 +231,8 @@ export default class ProductServiceBase extends EntityService {
public async GetDraft(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/products/getdraft`,isloading);
res.data.product = data.product;
this.tempStorage.setItem(context.srfsessionkey+'_productsubstitutes',JSON.stringify(res.data.productsubstitutes));
this.tempStorage.setItem(context.srfsessionkey+'_productpricelevels',JSON.stringify(res.data.productpricelevels));
this.tempStorage.setItem(context.srfsessionkey+'_productsubstitutes',JSON.stringify(res.data.productsubstitutes));
this.tempStorage.setItem(context.srfsessionkey+'_productassociations',JSON.stringify(res.data.productassociations));
return res;
}
......@@ -291,36 +291,36 @@ export default class ProductServiceBase extends EntityService {
*/
public async Save(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let productsubstitutesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes'),'undefined')){
productsubstitutesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes') as any);
if(productsubstitutesData && productsubstitutesData.length && productsubstitutesData.length > 0){
productsubstitutesData.forEach((item:any) => {
let productpricelevelsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels'),'undefined')){
productpricelevelsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels') as any);
if(productpricelevelsData && productpricelevelsData.length && productpricelevelsData.length > 0){
productpricelevelsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.productsubstituteid = null;
item.productpricelevelid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.productsubstitutes = productsubstitutesData;
let productpricelevelsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels'),'undefined')){
productpricelevelsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productpricelevels') as any);
if(productpricelevelsData && productpricelevelsData.length && productpricelevelsData.length > 0){
productpricelevelsData.forEach((item:any) => {
masterData.productpricelevels = productpricelevelsData;
let productsubstitutesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes'),'undefined')){
productsubstitutesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productsubstitutes') as any);
if(productsubstitutesData && productsubstitutesData.length && productsubstitutesData.length > 0){
productsubstitutesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.productpricelevelid = null;
item.productsubstituteid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.productpricelevels = productpricelevelsData;
masterData.productsubstitutes = productsubstitutesData;
let productassociationsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_productassociations'),'undefined')){
productassociationsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_productassociations') as any);
......@@ -338,8 +338,8 @@ export default class ProductServiceBase extends EntityService {
masterData.productassociations = productassociationsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/products/${context.product}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_productsubstitutes',JSON.stringify(res.data.productsubstitutes));
this.tempStorage.setItem(context.srfsessionkey+'_productpricelevels',JSON.stringify(res.data.productpricelevels));
this.tempStorage.setItem(context.srfsessionkey+'_productsubstitutes',JSON.stringify(res.data.productsubstitutes));
this.tempStorage.setItem(context.srfsessionkey+'_productassociations',JSON.stringify(res.data.productassociations));
return res;
}
......
......@@ -78,21 +78,6 @@ export default class QuoteServiceBase extends EntityService {
public async Create(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity && true){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
if(salesordersData && salesordersData.length && salesordersData.length > 0){
salesordersData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.salesorderid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.salesorders = salesordersData;
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -108,21 +93,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.contact && context.opportunity && true){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -138,6 +108,21 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.contact && context.opportunity && true){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -153,21 +138,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.account && context.opportunity && true){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -183,6 +153,21 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.account && context.opportunity && true){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -198,21 +183,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.opportunity && true){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -228,6 +198,21 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.opportunity && true){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -243,20 +228,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/opportunities/${context.opportunity}/quotes`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -272,6 +243,20 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
}
if(data.srffrontuf){
delete data.srffrontuf;
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/opportunities/${context.opportunity}/quotes`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -287,6 +272,21 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
if(salesordersData && salesordersData.length && salesordersData.length > 0){
salesordersData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.salesorderid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -296,8 +296,8 @@ export default class QuoteServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/quotes`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(tempContext.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
......@@ -313,21 +313,6 @@ export default class QuoteServiceBase extends EntityService {
public async Update(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
if(salesordersData && salesordersData.length && salesordersData.length > 0){
salesordersData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.salesorderid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.salesorders = salesordersData;
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -343,14 +328,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.contact && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -366,6 +343,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.contact && context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -381,14 +366,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.account && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -404,6 +381,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.account && context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -419,14 +404,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes/${context.quote}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -442,6 +419,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes/${context.quote}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -457,13 +442,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/opportunities/${context.opportunity}/quotes/${context.quote}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -479,6 +457,13 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/opportunities/${context.opportunity}/quotes/${context.quote}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -494,10 +479,25 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
if(salesordersData && salesordersData.length && salesordersData.length > 0){
salesordersData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.salesorderid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/quotes/${context.quote}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
......@@ -538,31 +538,31 @@ export default class QuoteServiceBase extends EntityService {
public async Get(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity && context.quote){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.contact && context.opportunity && context.quote){
let res:any = await Http.getInstance().get(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.account && context.opportunity && context.quote){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes/${context.quote}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.opportunity && context.quote){
let res:any = await Http.getInstance().get(`/opportunities/${context.opportunity}/quotes/${context.quote}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
let res:any = await Http.getInstance().get(`/quotes/${context.quote}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
......@@ -579,35 +579,35 @@ export default class QuoteServiceBase extends EntityService {
if(context.account && context.contact && context.opportunity && true){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/getdraft`,isloading);
res.data.quote = data.quote;
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.contact && context.opportunity && true){
let res:any = await Http.getInstance().get(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/getdraft`,isloading);
res.data.quote = data.quote;
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.account && context.opportunity && true){
let res:any = await Http.getInstance().get(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes/getdraft`,isloading);
res.data.quote = data.quote;
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.opportunity && true){
let res:any = await Http.getInstance().get(`/opportunities/${context.opportunity}/quotes/getdraft`,isloading);
res.data.quote = data.quote;
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
let res:any = await Http.getInstance().get(`/quotes/getdraft`,isloading);
res.data.quote = data.quote;
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
......@@ -638,21 +638,6 @@ export default class QuoteServiceBase extends EntityService {
public async CheckKey(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
if(salesordersData && salesordersData.length && salesordersData.length > 0){
salesordersData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.salesorderid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.salesorders = salesordersData;
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -668,14 +653,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.contact && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -691,6 +668,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.contact && context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -706,14 +691,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.account && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -729,6 +706,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.account && context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -744,14 +729,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes/${context.quote}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -767,6 +744,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes/${context.quote}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -782,10 +767,25 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
if(salesordersData && salesordersData.length && salesordersData.length > 0){
salesordersData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.salesorderid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/opportunities/${context.opportunity}/quotes/${context.quote}/checkkey`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
return Http.getInstance().post(`/quotes/${context.quote}/checkkey`,data,isloading);
......@@ -818,21 +818,6 @@ export default class QuoteServiceBase extends EntityService {
public async GenSalesOrder(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
if(salesordersData && salesordersData.length && salesordersData.length > 0){
salesordersData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.salesorderid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.salesorders = salesordersData;
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -848,14 +833,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/gensalesorder`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.contact && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -871,6 +848,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/gensalesorder`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.contact && context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -886,14 +871,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/gensalesorder`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.account && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -909,6 +886,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/gensalesorder`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.account && context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -924,14 +909,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes/${context.quote}/gensalesorder`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -947,6 +924,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes/${context.quote}/gensalesorder`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -962,10 +947,25 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
if(salesordersData && salesordersData.length && salesordersData.length > 0){
salesordersData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.salesorderid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/opportunities/${context.opportunity}/quotes/${context.quote}/gensalesorder`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
return Http.getInstance().post(`/quotes/${context.quote}/gensalesorder`,data,isloading);
......@@ -983,21 +983,6 @@ export default class QuoteServiceBase extends EntityService {
public async Save(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
if(context.account && context.contact && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
if(salesordersData && salesordersData.length && salesordersData.length > 0){
salesordersData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.salesorderid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.salesorders = salesordersData;
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -1013,14 +998,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.contact && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -1036,6 +1013,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.contact && context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -1051,14 +1036,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.account && context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -1074,6 +1051,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/contacts/${context.contact}/opportunities/${context.opportunity}/quotes/${context.quote}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.account && context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -1089,14 +1074,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes/${context.quote}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
if(context.opportunity && context.quote){
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -1112,6 +1089,14 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/opportunities/${context.opportunity}/quotes/${context.quote}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
if(context.opportunity && context.quote){
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -1127,13 +1112,6 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/opportunities/${context.opportunity}/quotes/${context.quote}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
return res;
}
let masterData:any = {};
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
......@@ -1149,6 +1127,13 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/opportunities/${context.opportunity}/quotes/${context.quote}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
let masterData:any = {};
let quotedetailsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails'),'undefined')){
quotedetailsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_quotedetails') as any);
......@@ -1164,10 +1149,25 @@ export default class QuoteServiceBase extends EntityService {
}
}
masterData.quotedetails = quotedetailsData;
let salesordersData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesorders'),'undefined')){
salesordersData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesorders') as any);
if(salesordersData && salesordersData.length && salesordersData.length > 0){
salesordersData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.salesorderid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.salesorders = salesordersData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/quotes/${context.quote}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
this.tempStorage.setItem(context.srfsessionkey+'_quotedetails',JSON.stringify(res.data.quotedetails));
this.tempStorage.setItem(context.srfsessionkey+'_salesorders',JSON.stringify(res.data.salesorders));
return res;
}
......
......@@ -62,6 +62,21 @@ export default class SalesLiteratureServiceBase extends EntityService {
*/
public async Create(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let competitorsalesliteraturesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures'),'undefined')){
competitorsalesliteraturesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures') as any);
if(competitorsalesliteraturesData && competitorsalesliteraturesData.length && competitorsalesliteraturesData.length > 0){
competitorsalesliteraturesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.competitorsalesliteratures = competitorsalesliteraturesData;
let salesliteratureitemsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesliteratureitems'),'undefined')){
salesliteratureitemsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesliteratureitems') as any);
......@@ -92,21 +107,6 @@ export default class SalesLiteratureServiceBase extends EntityService {
}
}
masterData.productsalesliteratures = productsalesliteraturesData;
let competitorsalesliteraturesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures'),'undefined')){
competitorsalesliteraturesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures') as any);
if(competitorsalesliteraturesData && competitorsalesliteraturesData.length && competitorsalesliteraturesData.length > 0){
competitorsalesliteraturesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.competitorsalesliteratures = competitorsalesliteraturesData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -116,9 +116,9 @@ export default class SalesLiteratureServiceBase extends EntityService {
}
let tempContext:any = JSON.parse(JSON.stringify(context));
let res:any = await Http.getInstance().post(`/salesliteratures`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_competitorsalesliteratures',JSON.stringify(res.data.competitorsalesliteratures));
this.tempStorage.setItem(tempContext.srfsessionkey+'_salesliteratureitems',JSON.stringify(res.data.salesliteratureitems));
this.tempStorage.setItem(tempContext.srfsessionkey+'_productsalesliteratures',JSON.stringify(res.data.productsalesliteratures));
this.tempStorage.setItem(tempContext.srfsessionkey+'_competitorsalesliteratures',JSON.stringify(res.data.competitorsalesliteratures));
return res;
}
......@@ -133,6 +133,21 @@ export default class SalesLiteratureServiceBase extends EntityService {
*/
public async Update(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let competitorsalesliteraturesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures'),'undefined')){
competitorsalesliteraturesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures') as any);
if(competitorsalesliteraturesData && competitorsalesliteraturesData.length && competitorsalesliteraturesData.length > 0){
competitorsalesliteraturesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.competitorsalesliteratures = competitorsalesliteraturesData;
let salesliteratureitemsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesliteratureitems'),'undefined')){
salesliteratureitemsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesliteratureitems') as any);
......@@ -163,26 +178,11 @@ export default class SalesLiteratureServiceBase extends EntityService {
}
}
masterData.productsalesliteratures = productsalesliteraturesData;
let competitorsalesliteraturesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures'),'undefined')){
competitorsalesliteraturesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures') as any);
if(competitorsalesliteraturesData && competitorsalesliteraturesData.length && competitorsalesliteraturesData.length > 0){
competitorsalesliteraturesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.competitorsalesliteratures = competitorsalesliteraturesData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/salesliteratures/${context.salesliterature}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_competitorsalesliteratures',JSON.stringify(res.data.competitorsalesliteratures));
this.tempStorage.setItem(context.srfsessionkey+'_salesliteratureitems',JSON.stringify(res.data.salesliteratureitems));
this.tempStorage.setItem(context.srfsessionkey+'_productsalesliteratures',JSON.stringify(res.data.productsalesliteratures));
this.tempStorage.setItem(context.srfsessionkey+'_competitorsalesliteratures',JSON.stringify(res.data.competitorsalesliteratures));
return res;
}
......@@ -210,9 +210,9 @@ export default class SalesLiteratureServiceBase extends EntityService {
*/
public async Get(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/salesliteratures/${context.salesliterature}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_competitorsalesliteratures',JSON.stringify(res.data.competitorsalesliteratures));
this.tempStorage.setItem(context.srfsessionkey+'_salesliteratureitems',JSON.stringify(res.data.salesliteratureitems));
this.tempStorage.setItem(context.srfsessionkey+'_productsalesliteratures',JSON.stringify(res.data.productsalesliteratures));
this.tempStorage.setItem(context.srfsessionkey+'_competitorsalesliteratures',JSON.stringify(res.data.competitorsalesliteratures));
return res;
}
......@@ -228,9 +228,9 @@ export default class SalesLiteratureServiceBase extends EntityService {
public async GetDraft(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let res:any = await Http.getInstance().get(`/salesliteratures/getdraft`,isloading);
res.data.salesliterature = data.salesliterature;
this.tempStorage.setItem(context.srfsessionkey+'_competitorsalesliteratures',JSON.stringify(res.data.competitorsalesliteratures));
this.tempStorage.setItem(context.srfsessionkey+'_salesliteratureitems',JSON.stringify(res.data.salesliteratureitems));
this.tempStorage.setItem(context.srfsessionkey+'_productsalesliteratures',JSON.stringify(res.data.productsalesliteratures));
this.tempStorage.setItem(context.srfsessionkey+'_competitorsalesliteratures',JSON.stringify(res.data.competitorsalesliteratures));
return res;
}
......@@ -258,6 +258,21 @@ export default class SalesLiteratureServiceBase extends EntityService {
*/
public async Save(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let masterData:any = {};
let competitorsalesliteraturesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures'),'undefined')){
competitorsalesliteraturesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures') as any);
if(competitorsalesliteraturesData && competitorsalesliteraturesData.length && competitorsalesliteraturesData.length > 0){
competitorsalesliteraturesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.competitorsalesliteratures = competitorsalesliteraturesData;
let salesliteratureitemsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_salesliteratureitems'),'undefined')){
salesliteratureitemsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_salesliteratureitems') as any);
......@@ -288,26 +303,11 @@ export default class SalesLiteratureServiceBase extends EntityService {
}
}
masterData.productsalesliteratures = productsalesliteraturesData;
let competitorsalesliteraturesData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures'),'undefined')){
competitorsalesliteraturesData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_competitorsalesliteratures') as any);
if(competitorsalesliteraturesData && competitorsalesliteraturesData.length && competitorsalesliteraturesData.length > 0){
competitorsalesliteraturesData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.relationshipsid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.competitorsalesliteratures = competitorsalesliteraturesData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/salesliteratures/${context.salesliterature}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_competitorsalesliteratures',JSON.stringify(res.data.competitorsalesliteratures));
this.tempStorage.setItem(context.srfsessionkey+'_salesliteratureitems',JSON.stringify(res.data.salesliteratureitems));
this.tempStorage.setItem(context.srfsessionkey+'_productsalesliteratures',JSON.stringify(res.data.productsalesliteratures));
this.tempStorage.setItem(context.srfsessionkey+'_competitorsalesliteratures',JSON.stringify(res.data.competitorsalesliteratures));
return res;
}
......
......@@ -34,7 +34,7 @@
<app-form-item name='parentaccountname' :itemRules="this.rules.parentaccountname" class='' :caption="$t('entities.account.edit_accountinfo_form.details.parentaccountname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentaccountname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -69,7 +69,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='defaultpricelevelname' :itemRules="this.rules.defaultpricelevelname" class='' :caption="$t('entities.account.edit_accountinfo_form.details.defaultpricelevelname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.defaultpricelevelname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -34,7 +34,7 @@
<app-form-item name='parentaccountname' :itemRules="this.rules.parentaccountname" class='' :caption="$t('entities.account.main_form.details.parentaccountname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentaccountname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -69,7 +69,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='defaultpricelevelname' :itemRules="this.rules.defaultpricelevelname" class='' :caption="$t('entities.account.main_form.details.defaultpricelevelname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.defaultpricelevelname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -34,7 +34,7 @@
<app-form-item name='parentaccountname' :itemRules="this.rules.parentaccountname" class='' :caption="$t('entities.account.quickcreate_form.details.parentaccountname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentaccountname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -69,7 +69,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='defaultpricelevelname' :itemRules="this.rules.defaultpricelevelname" class='' :caption="$t('entities.account.quickcreate_form.details.defaultpricelevelname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.defaultpricelevelname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -22,7 +22,7 @@
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.campaign.quickcreate_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='entity2name' :itemRules="this.rules.entity2name" class='' :caption="$t('entities.competitorproduct.edit_comppro_form.details.entity2name')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.entity2name.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='entityname' :itemRules="this.rules.entityname" class='' :caption="$t('entities.competitorsalesliterature.sallitcomp_form.details.entityname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.entityname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -22,7 +22,7 @@
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.competitor.quickcreate_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -32,7 +32,7 @@
<app-form-item name='record1rolename' :itemRules="this.rules.record1rolename" class='' :caption="$t('entities.connection.main_form.details.record1rolename')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.record1rolename.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -41,7 +41,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='record2rolename' :itemRules="this.rules.record2rolename" class='' :caption="$t('entities.connection.main_form.details.record2rolename')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.record2rolename.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.contact.bookedit_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -22,7 +22,7 @@
<app-form-item name='customername' :itemRules="this.rules.customername" class='' :caption="$t('entities.contact.edit_abstract_form.details.customername')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.customername.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -176,7 +176,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='originatingleadname' :itemRules="this.rules.originatingleadname" class='' :caption="$t('entities.contact.edit_abstract_form.details.originatingleadname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.originatingleadname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -240,7 +240,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.contact.edit_abstract_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='originatingleadname' :itemRules="this.rules.originatingleadname" class='' :caption="$t('entities.contact.marketedit_form.details.originatingleadname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.originatingleadname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -22,7 +22,7 @@
<app-form-item name='customername' :itemRules="this.rules.customername" class='' :caption="$t('entities.contact.quickcreate_form.details.customername')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.customername.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -16,7 +16,7 @@
<app-form-item name='parentgoalname' :itemRules="this.rules.parentgoalname" class='' :caption="$t('entities.goal.edit_childgoal_form.details.parentgoalname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentgoalname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -25,7 +25,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='metricname' :itemRules="this.rules.metricname" class='' :caption="$t('entities.goal.edit_childgoal_form.details.metricname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.metricname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -16,7 +16,7 @@
<app-form-item name='parentgoalname' :itemRules="this.rules.parentgoalname" class='' :caption="$t('entities.goal.quickcreate_form.details.parentgoalname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentgoalname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -31,7 +31,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='metricname' :itemRules="this.rules.metricname" class='' :caption="$t('entities.goal.quickcreate_form.details.metricname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.metricname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -54,7 +54,7 @@
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.ibizlist.abstractedit_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -54,7 +54,7 @@
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.ibizlist.quickcreate_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -16,7 +16,7 @@
<app-form-item name='subjectname' :itemRules="this.rules.subjectname" class='' :caption="$t('entities.incident.byparentkey_form.details.subjectname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.subjectname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -45,7 +45,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='productname' :itemRules="this.rules.productname" class='' :caption="$t('entities.incident.byparentkey_form.details.productname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.productname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -54,7 +54,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='entitlementname' :itemRules="this.rules.entitlementname" class='' :caption="$t('entities.incident.byparentkey_form.details.entitlementname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.entitlementname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -69,7 +69,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='customername' :itemRules="this.rules.customername" class='' :caption="$t('entities.incident.byparentkey_form.details.customername')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.customername.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -22,7 +22,7 @@
<app-form-item name='subjectname' :itemRules="this.rules.subjectname" class='' :caption="$t('entities.incident.edit_childincident_form.details.subjectname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.subjectname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -51,7 +51,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='primarycontactname' :itemRules="this.rules.primarycontactname" class='' :caption="$t('entities.incident.edit_childincident_form.details.primarycontactname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.primarycontactname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -80,7 +80,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='productname' :itemRules="this.rules.productname" class='' :caption="$t('entities.incident.edit_childincident_form.details.productname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.productname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -89,7 +89,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='entitlementname' :itemRules="this.rules.entitlementname" class='' :caption="$t('entities.incident.edit_childincident_form.details.entitlementname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.entitlementname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -16,7 +16,7 @@
<app-form-item name='subjectname' :itemRules="this.rules.subjectname" class='' :caption="$t('entities.incident.quickcreate_form.details.subjectname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.subjectname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -25,7 +25,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='customername' :itemRules="this.rules.customername" class='' :caption="$t('entities.incident.quickcreate_form.details.customername')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.customername.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -54,7 +54,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='productname' :itemRules="this.rules.productname" class='' :caption="$t('entities.incident.quickcreate_form.details.productname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.productname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -63,7 +63,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='entitlementname' :itemRules="this.rules.entitlementname" class='' :caption="$t('entities.incident.quickcreate_form.details.entitlementname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.entitlementname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='productname' :itemRules="this.rules.productname" class='' :caption="$t('entities.invoicedetail.main_form.details.productname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.productname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -31,7 +31,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='uomname' :itemRules="this.rules.uomname" class='' :caption="$t('entities.invoicedetail.main_form.details.uomname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.uomname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -22,7 +22,7 @@
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.invoice.quickcreate_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -31,7 +31,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='pricelevelname' :itemRules="this.rules.pricelevelname" class='' :caption="$t('entities.invoice.quickcreate_form.details.pricelevelname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.pricelevelname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='incidentname' :itemRules="this.rules.incidentname" class='' :caption="$t('entities.knowledgearticleincident.main_form.details.incidentname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.incidentname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -85,7 +85,7 @@
<app-form-item name='subjectname' :itemRules="this.rules.subjectname" class='' :caption="$t('entities.knowledgearticle.info_knowledgearticle_form.details.subjectname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.subjectname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='entity2name' :itemRules="this.rules.entity2name" class='' :caption="$t('entities.leadcompetitor.edit_complead_form.details.entity2name')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.entity2name.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -138,7 +138,7 @@
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.lead.edit_main_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -156,7 +156,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='campaignname' :itemRules="this.rules.campaignname" class='' :caption="$t('entities.lead.edit_main_form.details.campaignname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.campaignname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='parentcontactname' :itemRules="this.rules.parentcontactname" class='' :caption="$t('entities.lead.qualification_form.details.parentcontactname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentcontactname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -19,7 +19,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='parentaccountname' :itemRules="this.rules.parentaccountname" class='' :caption="$t('entities.lead.qualification_form.details.parentaccountname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentaccountname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='entity2name' :itemRules="this.rules.entity2name" class='' :caption="$t('entities.listlead.quickcreatebylist_form.details.entity2name')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.entity2name.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='entityname' :itemRules="this.rules.entityname" class='' :caption="$t('entities.opportunitycompetitor.edit_compopp_form.details.entityname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.entityname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='entity2name' :itemRules="this.rules.entity2name" class='' :caption="$t('entities.opportunitycompetitor.main_form.details.entity2name')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.entity2name.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -16,7 +16,7 @@
<app-form-item name='parentcontactname' :itemRules="this.rules.parentcontactname" class='' :caption="$t('entities.opportunity.main_form.details.parentcontactname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentcontactname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -25,7 +25,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='parentaccountname' :itemRules="this.rules.parentaccountname" class='' :caption="$t('entities.opportunity.main_form.details.parentaccountname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentaccountname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -54,7 +54,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.opportunity.main_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -122,7 +122,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='pricelevelname' :itemRules="this.rules.pricelevelname" class='' :caption="$t('entities.opportunity.main_form.details.pricelevelname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.pricelevelname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -16,7 +16,7 @@
<app-form-item name='parentcontactname' :itemRules="this.rules.parentcontactname" class='' :caption="$t('entities.opportunity.quickcreate_form.details.parentcontactname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentcontactname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -25,7 +25,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='parentaccountname' :itemRules="this.rules.parentaccountname" class='' :caption="$t('entities.opportunity.quickcreate_form.details.parentaccountname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.parentaccountname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -54,7 +54,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.opportunity.quickcreate_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='associatedproductname' :itemRules="this.rules.associatedproductname" class='' :caption="$t('entities.productassociation.main_form.details.associatedproductname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.associatedproductname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -25,7 +25,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='uomname' :itemRules="this.rules.uomname" class='' :caption="$t('entities.productassociation.main_form.details.uomname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.uomname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='productname' :itemRules="this.rules.productname" class='' :caption="$t('entities.productpricelevel.proprilv_form.details.productname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.productname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -19,7 +19,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='pricelevelname' :itemRules="this.rules.pricelevelname" class='' :caption="$t('entities.productpricelevel.proprilv_form.details.pricelevelname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.pricelevelname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -28,7 +28,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='uomname' :itemRules="this.rules.uomname" class='' :caption="$t('entities.productpricelevel.proprilv_form.details.uomname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.uomname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -37,7 +37,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='currencyname' :itemRules="this.rules.currencyname" class='' :caption="$t('entities.productpricelevel.proprilv_form.details.currencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.currencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -46,7 +46,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='discounttypename' :itemRules="this.rules.discounttypename" class='' :caption="$t('entities.productpricelevel.proprilv_form.details.discounttypename')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.discounttypename.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='entityname' :itemRules="this.rules.entityname" class='' :caption="$t('entities.productsalesliterature.sallitpro_form.details.entityname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.entityname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='substitutedproductname' :itemRules="this.rules.substitutedproductname" class='' :caption="$t('entities.productsubstitute.main_form.details.substitutedproductname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.substitutedproductname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -22,7 +22,7 @@
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.quote.quickcreate_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -31,7 +31,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='opportunityname' :itemRules="this.rules.opportunityname" class='' :caption="$t('entities.quote.quickcreate_form.details.opportunityname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.opportunityname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -46,7 +46,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='pricelevelname' :itemRules="this.rules.pricelevelname" class='' :caption="$t('entities.quote.quickcreate_form.details.pricelevelname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.pricelevelname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -16,7 +16,7 @@
<app-form-item name='subjectname' :itemRules="this.rules.subjectname" class='' :caption="$t('entities.salesliterature.quickcreate_form.details.subjectname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.subjectname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -10,7 +10,7 @@
<app-form-item name='productname' :itemRules="this.rules.productname" class='' :caption="$t('entities.salesorderdetail.soproductedit_form.details.productname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.productname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -31,7 +31,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='uomname' :itemRules="this.rules.uomname" class='' :caption="$t('entities.salesorderdetail.soproductedit_form.details.uomname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.uomname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -22,7 +22,7 @@
<app-form-item name='transactioncurrencyname' :itemRules="this.rules.transactioncurrencyname" class='' :caption="$t('entities.salesorder.quickcreate_form.details.transactioncurrencyname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.transactioncurrencyname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......@@ -31,7 +31,7 @@ FTL stack trace ("~" means nesting-related):
<app-form-item name='pricelevelname' :itemRules="this.rules.pricelevelname" class='' :caption="$t('entities.salesorder.quickcreate_form.details.pricelevelname')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.pricelevelname.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
......@@ -22,7 +22,7 @@
<app-form-item name='ownername' :itemRules="this.rules.ownername" class='' :caption="$t('entities.task.quickcreate_form.details.ownername')" uiStyle="DEFAULT" :labelWidth="130" :isShowCaption="true" :error="detailsModel.ownername.error" :isEmptyCaption="false" labelPos="LEFT">
!!!!模版产生代码错误:----
FTL stack trace ("~" means nesting-related):
- Failed at: ${editor.getEditorParams()} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
- Failed at: ${editor.getEditorParams()?c} [in template "TEMPLCODE_zh_CN" at line 175, column 18]
----
</app-form-item>
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册