Proyectos de Subversion LeadersLinked - Backend

Rev

Rev 11438 | Rev 11486 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 11438 Rev 11467
Línea 5... Línea 5...
5
import axios from 'axios'
5
import axios from 'axios'
6
import { addNotification } from '../../../redux/notification/notification.actions'
6
import { addNotification } from '../../../redux/notification/notification.actions'
7
import ContentTitle from '../../../shared/ContentTitle'
7
import ContentTitle from '../../../shared/ContentTitle'
8
import { LengthFilter, SearchInput, Table, TablePagination } from '../../../recruitment_and_selection/components/TableComponents'
8
import { LengthFilter, SearchInput, Table, TablePagination } from '../../../recruitment_and_selection/components/TableComponents'
9
import DeleteModal from '../../../shared/DeleteModal'
9
import DeleteModal from '../../../shared/DeleteModal'
10
import { useHistory } from 'react-router-dom'
-
 
11
import EditAndAddModal from '../components/objetives_and_goals/EditAndAddModal'
10
import EditAndAddModal from '../components/objetives_and_goals/EditAndAddModal'
Línea 12... Línea 11...
12
 
11
 
13
const headers = [
12
const headers = [
14
	{ key: 'title', label: 'Nombre', isSorteable: true },
13
	{ key: 'title', label: 'Nombre', isSorteable: true },
Línea 18... Línea 17...
18
	{ key: 'cost', label: 'Costo', isSorteable: true },
17
	{ key: 'cost', label: 'Costo', isSorteable: true },
19
	{ key: 'status', label: 'Estatus', isSorteable: true },
18
	{ key: 'status', label: 'Estatus', isSorteable: true },
20
	{ key: 'actions', label: 'Acciones', isSorteable: false }
19
	{ key: 'actions', label: 'Acciones', isSorteable: false }
21
]
20
]
Línea 22... Línea 21...
22
 
21
 
Línea 23... Línea 22...
23
const ObjectivesAndGoals = ({ add_link, table_link, permisions, setExternalLink }) => {
22
const ObjectivesAndGoals = ({ add_link, table_link, permisions }) => {
24
 
-
 
25
	const dispatch = useDispatch()
23
 
26
	const history = useHistory()
24
	const dispatch = useDispatch()
27
	const [modalToShow, setModalToShow] = useState('')
25
	const [modalToShow, setModalToShow] = useState('')
28
	const [actionLink, setActionLink] = useState(add_link)
26
	const [actionLink, setActionLink] = useState(add_link)
29
	const [items, setItems] = useState([])
27
	const [items, setItems] = useState([])
Línea 107... Línea 105...
107
										{
105
										{
108
											permisions.allowAdd
106
											permisions.allowAdd
109
                                            &&
107
                                            &&
110
                                            <label
108
                                            <label
111
                                            	className='d-flex align-items-center'
109
                                            	className='d-flex align-items-center'
-
 
110
                                            	onClick={() => {
112
                                            	onClick={() => setModalToShow('add')}
111
                                            		setModalToShow('add')
-
 
112
                                            		setActionLink(add_link)
-
 
113
                                            	}}
113
                                            	style={{ cursor: 'pointer' }}
114
                                            	style={{ cursor: 'pointer' }}
114
                                            >
115
                                            >
115
                                            	<i className="fa fa-plus mr-2" />
116
                                            	<i className="fa fa-plus mr-2" />
116
                                                Agregar
117
                                                Agregar
117
                                            </label>
118
                                            </label>
Línea 171... Línea 172...
171
                                                		<td>
172
                                                		<td>
172
                                                			<div className="d-flex align-items-center" style={{ gap: '5px' }}>
173
                                                			<div className="d-flex align-items-center" style={{ gap: '5px' }}>
173
                                                				{
174
                                                				{
174
                                                					permisions.allowObjective
175
                                                					permisions.allowObjective
175
                                                                    &&
176
                                                                    &&
176
                                                                    <i
-
 
177
                                                                    	className='fa fa-level-down'
-
 
178
                                                                    	onClick={() => {
-
 
179
                                                                    		setExternalLink(item.actions.link_objective)
177
                                                                    <a href={item.actions.link_objective} style={{ color: '#333' }}>
180
                                                                    		history.push('/goals')
-
 
181
                                                                    	}}
-
 
182
                                                                    	style={{ cursor: 'pointer' }}
178
                                                                    	<i className='fa fa-level-down' />
183
                                                                    />
179
                                                                    </a>
184
                                                				}
180
                                                				}
185
                                                				{
181
                                                				{
186
                                                					permisions.allowEdit
182
                                                					permisions.allowEdit
187
                                                                    &&
183
                                                                    &&
188
                                                                    <i
184
                                                                    <i