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.223.108.134
(window.webpackJsonp=window.webpackJsonp||[]).push([[127],{1169:function(e,t,a){"use strict";a.r(t);var r=a(41),n=a.n(r),o=a(68),l=a(99),c=a(100),s=a(102),u=a(101),i=a(103),p=a(1),m=a.n(p),d=a(266),g=a(269),f=(a(327),a(1139)),h=a(1098),E=a(1100),v=a(1106),b=a(1101),w=a(104),y=function(e){function t(){var e,a;Object(l.a)(this,t);for(var r=arguments.length,c=new Array(r),i=0;i<r;i++)c[i]=arguments[i];return(a=Object(s.a)(this,(e=Object(u.a)(t)).call.apply(e,[this].concat(c)))).state={correctionType:"",collRangeFrom:"0",collRangeTo:"z",regrangefrom:"0",regrangeto:"z",status:"",frmsubmit:!1,loadsub:""},a.regfromchange=function(e,t){a.setState({regrangefrom:t.value})},a.regfromchange=function(e,t){a.setState({regrangefrom:t.value})},a.regtochange=function(e,t){a.setState({regrangeto:t.value})},a.dropDownChange=function(e,t){a.setState({correctionType:t.value})},a.fromChange=function(e,t){console.log(t),a.setState({collRangeFrom:t.value})},a.toChange=function(e,t){a.setState({collRangeTo:t.value})},a.loadsubChnage=function(e,t){a.setState({loadsub:t.value})},a.statusDropDown=function(){var e=Object(o.a)(n.a.mark(function e(t,r){return n.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a.setState({status:r.value});case 2:case"end":return e.stop()}},e)}));return function(t,a){return e.apply(this,arguments)}}(),a.submitHandler=Object(o.a)(n.a.mark(function e(){var t,r,o,l,c,s;return n.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(""!==a.state.correctionType){e.next=6;break}return t={header:"Error",content:"Select correction type"},a.props.showError(t),e.abrupt("return");case 6:if(""!==a.state.collRangeFrom){e.next=12;break}return r={header:"Error",content:"Select college range(from)"},a.props.showError(r),e.abrupt("return");case 12:if(""!==a.state.collRangeTo){e.next=18;break}return o={header:"Error",content:"Select college range(to)"},a.props.showError(o),e.abrupt("return");case 18:if(""!==a.state.regrangefrom){e.next=24;break}return l={header:"Error",content:"Select reg. no. range(from)"},a.props.showError(l),e.abrupt("return");case 24:if(""!==a.state.regrangeto){e.next=30;break}return c={header:"Error",content:"Select reg. no. range(to)"},a.props.showError(c),e.abrupt("return");case 30:if(""!=a.state.loadsub){e.next=36;break}return s={header:"Error",content:"Select Cannot be empty"},a.props.showError(s),e.abrupt("return");case 36:return e.next=38,a.props.submitApproveStudName(a.state);case 38:a.setState({frmsubmit:!0});case 39:case"end":return e.stop()}},e)})),a.saveApprove=function(){var e=Object(o.a)(n.a.mark(function e(t,r,o,l,c,s){return n.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a.props.saveNameStatus(t,r,o,l,a.state.status,s,a.props.user.fmobileno);case 2:case"end":return e.stop()}},e)}));return function(t,a,r,n,o,l){return e.apply(this,arguments)}}(),a}return Object(i.a)(t,e),Object(c.a)(t,[{key:"componentDidMount",value:function(){this.setState({frmsubmit:!1})}},{key:"render",value:function(){var e=this,t=this.state,a=(t.correctionType,t.collRangeFrom,t.collRangeTo,t.status,t.regrangefrom),r=t.regrangeto,n=[{key:1,value:"approved",text:"Approved"},{key:2,value:"pending",text:"Pending"},{key:3,value:"rejected",text:"Rejected"}];return m.a.createElement("div",null,m.a.createElement(f.a,{fluid:!0},m.a.createElement(f.a.Content,null,m.a.createElement(f.a.Description,null,m.a.createElement(h.a.Group,null,m.a.createElement(h.a.Field,null,m.a.createElement("label",null,"Correction Type"),m.a.createElement(E.a,{style:{width:"29.5%",marginBottom:"10px"},fluid:!0,search:!0,selection:!0,value:this.state.correctionType,options:[{key:1,value:"Name Correction",text:"Name Correction"}],allowAdditions:!0,placeholder:"Type",onChange:this.dropDownChange})),m.a.createElement("label",null,"Register No. Range"),m.a.createElement(h.a.Group,{style:{display:"flex"}},m.a.createElement(h.a.Input,{placeholder:"Register No. {From}",value:a,width:4,name:"fregfrom",onChange:this.regfromchange}),m.a.createElement(h.a.Input,{style:{marginLeft:"20px"},placeholder:"Register No. {To}",value:r,width:4,name:"fregto",onChange:this.regtochange}))),m.a.createElement("label",null,"College Range"),m.a.createElement(h.a.Group,{style:{display:"flex"}},m.a.createElement(h.a.Input,{placeholder:"College Range {From}",value:this.state.collRangeFrom,width:4,name:"ffrom",onChange:this.fromChange}),m.a.createElement(h.a.Input,{style:{marginLeft:"20px"},placeholder:"College Range {To}",value:this.state.collRangeTo,width:4,name:"fto",onChange:this.toChange})),m.a.createElement(h.a.Field,null,m.a.createElement("label",null,"Select Type"),m.a.createElement(E.a,{style:{width:"29.5%",marginBottom:"10px"},fluid:!0,search:!0,selection:!0,value:this.state.loadsub,options:[{key:1,value:"all",text:"All"},{key:2,value:"approved",text:"Approved"},{key:3,value:"pending",text:"Pending"},{key:4,value:"rejected",text:"Rejected"}],allowAdditions:!0,placeholder:"Type",onChange:this.loadsubChnage})),m.a.createElement("div",{className:"btn",style:{width:"20%",marginTop:"10px",alignItems:"center"}},m.a.createElement(v.a,{basic:!0,color:"blue",content:"Submit",onClick:this.submitHandler})),this.state.frmsubmit?m.a.createElement(b.a,{celled:!0,padded:!0},m.a.createElement(b.a.Header,null,m.a.createElement(b.a.Row,null,m.a.createElement(b.a.HeaderCell,{singleLine:!0},"App. No."),m.a.createElement(b.a.HeaderCell,null,"College Name"),m.a.createElement(b.a.HeaderCell,null,"College Code"),m.a.createElement(b.a.HeaderCell,null,"Reg. No."),m.a.createElement(b.a.HeaderCell,null,"Old Name"),m.a.createElement(b.a.HeaderCell,null,"New Name"),m.a.createElement(b.a.HeaderCell,null,"Attachment"),m.a.createElement(b.a.HeaderCell,null,"Status"),m.a.createElement(b.a.HeaderCell,null,"Action"))),m.a.createElement(b.a.Body,null,this.props.changeStudInfo.map(function(t,a){t.fdoc;return m.a.createElement(b.a.Row,{key:a},m.a.createElement(b.a.Cell,{textAlign:"center"},t.fapp),m.a.createElement(b.a.Cell,null,t.fcollname+" - "+t.ftown),m.a.createElement(b.a.Cell,{textAlign:"center"},t.fcollcode),m.a.createElement(b.a.Cell,{textAlign:"center"},t.fregno),m.a.createElement(b.a.Cell,null,t.foldname),m.a.createElement(b.a.Cell,null,t.fnewname),m.a.createElement(b.a.Cell,{textAlign:"center"},m.a.createElement("a",{href:"https://admission-certificates.s3.ap-south-1.amazonaws.com/"+t.fdoc,target:"_blank"},"View")),m.a.createElement(b.a.Cell,{textAlign:"center"},m.a.createElement(E.a,{fluid:!0,search:!0,selection:!0,value:""==e.state.status?t.fstatus:e.status,options:n,allowAdditions:!0,placeholder:"Type",onChange:e.statusDropDown})),m.a.createElement(b.a.Cell,null,m.a.createElement(v.a,{positive:!0,onClick:function(){return e.saveApprove(t.fregno,t.fcollname,t.foldname,t.fnewname,t.status,t.fcollcode)}},"Save")))}))):this.state.frmsubmit))))}}]),t}(m.a.Component);t.default=Object(w.b)(function(e){return{deggrp:e.deggrp,changeStudInfo:e.getStudNameChange,user:e.user}},{submitApproveStudName:function(e){return function(){var t=Object(o.a)(n.a.mark(function t(a,r){var o,l,c,s;return n.a.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return o=r(),a({type:"SET_LOADER"}),a({type:"DELETE_QPSTATS"}),a({type:"CLEAR_TEACHER_ID"}),t.next=6,g.a.get("/app.php",{params:{a:"approvestudname",univcode:o.user.fcuruniv,type:e.correctionType,colfrom:e.collRangeFrom,colto:e.collRangeTo,regfrom:e.regrangefrom,regto:e.regrangeto,status:e.status,option:e.loadsub}});case 6:l=t.sent,a({type:"UNSET_LOADER"}),"object"!==typeof l.data?(c={header:"Error",content:"Something went wrong"},a(Object(d.w)(c))):-1===l.data.error_code?(s={header:"Error",content:l.data.data.msg},a(Object(d.w)(s))):a({type:"APPROVE_STUD_NAME",payload:l.data});case 9:case"end":return t.stop()}},t)}));return function(e,a){return t.apply(this,arguments)}}()},showError:d.w,saveNameStatus:function(e,t,a,r,l,c,s){return function(){var u=Object(o.a)(n.a.mark(function o(u,i){var p,m,f,h,E;return n.a.wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return p=i(),n.next=3,g.a.post("/app.php?a=saveNameStatus&univcode="+p.univ.funivcode+"®no="+e+"&collname="+t+"&oldname="+a+"&newname="+r+"&status="+l+"&collcode="+c+"&updmobile="+s);case 3:m=n.sent,u({type:"UNSET_LOADER"}),"object"!==typeof m.data?(f={header:"Error",content:"Something went wrong"},u(Object(d.w)(f))):-1===m.data.error_code?(h={header:"Error",content:m.data.data.msg},u(Object(d.w)(h))):(E={header:"Success",content:m.data.data.msg},u(Object(d.w)(E)));case 6:case"end":return n.stop()}},o)}));return function(e,t){return u.apply(this,arguments)}}()}})(y)},327:function(e,t,a){}}]);
//# sourceMappingURL=127.87f1a811.chunk.js.map
|