PageSourceSearch

https://parliament.gov.mw/chunk-P2TB4KSX.js

js parliament.gov.mw collected 2026-09-25 06:43:56 UTC 11,822 bytes, 8 lines download raw bytes

1import{a as I,b as j,c as G,d as W}from"./chunk-LDCG4ONF.js";import{a as U}from"./chunk-2BZPFJEO.js";import{a as z}from"./chunk-HHEDRXB5.js";import"./chunk-LVJT2FB6.js";import{a as H}from"./chunk-NRSKAIFJ.js";import{a as Z}from"./chunk-AFIQDRIC.js";import"./chunk-QUW347F2.js";import"./chunk-BCUM6MUG.js";import{a as B,f as V}from"./chunk-RESS5MLH.js";import{d as _,f as F}from"./chunk-SR5WHKYH.js";import"./chunk-W4BNGQYG.js";import{O as L,f as O,ja as Q,ka as k,o as q,oa as Y}from"./chunk-7TR4GPKW.js";import{$b as p,Bb as E,Hb as x,Pb as c,Wb as N,_b as m,ac as u,ec as P,ia as w,jc as D,kc as M,na as S,oa as f,ob as d,wa as b,wc as C,xa as R}from"./chunk-7RSPASZG.js";import{a as g,d as T,g as h}from"./chunk-TSRGIXR5.js";var K={title:"MEDIA ACCREDITATION FORM \u2013 PARLIAMENT COVERAGE",clearInvisibleValues:"onHidden",showProgressBar:"top",progressBarType:"buttons",progressBarLocation:"auto",progressBarShowPageNumbers:!0,progressBarShowPageTitles:!0,showQuestionNumbers:"off",questionErrorLocation:"bottom",completeText:"Submit Application",widthMode:"responsive",showNavigationButtons:"true",completedHtml:"<h3>Thank you for submitting your application</h3><p>The Authority will process your application and contact you if additional information is required.</p>",pages:[{name:"Application type",showQuestionNumbers:"off",elements:[{type:"radiogroup",name:"applicationType",title:"Application Type",isRequired:!0,choices:[{value:"first_time",text:"First-Time Applicant"},{value:"renew",text:"Renewal"}]},{type:"text",name:"previousApplicationId",title:"Previous Application ID",isRequired:!0,visibleIf:"{applicationType} = 'renew'"}]},{name:"Personal details",showQuestionNumbers:"off",elements:[{type:"panel",title:"1. PERSONAL DETAILS",elements:[{type:"text",name:"fullName",title:"Full Name",isRequired:!0},{type:"text",name:"nationality",title:"Nationality",isRequired:!0},{type:"dropdown",name:"idType",title:"ID Type",choices:["Passport","National ID","Other"],isRequired:!0},{type:"file",name:"passportPhotoUrl",title:"Attach Passport Size Photo",isRequired:!0,showPreview:!0,maxSize:10485760,acceptedTypes:"image/*",maxFiles:1}]}]},{name:"Contact information",showQuestionNumbers:"off",elements:[{type:"panel",title:"2. CONTACT INFORMATION",elements:[{type:"text",name:"phone",title:"Phone Number",inputType:"tel",isRequired:!0},{type:"text",name:"dob",title:"Date of Birth",inputType:"date",isRequired:!0},{type:"radiogroup",name:"gender",title:"Gender",isRequired:!0,choices:[{value:"Male",text:"Male"},{value:"Female",text:"Female"},{value:"Other",text:"Other"}],colCount:3},{type:"text",name:"idNumber",title:"ID Number",isRequired:!0},{type:"text",name:"email",title:"Email Address",isRequired:!0,inputType:"email",validators:[{type:"email",text:"Please enter a valid email address."}],maxLength:100},{type:"comment",name:"mailingAddress",title:"Mailing Address"}]}]},{name:"Media organization",showQuestionNumbers:"off",elements:[{type:"panel",title:"3. MEDIA ORGANIZATION",elements:[{type:"text",name:"organizationName",title:"Organization Name",isRequired:!0},{type:"dropdown",name:"mediaType",title:"Type of Media",isRequired:!0,choices:[{value:"TV",text:"TV"},{value:"Radio",text:"Radio"},{value:"Print",text:"Print"},{value:"Online",text:"Online"},{value:"Freelance",text:"Freelance"}],defaultValue:null},{type:"text",name:"organizationWebsite",title:"Organization Website",inputType:"url"},{type:"text",name:"editorName",title:"Editor Name",isRequired:!0},{type:"text",name:"editorContact",title:"Editor Contact",isRequired:!0},{type:"comment",name:"editorMailingAddress",title:"Editor Mailing Address",isRequired:!0}]}]},{name:"Coverage details",showQuestionNumbers:"off",elements:[{type:"panel",title:"4. COVERAGE DETAILS",elements:[{type:"text",name:"role",title:"Your Role",isRequired:!0},{type:"text",name:"natureOfCoverage",title:"Nature of Coverage",isRequired:!0},{type:"text",name:"requestedStartDate",title:"Requested Start Date",inputType:"date",isRequired:!0,requiredErrorText:"Please select a start date."},{type:"text",name:"requestedEndDate",title:"Requested End Date",inputType:"date",isRequired:!0,requiredErrorText:"Please select an end date."},{type:"text",name:"areasRequested",title:"Areas Requested"}]}]},{name:"Accreditation history",showQuestionNumbers:"off",elements:[{type:"panel",title:"5. ACCREDITATION HISTORY",elements:[{type:"radiogroup",name:"coveredBefore",title:"Covered Parliament Before?",choices:[{value:"Y",text:"Yes"},{value:"N",text:"No"}],isRequired:!0,requiredErrorText:"Please select Yes or No."},{type:"text",name:"coveredWhen",title:"If Yes, When?",inputType:"date",isRequired:!0,visibleIf:"{coveredBefore} = 'Y'",requiredErrorText:"Please select the recent date when you covered Parliament."}]}]},{name:"Documents",showQuestionNumbers:"off",elements:[{type:"paneldynamic",name:"pomMediaAccreditationDocuments",title:"Upload Supporting Documents",panelCount:3,minPanelCount:3,maxPanelCount:3,allowAddPanel:!0,allowRemovePanel:!0,panelAddText:"Add another document",templateElements:[{type:"dropdown",name:"documentType",title:"Document Type",isRequired:!0,choices:[{value:"assignmentLetter",text:"Assignment Letter"},{value:"pressId",text:"Press ID"},{value:"nationalId",text:"National ID"}]},{type:"file",name:"pomMediaAccreditationDocument",title:"Upload File",allowMultiple:!1,showPreview:!0,maxSize:10485760,isRequired:!0,acceptedTypes:".pdf,.doc,.docx,.jpg,.png"}]}]},{name:"Declarations",showQuestionNumbers:"off",elements:[{type:"panel",title:"7. DECLARATIONS",elements:[{type:"checkbox",name:"declarations",title:"Please accept all declarations:",isRequired:!0,validators:[{type:"expression",expression:"{declarations.length} = 2",text:"You must accept all declarations."}],choices:["I declare all information provided is true.","I agree to abide by Parliament\u2019s Media Code of Conduct."]},{type:"text",name:"signature",title:"Signature",isRequired:!0,requiredErrorText:"Please provide your signature."},{type:"text",name:"signatureDate",title:"Date",inputType:"date",isRequired:!0,requiredErrorText:"Please select the date."}]}]}]};var y=class a extends z{constructor(i){super(i,"/pom-media-accreditation-applications","i
1d")}static \u0275fac=function(e){return new(e||a)(S(F))};static \u0275prov=w({token:a,factory:a.\u0275fac,providedIn:"root"})};function J(a,i){if(a&1){let e=P();m(0,"span",7),D("click",function(){b(e);let n=M();return R(n.logout())}),C(1,"Logout "),u(2,"i",8),p()}}function X(a,i){if(a&1&&(m(0,"div"),u(1,"survey",9),p()),a&2){let e=M();d(),c("model",e.surveyModel)}}function ee(a,i){a&1&&(m(0,"div",10),C(1," Media accreditation submissions are closed "),p())}function te(a,i){a&1&&(m(0,"div",10),C(1," Login to your account to submit your application "),p(),u(2,"app-sign-in"))}var A=class a{applicationService=f(y);notificationService=f(_);dataService=f(B);authService=f(H);title="Media Accreditation Application Form";surveyModel;prevLicenseApplication;isLogged=!1;mediaAccreditationSubmissionOpen=!1;constructor(){}ngOnInit(){let i=this.dataService.config;this.isLogged=this.authService.isLogged(),this.mediaAccreditationSubmissionOpen=i.mediaAccreditationSubmissionOpen&&i.mediaAccreditationSubmissionOpen=="Y";let e=new j(K);this.prevLicenseApplication&&(e.data=this.prevLicenseApplication),e.onUploadFiles.add((o,r)=>{let s=new FormData;r.files.forEach(function(l){s.append(l.name,l)})}),e.onCompleting.add((o,r)=>
1h(this,null,function*(){r.allow=!1,o.showProgressBar=!0,o.clearIncorrectValues(!0),yield this.editForm(o,r)})),e.onComplete.add((o,r)=>h(this,null,function*(){r.showSaveInProgress(),r.showSaveSuccess()})),e.locale="en",e.applyTheme(V),this.surveyModel=e,this.attachValidationLogic();let t=this.surveyModel.getQuestionByName("signature_date");if(t){let o=new I("{signature_date} <= today()");o.text="Date cannot be in the future.",t.validators.push(o)}let n=this.surveyModel.getQuestionByName("requested_end_date");if(n){let o=new I("{requested_end_date} >= {requested_start_date}");o.text="End date must be on or after the start date.",n.validators.push(o)}}editForm(i,e){return h(this,null,function*(){let t=g({},i.data);t.declarationInfoTrue="Y",t.declarationCodeOfConduct="Y",t.passportPhotoUrl=t.passportPhotoUrl[0],delete t.declarations,yield this.applicationService.create(t).then(n=>{i.completedHtml=`
2                      <div style="text-align:center; margin-top:40px;">
3                        <i class="fa fa-check-circle" style="font-size:48px; color:#FF8E9E;"></i>
4                        <h4 style="margin-top:20px;">Application successfully submitted!</h4>
5                        <h4 style="margin-top:20px;">Application ID: <b>`+n.id+`</b></h4>
6                        <h6>Consider saving this ID for future reference.</h6>
7                      </div>
8                    `,e.allow=!0},n=>{this.notificationService.error("Error","Failed to save. Please try again."),i.completedHtml="<h4>Failed to save. Please try again.</h4>",e.allow=!1})})}attachValidationLogic(){this.surveyModel.onServerValidateQuestions.add((i,e)=>{let t=e.data.previousApplicationId;if(!t){i.getQuestionByName("previousApplicationId").readOnly=!1,e.complete();return}this.applicationService.getById(t).then(n=>{if(!n)e.errors.previousApplicationId=`No application found with this ID: ${t}`;else{this.prevLicenseApplication=n;let o=n,{applicationType:r,previousApplicationId:s,passportPhotoUrl:l}=o,v=T(o,["applicationType","previousApplicationId","passportPhotoUrl"]);i.data=g(g({},i.data),v),i.getQuestionByName("previousApplicationId").readOnly=!0,this.notificationService.pomInformation("Info","Edit the loaded data accordingly. Make sure you add new dates and upload latest file(s).")}e.complete()}).catch(()=>{e.errors.previousApplicationId="Error validating application ID. Please try again.",e.complete()})}),this.surveyModel.onValueChanged.add((i,e)=>{if(e.name!=="documents")return;let t=i.getQuestionByName("documents"),n=t.panels,o=new Set;n.forEach(r=>{let s=r.getQuestionByName("documentType");if(!s)return;s.clearErrors();let l=s.value;if(!l)return;let v=typeof l=="string"?l:l.value;o.has(v)?(s.value=null,s.addError("This document type has already been selected.")):o.add(v)}),t.allowAddPanel=n.length<3})}logout(){this.authService.logout()}static \u0275fac=function(e){return new(e||a)};static \u0275cmp=E({type:a,selectors:[["app-media-accreditation-application-form"]],decls:9,vars:5,consts:[[3,"title"],[1,"comments-section"],[1,"comments-title"],[1,"fas","fa-comments"],["class","pull-right cursor-pointer","ngbTooltip","Logout",3,"click",4,"ngIf"],[4,"ngIf"],["class","alert alert-info","role","alert",4,"ngIf"],["ngbTooltip","Logout",1,"pull-right","cursor-pointer",3,"click"],[1,"fas","fa-sign-out-alt"],[3,"model"],["role","alert",1,"alert","alert-info"]],template:function(e,t){e&1&&(u(0,"app-page-title",0),m(1,"div",1)(2,"h3",2),u(3,"i",3),C(4," Media Accreditation Application Form "),x(5,J,3,0,"span",4),p(),x(6,X,2,1,"div",5)(7,ee,2,0,"div",6)(8,te,3,0),p()),e&2&&(c("title",t.title),d(5),c("ngIf",t.isLogged),d(),c("ngIf",t.mediaAccreditationSubmissionOpen&&t.isLogged),d(),c("ngIf",!t.mediaAccreditationSubmissionOpen),d(),N(t.mediaAccreditationSubmissionOpen&&!t.isLogged?8:-1))},dependencies:[Z,W,G,U,q,O,Q,k,L,Y],styles:[".comments-section[_ngcontent-%COMP%]{margin-top:40px;padding:20px;background:snow;border-radius:12px;border:1px solid #f0d7da;box-shadow:0 6px 18px #0000000f;animation:fadeIn .6s ease both}.fa[_ngcontent-%COMP%], .fas[_ngcontent-%COMP%], .far[_ngcontent-%COMP%], .fab[_ngcontent-%COMP%]{color:var(--main-primary)}"]})};var Ne=[{path:"",component:A,data:{title:"Media Accreditation Application Form",breadcrumb:[{label:"Home",url:"/"},{label:"Media Accreditation Application Form",url:""}]}}];export{Ne as MEDIA_ACCREDITATION_FORM_ROUTES};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.