View | Details | Raw Unified | Return to bug 35341
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tt (-12 / +16 lines)
Lines 475-481 Link Here
475
                                       <option value="0">Exactly on</option>
475
                                       <option value="0">Exactly on</option>
476
                                       <option value="1">After</option>
476
                                       <option value="1">After</option>
477
                                    </select>
477
                                    </select>
478
                                    <input type="text" size="10" id="hardduedate" name="hardduedate" value="[% hardduedate | html %]" class="flatpickr" />
478
                                    <input type="text" size="10" id="hardduedate" name="hardduedate" class="flatpickr" />
479
                                    <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
479
                                    <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
480
                                </td>
480
                                </td>
481
                                <td><input type="text" name="decreaseloanholds" id="decreaseloanholds" size="2" /></td>
481
                                <td><input type="text" name="decreaseloanholds" id="decreaseloanholds" size="2" /></td>
Lines 508-514 Link Here
508
                                </td>
508
                                </td>
509
                                <td><input type="text" name="no_auto_renewal_after" id="no_auto_renewal_after" size="3" /></td>
509
                                <td><input type="text" name="no_auto_renewal_after" id="no_auto_renewal_after" size="3" /></td>
510
                                <td>
510
                                <td>
511
                                    <input type="text" size="10" name="no_auto_renewal_after_hard_limit" id="no_auto_renewal_after_hard_limit" value="[% no_auto_renewal_after_hard_limit | html %]" class="flatpickr"/>
511
                                    <input type="text" size="10" name="no_auto_renewal_after_hard_limit" id="no_auto_renewal_after_hard_limit" class="flatpickr"/>
512
                                    <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
512
                                    <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
513
                                </td>
513
                                </td>
514
                                <td><input type="text" name="reservesallowed"  id="reservesallowed"  size="2" /></td>
514
                                <td><input type="text" name="reservesallowed"  id="reservesallowed"  size="2" /></td>
Lines 1503-1518 Link Here
1503
                        var note = $(this).find("a[name='viewnote']").data("content");
1503
                        var note = $(this).find("a[name='viewnote']").data("content");
1504
                        $(current_column).find("input[type='text']").val(note);
1504
                        $(current_column).find("input[type='text']").val(note);
1505
                    } else if ( i == 9 ) {
1505
                    } else if ( i == 9 ) {
1506
                        // specific processing for the Hard due date column
1506
                        // specific processing for Hard due date
1507
                        var select_value = $(this).find("input[type='hidden'][name='hardduedatecomparebackup']").val();
1507
                        $(current_column).find("select").val(itm_code);
1508
                        var input_value = '';
1508
                        if (itm_text) {
1509
                        if (typeof select_value === 'undefined'){
1509
                            input_values = itm_text.split(' ');
1510
                            select_value = '-1';
1510
                            var fp = $('#hardduedate').flatpickr();
1511
                        }else {
1511
                            var hardduedate = fp.parseDate( input_values[1], flatpickr_dateformat_string );
1512
                            input_value = itm_text.split(' ')[1];
1512
                            if( hardduedate) fp.setDate( hardduedate, 1 );
1513
                        }
1514
                    } else if ( i == 26 ) {
1515
                        // specific processing for No automatic renewal after (hard limit)
1516
                        if (itm_text) {
1517
                            var fp = $('#no_auto_renewal_after_hard_limit').flatpickr();
1518
                            var renewdate = fp.parseDate( itm_text, flatpickr_dateformat_string );
1519
                            if( renewdate) fp.setDate( renewdate, 1 );
1513
                        }
1520
                        }
1514
                        $(current_column).find("input[type='text']").val(input_value);
1515
                        $(current_column).find("select").val(select_value);
1516
                    } else if ( i == 16 ) {
1521
                    } else if ( i == 16 ) {
1517
                        // specific processing for cap_fine_to_replacement_price
1522
                        // specific processing for cap_fine_to_replacement_price
1518
                        var cap_fine_to_replacement_price = $(this).find("input[type='checkbox']");
1523
                        var cap_fine_to_replacement_price = $(this).find("input[type='checkbox']");
1519
- 

Return to bug 35341