mirror of
https://github.com/ansible/awx.git
synced 2026-05-11 11:27:36 -02:30
Major rename of package from lib to ansibleworks.
This commit is contained in:
39
ansibleworks/ui/static/js/lists/Admins.js
Normal file
39
ansibleworks/ui/static/js/lists/Admins.js
Normal file
@@ -0,0 +1,39 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* Admins.js
|
||||
* List view object for Admins data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('AdminListDefinition', [])
|
||||
.value(
|
||||
'AdminList', {
|
||||
|
||||
name: 'admins',
|
||||
iterator: 'admin',
|
||||
selectTitle: 'Add Administrators',
|
||||
editTitle: 'Admins',
|
||||
selectInstructions: 'Click on a row to select it. Click the Finished button when done.',
|
||||
base: 'users',
|
||||
index: true,
|
||||
|
||||
fields: {
|
||||
username: {
|
||||
key: true,
|
||||
label: 'Username'
|
||||
},
|
||||
first_name: {
|
||||
label: 'First Name'
|
||||
},
|
||||
last_name: {
|
||||
label: 'Last Name'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
}
|
||||
});
|
||||
68
ansibleworks/ui/static/js/lists/Credentials.js
Normal file
68
ansibleworks/ui/static/js/lists/Credentials.js
Normal file
@@ -0,0 +1,68 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* Credentials.js
|
||||
* List view object for Credential data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('CredentialsListDefinition', [])
|
||||
.value(
|
||||
'CredentialList', {
|
||||
|
||||
name: 'credentials',
|
||||
iterator: 'credential',
|
||||
selectTitle: 'Add Credentials',
|
||||
editTitle: 'Credentials',
|
||||
selectInstructions: 'Click on a row to select it, and click Finished when done. Use the green <i class=\"icon-plus\"></i> button to create a new row.',
|
||||
index: true,
|
||||
|
||||
fields: {
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name'
|
||||
},
|
||||
description: {
|
||||
label: 'Description'
|
||||
},
|
||||
team: {
|
||||
label: 'Team',
|
||||
ngBind: 'credential.summary_fields.team.name',
|
||||
sourceModel: 'team',
|
||||
sourceField: 'name'
|
||||
},
|
||||
user: {
|
||||
label: 'User',
|
||||
ngBind: 'credential.summary_fields.user.usename',
|
||||
sourceModel: 'user',
|
||||
sourceField: 'username'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
add: {
|
||||
icon: 'icon-plus',
|
||||
mode: 'all', // One of: edit, select, all
|
||||
ngClick: 'addCredential()',
|
||||
basePaths: ['credentials'], // base path must be in list, or action not available
|
||||
class: 'btn-success',
|
||||
awToolTip: 'Create a new credential'
|
||||
}
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
edit: {
|
||||
ngClick: "editCredential(\{\{ credential.id \}\})",
|
||||
icon: 'icon-edit',
|
||||
class: 'btn-mini',
|
||||
awToolTip: 'View/Edit credential'
|
||||
},
|
||||
|
||||
delete: {
|
||||
ngClick: "deleteCredential(\{\{ credential.id \}\},'\{\{ credential.name \}\}')",
|
||||
icon: 'icon-remove',
|
||||
class: 'btn-mini btn-danger',
|
||||
awToolTip: 'Delete credential'
|
||||
}
|
||||
}
|
||||
});
|
||||
55
ansibleworks/ui/static/js/lists/Groups.js
Normal file
55
ansibleworks/ui/static/js/lists/Groups.js
Normal file
@@ -0,0 +1,55 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* Groups.js
|
||||
* List view object for Group data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('GroupListDefinition', [])
|
||||
.value(
|
||||
'GroupList', {
|
||||
|
||||
name: 'groups',
|
||||
iterator: 'group',
|
||||
selectTitle: 'Add Group',
|
||||
editTitle: 'Groups',
|
||||
selectInstructions: 'Click on a row to select it, and click Finished when done. Use the green <i class=\"icon-plus\"></i> button to create a new row.',
|
||||
index: true,
|
||||
|
||||
fields: {
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name'
|
||||
},
|
||||
description: {
|
||||
label: 'Description'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
add: {
|
||||
icon: 'icon-plus',
|
||||
mode: 'all', // One of: edit, select, all
|
||||
ngClick: 'addGroup()',
|
||||
class: 'btn-success',
|
||||
awToolTip: 'Create a new group'
|
||||
}
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
edit: {
|
||||
ngClick: "editGroup(\{\{ group.id \}\})",
|
||||
icon: 'icon-edit',
|
||||
class: 'btn-mini',
|
||||
awToolTip: 'View/Edit group'
|
||||
},
|
||||
|
||||
delete: {
|
||||
ngClick: "deleteGroup(\{\{ group.id \}\},'\{\{ group.name \}\}')",
|
||||
icon: 'icon-remove',
|
||||
class: 'btn-mini btn-danger',
|
||||
awToolTip: 'Delete group'
|
||||
}
|
||||
}
|
||||
});
|
||||
55
ansibleworks/ui/static/js/lists/Hosts.js
Normal file
55
ansibleworks/ui/static/js/lists/Hosts.js
Normal file
@@ -0,0 +1,55 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* Hosts.js
|
||||
* List view object for Users data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('HostListDefinition', [])
|
||||
.value(
|
||||
'HostList', {
|
||||
|
||||
name: 'hosts',
|
||||
iterator: 'host',
|
||||
selectTitle: 'Add Host',
|
||||
selectInstructions: 'Click on a row to select it, and click Finished when done. Use the green <i class=\"icon-plus\"></i> button to create a new row.',
|
||||
editTitle: 'Hosts',
|
||||
index: true,
|
||||
|
||||
fields: {
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name'
|
||||
},
|
||||
description: {
|
||||
label: 'Description'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
add: {
|
||||
icon: 'icon-plus',
|
||||
mode: 'all', // One of: edit, select, all
|
||||
ngClick: 'addHost()',
|
||||
class: 'btn-success',
|
||||
awToolTip: 'Create a new host'
|
||||
}
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
edit: {
|
||||
ngClick: "editHost(\{\{ host.id \}\})",
|
||||
icon: 'icon-edit',
|
||||
class: 'btn-mini',
|
||||
awToolTip: 'View/Edit host'
|
||||
},
|
||||
|
||||
delete: {
|
||||
ngClick: "deleteHost(\{\{ host.id \}\},'\{\{ host.name \}\}')",
|
||||
icon: 'icon-remove',
|
||||
class: 'btn-mini btn-danger',
|
||||
awToolTip: 'Delete host'
|
||||
}
|
||||
}
|
||||
});
|
||||
61
ansibleworks/ui/static/js/lists/Inventories.js
Normal file
61
ansibleworks/ui/static/js/lists/Inventories.js
Normal file
@@ -0,0 +1,61 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* Inventories.js
|
||||
* List view object for Inventories data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('InventoriesListDefinition', [])
|
||||
.value(
|
||||
'InventoryList', {
|
||||
|
||||
name: 'inventories',
|
||||
iterator: 'inventory',
|
||||
selectTitle: 'Add Inventories',
|
||||
editTitle: 'Inventories',
|
||||
selectInstructions: 'Click on a row to select it, and click Finished when done. Use the green <i class=\"icon-plus\"></i> button to create a new row.',
|
||||
index: true,
|
||||
|
||||
fields: {
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name'
|
||||
},
|
||||
description: {
|
||||
label: 'Descriptions'
|
||||
},
|
||||
organization: {
|
||||
label: 'Organization',
|
||||
ngBind: 'inventory.summary_fields.organization.name',
|
||||
sourceModel: 'organization',
|
||||
sourceField: 'name'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
add: {
|
||||
icon: 'icon-plus',
|
||||
mode: 'all', // One of: edit, select, all
|
||||
ngClick: 'addInventory()',
|
||||
class: 'btn-success',
|
||||
awToolTip: 'Create a new row'
|
||||
}
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
edit: {
|
||||
ngClick: "editInventory(\{\{ inventory.id \}\})",
|
||||
icon: 'icon-edit',
|
||||
class: 'btn-mini',
|
||||
awToolTip: 'View/Edit inventory'
|
||||
},
|
||||
|
||||
delete: {
|
||||
ngClick: "deleteInventory(\{\{ inventory.id \}\},'\{\{ inventory.name \}\}')",
|
||||
icon: 'icon-remove',
|
||||
class: 'btn-mini btn-danger',
|
||||
awToolTip: 'Delete'
|
||||
}
|
||||
}
|
||||
});
|
||||
62
ansibleworks/ui/static/js/lists/JobTemplates.js
Normal file
62
ansibleworks/ui/static/js/lists/JobTemplates.js
Normal file
@@ -0,0 +1,62 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* JobTemplates.js
|
||||
* List view object for Job Templates data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('JobTemplatesListDefinition', [])
|
||||
.value(
|
||||
'JobTemplateList', {
|
||||
|
||||
name: 'job_templates',
|
||||
iterator: 'job_template',
|
||||
selectTitle: 'Add Job Template',
|
||||
editTitle: 'Job Templates',
|
||||
selectInstructions: 'Click on a row to select it, and click Finished when done. Use the green <i class=\"icon-plus\"></i> button to create a new row.',
|
||||
index: true,
|
||||
|
||||
fields: {
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name'
|
||||
},
|
||||
description: {
|
||||
label: 'Description'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
add: {
|
||||
icon: 'icon-plus',
|
||||
mode: 'all', // One of: edit, select, all
|
||||
ngClick: 'addJobTemplate()',
|
||||
class: 'btn-success',
|
||||
basePaths: ['job_templates'],
|
||||
awToolTip: 'Create a new template'
|
||||
}
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
edit: {
|
||||
ngClick: "editJobTemplate(\{\{ job_template.id \}\})",
|
||||
icon: 'icon-edit',
|
||||
awToolTip: 'View/Edit template',
|
||||
class: 'btn-mini'
|
||||
},
|
||||
submit: {
|
||||
icon: 'icon-play',
|
||||
mode: 'all',
|
||||
class: 'btn-mini btn-success',
|
||||
ngClick: 'submitJob(\{\{ job_template.id \}\})',
|
||||
awToolTip: 'Create and run a job using this template'
|
||||
},
|
||||
delete: {
|
||||
ngClick: "deleteJobTemplate(\{\{ job_template.id \}\},'\{\{ job_template.name \}\}')",
|
||||
icon: 'icon-remove',
|
||||
class: 'btn-danger btn-mini',
|
||||
awToolTip: 'Delete template'
|
||||
}
|
||||
}
|
||||
});
|
||||
85
ansibleworks/ui/static/js/lists/Jobs.js
Normal file
85
ansibleworks/ui/static/js/lists/Jobs.js
Normal file
@@ -0,0 +1,85 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* Jobs.js
|
||||
* List view object for Team data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('JobsListDefinition', [])
|
||||
.value(
|
||||
'JobList', {
|
||||
|
||||
name: 'jobs',
|
||||
iterator: 'job',
|
||||
editTitle: 'Jobs',
|
||||
index: false,
|
||||
hover: true,
|
||||
class: 'jobs-table',
|
||||
|
||||
fields: {
|
||||
id: {
|
||||
label: 'Job ID',
|
||||
key: true,
|
||||
desc: true,
|
||||
searchType: 'int'
|
||||
},
|
||||
name: {
|
||||
label: 'Name',
|
||||
link: true,
|
||||
},
|
||||
created: {
|
||||
label: 'Creation Date',
|
||||
link: true
|
||||
},
|
||||
status: {
|
||||
label: 'Status',
|
||||
icon: 'icon-circle',
|
||||
class: 'job-\{\{ job.status \}\}'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
refresh: {
|
||||
ngClick: "refreshJob(\{\{ job.id \}\})",
|
||||
icon: 'icon-refresh',
|
||||
awToolTip: 'Refresh the page',
|
||||
mode: 'all'
|
||||
}
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
edit: {
|
||||
ngClick: "editJob(\{\{ job.id \}\})",
|
||||
icon: 'icon-edit',
|
||||
class: 'btn-mini',
|
||||
awToolTip: 'View/Edit detail',
|
||||
},
|
||||
summary: {
|
||||
title: 'Summary',
|
||||
icon: 'icon-filter',
|
||||
ngClick: 'viewSummary(\{{ job.id \}\})',
|
||||
class: 'btn-success btn-mini',
|
||||
awToolTip: 'View host summary',
|
||||
ngDisabled: "job.status == 'new'"
|
||||
},
|
||||
events: {
|
||||
title: 'Detail',
|
||||
icon: 'icon-list-ul',
|
||||
mode: 'all',
|
||||
ngClick: 'viewEvents(\{{ job.id \}\})',
|
||||
class: 'btn-success btn-mini',
|
||||
awToolTip: 'View events',
|
||||
ngDisabled: "job.status == 'new'"
|
||||
},
|
||||
cancel: {
|
||||
title: 'Cancel',
|
||||
icon: 'icon-minus-sign',
|
||||
mode: 'all',
|
||||
ngClick: 'deleteJob(\{\{ job.id \}\})',
|
||||
class: 'btn-danger btn-mini',
|
||||
awToolTip: 'Cancel job',
|
||||
ngDisabled: "job.status == 'error' || job.status == 'failed' || job.status == 'success'"
|
||||
}
|
||||
}
|
||||
});
|
||||
54
ansibleworks/ui/static/js/lists/Organizations.js
Normal file
54
ansibleworks/ui/static/js/lists/Organizations.js
Normal file
@@ -0,0 +1,54 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* Organizations.js
|
||||
* List view object for Organizations data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('OrganizationListDefinition', [])
|
||||
.value(
|
||||
'OrganizationList', {
|
||||
|
||||
name: 'organizations',
|
||||
iterator: 'organization',
|
||||
selectTitle: 'Add Organizations',
|
||||
editTitle: 'Organizations',
|
||||
index: true,
|
||||
|
||||
fields: {
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name'
|
||||
},
|
||||
description: {
|
||||
label: 'Description'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
add: {
|
||||
icon: 'icon-plus',
|
||||
mode: 'all', // One of: edit, select, all
|
||||
ngClick: 'addOrganization()',
|
||||
class: 'btn-success',
|
||||
awToolTip: 'Create a new row'
|
||||
}
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
edit: {
|
||||
ngClick: "editOrganization(\{\{ organization.id \}\})",
|
||||
icon: 'icon-edit',
|
||||
class: 'btn-mini',
|
||||
awToolTip: 'View/Edit organization'
|
||||
},
|
||||
|
||||
delete: {
|
||||
ngClick: "deleteOrganization(\{\{ organization.id \}\},'\{\{ organization.name \}\}')",
|
||||
icon: 'icon-remove',
|
||||
class: 'btn-mini btn-danger',
|
||||
awToolTip: 'Delete organization'
|
||||
}
|
||||
}
|
||||
});
|
||||
55
ansibleworks/ui/static/js/lists/Projects.js
Normal file
55
ansibleworks/ui/static/js/lists/Projects.js
Normal file
@@ -0,0 +1,55 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* Projects.js
|
||||
* List view object for Project data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('ProjectsListDefinition', [])
|
||||
.value(
|
||||
'ProjectList', {
|
||||
|
||||
name: 'projects',
|
||||
iterator: 'project',
|
||||
selectTitle: 'Add Project',
|
||||
editTitle: '{{ name }}',
|
||||
selectInstructions: 'Click on a row to select it, and click Finished when done. Use the green <i class=\"icon-plus\"></i> button to create a new row.',
|
||||
index: true,
|
||||
|
||||
fields: {
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name'
|
||||
},
|
||||
description: {
|
||||
label: 'Descriptions'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
add: {
|
||||
icon: 'icon-plus',
|
||||
mode: 'all', // One of: edit, select, all
|
||||
ngClick: 'addProject()',
|
||||
class: 'btn-success',
|
||||
awToolTip: 'Create a new project'
|
||||
}
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
edit: {
|
||||
ngClick: "editProject(\{\{ project.id \}\})",
|
||||
icon: 'icon-edit',
|
||||
class: 'btn-mini',
|
||||
awToolTip: 'View/edit project'
|
||||
},
|
||||
|
||||
delete: {
|
||||
ngClick: "deleteProject(\{\{ project.id \}\},'\{\{ project.name \}\}')",
|
||||
icon: 'icon-remove',
|
||||
class: 'btn-mini btn-danger',
|
||||
awToolTip: 'Delete project'
|
||||
}
|
||||
}
|
||||
});
|
||||
61
ansibleworks/ui/static/js/lists/Teams.js
Normal file
61
ansibleworks/ui/static/js/lists/Teams.js
Normal file
@@ -0,0 +1,61 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* Teams.js
|
||||
* List view object for Team data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('TeamsListDefinition', [])
|
||||
.value(
|
||||
'TeamList', {
|
||||
|
||||
name: 'teams',
|
||||
iterator: 'team',
|
||||
selectTitle: 'Add Team',
|
||||
editTitle: 'Teams',
|
||||
selectInstructions: 'Click on a row to select it, and click Finished when done. Use the green <i class=\"icon-plus\"></i> button to create a new row.',
|
||||
index: true,
|
||||
|
||||
fields: {
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name'
|
||||
},
|
||||
description: {
|
||||
label: 'Descriptions'
|
||||
},
|
||||
organization: {
|
||||
label: 'Organization',
|
||||
ngBind: 'team.organization_name',
|
||||
sourceModel: 'organization',
|
||||
sourceField: 'name'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
add: {
|
||||
icon: 'icon-plus',
|
||||
mode: 'all', // One of: edit, select, all
|
||||
ngClick: 'addTeam()',
|
||||
class: 'btn-success',
|
||||
awToolTip: 'Create a new team'
|
||||
}
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
edit: {
|
||||
ngClick: "editTeam(\{\{ team.id \}\})",
|
||||
icon: 'icon-edit',
|
||||
class: 'btn-mini',
|
||||
awToolTip: 'View/Edit team'
|
||||
},
|
||||
|
||||
delete: {
|
||||
ngClick: "deleteTeam(\{\{ team.id \}\},'\{\{ team.name \}\}')",
|
||||
icon: 'icon-remove',
|
||||
class: 'btn-mini btn-danger',
|
||||
awToolTip: 'Delete team'
|
||||
}
|
||||
}
|
||||
});
|
||||
60
ansibleworks/ui/static/js/lists/Users.js
Normal file
60
ansibleworks/ui/static/js/lists/Users.js
Normal file
@@ -0,0 +1,60 @@
|
||||
/*********************************************
|
||||
* Copyright (c) 2013 AnsibleWorks, Inc.
|
||||
*
|
||||
* Users.js
|
||||
* List view object for Users data model.
|
||||
*
|
||||
*
|
||||
*/
|
||||
angular.module('UserListDefinition', [])
|
||||
.value(
|
||||
'UserList', {
|
||||
|
||||
name: 'users',
|
||||
iterator: 'user',
|
||||
selectTitle: 'Add Users',
|
||||
editTitle: 'Users',
|
||||
selectInstructions: 'Check the Select checkbox next to each user to be added, and click Finished when done. Use the green <i class=\"icon-plus\"></i> button to create a new user.',
|
||||
editInstructions: 'Create new users from the Organizations tab. Each Organization has an associated list of Users.',
|
||||
index: true,
|
||||
|
||||
fields: {
|
||||
username: {
|
||||
key: true,
|
||||
label: 'Username'
|
||||
},
|
||||
first_name: {
|
||||
label: 'First Name'
|
||||
},
|
||||
last_name: {
|
||||
label: 'Last Name'
|
||||
}
|
||||
},
|
||||
|
||||
actions: {
|
||||
add: {
|
||||
icon: 'icon-plus',
|
||||
mode: 'select', // One of: edit, select, all
|
||||
ngClick: 'addUser()',
|
||||
basePaths: ['organizations'], // base path must be in list, or action not available
|
||||
class: 'btn-success',
|
||||
awToolTip: 'Create a new user'
|
||||
}
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
edit: {
|
||||
ngClick: "editUser(\{\{ user.id \}\})",
|
||||
icon: 'icon-edit',
|
||||
class: 'btn-mini',
|
||||
awToolTip: 'View/Edit user'
|
||||
},
|
||||
|
||||
delete: {
|
||||
ngClick: "deleteUser(\{\{ user.id \}\},'\{\{ user.username \}\}')",
|
||||
icon: 'icon-remove',
|
||||
class: 'btn-mini btn-danger',
|
||||
awToolTip: 'Delete user'
|
||||
}
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user