Compare commits
10 Commits
b0685ad4db
...
a13f5361f7
| Author | SHA1 | Date | |
|---|---|---|---|
| a13f5361f7 | |||
| fad57ce963 | |||
| 38e4f2c4c9 | |||
| 433a6f33dc | |||
| 1e83c3cea9 | |||
|
|
7969f25593 | ||
|
|
bff7cf8473 | ||
|
|
2ceb46fe5f | ||
|
|
adf7de69a9 | ||
|
|
01f0e3bc5a |
32
.github/workflows/push-dappbundle.yml
vendored
Normal file
32
.github/workflows/push-dappbundle.yml
vendored
Normal file
@ -0,0 +1,32 @@
|
||||
name: Workflow push to Dappbundle
|
||||
on: [push]
|
||||
jobs:
|
||||
build:
|
||||
name: Build
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Executing remote command
|
||||
uses: appleboy/ssh-action@v1.0.0
|
||||
with:
|
||||
host: ${{ secrets.R_HOST }}
|
||||
username: ${{ secrets.P_USERNAME }}
|
||||
password: ${{ secrets.P_PASSWORD }}
|
||||
port: ${{ secrets.SSH_PORT }}
|
||||
script: |
|
||||
if [ -d "${{ secrets.DEPLOYMENT_LOCATION}}/dappbundle" ]; then
|
||||
echo "Folder exists. Skipping Git clone."
|
||||
else
|
||||
echo "Folder does not exist. Cloning repository..."
|
||||
cd ${{ secrets.DEPLOYMENT_LOCATION}}/ && git clone https://github.com/ranchimall/dappbundle.git
|
||||
fi
|
||||
|
||||
if [ -d "${{ secrets.DEPLOYMENT_LOCATION}}/dappbundle/${{ github.event.repository.name }}" ]; then
|
||||
echo "Repository exists. Remove folder "
|
||||
rm -r "${{ secrets.DEPLOYMENT_LOCATION}}/dappbundle/${{ github.event.repository.name }}"
|
||||
fi
|
||||
|
||||
echo "Cloning repository..."
|
||||
cd ${{ secrets.DEPLOYMENT_LOCATION}}/dappbundle && git clone https://github.com/ranchimall/${{ github.event.repository.name }}
|
||||
|
||||
cd "${{ secrets.DEPLOYMENT_LOCATION}}/dappbundle/${{ github.event.repository.name }}" && rm -rf .gitattributes .git .github .gitignore
|
||||
cd ${{ secrets.DEPLOYMENT_LOCATION}}/dappbundle/ && git add . && git commit -m "Workflow updating files of ${{ github.event.repository.name }}" && git push "https://ranchimalldev:${{ secrets.RM_ACCESS_TOKEN }}@github.com/ranchimall/dappbundle.git"
|
||||
18
index.html
18
index.html
@ -20,8 +20,8 @@
|
||||
blockchain: "FLO",
|
||||
adminID: "FKAEdnPfjXLHSYwrXQu377ugN4tXU7VGdf",
|
||||
application: "TEST_MODE",
|
||||
RMincorporationID: "FKNW5eCCp2SnJMJ6pLLpUCvk5hAage8Jtk",
|
||||
RIBC_id: "FDaX363r1ooANA9A2erhehhigNTnidq3o4",
|
||||
rmIncorporationId: "FKNW5eCCp2SnJMJ6pLLpUCvk5hAage8Jtk",
|
||||
ribcId: "FDaX363r1ooANA9A2erhehhigNTnidq3o4",
|
||||
RM_CertificateIssuer_id: "FFCpiaZi31TpbYw5q5VNk8qJMeDiTLgsrE",
|
||||
}
|
||||
</script>
|
||||
@ -267,7 +267,7 @@
|
||||
}
|
||||
const render = {
|
||||
issuedCertCard(details) {
|
||||
const { floData, txid, name, floId, btcId, certType, time, verificationLink } = details
|
||||
const { data, txid, name, floId, btcId, certType, time, verificationLink } = details
|
||||
return html`
|
||||
<li class="cert-card">
|
||||
<div class="flex align-items-center space-between">
|
||||
@ -290,7 +290,7 @@
|
||||
`;
|
||||
},
|
||||
certificate(txid, downloadButton) {
|
||||
const { floData, time, name, floId, certType, isNewer, certPara, verificationLink } = floGlobals.validCerts.get(txid)
|
||||
const { data, time, name, floId, certType, isNewer, certPara, verificationLink } = floGlobals.validCerts.get(txid)
|
||||
let paraSplitWord
|
||||
let certificateVerification = ''
|
||||
switch (certType) {
|
||||
@ -307,7 +307,7 @@
|
||||
paraSplitWord = 'participated'
|
||||
break;
|
||||
}
|
||||
const remarks = isNewer ? certPara : removeWordsBefore(floData, paraSplitWord)
|
||||
const remarks = isNewer ? certPara : removeWordsBefore(data, paraSplitWord)
|
||||
const certPdf = new window.jspdf.jsPDF({
|
||||
orientation: 'l',
|
||||
unit: 'pt',
|
||||
@ -332,7 +332,7 @@
|
||||
certPdf.text(`Issued: ${getFormattedTime(time, 'date-only')}`, 700, 254, { align: 'center' }); // issued date
|
||||
certPdf.text("RanchiMall, a blockchain incorporated entity certifies that", 700, 310, { align: 'center' });
|
||||
certPdf.setFont('times', 'bold');
|
||||
certPdf.setFontSize(64);
|
||||
certPdf.setFontSize(56);
|
||||
certPdf.text(name.toUpperCase(), 700, 380, { align: 'center' }); // name
|
||||
certPdf.setFont('times', 'normal');
|
||||
certPdf.setFontSize(18);
|
||||
@ -346,9 +346,9 @@
|
||||
certPdf.setFontSize(14);
|
||||
certPdf.text("INTERNSHIP CONTRACT ADDRESS", 1240, 786, { align: 'right' });
|
||||
certPdf.setFontSize(18);
|
||||
certPdf.text("FDaX363r1ooANA9A2erhehhigNTnidq3o4", 1240, 810, { align: 'right' });
|
||||
certPdf.text(floGlobals.ribcId, 1240, 810, { align: 'right' });
|
||||
certPdf.text("Scan to verify this certificate", 700, 832, { align: 'center' });
|
||||
certPdf.text(`Transaction ID: ${txid}`, 700, 860, { align: 'center' });
|
||||
certPdf.textWithLink(`FLO Transaction ID: ${txid}`, 700, 860, { align: 'center', url: verificationLink });
|
||||
// jspdf add svg
|
||||
let svgNode = QRCode({
|
||||
msg: verificationLink,
|
||||
@ -381,7 +381,7 @@
|
||||
floBlockchainAPI.readData(floGlobals.RM_CertificateIssuer_id, {
|
||||
sentOnly: true,
|
||||
tx: true,
|
||||
receivers: [floGlobals.RMincorporationID, floGlobals.RIBC_id],
|
||||
receivers: [floGlobals.rmIncorporationId, floGlobals.ribcId],
|
||||
filter: d => d.startsWith('CERTIFICATE OF')
|
||||
}).then(res => {
|
||||
for (tx of res.items) {
|
||||
|
||||
File diff suppressed because one or more lines are too long
1
scripts/floBlockchainAPI.min.js
vendored
Normal file
1
scripts/floBlockchainAPI.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user