Selaa lähdekoodia

Refactoring code

master
Safet Purkovic 4 vuotta sitten
vanhempi
commit
8f737b5102

+ 2
- 1
src/views/demoComponent/DemoComponent1.js Näytä tiedosto

const DemoComponent1 = () => { const DemoComponent1 = () => {
const exec = () => { const exec = () => {
const pdf = new PDFEngine(); const pdf = new PDFEngine();
window.print();
pdf.execute();
// window.print();
} }
// const apiCall = () => { // const apiCall = () => {



+ 1
- 0
src/views/demoComponent/DemoComponent11.js Näytä tiedosto



const exec = () => { const exec = () => {
const pdf = new PDFEngine(); const pdf = new PDFEngine();
pdf.execute();
// window.print(); // window.print();
} }
return ( return (

+ 12
- 10
src/views/demoComponent/DemoComponent14.js Näytä tiedosto



pdf.execute(); pdf.execute();
window.print();
// window.print();
} }
// const apiCall = () => { // const apiCall = () => {
// } // }
return ( return (
<> <>
<div code="br-hide" style={{ display: 'flex', flexDirection: 'row', border: '1px solid #dedede', width: '50%', height: '200px', backgroundColor: 'white', padding: '5px', borderRadius: '10px' }}>
<div style={{ backgroundColor: 'white', minHeight: '100%', width: '50%', padding: '2px', margin: '5px' }}>
<div style={{ backgroundColor: 'white', width: '50%', padding: '2px', marginBottom: '20px' }}>
<h4 id="nesto">PDFEngine</h4>
<div code="br-hide">
<div style={{ display: 'flex', flexDirection: 'row', border: '1px solid #dedede', width: '50%', height: '200px', backgroundColor: 'white', padding: '5px', borderRadius: '10px' }}>
<div style={{ backgroundColor: 'white', minHeight: '100%', width: '50%', padding: '2px', margin: '5px' }}>
<div style={{ backgroundColor: 'white', width: '50%', padding: '2px', marginBottom: '20px' }}>
<h4>PDFEngine</h4>
</div>
<div style={{ display: 'flex', flexDirection: 'row', marginLeft: '10px' }}>
<button style={{ marginLeft: '5px' }} className=" btn btn-primary" onClick={exec}>Print view</button>
</div>
</div> </div>
<div style={{ display: 'flex', flexDirection: 'row', marginLeft: '10px' }}>
<button style={{ marginLeft: '5px' }} className=" btn btn-primary" onClick={exec}>Print view</button>
<div style={{ backgroundColor: 'white', minHeight: '100%', width: '50%', padding: '5px' }}>
</div> </div>
</div> </div>
<div style={{ backgroundColor: 'white', minHeight: '100%', width: '50%', padding: '5px' }}>
</div>
</div> </div>
<br /> <br />
1
<br /> <br />
<br /> <br />
<WidgetsDropdown /> <WidgetsDropdown />

+ 0
- 1
src/views/demoComponent/DemoComponent2.js Näytä tiedosto



const DemoComponent2 = () => { const DemoComponent2 = () => {
const exec = () => { const exec = () => {
console.log(PDFEngine());
const url = encodeURIComponent("http://localhost:3000/#/DemoComponent2"); const url = encodeURIComponent("http://localhost:3000/#/DemoComponent2");
const dateNow = new Date(); const dateNow = new Date();
fetch('https://localhost:7285/api/PDFGenerator/' + url) fetch('https://localhost:7285/api/PDFGenerator/' + url)

+ 1
- 0
src/views/demoComponent/DemoComponent3.js Näytä tiedosto

const exec = () => const exec = () =>
{ {
const pdf = new PDFEngine(); const pdf = new PDFEngine();
pdf.execute();
// window.print(); // window.print();
} }
return ( return (

+ 1
- 0
src/views/demoComponent/DemoComponent4.js Näytä tiedosto

const exec = () => const exec = () =>
{ {
const pdf = new PDFEngine(); const pdf = new PDFEngine();
pdf.execute();
// window.print(); // window.print();
} }
return ( return (

+ 1
- 0
src/views/demoComponent/DemoComponent5.js Näytä tiedosto



const exec = () => { const exec = () => {
const pdf = new PDFEngine(); const pdf = new PDFEngine();
pdf.execute();
// window.print(); // window.print();
} }
return ( return (

+ 1
- 0
src/views/demoComponent/DemoComponent6.js Näytä tiedosto

const exec = () => const exec = () =>
{ {
const pdf = new PDFEngine(); const pdf = new PDFEngine();
pdf.execute();
// window.print(); // window.print();
} }
return ( return (

+ 1
- 0
src/views/demoComponent/DemoComponent8.js Näytä tiedosto

const exec = () => const exec = () =>
{ {
const pdf = new PDFEngine(); const pdf = new PDFEngine();
pdf.execute();
// window.print(); // window.print();
} }
return ( return (

Loading…
Peruuta
Tallenna