0xV3NOMx
Linux ip-172-26-7-228 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64



Your IP : 18.118.28.31


Current Path : /proc/thread-self/root/var/www/college/static/js/
Upload File :
Current File : //proc/thread-self/root/var/www/college/static/js/518.aefc497d.chunk.js

"use strict";(self.webpackChunkcollege_portal_app=self.webpackChunkcollege_portal_app||[]).push([[518],{4853:(e,a,t)=>{t.d(a,{B3:()=>i,PV:()=>p,Si:()=>c,jE:()=>o,ji:()=>d,zo:()=>h});var l=t(86213),s=t(150),n=t(15355);const r=e=>({type:"LOADING",load:e}),o=async(e,a,t,n,r)=>{try{await(0,l.A)({method:"GET",url:s.A+"loaddayteachname&collcode="+a+"&univcode="+t+"&usertype="+n+"&user="+r,headers:{"Content-Type":"application/json"}}).then((a=>{0==a.data.error_code?e({type:"GETTEACHNAMES",payload:a.data.data}):e({type:"CLEAR_DATA",payload:[]})}))}catch(o){}},d=async(e,a,t,n,r)=>{try{await(0,l.A)({method:"GET",url:s.A+"loadclassnameday&collcode="+a+"&usertype="+t+"&user="+n+"&teachcode="+r,headers:{"Content-Type":"application/json"}}).then((a=>{0==a.data.error_code?(console.log("anita"),e({type:"GETCLANAME",payload:a.data.data})):e({type:"CLEAR_DATA",payload:[]})}))}catch(o){}},c=async(e,a,t,n)=>{e(r(!1));try{await l.A.post(s.A+"viewattendanceentry&collcode="+t+"&sort="+n,a).then((a=>{0==a.data.error_code?(e(r(!1)),e({type:"VIEW1DATA",payload:a.data.data})):(e(r(!1)),e({type:"CLEAR_DATA",payload:[]}))}))}catch(o){e(r(!1))}},i=async(e,a)=>{try{await l.A.post(s.A+"saveattendanceentry",a).then((e=>0==e.data.error_code?void(0,n.F)(e.data.msg):void(0,n.F)(e.data.data.msg)))}catch(t){}},p=async(e,a,t,n,r,o,d)=>{try{await(0,l.A)({method:"GET",url:s.A+"viewDeleteAddStudDet&collcode="+a+"&univcode="+t+"&usertype="+n+"&user="+r+"&fromteach="+o+"&toteach="+d,headers:{"Content-Type":"application/json"}}).then((a=>{0==a.data.error_code?e({type:"GETFORDELETE",payload:a.data.data}):e({type:"CLEAR_DATA",payload:[]})}))}catch(c){}},h=async(e,a,t,r,o,d)=>{try{await(0,l.A)({method:"GET",url:s.A+"deleteAddstudentry&collcode="+e+"&teachcode="+a+"&clsid="+t+"&period="+r+"&noofcls="+o+"&date="+d,headers:{"Content-Type":"application/json"}}).then((e=>{e.data.error_code,(0,n.F)(e.data.data)}))}catch(c){}}},10925:(e,a,t)=>{t.d(a,{NS:()=>d,Pe:()=>i,Yg:()=>c});var l=t(15444),s=t(6051),n=t(87021),r=t(62058),o=t(70579);const d=e=>({filterDropdown:a=>{let{setSelectedKeys:t,selectedKeys:d,confirm:c,clearFilters:i,close:p}=a;return(0,o.jsxs)("div",{style:{padding:8},onKeyDown:e=>e.stopPropagation(),children:[(0,o.jsx)(l.A,{autoFocus:!0,placeholder:"Search ".concat(e),value:d,onChange:e=>t(e.target.value?[e.target.value]:[]),onPressEnter:()=>{c()},style:{marginBottom:8,display:"block"}}),(0,o.jsxs)(s.A,{children:[(0,o.jsx)(n.Ay,{type:"primary",onClick:()=>c(),icon:(0,o.jsx)(r.A,{}),size:"small",style:{width:90},children:"Search"}),(0,o.jsx)(n.Ay,{onClick:()=>{i(),c()},size:"small",style:{width:90},children:"Reset"})]})]})},filterIcon:e=>(0,o.jsx)(r.A,{style:{color:e?"#CFFF8D":"#fff"}}),onFilter:(a,t)=>t[e].toString().toLowerCase().includes(a.toLowerCase())}),c=(e,a)=>a.value.toString().toLowerCase().indexOf(e.toLowerCase())>=0||a.label.toString().toLowerCase().indexOf(e.toLowerCase())>=0,i=(e,a,t)=>e[t].localeCompare(a[t])},54518:(e,a,t)=>{t.r(a),t.d(a,{default:()=>w});var l=t(65043),s=t(32513),n=t(5397),r=t(6051),o=t(87021),d=t(62918),c=t(70170),i=t(79672),p=t(14647),h=t(95010),u=t(15444),y=t(90798),x=t(4853),m=t(83003),A=t(73216),g=t(35475),f=t(10925),j=t(15355),v=t(70579);const w=(0,m.Ng)((e=>(console.log(e.modifysttEntryToDeleteReducer.modifyForAttEntry,"hhsdvcuh"),{user:e.AuthReducer.userData,teachData:e.getattEntryTeacherNameReducer.teachData,classData:e.getattEntryClassNameReducer.classData,view1Data:e.view1attEntryDataResucer.view1Data,viewToDeleteAtt:e.viewAttentryToDeleteReducer.viewToDeleteAtt,modifyForAttEntry:e.modifysttEntryToDeleteReducer.modifyForAttEntry,loading:e.degreeReducer.loading})))((function(e){const[a,t]=(0,l.useState)(""),[w,S]=(0,l.useState)([]),[C,b]=(0,l.useState)(""),[D,N]=(0,l.useState)([]),[E,T]=(0,l.useState)(""),[F,L]=(0,l.useState)(""),[k,P]=(0,l.useState)(""),[R,_]=(0,l.useState)(""),[O,I]=(0,l.useState)("fname"),[B,Y]=(0,l.useState)([]),[G,z]=(0,l.useState)(!1),[V,K]=(0,l.useState)(!1),[M,U]=(0,l.useState)(!1),H=(0,m.wA)(),J=(0,A.g)();(0,l.useEffect)((()=>{q(),S(e.teachData),t(J.teachcode),b(J.classid),T(J.date),L(J.period),P(J.noc),W()}),[]);const W=async()=>{const a=new FormData;a.append("teachnames",J.teachcode),a.append("clsnames",J.classid),a.append("date",J.date),a.append("period",J.period),a.append("noofcls",J.noc),await(0,x.Si)(H,a,e.user.fcollcode,O),""==J.teachcode||void 0==J.teachcode?K(!1):K(!0)},q=()=>{U(!1),(0,x.jE)(H,e.user.fcollcode,e.user.funivcode,e.user.fusertype,e.user.fuser)},Q=[{value:"select",label:"---Select Teacher---"},...e.teachData],X=[{value:"select",label:"---Select Class---"},...e.classData],Z=[{title:"Sl. No",dataIndex:"slno",align:"center",width:"3%"},{title:"Degree",dataIndex:"degree",...(0,f.NS)("degree"),sorter:(e,a)=>(0,f.Pe)(e,a,"degree"),sortDirections:["descend","ascend"],align:"center",width:"5%"},{title:"Semester",dataIndex:"semester",...(0,f.NS)("semester"),sorter:(e,a)=>(0,f.Pe)(e,a,"semester"),sortDirections:["descend","ascend"],align:"center",width:"5%"},{title:"USN",dataIndex:"usn",...(0,f.NS)("usn"),sorter:(e,a)=>(0,f.Pe)(e,a,"usn"),sortDirections:["descend","ascend"],align:"center",width:"6%"},{title:"Name",dataIndex:"name",...(0,f.NS)("name"),sorter:(e,a)=>(0,f.Pe)(e,a,"name"),sortDirections:["descend","ascend"],align:"left",width:"15%"},{title:(0,v.jsx)(s.A,{onChange:a=>(a=>{let t=e.view1Data.map(((e,t)=>(e.fpresent=a?"P":"A",e)));Y([...t])})(a.target.checked)}),dataIndex:"action",align:"center",width:"3%"}],$=e.view1Data.map(((a,t)=>({key:t,slno:t+1,degree:a.fdegree,semester:a.fexamno,usn:a.fregno,name:a.fname,action:(0,v.jsx)(s.A,{checked:"P"==a.fpresent,onChange:a=>((a,t)=>{const l=e.view1Data;l[t].fpresent=a?"P":"A",Y([...l])})(a.target.checked,t)})}))),ee=[{title:"Sl. No",dataIndex:"slno",align:"center",width:"2%"},{title:"USN",dataIndex:"usn",...(0,f.NS)("usn"),sorter:(e,a)=>(0,f.Pe)(e,a,"usn"),sortDirections:["descend","ascend"],align:"center",width:"4%"},{title:"Name",dataIndex:"name",...(0,f.NS)("name"),sorter:(e,a)=>(0,f.Pe)(e,a,"name"),sortDirections:["descend","ascend"],align:"left",width:"7%"}],ae=B.filter((e=>"A"===e.fpresent)).map(((e,a)=>({key:a,slno:a+1,usn:e.fregno,name:e.fname}))),te=B.filter((e=>"P"===e.fpresent)).map((e=>e)).length,le=B.filter((e=>"A"===e.fpresent)).map((e=>e)).length,se=B.length;return(0,v.jsx)("div",{className:"container-fluid",children:(0,v.jsxs)(n.A,{hoverable:!0,title:"Attendance Entry",style:{width:"100%"},extra:(0,v.jsxs)(r.A,{direction:"horizontal",children:[(0,v.jsx)(o.Ay,{className:"save",onClick:()=>{z(!0)},children:"Save"}),(0,v.jsx)(g.N_,{to:"/viewAttEntry",children:(0,v.jsx)(o.Ay,{className:"report",children:"View"})}),(0,v.jsx)(o.Ay,{className:"clear",children:"Clear"}),(0,v.jsx)(o.Ay,{className:"clear",children:"Back"}),(0,v.jsx)(o.Ay,{className:"exit",children:"Exit"})]}),children:[G&&(0,v.jsxs)(d.A,{title:"Following are Absentees",visible:G,onCancel:()=>z(!1),footer:null,centered:!0,style:{overflowY:"auto"},children:[(0,v.jsx)(c.A,{scroll:{y:150},pagination:!1,bordered:!0,columns:ee,dataSource:ae,size:"small"}),(0,v.jsxs)("table",{style:{width:"100%",borderCollapse:"collapse",marginTop:"10px"},children:[(0,v.jsx)("td",{style:{border:"1px solid black",padding:"4px",textAlign:"center"},children:(0,v.jsxs)("span",{children:["Total Students:",se," "]})}),(0,v.jsx)("td",{style:{border:"1px solid black",padding:"4px",textAlign:"center"},children:(0,v.jsxs)("span",{children:["Total Present: ",te]})}),(0,v.jsx)("td",{style:{border:"1px solid black",padding:"4px",textAlign:"center"},children:(0,v.jsxs)("span",{children:["Total Absent:",le]})})]}),(0,v.jsx)(o.Ay,{className:"save",onClick:()=>(async()=>{let t=new FormData;t.append("data",JSON.stringify(B)),t.append("collcode",e.user.fcollcode),t.append("univcode",e.user.funivcode),t.append("syllabus",R),t.append("sort",O),t.append("cls",C),t.append("dates",E),t.append("period",F),t.append("noofcls",k),t.append("teach",a),await(0,x.B3)(H,t),z(!1)})(),style:{marginTop:"10px",marginLeft:"43%"},children:"Save"})]}),(0,v.jsxs)("div",{style:{marginBottom:"20px"},children:[(0,v.jsxs)(i.A,{style:{marginBottom:"10px"},children:[(0,v.jsx)(p.A,{span:2,children:(0,v.jsx)("label",{children:"Teacher Name"})}),(0,v.jsx)(p.A,{xs:24,sm:24,md:12,lg:8,xl:8,children:(0,v.jsx)(h.A,{showSearch:!0,placeholder:"Select",style:{width:"100%"},disabled:M,value:a,options:Q,filterOption:f.Yg,onChange:a=>(async a=>{t(a),await(0,x.ji)(H,e.user.fcollcode,e.user.fusertype,e.user.fuser,a),N(e.classData)})(a)})}),(0,v.jsx)(p.A,{span:2,style:{marginLeft:"80px"},children:(0,v.jsx)("label",{children:"Class Name"})}),(0,v.jsx)(p.A,{xs:24,sm:24,md:12,lg:8,xl:8,children:(0,v.jsx)(h.A,{showSearch:!0,placeholder:"Select",style:{width:"100%"},value:C,options:X,filterOption:f.Yg,onChange:e=>(e=>{b(e)})(e)})})]}),(0,v.jsxs)(i.A,{style:{marginBottom:"10px"},children:[(0,v.jsx)(p.A,{span:2,children:(0,v.jsx)("label",{children:"Date"})}),(0,v.jsx)(p.A,{children:(0,v.jsx)(u.A,{type:"date",value:E,filterOption:f.Yg,onChange:e=>(e=>{T(e)})(e.target.value)})}),(0,v.jsx)(p.A,{span:2,style:{marginLeft:"35px"},children:(0,v.jsx)("label",{children:"Period"})}),(0,v.jsx)(p.A,{xs:6,sm:6,md:4,lg:4,xl:3,children:(0,v.jsx)(h.A,{showSearch:!0,placeholder:"Select",style:{width:"100%",marginLeft:"-20%"},value:F,options:[{value:"select",label:"---Select Period---"},{value:"1",label:"1"},{value:"2",label:"2"},{value:"3",label:"3"},{value:"4",label:"4"},{value:"5",label:"5"},{value:"6",label:"6"},{value:"7",label:"7"},{value:"8",label:"8"}],filterOption:f.Yg,onChange:e=>(e=>{L(e)})(e)})}),(0,v.jsx)(p.A,{span:2,style:{marginLeft:"50px"},children:(0,v.jsx)("label",{children:"No. of Classes"})}),(0,v.jsx)(p.A,{xs:12,sm:12,md:6,lg:4,xl:4,children:(0,v.jsx)(h.A,{showSearch:!0,placeholder:"Select",style:{width:"100%"},value:k,options:[{value:"select",label:"---Select Class---"},{value:"1",label:"1"},{value:"2",label:"2"},{value:"3",label:"3"}],filterOption:f.Yg,onChange:e=>(e=>{P(e)})(e)})})]}),(0,v.jsxs)(i.A,{style:{marginBottom:"10px"},children:[(0,v.jsx)(p.A,{span:2,children:(0,v.jsx)("label",{children:"Syllabus Covered"})}),(0,v.jsx)(p.A,{children:(0,v.jsx)(y.A,{style:{width:"100%"},value:R,filterOption:f.Yg,onChange:e=>(e=>{_(e)})(e.target.value)})}),(0,v.jsx)(p.A,{span:2,style:{marginLeft:"305px"},children:(0,v.jsx)("label",{children:"Sort"})}),(0,v.jsx)(p.A,{xs:12,sm:12,md:6,lg:4,xl:4,children:(0,v.jsx)(h.A,{showSearch:!0,placeholder:"Select",style:{width:"100%"},value:O,options:[{value:"fname",label:"Name"},{value:"fregno",label:"USN/ADM. No./Reg. No."}],filterOption:f.Yg,onChange:e=>(e=>{I(e)})(e)})})]}),(0,v.jsx)(i.A,{style:{marginBottom:"10px"},children:(0,v.jsx)(p.A,{span:2,style:{marginLeft:"100px"},children:(0,v.jsx)(o.Ay,{className:"report",onClick:()=>(async()=>{const t=new FormData;t.append("teachnames",a),t.append("clsnames",C),t.append("date",E),t.append("period",F),t.append("noofcls",k),await(0,x.Si)(H,t,e.user.fcollcode,O),"select"!=a&&""!=a&&void 0!=a?"select"!=C&&""!=C&&void 0!=C?""!=E&&void 0!=E?"select"!=F&&""!=F&&void 0!=F?"select"!=k&&""!=k&&void 0!=k?K(!0):(0,j.F)("Select No. Of Class"):(0,j.F)("Select Period"):(0,j.F)("Enter Date"):(0,j.F)("Select Class Name"):(0,j.F)("Select Teacher Name")})(),children:"View"})})})]}),V&&(0,v.jsx)(c.A,{scroll:{y:400},pagination:!1,bordered:!0,columns:Z,dataSource:$,size:"small",style:{padding:"2px",width:"70%",marginLeft:"15%",marginTop:"-10px",position:"sticky",top:1}})]})})}))}}]);
//# sourceMappingURL=518.aefc497d.chunk.js.map