From 64a589048c28a96e3f84027dd659adadd17074ca Mon Sep 17 00:00:00 2001
From: devendra <devendra@devendras-MacBook-Pro.local>
Date: Tue, 20 Dec 2022 09:06:34 +0530
Subject: [PATCH] Feat: submit districtName of institute while submitting form

---
 src/components/form/FormViewer.js | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/src/components/form/FormViewer.js b/src/components/form/FormViewer.js
index bdb1642..3b42b6a 100644
--- a/src/components/form/FormViewer.js
+++ b/src/components/form/FormViewer.js
@@ -20,6 +20,7 @@ import Helper from "../../helpers/auth";
 import { StatusBarLarge } from "../status-bar";
 import { CardThree } from "../cards";
 import { TextAreaField } from "../form-elements";
+import Auth from "../../helpers/auth";
 // import { BtnTwo } from "../buttons";
 // const $ = window.$;
 class FormViewer extends Component {
@@ -549,6 +550,11 @@ class FormViewer extends Component {
       }),
     };
 
+    const instituteCourses = Auth.get('instituteCourses');
+    if(instituteCourses.length > 0) {
+      formDetails['districtName'] = instituteCourses[0].districtName;
+    }
+
     // formDetails = JSON.stringify(formDetails);
     // console.log(JSON.parse(formDetails));
 
-- 
GitLab