angular.module("sn.$sp").constant('GlideConstant', {

    RESPONSE_TYPE: {
        MESSAGE: 'message',
        RECORD: 'record',
        RECORDS: 'records',
        ERROR: 'error'
    },
    PAGES: {
        "OEM_ADDENDUM": "oem_addendum",
        "SP_ADDENDUM": "sp_addendum",
        "REVIEW": "onboard_app_review",
        "PROGRAM_SELECTION": "program_selection",
        "PROGRAM_QUESTIONS": 'program_questions',
        "COMPLIANCE_QUESTIONS": 'compliance_questions',
        "CREDIT_CHECK": "credit_check",
        "THANK_YOU": "onboard_thank_you",
    },
    PROGRAMS: {
        SALES: 'sales',
        SERVICES: 'services',
        SERVICE_PROVIDER: 'Serviceprovider',
        TECHNOLOGY: 'technology',
        OEM: "OEM",
        PUBLIC_SECTOR: "PublicSector"
    },
    OnboardingSteps: {
        'Step_0': 'existing_partner_start',
        'Step_1': 'contact_info_entered',
        'Step_2': 'nda_accepted',
        'Step_3': 'program_info_entered',
        'Step_4': 'partner_agreements_accepted',
        'Thankyou': 'onboard_thank_you',
        'pmtareSignRequired': 'pmta_resign_required',
        'isComplainceRequired': 'compliance_questions',
        'isPreComplainceThankyou': 'isPreComplainceThankyou',
        'isAccountReviewBeforeCompliance': 'isAccountReviewBeforeCompliance',
        'complaince_info_entered': 'complaince_info_entered',
        'legal_questions_completed': 'legal_questions_completed',
        "compliance_certification_completed": "compliance_certification_completed",
        'reviewApplication': 'review_application'
    },
    OnboardinMessages: {
        'Thankyou_reg_complete': '<div class="row first-row"><div class="col s12 page-headings"> <span class="underline-acapulco">R</span>egistration Complete</div></div><div class="row"><div class="col s12 page-sub-headings"> <span class="underline-acapulco">T</span>hank You</div></div><div class="row first-row"><div class="col s12"><p>Thank you for your interest in becoming a ServiceNow partner. We have received your PartnerNow Program application and the signed PartnerNow Master Agreement.</p><p>Your application is currently under review. You will be notified by email of the status of each of the programs to which you have applied, or a ServiceNow representative may contact you with any questions that arise as we continue to process your membership application.</p></div></div> <program-partnership-status></program-partnership-status>',
        'Thankyou_deleg_complete': 'Thank you for completing the delegated task.<br/>The Primary Contact will be notified via email.',

        'Thankyou_resign_complete': '<p class=" row first-row"><div class=" page-sub-headings"> <span class="underline-acapulco">T</span>hank You</div></p>' +
            '<p>THANK YOU! YOUR PARTNER AGREEMENT HAS BEEN UPDATED SUCESSFULLY.</p>' +

            '<p>Thank you,</p>' +
            '<p>Partner Programs Team</p>' +
            '</div>',

        'Thankyou_reg_complete_expand': '<p class="row first-row"><div class=" page-sub-headings"> <span class="underline-acapulco">T</span>hank You</div></p>	<div class="">' +

            '<p></p>' +
            '<p>Thank you for your interest in expanding your ServiceNow partnership. We have received your application to enroll for additional Partner Programs.</p>' +
            '<p></p><br>' +
            '<p>Your application is currently under review. You will be notified by email of your acceptance into each of the programs to which you have applied. A ServiceNow representative may contact you if needed to process your membership application.</p>' +
            '</div>',

        'Thankyou_reg_preComplaince': '<p class="row first-row"><div class=" page-sub-headings"> <span class="underline-acapulco">T</span>hank You</div></p>	<div class="">' +

            '<p></p>' +
            '<p>Thank you for your interest in the ServiceNow Partner Program. We have received your application and is currently under review. You will be notified by email of your acceptance into the program(s) to which you have applied. A ServiceNow representative may contact you if needed to process your membership application.</p>' +

            '</div>',
        'thankyou_oem_app_desc': '<div class="row first-row"><div class="col s12 page-headings"> <span class="underline-acapulco">O</span>EM App Description Complete</div></div><div class="row"><div class="col s12 page-sub-headings"> <span class="underline-acapulco">T</span>hank You</div></div><div class="row first-row"><div class="col s12"><p>Thank you for your completeing the OEM App Desciption</p><p>Your application is currently under review. You will be notified by email of the status or a ServiceNow representative may contact you with any questions that arise as we continue to process your membership application.</p></div></div>'
    }

}).directive('nonEmptyArray', function() {
    return {
        require: 'ngModel',
        link: function(scope, element, attrs, ngModelCtrl) {
            var original = ngModelCtrl.$isEmpty;
            ngModelCtrl.$isEmpty = function(value) {
                return original.call(ngModelCtrl, value) || value.length === 0;
            };
        }
    };
}).constant('STATUS_LABEL_CLASS', {
    "Approved": "green",
    "Cancelled": "red",
    "Closed": "green",
    "Closed Approved": "green",
    "Closed Complete": "green",
    "Closed Incomplete": "red",
    "Closed Rejected": "red",
    "Closed Skipped": "grey",
    "Completed": "green",
    "Current": "green",
	"Declined": "red",
    "Denied": "red",
    "Development": "blue",
    "Draft": "yellow",
    "Expired": "red",
    "Extension Approved": "green",
    "Extension Denied": "red",
    "In Market": "green",
    "Inactive": "red",
    "In-process": "blue",
    "In-progress": "blue",
	"In-Review": "blue",
    "JPP-Plan": "blue",
    "Lost": "red",
    "More information Needed": "orange",
    "No Decision": "red",
    "Open": "blue",
    "Pending": "orange",
    "Pending Approval": "blue",
    "Pending Cancellation": "orange",
    "Pipeline": "yellow",
    "Production": "blue",
    "Rejected": "red",
    "Requested": "blue",
    "Resolved": "green",
    "Review in-progress": "blue",
    "Submitted": "orange",
    "Survey Initiated": "blue",
    "Transitioned": "lite-green",
    "UAT": "blue",
    "Update Required": "yellow",
    "Work in progress": "orange",
    "Add Verification Documents": "green-yellow",
    "Documentation Update Required": "yellow",
    "Verification in progress": "blue",
    "Quote Sent": "yellow",
    "Pending Provision": "orange",
    "PO Review pending": "blue",
    "Provisioned": "green",
    "Withdrawn": "yellow",
	"Not Certified": "red",
	"Certified": "green",
	"Information Not Available": "grey",
	"No Certification Exists": "yellow",
});