mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
ui-default: init
将ui-default合并至主存储库便于维护
This commit is contained in:
1 parent
6317c9057f
commit
5faa54c7ca
564 files changed
+23083
-14
No files matched your search
@@ -0,0 +1,18 @@
|
||||
import { NamedPage } from 'vj/misc/Page';
|
||||
import * as domainEnum from 'vj/constant/domain';
|
||||
|
||||
const page = new NamedPage('domain_join_applications', () => {
|
||||
const $role = $('[name="role"]');
|
||||
const $expire = $('[name="expire"]');
|
||||
const $code = $('[name="invitationCode"]');
|
||||
function updateFormState() {
|
||||
const method = parseInt($('[name="method"]').val(), 10);
|
||||
$role.prop('disabled', method === domainEnum.JOIN_METHOD_NONE).trigger('vjFormDisableUpdate');
|
||||
$expire.prop('disabled', method === domainEnum.JOIN_METHOD_NONE).trigger('vjFormDisableUpdate');
|
||||
$code.prop('disabled', method !== domainEnum.JOIN_METHOD_CODE).trigger('vjFormDisableUpdate');
|
||||
}
|
||||
updateFormState();
|
||||
$('[name="method"]').change(() => updateFormState());
|
||||
});
|
||||
|
||||
export default page;
|
||||
Reference in new issue
Block a user