
db={
	id: "healthcheck",
	name: "Best Value Health Check",
	criteria: [
	 {
	   name: "Commitment & Leadership",
	   questions: [
		{text: "Involvement by Executive and Non-Executive leadership in setting the strategic direction", answer:""},
		{text: "The mechanism for internal scrutiny by Executive and Non-Executive leadership of performance and service outcomes", answer:""},
		{text: "Involvement and ownership by Executive and Non-Executive leadership of the vision for the next 3-5 years", answer:""},
		{type: "multi", text: "Extent to which Executive and Non-Executive leadership have discussed and agreed approaches to:",
		 subquestions:[ {text: "Securing continuous improvement", answer:""},
		  		{text: "Demonstrating a customer-focused approach", answer:""},
		  		{text: "Achieving the best balance of cost and quality", answer:""},
		  		{text: "Having regard to economy, efficiency, effectiveness and equal opportunities", answer:""},
		  		{text: "Achieving sustainable development", answer:""}
		 ]
		},
		{text: "Understanding the needs of stakeholders", answer:""},
		{text: "Transparency in setting priorities and assessment of performance against relevant targets", answer:""},
		{text: "Reflection of Best Value principles in all mission statements, strategies, and plans at a corporate and operational level", answer:""},
		{text: "How we work with major partner organisations to provide services that meet stakeholder needs", answer:""},
		{text: "Realism and achievability of objectives, targets, strategies and plans", answer:""},
		{text: "Matching of finance and other resources to meet objectives, targets, strategies and plans", answer:""},
		{text: "Clarity of responsibilities for achieving objectives, and targets and for implementing strategies and plans", answer:""},
		{text: "Extent to which Best Value is integrated into everyday working practices and in developing approach to Best Value at all levels", answer:""},
		{text: "Effectiveness of internal and external performance reporting to ensure accountability and transparency", answer:""},
		{text: "Extent and clarity with which leadership expectations and vision are methodically communicated throughout the organisation by senior  managers", answer:""},
		{text: "Compliance with Ethical Standards in Public Life etc (Scotland) Act (2000)", answer:""},
		{text: "Compliance with The Companies Act (1985)", answer:""},
		{text: "Arrangements for compliance with a local code of conduct based on recognisable standards", answer:""},
		{text: "Policies on Fraud prevention, investigation and whistle blowing", answer:""},
		{text: "Extent to which discussions and decision-making are undertaken in an open, transparent and accessible way", answer:""},
		{text: "Clarity and traceability of documentation of formal decisions", answer:""},
		{text: "Arrangements for compliance with the Freedom of Information (Scotland) Act (2002)", answer:""}
	   ],
	   teamactions: [
		{appliesto: [1,2,3,4,6,7,9,10,11,12,13,14,19], text: "review the way in which senior management engages with the Board or non-executive members and the way in which the organisation sets and monitors its goals and performance", checked: true},
		{appliesto: [5,8], text: "critically assess the management of its relationships with key stakeholders and how it communicates with these groups individually and collectively", checked: true},
		{appliesto: [4,7,9,10,11], text: "check that the organisation has SMART goals and action plans which are owned and acted on by the appropriate people in the organisation", checked: true},
		{appliesto: [15,16,17,18,20,21], text: "conduct an assessment of the organisation, its decision making processes and its management practices against the Nolan principles", checked: true}
	   ],
	   myactions: [
		{appliesto: [1,2,3,4,6,7,9,10,11,12,13,14,15,16,17,18,19,20,21], text: "be clearer about my vision and values and more enthusiastic in my communication of these to everyone involved", checked: true},
		{appliesto: [1,3,5,7,8], text: "increase my engagement with stakeholders, and take responsibility for making important strategic and operational relationships more effective", checked: true},
		{appliesto: [4,5,8,11,14,19], text: "give and receive feedback more regularly on my own and others' performance", checked: true}
	   ]
	 },











	 {
	   name: "Responsiveness and Consultation",
	   questions: [
		{text: "Our Leadership recognises the diversity of customers and stakeholders", answer:""},
		{type: "multi", text: "The extent that we have developed and implemented:",
		 subquestions:[ {text: "an effective and accessible complaints system", answer:""},
		  		{text: "a methodical approach to identifying who to consult ", answer:""},
		  		{text: "how to undertake the consultation most effectively", answer:""},
		  		{text: "a systematic approach for co-ordinating consultation exercises", answer:""},
		  		{text: "sharing information both internally and externally subject to legislative and operational constraints", answer:""},
		  		{text: "links to the regular planning cycle ", answer:""},
		  		{text: "the results of this work in planning, designing and improving services and policy.", answer:""}
		 ]
		},
		{text: "Our consultation exercise objectives are clear with regards to what the organisation seeks to find out", answer:""},
		{text: "Our recommendations for action are clear and maintain the status quo where appropriate", answer:""},
		{text: "The extent our Leadership acknowledge the value of constructive engagement with a wide range of visible and less visible stakeholder", answer:""},
		{text: "How much stakeholders and partners feel that the organisation listens to, and takes account of their views", answer:""},
		{text: "Stakeholders and partners are provided with transparent information about the actions taken through the decision-making process and performance reporting", answer:""},
		{text: "We systematically review the effectiveness of approaches to consultation to ensure that these deliver the required outcomes at a reasonable cost", answer:""}
	   ],
	   teamactions: [
		{appliesto: [1, 2, 3, 4, 5, 6, 7, 8], text: "review the means by which the organisation understands all of its customers and other stakeholders and their needs", checked: true},
		{appliesto: [2, 3, 4, 5, 6, 7, 8], text: "develop an effective consultation strategy for the organisation with customers and other key stakeholder groups", checked: true},
		{appliesto: [1, 4, 5, 6, 7], text: "assess the effectiveness of the organisation’s ongoing engagement and communications with key internal and external stakeholders", checked: true},
		{appliesto: [2, 3, 5, 7, 8], text: "review the means by which consultations, communications and feedback are converted into organisational decisions and actions", checked: true}
	   ],
	   myactions: [
		{appliesto: [1, 2, 5], text: "communicate and inform colleagues of who my key stakeholders are and what their expectations are of the organisation", checked: true},
		{appliesto: [2, 3, 4, 7, 8], text: "ensure that I make my voice heard when shaping and responding through action to consultations with internal and external stakeholders", checked: true},
		{appliesto: [4, 5,6, 7, 8], text: "develop effective and constructive engagement with key stakeholders of immediate relevance to my areas of responsibility", checked: true}
	   ]
	 },



	
	 {
	   name: "Sound Governance at a strategic and Operational Level",
	   questions: [
		{text: "We have developed a corporate plan, which is translated into targets and specific actions at corporate and operational levels", answer:""},
		{text: "The extent that our corporate plan takes account of the Executive’s priorities and policy statements including the Partnership Agreement of May 2003", answer:""},
		{text: "Our plans are clear and cohesive and support policy development and service delivery across the whole organization at operational levels both internally and through service partners", answer:""},
		{type: "multi", text: "Where delivery is through others, we have:",
		 subquestions:[ {text: "Clear statement of roles and responsibilities", answer:""},
		  		{text: "A hierarchy of objectives and targets, aligned to the sponsor bodies objectives", answer:""},
		  		{text: "A system of performance and risk management and reporting.", answer:""}
		 ]
		},
		{text: "A robust framework of corporate governance is in place to manage delivery", answer:""},
		{text: "Service and budget planning processes match the financial, human and operational resources to their priorities", answer:""},
		{text: "Our formulation of indicators allow performance to be assessed as part of the planning process ", answer:""},
		{text: "Our Leadership is regularly informed of progress made. ", answer:""},
		{text: "We take action in the next planning cycle to learn from success and address areas of under-performance", answer:""},
		{text: "Our other key processes are linked to or integrated with the planning cycle", answer:""},
		{text: "Our performance is systematically measured across all areas of activity", answer:""},
		{text: "We know the key processes that determine the delivery of a customer centered, cost-effective approach", answer:""},
		{text: "Our performance management framework for the organisation extends throughout the structures of delivery", answer:""},
		{text: "Our system can track high level objectives through to final delivery outputs and outcomes", answer:""},
		{text: "Our performance information is accurate, up to date, includes relevant trends, comparisons, standards and targets, and is rigorously monitored on a regular basis", answer:""},
		{type: "multi", text: "The performance management system is effective in:",
		 subquestions:[ {text: "addressing areas of under-performance", answer:""},
		  		{text: "identifying the scope for improvement", answer:""},
		  		{text: "agreeing remedial action", answer:""},
		  		{text: "monitoring implementation", answer:""}
		 ]
		},
		{text: "Our comparative analyses are systematically used in order to identify the organisation’s performance potential and to learn from others as appropriate", answer:""},
		{text: "Our performance is reported systematically to Leadership, management, users and the public", answer:""},
		{text: "Any information provided in each case is relevant to its audience and clearly shows whether strategic and operational objectives and targets are being met.", answer:""},
		{text: "Our reports are honest and balanced", answer:""},
		{text: "Reports include information about what improvements are required during the forthcoming period", answer:""}
	   ],
	   teamactions: [
		{appliesto: [1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 19, 20, 21], text: "review its framework for planning, budgeting, monitoring and review in terms of  the clarity of its aims, the specification and alignment of resources with these, and the ultimate achievement of its strategic and operational goals and targets", checked: true},
		{appliesto: [2, 3, 4, 5, 12], text: "critically assess the way in which the organisation engages with delivery partners to ensure consistency, coherence, high performance and top quality service provision for end customers", checked: true},
		{appliesto: [3, 5, 7, 8, 9, 11, 13, 15, 16, 17, 18], text: "review the effectiveness of the performance management and reporting systems in terms of their ability to assist performance evaluation, organisational learning, failure recovery and continuous improvement", checked: true},
		{appliesto: [7, 8, 9, 11, 15, 16, 18, 20], text: "consider the means by which Board or non-Executive members as well as senior managers are kept informed and engage with the way in which performance information is analysed and used to support decision-making", checked: true}
	   ],
	   myactions: [
		{appliesto: [2, 6, 8, 20, 21], text: "review the way in which my ‘local’ planning and budgeting processes are linked to the organisation’s strategic goals and the extent to which our resources are aligned to these corporate aims", checked: true},
		{appliesto: [3, 7, 9, 11, 12, 13, 15, 16, 17], text: "ensure all managers under my supervision are clear about the organisation’s aims and priorities and are able to account for and take responsibility for improving performance year on year", checked: true},
		{appliesto: [1, 3, 4, 5, 8, 10, 14, 18, 19, 20, 21], text: "check to make sure that all of the targets and specific actions for which I am responsible are met and communicated to appropriate audiences", checked: true}
	   ]
	 },





	
	 {
	   name: "Sound Management of Resources and Contractual Relationships",
	   questions: [
		{text: "We have a systematic approach to risk management in relation to the organisation’s resources", answer:""},
		{text: "Our approach cascades down into structures of delivery", answer:""},
		{text: "Management resources are regularly reviewed by Leadership and senior managers across all activities", answer:""},
		{text: "Our employees are treated as a key strategic resource", answer:""},
		{text: "We ensure organisational capacity to implement its plans and make full use of its staff", answer:""},
		{text: "Our staffing requirements are explicitly related to strategic and operational objectives in terms of numbers, skills, knowledge, deployment, and organisational structure", answer:""},
		{text: "All employees are managed effectively and efficiently", answer:""},
		{text: "Our employees know what is expected of them", answer:""},
		{text: "Our employees performance is regularly assessed, and they are assisted in improving", answer:""},
		{text: "Our staff feel they are valued and their skills and knowledge are used fully and effectively", answer:""},
		{text: "We have a systematic approach for identifying and managing risks in relation to workforce matters", answer:""},
		{text: "We match our asset base to its objectives in terms of suitability, and sustainability", answer:""},
		{text: "We develop our asset management plans", answer:""},
		{text: "We ensures fixed assets are managed efficiently and effectively", answer:""},
		{text: "We consider factors such as availability, accessibility, utilisation, cost, condition and depreciation.", answer:""},
		{text: "We ensure there is a strategy for procurement and the management of contracts and contractors", answer:""},
		{text: "We treat procurement as a key component in achieving its objectives, including those relating to sustainable development, equalities, and health and safety", answer:""},
		{text: "We find the most cost effective method for securing the quality of assets and services it needs", answer:""},
		{text: "We ensure that the framing of specifications and the vetting of suppliers is consistent with objectives", answer:""},
		{text: "Appropriate procurement expertise, guidance and training is available to support its procurement activity and contractual relationships", answer:""},
		{text: "Where appropriate, we include a focal point for advice on developments in best practice and procurement law", answer:""},
		{text: "We fully comply with obligations under European Community law on public procurement and any other relevant international agreements.", answer:""},
		{text: "Any burden imposed on suppliers is minimized and consistent with the achievement of best value through effective tender competition.", answer:""},
		{type: "multi", text: "Our effective system for financial stewardship is maintained, in that:",
		 subquestions:[ {text: "Accounts are free from material misstatement ", answer:""},
		  		{text: "They are prepared in accordance with recognised accounting standards", answer:""},
		  		{text: "Sound financial controls minimise the risk of fraud and error", answer:""},
		  		{text: "They comply with specific statutory financial requirements", answer:""},
		  		{text: "Effective management of budgeting, monitoring and reporting is maintained", answer:""},
		  		{text: "Consequences of decisions are assessed at an appropriate level before major financial decisions are taken or agreed", answer:""},
		  		{text: "Feedback on major financial decisions to ensure that planned and anticipated benefits were realized", answer:""},
		  		{text: "Training and support is provided to ensure staff have the skills and information for managing budgets", answer:""},
		  		{text: "Suppliers are paid promptly", answer:""},
		  		{text: "Payment procedures are streamlined using electronic means wherever appropriate", answer:""},
		  		{text: "The organisation has a sound financial position.", answer:""}
		 ]
		},
		{text: "Our trading accounts are prepared and disclosed when required", answer:""}
	   ],
	   teamactions: [
		{appliesto: [1, 2, 3, 4, 6, 7, 11], text: "critically review and assess the effectiveness of the management and development of the organisation’s resources (human, capital, equipment, knowledge etc.) including approach to risk and the appropriateness of the balance between these in delivering key organisational goals", checked: true},
		{appliesto: [5, 8, 9, 10, 12, 13, 14, 15], text: "consider instituting systematic strategic resource reviews (eg HR strategy, Land, and Property Strategy, Capital Assets Strategy, Financial Strategy) staged at appropriate intervals to ensure corporate coherence in relation to resource management", checked: true},
		{appliesto: [16, 17, 18, 19, 20, 21, 23], text: "formally assess the organisation’s strategy and implementation practices for procurement and contractual relationships", checked: true},
		{appliesto: [22, 23, 24, 25], text: "confirm arrangements for compliance with statutory requirements and best practice in relation to the management of financial resources and decision-making", checked: true}
	   ],
	   myactions: [
		{appliesto: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 17, 20, 24], text: "review my ‘local’ approach to staff training, professional development as well as overall workforce planning in my area of responsibility", checked: true},
		{appliesto: [1, 3, 4, 6,  7, 11, 13, 14, 15, 16, 17, 18, 19, 20, 24], text: "ensure my own personal effectiveness and the ability of all managers under my supervision to meet the highest possible standards of financial and other resource management practice", checked: true},
		{appliesto: [15, 19, 21, 22, 23, 24, 25], text: "confirm compliance with legal and other formal standards expected of my operation", checked: true}
	   ]
	 },






	
	 {
	   name: "Use of Review and Option Appraisal",
	   questions: [
		{text: "Our reviews are regularly conducted", answer:""},
		{text: "Reviews are integrated into the organisation’s management arrangements", answer:""},
		{text: "We have rigorous challenging of current policies and approaches", answer:""},
		{text: "Our retained policies and approaches are justified", answer:""},
		{text: "We understand how future stakeholder needs and expectations may change in the future due to the demographic, natural, cultural and socio-economic factors", answer:""},
		{text: "Our systematic reviews concentrate on identified priorities", answer:""},
		{text: "Our reviews of poor performance areas offers clear opportunities for improvements", answer:""},
		{text: "We ensure high levels of service quality is supported", answer:""},
		{text: "Improvement is secured on a continuing basis", answer:""},
		{text: "Future demands are clearly addressed", answer:""},
		{text: "We need to achieve improvement in cross cutting agendas such as equalities, joint working and sustainable development", answer:""},
		{text: "We recognise the value of working with wider stakeholders and partners to achieve effective policy development and service delivery.", answer:""},
		{text: "We conduct a consistent corporate approach which ensures that review teams have the necessary skills, knowledge and aptitudes", answer:""},
		{text: "Our review teams are challenged on their conclusions", answer:""},
		{text: "We demonstrate that the views of stakeholders have been taken into account in analysis and developing recommendations", answer:""},
		{text: "We produce clear recommendations, which are based on analysis and evidence of considerations such as cost, quality and social impact.", answer:""},
		{text: "We develop actions which are clearly described, in sufficient detail to be readily understood", answer:""},
		{text: "Our actions are clearly explained in terms of importance, relevance and priority.", answer:""},
		{text: "Our actions are realistic and achievable", answer:""},
		{text: "Our statements are specific about what improvements are actually intended to achieve", answer:""},
		{text: "Our review activity involves Leadership at key stages ", answer:""},
		{text: "We ensure that Leadership approve the overall process and policies", answer:""},
		{text: "We are monitored by senior management in terms of progress in implementing recommendations / actions on a regular and systematic basis", answer:""},
		{text: "We take account of any guidance/approach agreed with sponsor departments and/or internal management", answer:""},
		{text: "We systematically validate reviews to ensure consistency, efficiency, continuing relevance and delivery of improvements", answer:""}
	   ],
	   teamactions: [
		{appliesto: [1, 2, 7, 13, 18, 21, 22], text: "Ensure reviews are systematic, regular and provide practical feedback by Leaders and managers to employees.", checked: true},
		{appliesto: [3,4,5,14], text: "Identify and challenge current and future weaknesses in the review process with a view to increasing it’s robustness", checked: true},
		{appliesto: [6, 8, 9, 10, 11, 12, 15, 16, 17, 19, 20, 23, 24, 25], text: "Regularly identify methods of improving and enhancing employee performance based on review recommendations.", checked: true}
	   ],
	   myactions: [
		{appliesto: [3, 4, 5, 8, 9, 10, 11, 12, 13, 14, 15, 16, 20], text: "Consider challenging policies to improve the use of review and option appraisal for all of my employees.", checked: true},
		{appliesto: [7, 12, 19], text: "Seek to improve development and opportunities for all of my employees.", checked: true},
		{appliesto: [1, 2, 6, 14, 17, 18, 19, 21, 22, 23, 24, 25], text: "Actively review, enhance & participate in any key issues of the review process to meet the needs of my department and employees.", checked: true}
	   ]
	 },


	
	 {
	   name: "Contribution to Sustainable Development",
	   questions: [
		{text: "Our Leadership is committed to contributing towards the achievement of sustainable development", answer:""},
		{text: "Contributions towards the achievement of sustainable development is reflected in objectives and reflected in all strategies and plans at corporate and operational level", answer:""},
		{text: "Our review activities take account of sustainability issues", answer:""},
		{text: "We assess the impact of policy proposals on sustainable development", answer:""},
		{text: "We account for sustainable development requirements in the procurement strategy", answer:""},
		{text: "Our systematic approach to the management of resources contributes to the achievement of sustainable development", answer:""}
	   ],
	   teamactions: [
		{appliesto: [1,2,3,4,5,6], text: "Recognise that sustainability issues should be addressed at the stages of planning, development, implementation, maintenance and feedback.", checked: true},
		{appliesto: [2, 5, 6], text: "Appropriate strategies recognise the need for sustainable development and are suitably focused on sustainability issues.", checked: true},
		{appliesto: [4], text: "Ensure any likely impact upon sustainable development is assessed, documented and understood", checked: true}
	   ],
	   myactions: [
		{appliesto: [1,2,3], text: "Ensure that all of my employees are aware of sustainability benefits and key issues", checked: true},
		{appliesto: [1, 3, 4, 5, 6], text: "Review and assess the impact of sustainability issues on the organisation.", checked: true}
	   ]
	 },

	 {
	   name: "Equal Opportunities Arrangements",
	   questions: [
		{text: "We have measures that are reflected in our objectives to encourage the observance of equal opportunities requirements", answer:""},
		{text: "Our measures are highlighted in all plans at corporate and service level", answer:""},
		{text: "We recognize the diverse needs of groups in the community ", answer:""},
		{text: "Diverse needs are reflected in programme and service planning, design and improvement", answer:""},
		{type: "multi", text: "Our leadership is committed to mainstream equalities within the Best Value framework when:",
		 subquestions:[ {text: "Undertaking reviews that account for equalities issues", answer:""},
		  		{text: "Assess the impact of policy proposals on equal opportunities", answer:""},
		  		{text: "Equalities requirements are taken into account in the procurement strategy", answer:""},
		  		{text: "Equality performance measures are identified to measure their performance", answer:""},
		  		{text: "Equality performance measures are reported to the public", answer:""},
		  		{text: "Employment policies are fully in line with their commitment to equal opportunities", answer:""},
		  		{text: "Training is in place to support commitment", answer:""}
		 ]
		},
		{text: "Our staff programmes are appropriate to the size and complexity of the organisation’s workforce", answer:""},
		{text: "We ensure that pay and reward systems meet the legislative requirements", answer:""},
		{text: "Our existing areas of discriminatory practice are addressed", answer:""},
		{text: "We take action that is necessary to meet obligations under existing equal opportunities legislation", answer:""},
		{text: "Our Leadership actively encourages opportunities for formal and informal joint working", answer:""},
		{text: "We are committed to working with partner organizations to meet needs of customers and stakeholders", answer:""},
		{type: "multi", text: "Where the partnership is involved in joint delivery it includes:",
		 subquestions:[ {text: "Agreeing respective roles and commitments", answer:""},
		  		{text: "Integrated management of resources where appropriate", answer:""},
		  		{text: "Effective monitoring of collective performance", answer:""},
		  		{text: "Joint problem solving", answer:""}
		 ]
		},
		{text: "Our Leadership address barriers, which inhibit integrated approaches to joint funding and joint management of activities with internal and external partners.", answer:""},
		{type: "multi", text: "Our appraisal of the benefits of joint working accounts for:",
		 subquestions:[ {text: "Wider policy issues", answer:""},
		  		{text: "Current agendas", answer:""},
		  		{text: "Any potential impact on equal opportunities and sustainable development.", answer:""}
		 ]
		},
		{text: "We participate effectively in Community Planning Partnerships and other joint working initiatives where obligated", answer:""},
		{text: "We integrate and progress the Community Partnership joint vision and joint objectives into the planning mechanisms when legally obligated", answer:""},
		{text: "We work transparently with internal and external partners towards objectives and performance management and reporting mechanisms", answer:""},
		{text: "We share information", answer:""},
		{text: "We seek to develop data compatibility with partners", answer:""},
		{text: "We respond to opportunities to aggregate procurement demand with partners", answer:""}
	   ],
	   teamactions: [
		{appliesto: [1, 2, 6], text: "Implement sound measures of equal opportunities to assess their impact on the organisation", checked: true},
		{appliesto: [1,2,3,4,5,7,8], text: "Ensure that equal opportunities are acknowledged in all aspects of the organisation", checked: true},
		{appliesto: [7,8,9], text: "Regularly review and assess areas of discrimination", checked: true},
		{appliesto: [3,4,5,7,8,9], text: "Introduce methods of enhancing and improving equal opportunities in all areas of the organisation.", checked: true}
	   ],
	   myactions: [
		{appliesto: [5,7,8,9], text: "Regularly review, assess and implement legislation that applies to my employees.", checked: true},
		{appliesto: [1, 2, 3, 4, 6], text: "Consider widening the scope of equal opportunities in my department", checked: true}
	   ]
	 },



	 {
	   name: "Joint Working",
	   questions: [
		{text: "Our Leadership actively encourages opportunities for formal and informal joint working", answer:""},
		{text: "We are committed to working with partner organizations to meet needs of customers and stakeholders", answer:""},
		{type: "multi", text: "Where the partnership is involved in joint delivery it includes:",
		 subquestions:[ {text: "Agreeing respective roles and commitments", answer:""},
		  		{text: "Integrated management of resources where appropriate", answer:""},
		  		{text: "Effective monitoring of collective performance", answer:""},
		  		{text: "Joint problem solving", answer:""}
		 ]
		},
		{text: "Our Leadership address barriers which inhibit integrated approaches to joint funding and joint management of activities with internal and external partners.", answer:""},
		{type: "multi", text: "Our appraisal of the benefits of joint working accounts for:",
		 subquestions:[ {text: "Wider policy issues", answer:""},
		  		{text: "Current agendas", answer:""},
		  		{text: "Any potential impact on equal opportunities and sustainable development.", answer:""}
		 ]
		},
		{text: "We participate effectively in Community Planning Partnerships and other joint working initiatives where obligated", answer:""},
		{text: "We integrate and progress the Community Partnership joint vision and joint objectives into the planning mechanisms when legally obligated", answer:""},
		{text: "We work transparently with internal and external partners towards objectives and performance management and reporting mechanisms", answer:""},
		{text: "We share information", answer:""},
		{text: "We seek to develop data compatibility with partners", answer:""},
		{text: "We respond to opportunities to aggregate procurement demand with partners", answer:""}
	   ],
	   teamactions: [
		{appliesto: [1,2,3,4,5,6,7,8], text: "All plans and strategies recognise and identify suitable partnerships", checked: true},
		{appliesto: [8,9,10,11], text: "Relevant information is made available to all joint partners in an equitable and transparent manner", checked: true}
	   ],
	   myactions: [
		{appliesto: [1,2, 3, 6, 7, 8, 11], text: "Regularly assess and encourage joint working opportunities amongst my employees and other agencies", checked: true},
		{appliesto: [4,5,8, 9,10], text: "Identify and provide solutions to gaps in effective joint partnership working", checked: true}
	   ]
	 },


	



	 {
	   name: "Accountability",
	   questions: [
		{text: "We identify what information stakeholders need in order to form a clear view on performance ", answer:""},
		{text: "We recognise that different sections of the community will need different information and responses", answer:""},
		{text: "Our present information is in a form that people find useful and accessible", answer:""},
		{text: "Arrangements are in place to secure Best Value under the terms of the Public Finance and Accountability Act (2000)", answer:""}
	   ],
	   teamactions: [
		{appliesto: [1,3,4], text: "Ensure financial statements are consistent with legislative requirements and UK GAAP.", checked: true},
		{appliesto: [1,2,3], text: "Make financial information publicly available through a wide variety of communication vehicles.", checked: true}
	   ],
	   myactions: [
		{appliesto: [1,2,3,4], text: "Ensure that suitably qualified and experienced personnel prepare the financial statements.", checked: true}
	   ]
	 }



/*
	 {
	   name: "",
	   questions: [
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{type: "multi", text: "",
		 subquestions:[ {text: "", answer:""},
		  		{text: "", answer:""},
		  		{text: "", answer:""},
		  		{text: "", answer:""},
		  		{text: "", answer:""}
		 ]
		},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""},
		{text: "", answer:""}
	   ],
	   teamactions: [
		{appliesto: [], text: "", checked: true},
		{appliesto: [], text: "", checked: true},
		{appliesto: [], text: "", checked: true},
		{appliesto: [], text: "", checked: true}
	   ],
	   myactions: [
		{appliesto: [], text: "", checked: true},
		{appliesto: [], text: "", checked: true},
		{appliesto: [], text: "", checked: true}
	   ]
	 }
*/
	]
}





	// copy the answers from a long comma-separated string into the database
	function stringtoanswers(criterion, answerstring) {
		if (answerstring=='') return
		var answers=answerstring.split(',')
		var answersi=0
		var i=criterion

		for (var j=0;j<db.criteria[i].questions.length;j++) {
			var question=db.criteria[i].questions[j]
			if (question.type=="multi") {
				for (var k=0;k<question.subquestions.length;k++) {
					question.subquestions[k].answer=answers[answersi++]
				}
			}
			else {
				question.answer=answers[answersi++]
			}
		}
	}

	function answerstostring(criterion) {
		var answers=[]
		var i=criterion

		for (var j=0;j<db.criteria[i].questions.length;j++) {
			var question=db.criteria[i].questions[j]
			if (question.type=="multi") {
				for (var k=0;k<question.subquestions.length;k++) {
					answers.push(question.subquestions[k].answer)
				}
			}
			else {
				answers.push(question.answer)
			}
		}
		return answers.join(',')
	}


	//=======================================
	function stringtoactions(criterion,type, str) {
		var tickedactions=str.split(',')

		for (var i=0;i<db.criteria[criterion][type+'actions'].length;i++) {

			var action=db.criteria[criterion][type+'actions'][i]
			if (inArray(i.toString(),tickedactions)) action.checked=true
			else action.checked=false
		}
	}



	function inArray (needle,haystack) {
		for (var i=0; i < haystack.length; i++) {
			if (haystack[i] === needle) return true
		}
		return false;
	};
