MCPcopy
hub / github.com/chartbrew/chartbrew / create

Method create

server/controllers/ChartController.js:99–112  ·  view source on GitHub ↗
(data, user)

Source from the content-addressed store, hash-verified

97 }
98
99 create(data, user) {
100 return db.Chart.create({ ...data, chartDataUpdated: moment() })
101 .then((chart) => {
102 // delete chart cache
103 if (user) {
104 this.chartCache.remove(user.id, chart.id);
105 }
106
107 return this.findById(chart.id);
108 })
109 .catch((error) => {
110 return new Promise((resolve, reject) => reject(error));
111 });
112 }
113
114 findAll(conditions = {}) {
115 return db.Chart.findAll(conditions)

Callers 15

index.jsFile · 0.45
getOrchestrationFunction · 0.45
createFunction · 0.45
updateFunction · 0.45
addIntegrationFunction · 0.45
createTeamMethod · 0.45
addTeamRoleMethod · 0.45
saveTeamInviteMethod · 0.45
createApiKeyMethod · 0.45
deleteApiKeyMethod · 0.45
createSharePolicyFunction · 0.45

Calls 2

findByIdMethod · 0.95
removeMethod · 0.45

Tested by 9

seedStripeTemplateSetupFunction · 0.36
seedJiraTemplateSetupFunction · 0.36
createOwnedConversationFunction · 0.36
seedDatasetScopedAccessFunction · 0.36
createTemplateProjectFunction · 0.36
seedProjectScopedAccessFunction · 0.36
seedPublicChartFunction · 0.36