Overview
Comment:Fix copy service
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk | stable
Files: files | file ages | folders
SHA3-256: ab0846d7707df1dff88384ee926d184b238d993ba4ef597d723ec8e6099426f3
User & Date: bohwaz on 2022-01-21 01:49:24
Other Links: manifest | tags
References
2022-01-21
01:50 Fixed ticket [5305a614f2]: Recopier depuis une activité plus 4 other changes artifact: e3e232b973 user: bohwaz
Context
2022-01-24
13:14
Fix upgrade process for very slow servers, sometimes it failed after the alter table, not sure why, but this fixes it check-in: b6eefbb81e user: bohwaz tags: trunk, stable
2022-01-21
01:49
Fix copy service check-in: ab0846d770 user: bohwaz tags: trunk, stable
2022-01-20
17:32
Fix datepicker when switching to December from January, fix [9f765f4ab37f5631da5b31ecb8ce7b77da311e61] check-in: c4f649c737 user: bohwaz tags: trunk, stable
Changes

Modified src/www/admin/services/user/add.php from [97a4cefe05] to [b77ee3ba87].

13
14
15
16
17
18
19
20
21
22
23
24

$count_all = Services::count();

if (!$count_all) {
	Utils::redirect(ADMIN_URL . 'services/?CREATE');
}

$services = array_merge([0 => '-- Sélectionner une activité'], Services::listAssoc());

$tpl->assign(compact('services'));

$tpl->display('services/user/add.tpl');







|




13
14
15
16
17
18
19
20
21
22
23
24

$count_all = Services::count();

if (!$count_all) {
	Utils::redirect(ADMIN_URL . 'services/?CREATE');
}

$services = [0 => '-- Sélectionner une activité'] + Services::listAssoc();

$tpl->assign(compact('services'));

$tpl->display('services/user/add.tpl');

Modified src/www/admin/services/user/subscribe.php from [92ce32bd63] to [e4d11cfc89].

28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
	$users = [(int)qg('user') => $name];
}
elseif (f('users') && is_array(f('users')) && count(f('users'))) {
	$users = f('users');
	$users = array_filter($users, 'intval', \ARRAY_FILTER_USE_KEY);
}
elseif (f('copy_service')
	&& $copy_service = Services::get((int)f('copy_service'))) {
	$copy_service_only_paid = (bool) f('copy_service_only_paid');
}
else {
	throw new UserException('Aucun membre n\'a été sélectionné');
}

$form_url = '?';







|







28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
	$users = [(int)qg('user') => $name];
}
elseif (f('users') && is_array(f('users')) && count(f('users'))) {
	$users = f('users');
	$users = array_filter($users, 'intval', \ARRAY_FILTER_USE_KEY);
}
elseif (f('copy_service')
	&& ($copy_service = Services::get((int)f('copy_service')))) {
	$copy_service_only_paid = (bool) f('copy_service_only_paid');
}
else {
	throw new UserException('Aucun membre n\'a été sélectionné');
}

$form_url = '?';