11 lines
1.6 KiB
Python
11 lines
1.6 KiB
Python
from pathlib import Path
|
|
p=Path('C:/Users/macbook/.config/investmoz/navegacao-consolidacao-QA-20261016/source')
|
|
def edit(f,a,b):
|
|
q=p/f;s=q.read_text('utf-8');assert a in s,(f,a);q.write_text(s.replace(a,b,1),'utf-8')
|
|
edit('resources/js/components/dossier-prefill.tsx',"String(source[k] ?? '')", "text(source[k])")
|
|
edit('resources/js/pages/portal/services.tsx',"<Link className={button} href={'/investimentos/iniciar?source=sector:'+p.sector.id}>Iniciar ou continuar uma ideia neste sector</Link>","{!p.sectorEntry&&<Link className={button} href={'/investimentos/iniciar?source=sector:'+p.sector.id}>Iniciar ou continuar uma ideia neste sector</Link>}")
|
|
edit('resources/js/pages/portal/services.tsx','<SectorEntry data={p.sectorEntry} />','<SectorEntry data={{...p.sectorEntry,start_href:p.sectorEntry.start_href?\'/investimentos/iniciar?source=sector:\'+p.sector.id:null}} />')
|
|
edit('resources/js/pages/investment/catalogue.tsx',' <CatalogueNavigation dimensionUrl={dimensionUrl} />', " <CatalogueNavigation dimensionUrl={dimensionUrl} />\n {!!territoryPath.length&&<Link className={button} href={'/investimentos/iniciar?source=territory:'+territoryPath[territoryPath.length-1].id}>Iniciar ou continuar ideia nesta localização</Link>}")
|
|
edit('resources/js/lib/investor-context.ts',"project_title: 'Título do investimento',", "title:'Título do investimento', territory_id:'Localização documentada', location_source:'Origem da localização', description:'Descrição', project_title: 'Título do investimento',")
|
|
print('Source entries and comparison labels finished')
|