mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-22 16:03:47 +01:00
Enable/Disable add participants based on participant value in calendar edit
This commit is contained in:
parent
c4ff76b47d
commit
0ba271d581
@ -94,7 +94,7 @@ var et2_button = (function(){ "use strict"; return et2_baseWidget.extend([et2_II
|
||||
this.setDOMNode(this.image[0]);
|
||||
return;
|
||||
}
|
||||
if (!this.options.readonly)
|
||||
if (!this.options.readonly || this.options.ro_image)
|
||||
{
|
||||
this.btn = $j(document.createElement("button"))
|
||||
.addClass("et2_button")
|
||||
|
@ -254,6 +254,7 @@ button.et2_button_with_image {
|
||||
background-repeat: no-repeat;
|
||||
background-size: 16px;
|
||||
height: 24px;
|
||||
background-position: center;
|
||||
}
|
||||
button.et2_button_with_image.et2_button_text {
|
||||
background-position: 4px center;
|
||||
|
@ -1119,6 +1119,18 @@ app.classes.calendar = (function(){ "use strict"; return AppJS.extend(
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Change participant add button status based on
|
||||
* participants field value
|
||||
*
|
||||
*/
|
||||
participantOnChange: function () {
|
||||
var add = this.et2.getWidgetById('add');
|
||||
var participant = this.et2.getWidgetById('participant');
|
||||
|
||||
add.set_readonly(!Number(participant.get_value()));
|
||||
},
|
||||
|
||||
/**
|
||||
* print_participants_status(egw,widget)
|
||||
* Handle to apply changes from status in print popup
|
||||
|
@ -54,9 +54,9 @@
|
||||
</columns>
|
||||
<rows>
|
||||
<row class="th"></row>
|
||||
<row disabled="@no_add" height="35">
|
||||
<button align="center" id="add" image="add" background_image="1" novalidate="1"/>
|
||||
<calendar-owner id="participant" allowFreeEntries="true" span="2" empty_label="Add new participants or resource"/>
|
||||
<row disabled="@no_add" height="35" class="et2_toolbar">
|
||||
<button align="center" id="add" image="add" novalidate="1" background_image="1" readonly="true" ro_image="add"/>
|
||||
<calendar-owner id="participant" allowFreeEntries="true" span="2" empty_label="Add new participants or resource" onchange="app.calendar.participantOnChange"/>
|
||||
<textbox type="integer" align="center" id="quantity" min="1" size="3"/>
|
||||
<menulist>
|
||||
<menupopup class="selectRole" id="role"/>
|
||||
|
@ -11,7 +11,7 @@
|
||||
* @package calendar
|
||||
* @version $Id$
|
||||
*/
|
||||
/* $Id: app.css 55754 2016-04-15 11:12:08Z hnategh $ */
|
||||
/* $Id: app.css 55760 2016-04-18 08:34:53Z hnategh $ */
|
||||
/*Media print classes*/
|
||||
@media print {
|
||||
#calendar-view.et2_container,
|
||||
@ -2383,8 +2383,9 @@ button#exception:active {
|
||||
}
|
||||
/*calendar series add*/
|
||||
#calendar-edit_add {
|
||||
/* .Complete_Button_add;
|
||||
&:hover {.Complete_Button_add_hover;} */
|
||||
padding-left: 24px;
|
||||
background-size: 16px;
|
||||
background-position: center;
|
||||
}
|
||||
#calendar-edit_add:active {
|
||||
background-color: #1aa200 !important;
|
||||
|
@ -1089,8 +1089,9 @@ button#exception {
|
||||
/*calendar series add*/
|
||||
#calendar-edit_add {
|
||||
&:active {background-color: @color_positive_action_active !important;}
|
||||
/* .Complete_Button_add;
|
||||
&:hover {.Complete_Button_add_hover;} */
|
||||
padding-left:24px;
|
||||
background-size:16px;
|
||||
background-position: center;
|
||||
}
|
||||
/*calendar search freetime*/
|
||||
#calendar-edit_freetime{
|
||||
|
Loading…
Reference in New Issue
Block a user