Merge branch 'OpenSignLabs:staging' into spanish-translation

This commit is contained in:
1024mb
2024-10-01 21:31:40 -05:00
committed by GitHub
24 changed files with 173 additions and 131 deletions
+15 -15
View File
@@ -28,7 +28,7 @@
"print-js": "^1.6.0",
"radix-ui": "^1.0.1",
"react": "^18.2.0",
"react-bootstrap": "^2.10.4",
"react-bootstrap": "^2.10.5",
"react-confetti": "^6.1.0",
"react-cookie": "^7.2.0",
"react-datepicker": "^7.4.0",
@@ -70,7 +70,7 @@
"autoprefixer": "^10.4.20",
"babel-loader": "^9.2.1",
"clean-webpack-plugin": "^4.0.0",
"commitizen": "^4.3.0",
"commitizen": "^4.3.1",
"concurrently": "^9.0.1",
"css-loader": "^7.1.2",
"daisyui": "^4.12.10",
@@ -78,7 +78,7 @@
"dotenv-webpack": "^8.1.0",
"eslint": "^9.11.1",
"eslint-plugin-prettier": "^5.2.1",
"eslint-plugin-react": "^7.36.1",
"eslint-plugin-react": "^7.37.0",
"lint-staged": "^15.2.10",
"mini-css-extract-plugin": "^2.9.1",
"postcss": "^8.4.47",
@@ -8750,9 +8750,9 @@
}
},
"node_modules/commitizen": {
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/commitizen/-/commitizen-4.3.0.tgz",
"integrity": "sha512-H0iNtClNEhT0fotHvGV3E9tDejDeS04sN1veIebsKYGMuGscFaswRoYJKmT3eW85eIJAs0F28bG2+a/9wCOfPw==",
"version": "4.3.1",
"resolved": "https://registry.npmjs.org/commitizen/-/commitizen-4.3.1.tgz",
"integrity": "sha512-gwAPAVTy/j5YcOOebcCRIijn+mSjWJC+IYKivTu6aG8Ei/scoXgfsMRnuAk6b0GRste2J4NGxVdMN3ZpfNaVaw==",
"dev": true,
"dependencies": {
"cachedir": "2.3.0",
@@ -10856,9 +10856,9 @@
}
},
"node_modules/eslint-plugin-react": {
"version": "7.36.1",
"resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.36.1.tgz",
"integrity": "sha512-/qwbqNXZoq+VP30s1d4Nc1C5GTxjJQjk4Jzs4Wq2qzxFM7dSmuG2UkIjg2USMLh3A/aVcUNrK7v0J5U1XEGGwA==",
"version": "7.37.0",
"resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.37.0.tgz",
"integrity": "sha512-IHBePmfWH5lKhJnJ7WB1V+v/GolbB0rjS8XYVCSQCZKaQCAUhMoVoOEn1Ef8Z8Wf0a7l8KTJvuZg5/e4qrZ6nA==",
"dependencies": {
"array-includes": "^3.1.8",
"array.prototype.findlast": "^1.2.5",
@@ -20271,9 +20271,9 @@
"integrity": "sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg=="
},
"node_modules/react-bootstrap": {
"version": "2.10.4",
"resolved": "https://registry.npmjs.org/react-bootstrap/-/react-bootstrap-2.10.4.tgz",
"integrity": "sha512-W3398nBM2CBfmGP2evneEO3ZZwEMPtHs72q++eNw60uDGDAdiGn0f9yNys91eo7/y8CTF5Ke1C0QO8JFVPU40Q==",
"version": "2.10.5",
"resolved": "https://registry.npmjs.org/react-bootstrap/-/react-bootstrap-2.10.5.tgz",
"integrity": "sha512-XueAOEn64RRkZ0s6yzUTdpFtdUXs5L5491QU//8ZcODKJNDLt/r01tNyriZccjgRImH1REynUc9pqjiRMpDLWQ==",
"dependencies": {
"@babel/runtime": "^7.24.7",
"@restart/hooks": "^0.4.9",
@@ -22508,9 +22508,9 @@
}
},
"node_modules/rollup": {
"version": "2.79.1",
"resolved": "https://registry.npmjs.org/rollup/-/rollup-2.79.1.tgz",
"integrity": "sha512-uKxbd0IhMZOhjAiD5oAFp7BqvkA4Dv47qpOCtaNvng4HBwdbWtdOh8f5nZNuk2rp51PMGk3bzfWu5oayNEuYnw==",
"version": "2.79.2",
"resolved": "https://registry.npmjs.org/rollup/-/rollup-2.79.2.tgz",
"integrity": "sha512-fS6iqSPZDs3dr/y7Od6y5nha8dW1YnbgtsyotCVvoFGKbERG++CVRFv1meyGDE1SNItQA8BrnCw7ScdAhRJ3XQ==",
"bin": {
"rollup": "dist/bin/rollup"
},
+3 -3
View File
@@ -23,7 +23,7 @@
"print-js": "^1.6.0",
"radix-ui": "^1.0.1",
"react": "^18.2.0",
"react-bootstrap": "^2.10.4",
"react-bootstrap": "^2.10.5",
"react-confetti": "^6.1.0",
"react-cookie": "^7.2.0",
"react-datepicker": "^7.4.0",
@@ -102,7 +102,7 @@
"autoprefixer": "^10.4.20",
"babel-loader": "^9.2.1",
"clean-webpack-plugin": "^4.0.0",
"commitizen": "^4.3.0",
"commitizen": "^4.3.1",
"concurrently": "^9.0.1",
"css-loader": "^7.1.2",
"daisyui": "^4.12.10",
@@ -110,7 +110,7 @@
"dotenv-webpack": "^8.1.0",
"eslint": "^9.11.1",
"eslint-plugin-prettier": "^5.2.1",
"eslint-plugin-react": "^7.36.1",
"eslint-plugin-react": "^7.37.0",
"lint-staged": "^15.2.10",
"mini-css-extract-plugin": "^2.9.1",
"postcss": "^8.4.47",
@@ -265,10 +265,10 @@
"make-template-public-alert": "Are you sure you want to make this template public?",
"make-template-private-alert": "Are you sure you want to make this template private? This will remove it from your public profile.",
"public-role": "Public role",
"public-url": "Public URL",
"public-url": "Public profile needed",
"public-url-copy": "Heres your public URL: ",
"public-url-copy-mssg":"Copy it or share it with the signer, and you will be able to see all your publicly set templates.",
"add-public-url-alert": "Please add your public URL, and you will be able to make a public template.",
"add-public-url-alert": "Please complete your OpenSign public profile setup. Once done, youll be able to make templates public. This process only needs to be completed once.",
"share-with-alert": "You cannot share a template if any roles already have contacts assigned. Please remove all contact assignments from the roles before sharing the template.",
"share-with": "Share with",
"team-not-found": "Team not found",
@@ -672,6 +672,7 @@
"document-logs":"Document logs",
"server-down": "Unable to connect to the OpenSign server. If you are self-hosting OpenSign, please ensure that all the steps in the documentation have been followed correctly. If you're running OpenSign locally, you might be accessing it through an incorrect port number.",
"admin-exists": "Admin already exists. Please login to the application using admin credentials in order to manage users.",
"public-tour-message":"Please make template public to copy public URL"
"public-tour-message":"The template needs to be public before you can generate a shareable link.",
"add-user-template": "You need to add a role before you can add fields for it."
}
@@ -264,10 +264,10 @@
"make-template-public-alert": "Êtes-vous sûr de vouloir rendre ce modèle public ?",
"make-template-private-alert": "Êtes-vous sûr de vouloir rendre ce modèle privé ? Cela le supprimera de votre profil public.",
"public-role": "Rôle public",
"public-url": "URL publique",
"public-url": "Profil public requis",
"public-url-copy": "Voici votre URL publique : ",
"public-url-copy-mssg": "copiez-la ou partagez-le avec le signataire et vous pouvoir voir tous vos paramètres publics modèles.",
"add-public-url-alert": "Veuillez ajouter votre URL publique et vous pourra rendre public modèle.",
"add-public-url-alert": "Veuillez terminer la configuration de votre profil public OpenSign. Une fois cela fait, vous pourrez rendre les modèles publics. Ce processus ne doit être effectué quune seule fois.",
"share-with-alert": "Vous ne pouvez pas partager un modèle si des contacts sont déjà attribués à des rôles. Veuillez supprimer toutes les attributions de contacts des rôles avant de partager le modèle.",
"share-with": "Partager avec",
"team-not-found": "Équipe introuvable",
@@ -671,7 +671,8 @@
"document-logs":"Journaux de documents",
"server-down": "Impossible de se connecter au serveur OpenSign. Si vous hébergez vous-même OpenSign, veuillez vous assurer que toutes les étapes de la documentation ont été correctement suivies. Si vous exécutez OpenSign localement, vous y accédez peut-être via un numéro de port incorrect.",
"admin-exists": "L'administrateur existe déjà. Veuillez vous connecter à l'application en utilisant les informations d'identification de l'administrateur afin de gérer les utilisateurs.",
"public-tour-message":"Veuillez rendre le modèle public pour copier l'URL publique"
"public-tour-message": "Le modèle doit être public avant que vous puissiez générer un lien partageable.",
"add-user-template":"Vous devez ajouter un rôle avant de pouvoir lui ajouter des champs. "
}
@@ -418,11 +418,7 @@ function Header({
{templateId && (
<button
onClick={() =>
handleDownloadPdf(
pdfDetails,
pdfUrl,
setIsDownloading
)
handleDownloadPdf(pdfDetails, setIsDownloading)
}
type="button"
className="op-btn op-btn-ghost op-btn-sm mr-[3px]"
+83 -48
View File
@@ -24,9 +24,11 @@ const ManageSign = () => {
const [Initials, setInitials] = useState("");
const [isInitials, setIsInitials] = useState(false);
const [id, setId] = useState("");
const [imgInitials, setImgInitials] = useState("");
const canvasRef = useRef(null);
const imageRef = useRef(null);
const initailsRef = useRef(null);
const imgInitialsRef = useRef(null);
useEffect(() => {
fetchUserSign();
// eslint-disable-next-line
@@ -54,8 +56,9 @@ const ManageSign = () => {
}
setImage(res?.ImageURL);
if (res && res.Initials) {
setInitials(res.Initials);
// setInitials(res.Initials);
setIsInitials(true);
setImgInitials(res?.Initials);
}
} else {
if (User?.get("name")) {
@@ -95,6 +98,10 @@ const ManageSign = () => {
if (initailsRef.current) {
initailsRef.current.clear();
}
if (imgInitialsRef.current) {
imgInitialsRef.current.value = "";
}
setImgInitials("");
setInitials("");
if (image) {
setIsValue(true);
@@ -119,8 +126,7 @@ const ManageSign = () => {
};
const handleSubmit = async (e) => {
e.preventDefault();
const isUrl = image.includes("https") || image.includes("http");
const isUrl = image?.includes("https") || image?.includes("http");
if (!isvalue) {
setWarning(true);
setTimeout(() => setWarning(false), 1000);
@@ -142,15 +148,25 @@ const ManageSign = () => {
} else {
imgUrl = image;
}
let initialsUrl = "";
const isInitialsUrl =
Initials.includes("https") || Initials.includes("http");
if (!isInitialsUrl && Initials) {
const initialsImg = base64StringtoFile(
Initials,
`${replaceSpace}_initials.png`
);
initialsUrl = await uploadFile(initialsImg);
imgInitials?.includes("https") || imgInitials?.includes("http");
let initialFile;
if (Initials) {
initialFile = base64StringtoFile(Initials, `${replaceSpace}_sign.png`);
} else {
if (imgInitials && !isInitialsUrl) {
initialFile = base64StringtoFile(
imgInitials,
`${replaceSpace}__sign.png`
);
}
}
let initialsUrl;
if (initialFile && !isInitialsUrl) {
initialsUrl = await uploadFile(initialFile);
} else {
initialsUrl = imgInitials;
}
if (imgUrl) {
await saveEntry({
@@ -191,7 +207,7 @@ const ManageSign = () => {
const saveEntry = async (obj) => {
const signCls = "contracts_Signature";
const User = Parse.User.current().id;
const User = Parse?.User?.current()?.id;
const userId = { __type: "Pointer", className: "_User", objectId: User };
if (id) {
try {
@@ -202,20 +218,13 @@ const ManageSign = () => {
updateSign.set("SignatureName", obj.name);
updateSign.set("UserId", userId);
const res = await updateSign.save();
setIsLoader(false);
setIsAlert({
type: "success",
message: t("signature-saved-alert")
});
setTimeout(() => setIsAlert({}), 2000);
setIsAlert({ type: "success", message: t("signature-saved-alert") });
return res;
} catch (err) {
console.log(err);
setIsAlert({ type: "danger", message: `${err.message}` });
} finally {
setIsLoader(false);
setIsAlert({
type: "danger",
message: `${err.message}`
});
setTimeout(() => setIsAlert({}), 2000);
}
} else {
@@ -226,20 +235,13 @@ const ManageSign = () => {
updateSign.set("SignatureName", obj.name);
updateSign.set("UserId", userId);
const res = await updateSign.save();
setIsLoader(false);
setIsAlert({
type: "success",
message: t("signature-saved-alert")
});
setTimeout(() => setIsAlert({}), 2000);
setIsAlert({ type: "success", message: t("signature-saved-alert") });
return res;
} catch (err) {
console.log(err);
setIsAlert({ type: "success", message: `${err.message}` });
} finally {
setIsLoader(false);
setIsAlert({
type: "success",
message: `${err.message}`
});
setTimeout(() => setIsAlert({}), 2000);
}
}
@@ -250,7 +252,29 @@ const ManageSign = () => {
};
const handleInitialsChange = () => {
setInitials(initailsRef.current.toDataURL());
setIsValue(true);
if (image || signature) {
setIsValue(true);
}
};
const handleUploadInitials = () => {
imgInitialsRef.current.click();
};
const onImgInitialsChange = async (event) => {
if (initailsRef.current) {
initailsRef.current.clear();
}
setInitials("");
if (event.target.files && event.target.files[0]) {
const file = event.target.files[0];
const base64Img = await toDataUrl(file);
setImgInitials(base64Img);
if (image || signature) {
setIsValue(true);
}
} else {
setImgInitials("");
setIsValue(false);
}
};
return (
<div className="relative h-full bg-base-100 text-base-content flex shadow-md rounded-box overflow-auto">
@@ -348,7 +372,7 @@ const ManageSign = () => {
className="op-link"
onClick={() => handleUploadBtn()}
>
{t("upload-image")}
{t("upload")}
</div>
<div
type="button"
@@ -372,17 +396,21 @@ const ManageSign = () => {
<span className="font-medium select-none flex mb-[10px] pl-[10px]">
{t("initials")}
</span>
<input
type="file"
onChange={onImgInitialsChange}
className="filetype"
accept="image/*"
ref={imgInitialsRef}
hidden
/>
<div>
{isInitials ? (
{imgInitials ? (
<div className="intialSignature relative border-[1px] border-[#888] rounded-box overflow-hidden">
<img
alt="inititals"
src={Initials}
style={{
width: "100%",
height: "100%",
objectFit: "contain"
}}
src={imgInitials}
className="w-[100%] h-[100%] object-contain"
/>
</div>
) : (
@@ -393,9 +421,7 @@ const ManageSign = () => {
className: "intialSignature rounded-box"
}}
// backgroundColor="rgb(255, 255, 255)"
onEnd={() =>
handleInitialsChange(initailsRef.current.toDataURL())
}
onEnd={() => handleInitialsChange()}
dotSize={1}
/>
)}
@@ -418,6 +444,7 @@ const ManageSign = () => {
? "2px solid black"
: "2px solid white"
}}
className="fa-light fa-pen-nib"
onClick={() => {
if (key === 0) {
setInitialPen("blue");
@@ -428,7 +455,6 @@ const ManageSign = () => {
}
}}
key={key}
className="fa-light fa-pen-nib"
width={20}
height={20}
></i>
@@ -437,13 +463,22 @@ const ManageSign = () => {
</div>
)}
</div>
<div>
<div className="flex flex-row gap-1">
<div
type="button"
className="op-link text-sm md:text-base mr-1"
onClick={() => handleClearInitials()}
onClick={() => handleUploadInitials()}
>
{t("clear")}
{t("upload")}
</div>
<div>
<div
type="button"
className="op-link text-sm md:text-base mr-1"
onClick={() => handleClearInitials()}
>
{t("clear")}
</div>
</div>
</div>
</div>
+18 -13
View File
@@ -73,7 +73,7 @@ function PdfRequestFiles(props) {
const [selectWidgetId, setSelectWidgetId] = useState("");
const [otpLoader, setOtpLoader] = useState(false);
const [isCelebration, setIsCelebration] = useState(false);
const [requestSignTour, setRequestSignTour] = useState(false);
const [requestSignTour, setRequestSignTour] = useState(true);
const [tourStatus, setTourStatus] = useState([]);
const [isLoading, setIsLoading] = useState({
isLoad: true,
@@ -129,7 +129,7 @@ function PdfRequestFiles(props) {
const [contact, setContact] = useState({ name: "", phone: "", email: "" });
const [isOtp, setIsOtp] = useState(false);
const [loading, setLoading] = useState(false);
const [res, setRes] = useState({});
const [publicRes, setPublicRes] = useState({});
const [documentId, setDocumentId] = useState("");
const [isPublicContact, setIsPublicContact] = useState(false);
const [pdfArrayBuffer, setPdfArrayBuffer] = useState("");
@@ -429,7 +429,7 @@ function PdfRequestFiles(props) {
currUserId = getCurrentSigner?.objectId
? getCurrentSigner.objectId
: contactBookId || "";
: contactBookId || signerObjectId || "";
if (isEnableSubscription) {
await checkIsSubscribed(
documentData[0]?.ExtUserPtr?.objectId,
@@ -1013,7 +1013,7 @@ function PdfRequestFiles(props) {
receiver_phone: user.Phone,
expiry_date: localExpireDate,
company_name: orgName,
signing_url: `<a href=${signPdf}>Sign here</a>`
signing_url: `<a href=${signPdf} target=_blank>Sign here</a>`
};
replaceVar = replaceMailVaribles(
requestSubject,
@@ -1047,7 +1047,7 @@ function PdfRequestFiles(props) {
orgName +
"</td></tr> <tr> <td style='font-weight:bold;font-family:sans-serif;font-size:15px'>Expires on</td><td> </td> <td style='color:#626363;font-weight:bold'>" +
localExpireDate +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a href=" +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a target=_blank href=" +
signPdf +
"> <button style='padding: 12px 12px 12px 12px;background-color: #d46b0f;color: white; border: 0px;box-shadow: rgba(0, 0, 0, 0.05) 0px 6px 24px 0px,rgba(0, 0, 0, 0.08) 0px 0px 0px 1px;font-weight:bold;margin-top:30px'>Sign here</button></a> </div> <div style='display: flex; justify-content: center;margin-top: 10px;'> </div></div></div><div><p> This is an automated email from OpenSign™. For any queries regarding this email, please contact the sender " +
senderEmail +
@@ -1510,8 +1510,17 @@ function PdfRequestFiles(props) {
);
if (userRes?.data?.result) {
setRes(userRes.data.result);
await SendOtp();
setPublicRes(userRes.data.result);
const isEnableOTP = pdfDetails?.[0]?.IsEnableOTP || false;
if (isEnableOTP) {
await SendOtp();
} else {
setIsPublicContact(false);
setIsPublicTemplate(false);
setDocumentId(userRes.data?.result?.docId);
const contactId = userRes.data.result?.contactId;
setSignerObjectId(contactId);
}
} else {
console.log("error in public-sign to create user details");
setIsAlert({
@@ -1553,7 +1562,7 @@ function PdfRequestFiles(props) {
const SendOtp = async () => {
try {
const params = { email: contact.email, docId: res.docId };
const params = { email: contact.email, docId: publicRes?.docId };
const Otp = await axios.post(
`${localStorage.getItem("baseUrl")}/functions/SendOTPMailV1`,
params,
@@ -1619,17 +1628,13 @@ function PdfRequestFiles(props) {
JSON.stringify(contractUserDetails)
);
}
localStorage.setItem("username", _user.name);
localStorage.setItem("accesstoken", _user.sessionToken);
setLoading(false);
// navigate(`/load/recipientSignPdf/${res?.docId}/${res?.contactId}`);
// document.getElementById("my_modal").close();
setIsPublicContact(false);
setIsPublicTemplate(false);
setIsLoading({ isLoad: false });
setDocumentId(res?.docId);
getDocumentDetails(res?.docId);
setDocumentId(publicRes?.docId);
}
} catch (error) {
console.log("err ", error);
+2 -2
View File
@@ -1121,7 +1121,7 @@ function PlaceHolderSign() {
receiver_phone: signerMail[i]?.Phone || "",
expiry_date: localExpireDate,
company_name: orgName,
signing_url: `<a href=${signPdf}>Sign here</a>`
signing_url: `<a href=${signPdf} target=_blank>Sign here</a>`
};
replaceVar = replaceMailVaribles(
requestSubject,
@@ -1155,7 +1155,7 @@ function PlaceHolderSign() {
orgName +
"</td></tr> <tr> <td style='font-weight:bold;font-family:sans-serif;font-size:15px'>Expire on</td><td> </td> <td style='color:#626363;font-weight:bold'>" +
localExpireDate +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a href=" +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a target=_blank href=" +
signPdf +
"> <button style='padding: 12px 12px 12px 12px;background-color: #d46b0f;color: white; border: 0px;box-shadow: rgba(0, 0, 0, 0.05) 0px 6px 24px 0px,rgba(0, 0, 0, 0.08) 0px 0px 0px 1px;font-weight:bold;margin-top:30px'>Sign here</button></a> </div> <div style='display: flex; justify-content: center;margin-top: 10px;'> </div></div></div><div><p> This is an automated email from OpenSign™. For any queries regarding this email, please contact the sender " +
senderEmail +
@@ -508,7 +508,7 @@ const TemplatePlaceholder = () => {
const tourAddRole = [
{
selector: '[data-tut="reactourAddbtn"]',
content: "You need to add a role before you can add fields for it. ",
content: t("add-user-template"),
position: "top",
style: { fontSize: "13px" }
}
+1 -1
View File
@@ -611,7 +611,7 @@ function UserProfile() {
<div className="flex flex-row md:items-center gap-1">
{editmode || !extendUser?.[0]?.Tagline ? (
<input
maxLength={40}
maxLength={100}
onChange={handleOnchangeTagLine}
value={tagLine}
disabled={!editmode}
@@ -711,7 +711,7 @@ const ReportTable = (props) => {
receiver_phone: userDetails?.Phone || "",
expiry_date: localExpireDate,
company_name: doc.ExtUserPtr.Company,
signing_url: `<a href=${signPdf}>Sign here</a>`
signing_url: `<a href=${signPdf} target=_blank>Sign here</a>`
};
const res = replaceMailVaribles(subject, "", variables);
@@ -740,7 +740,7 @@ const ReportTable = (props) => {
receiver_phone: userDetails?.Phone || "",
expiry_date: localExpireDate,
company_name: doc.ExtUserPtr.Company,
signing_url: `<a href=${signPdf}>Sign here</a>`
signing_url: `<a href=${signPdf} target=_blank>Sign here</a>`
};
const res = replaceMailVaribles("", body, variables);
@@ -781,7 +781,7 @@ const ReportTable = (props) => {
receiver_phone: user?.signerPtr?.Phone || "",
expiry_date: localExpireDate,
company_name: doc?.ExtUserPtr?.Company || "",
signing_url: `<a href=${signPdf}>Sign here</a>`
signing_url: `<a href=${signPdf} target=_blank>Sign here</a>`
};
const subject =
@@ -1511,14 +1511,14 @@ const ReportTable = (props) => {
<span>{t("public-url-copy")}</span>
<div className=" flex items-center justify-between gap-3 p-[2px] ">
<div className="w-[280px] whitespace-nowrap overflow-hidden text-ellipsis">
<span
onClick={() =>
copytoProfileLink()
}
<a
rel="noreferrer"
target="_blank"
href={publicUrl()}
className="ml-[2px] underline underline-offset-2 cursor-pointer text-blue-800"
>
{publicUrl()}
</span>
</a>
</div>
<div className="flex items-center gap-2">
<RWebShare
@@ -1535,7 +1535,7 @@ const ReportTable = (props) => {
</button>
</RWebShare>
<button
className="op-btn op-btn-primary op-btn-outline op-btn-xs md:op-btn-sm"
className="op-btn op-btn-primary op-btn-outline op-btn-xs md:op-btn-sm md:w-[100px]"
onClick={() =>
copytoProfileLink()
}
@@ -1561,7 +1561,7 @@ const ReportTable = (props) => {
className="mt-3 op-btn op-btn-primary"
onClick={() => navigate("/profile")}
>
{t("add")}
{t("Proceed")}
</button>
</div>
)}
@@ -265,10 +265,10 @@
"make-template-public-alert": "Are you sure you want to make this template public?",
"make-template-private-alert": "Are you sure you want to make this template private? This will remove it from your public profile.",
"public-role": "Public role",
"public-url": "Public URL",
"public-url": "Public profile needed",
"public-url-copy": "Heres your public URL: ",
"public-url-copy-mssg": "Copy it or share it with the signer, and you will be able to see all your publicly set templates.",
"add-public-url-alert": "Please add your public URL, and you will be able to make a public template.",
"add-public-url-alert": "Please complete your OpenSign public profile setup. Once done, youll be able to make templates public. This process only needs to be completed once.",
"share-with-alert": "You cannot share a template if any roles already have contacts assigned. Please remove all contact assignments from the roles before sharing the template.",
"share-with": "Share with",
"team-not-found": "Team not found",
@@ -672,5 +672,6 @@
"document-logs": "Document logs",
"server-down": "Unable to connect to the OpenSign server. If you are self-hosting OpenSign, please ensure that all the steps in the documentation have been followed correctly. If you're running OpenSign locally, you might be accessing it through an incorrect port number.",
"admin-exists": "Admin already exists. Please login to the application using admin credentials in order to manage users.",
"public-tour-message": "Please make template public to copy public URL"
"public-tour-message":"The template needs to be public before you can generate a shareable link.",
"add-user-template": "You need to add a role before you can add fields for it."
}
@@ -264,10 +264,10 @@
"make-template-public-alert": "Êtes-vous sûr de vouloir rendre ce modèle public ?",
"make-template-private-alert": "Êtes-vous sûr de vouloir rendre ce modèle privé ? Cela le supprimera de votre profil public.",
"public-role": "Rôle public",
"public-url": "URL publique",
"public-url": "Profil public requis",
"public-url-copy": "Voici votre URL publique : ",
"public-url-copy-mssg": "copiez-la ou partagez-le avec le signataire et vous pouvoir voir tous vos paramètres publics modèles.",
"add-public-url-alert": "Veuillez ajouter votre URL publique et vous pourra rendre public modèle.",
"add-public-url-alert": "Veuillez terminer la configuration de votre profil public OpenSign. Une fois cela fait, vous pourrez rendre les modèles publics. Ce processus ne doit être effectué quune seule fois.",
"share-with-alert": "Vous ne pouvez pas partager un modèle si des contacts sont déjà attribués à des rôles. Veuillez supprimer toutes les attributions de contacts des rôles avant de partager le modèle.",
"share-with": "Partager avec",
"team-not-found": "Équipe introuvable",
@@ -671,5 +671,6 @@
"document-logs": "Journaux de documents",
"server-down": "Impossible de se connecter au serveur OpenSign. Si vous hébergez vous-même OpenSign, veuillez vous assurer que toutes les étapes de la documentation ont été correctement suivies. Si vous exécutez OpenSign localement, vous y accédez peut-être via un numéro de port incorrect.",
"admin-exists": "L'administrateur existe déjà. Veuillez vous connecter à l'application en utilisant les informations d'identification de l'administrateur afin de gérer les utilisateurs.",
"public-tour-message": "Veuillez rendre le modèle public pour copier l'URL publique"
"public-tour-message": "Le modèle doit être public avant que vous puissiez générer un lien partageable.",
"add-user-template":"Vous devez ajouter un rôle avant de pouvoir lui ajouter des champs. "
}
@@ -53,7 +53,7 @@ async function sendMail(doc, signer) {
receiver_phone: signer?.Phone || '',
expiry_date: localExpireDate,
company_name: doc?.ExtUserPtr?.Company || '',
signing_url: `<a href=${signPdf}>Sign here</a>`,
signing_url: `<a href=${signPdf} target=_blank>Sign here</a>`,
};
const mail = replaceMailVaribles(subject, body, variables);
@@ -196,8 +196,9 @@ export default async function createDocumentWithTemplate(request, response) {
if (TimeToCompleteDays) {
object.set('TimeToCompleteDays', TimeToCompleteDays);
}
const enableOTP = request.body?.enableOTP === true ? true : false;
const IsEnableOTP = enableOTP || template?.IsEnableOTP || false;
const enableOTP = request.body?.enableOTP;
const IsEnableOTP =
enableOTP !== undefined ? enableOTP : template?.IsEnableOTP || false;
object.set('IsEnableOTP', IsEnableOTP);
object.set('CreatedBy', template.CreatedBy);
object.set('ExtUserPtr', {
@@ -268,7 +269,7 @@ export default async function createDocumentWithTemplate(request, response) {
orgName +
"</td></tr> <tr> <td style='font-weight:bold;font-family:sans-serif;font-size:15px'>Expires on</td><td> </td> <td style='color:#626363;font-weight:bold'>" +
localExpireDate +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a href=" +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a target=_blank href=" +
signPdf +
"> <button style='padding: 12px 12px 12px 12px;background-color: #d46b0f;color: white; border: 0px;box-shadow: rgba(0, 0, 0, 0.05) 0px 6px 24px 0px,rgba(0, 0, 0, 0.08) 0px 0px 0px 1px;font-weight:bold;margin-top:30px;'>Sign here</button></a> </div> <div style='display: flex; justify-content: center;margin-top: 10px;'> </div></div></div><div><p> This is an automated email from OpenSign™. For any queries regarding this email, please contact the sender " +
sender +
@@ -325,7 +325,7 @@ export default async function createDocumentwithCoordinate(request, response) {
orgName +
"</td></tr> <tr> <td style='font-weight:bold;font-family:sans-serif;font-size:15px'>Expires on</td><td> </td> <td style='color:#626363;font-weight:bold'>" +
localExpireDate +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a href=" +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a target=_blank href=" +
signPdf +
"> <button style='padding: 12px 12px 12px 12px;background-color: #d46b0f;color: white; border: 0px;box-shadow: rgba(0, 0, 0, 0.05) 0px 6px 24px 0px,rgba(0, 0, 0, 0.08) 0px 0px 0px 1px;font-weight:bold;margin-top:30px'>Sign here</button></a> </div> <div style='display: flex; justify-content: center;margin-top: 10px;'> </div></div></div><div><p> This is an automated email from OpenSign™. For any queries regarding this email, please contact the sender " +
sender +
@@ -86,7 +86,7 @@ export default async function resendMail(request, response) {
orgName +
"</td></tr> <tr> <td style='font-weight:bold;font-family:sans-serif;font-size:15px'>Expires on</td><td> </td> <td style='color:#626363;font-weight:bold'>" +
localExpireDate +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a href=" +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a target=_blank href=" +
signPdf +
"> <button style='padding: 12px 12px 12px 12px;background-color: #d46b0f;color: white; border: 0px;box-shadow: rgba(0, 0, 0, 0.05) 0px 6px 24px 0px,rgba(0, 0, 0, 0.08) 0px 0px 0px 1px;font-weight:bold;margin-top:30px'>Sign here</button></a> </div> <div style='display: flex; justify-content: center;margin-top: 10px;'> </div></div></div><div><p> This is an automated email from OpenSign™. For any queries regarding this email, please contact the sender " +
sender +
@@ -48,10 +48,10 @@ export default async function updateDocument(request, response) {
objectId: request?.body?.folderId,
});
}
if (request.body?.enableOTP) {
if (request.body?.enableOTP !== undefined) {
updateQuery.set('IsEnableOTP', request.body?.enableOTP);
}
const updatedRes = await updateQuery.save(null, { useMasterKey: true });
if (updatedRes) {
if (request.posthog) {
@@ -48,7 +48,7 @@ export default async function updateTemplate(request, response) {
objectId: request?.body?.folderId,
});
}
if (request.body?.enableOTP) {
if (request.body?.enableOTP !== undefined) {
updateQuery.set('IsEnableOTP', request.body?.enableOTP);
}
const updatedRes = await updateQuery.save(null, { useMasterKey: true });
@@ -168,7 +168,7 @@ const sendMailToAllSigners = async docId => {
receiver_phone: signerMail[i]?.Phone || '',
expiry_date: localExpireDate,
company_name: orgName,
signing_url: `<a href=${signPdf}>Sign here</a>`,
signing_url: `<a href=${signPdf} target=_blank>Sign here</a>`,
};
replaceVar = replaceMailVaribles(requestSubject, htmlReqBody, variables);
}
@@ -95,7 +95,7 @@ async function sendMail(document, sessionToken) {
orgName +
"</td></tr> <tr> <td style='font-weight:bold;font-family:sans-serif;font-size:15px'>Expires on</td><td> </td> <td style='color:#626363;font-weight:bold'>" +
localExpireDate +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a href=" +
"</td></tr><tr> <td></td> <td> </td></tr></table> </div> <div style='margin-left:70px'><a target=_blank href=" +
signPdf +
"> <button style='padding: 12px 12px 12px 12px;background-color: #d46b0f;color: white; border: 0px;box-shadow: rgba(0, 0, 0, 0.05) 0px 6px 24px 0px,rgba(0, 0, 0, 0.08) 0px 0px 0px 1px;font-weight:bold;margin-top:30px;'>Sign here</button></a> </div> <div style='display: flex; justify-content: center;margin-top: 10px;'> </div></div></div><div><p> This is an automated email from OpenSign™. For any queries regarding this email, please contact the sender " +
sender +
+2 -1
View File
@@ -24,8 +24,9 @@ if (useLocal !== 'true') {
try {
const spacesEndpoint = new AWS.Endpoint(process.env.DO_ENDPOINT);
const s3Options = {
bucket: process.env.DO_SPACE, // globalConfig.S3FilesAdapter.bucket,
bucket: process.env.DO_SPACE,
baseUrl: process.env.DO_BASEURL,
fileAcl: 'none',
region: process.env.DO_REGION,
directAccess: true,
preserveFileName: true,
+8 -8
View File
@@ -25,7 +25,7 @@
"googleapis": "^144.0.0",
"jsonschema": "^1.4.1",
"mailgun.js": "^10.2.3",
"mongoose": "^8.6.3",
"mongoose": "^8.7.0",
"multer": "^1.4.5-lts.1",
"multer-s3": "^3.0.1",
"node-forge": "^1.3.1",
@@ -8247,13 +8247,13 @@
}
},
"node_modules/mongoose": {
"version": "8.6.3",
"resolved": "https://registry.npmjs.org/mongoose/-/mongoose-8.6.3.tgz",
"integrity": "sha512-++yRmm7hjMbqVA/8WeiygTnEfrFbiy+OBjQi49GFJIvCQuSYE56myyQWo4j5hbpcHjhHQU8NukMNGTwAWFWjIw==",
"version": "8.7.0",
"resolved": "https://registry.npmjs.org/mongoose/-/mongoose-8.7.0.tgz",
"integrity": "sha512-rUCSF1mMYQXjXYdqEQLLlMD3xbcj2j1/hRn+9VnVj7ipzru/UoUZxlj/hWmteKMAh4EFnDZ+BIrmma9l/0Hi1g==",
"dependencies": {
"bson": "^6.7.0",
"kareem": "2.6.3",
"mongodb": "6.8.0",
"mongodb": "6.9.0",
"mpath": "0.9.0",
"mquery": "5.0.0",
"ms": "2.1.3",
@@ -8325,9 +8325,9 @@
}
},
"node_modules/mongoose/node_modules/mongodb": {
"version": "6.8.0",
"resolved": "https://registry.npmjs.org/mongodb/-/mongodb-6.8.0.tgz",
"integrity": "sha512-HGQ9NWDle5WvwMnrvUxsFYPd3JEbqD3RgABHBQRuoCEND0qzhsd0iH5ypHsf1eJ+sXmvmyKpP+FLOKY8Il7jMw==",
"version": "6.9.0",
"resolved": "https://registry.npmjs.org/mongodb/-/mongodb-6.9.0.tgz",
"integrity": "sha512-UMopBVx1LmEUbW/QE0Hw18u583PEDVQmUmVzzBRH0o/xtE9DBRA5ZYLOjpLIa03i8FXjzvQECJcqoMvCXftTUA==",
"dependencies": {
"@mongodb-js/saslprep": "^1.1.5",
"bson": "^6.7.0",
+1 -1
View File
@@ -34,7 +34,7 @@
"googleapis": "^144.0.0",
"jsonschema": "^1.4.1",
"mailgun.js": "^10.2.3",
"mongoose": "^8.6.3",
"mongoose": "^8.7.0",
"multer": "^1.4.5-lts.1",
"multer-s3": "^3.0.1",
"node-forge": "^1.3.1",