Configure edition fields of UUID
This commit is contained in:
		@@ -17,7 +17,7 @@ public interface MockedResponseRepository extends CrudRepository<MockedMessage,
 | 
				
			|||||||
    /**
 | 
					    /**
 | 
				
			||||||
     * Finds all messages by their uuid
 | 
					     * Finds all messages by their uuid
 | 
				
			||||||
     * @param clientUUID the key-uuid of given set of messages
 | 
					     * @param clientUUID the key-uuid of given set of messages
 | 
				
			||||||
     * @return list of {@link com.r11.tools.model.MockedMessage}
 | 
					     * @return Optional of list of {@link com.r11.tools.model.MockedMessage}
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    List<MockedMessage> findAllByClientUUID(UUID clientUUID);
 | 
					    List<MockedMessage> findAllByClientUUID(UUID clientUUID);
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -17,6 +17,10 @@
 | 
				
			|||||||
    border: 0;
 | 
					    border: 0;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#uuid-flex-container .uuid-inputField-icon:hover{
 | 
				
			||||||
 | 
					    color: #2A93B0;
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.uuid-inputField-icon-span {
 | 
					.uuid-inputField-icon-span {
 | 
				
			||||||
    font-size: x-large;
 | 
					    font-size: x-large;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
@@ -20,13 +20,13 @@
 | 
				
			|||||||
                <div>
 | 
					                <div>
 | 
				
			||||||
                    <label for="uuid-input" class="block-display">UUID</label>
 | 
					                    <label for="uuid-input" class="block-display">UUID</label>
 | 
				
			||||||
                    <div id="uuid-flex-container">
 | 
					                    <div id="uuid-flex-container">
 | 
				
			||||||
                        <input id="uuid-input" disabled class="bordered-field flex-item with-padding diabled-background" value="UUID" style="margin-bottom:2%; width: 60%;"/>
 | 
					                        <input id="uuid-input" disabled onfocusout="changeUUID(this);" class="bordered-field flex-item with-padding diabled-background" value="UUID" style="margin-bottom:2%; width: 60%;"/>
 | 
				
			||||||
                        <button class="uuid-inputField-icon modification-button flex-item btn-copy action-button"> 
 | 
					                        <button onclick="copyUUIDToClipboard();" class="uuid-inputField-icon modification-button flex-item btn-copy action-button"> 
 | 
				
			||||||
                            <span class="material-icons uuid-inputField-icon-span ">content_copy</span> 
 | 
					                            <span class="material-icons uuid-inputField-icon-span ">content_copy</span> 
 | 
				
			||||||
                        </button>
 | 
					                        </button>
 | 
				
			||||||
                    </div>
 | 
					                    </div>
 | 
				
			||||||
                    <label for="editable">Editable</label>
 | 
					                        <label for="editable">Editable</label>
 | 
				
			||||||
                    <input type="checkbox" name="editable" id="editable" value="false"/>
 | 
					                        <input type="checkbox" onchange="changeEditionOfUUID(this)" name="editable" id="editable" value="false"/>
 | 
				
			||||||
                </div>
 | 
					                </div>
 | 
				
			||||||
                <div>
 | 
					                <div>
 | 
				
			||||||
                    <!-- h2 -->
 | 
					                    <!-- h2 -->
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -233,6 +233,27 @@ function fillStaticFields(uuid, id, mediaType, body, httpStatus){
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					function changeEditionOfUUID(element){
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    var inputFieldId= "#uuid-input"
 | 
				
			||||||
 | 
					    if(element.checked){
 | 
				
			||||||
 | 
					        $(inputFieldId).removeAttr('disabled');
 | 
				
			||||||
 | 
					    } else{
 | 
				
			||||||
 | 
					        $(inputFieldId).attr('disabled', true);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					function copyUUIDToClipboard(){
 | 
				
			||||||
 | 
					    navigator.clipboard.writeText( document.getElementById('uuid-input').value );
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					function changeUUID(element){
 | 
				
			||||||
 | 
					    clientUUID = element.value ;
 | 
				
			||||||
 | 
					    checkUuid();
 | 
				
			||||||
 | 
					    setCookie();
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function createLink(uuid, id){
 | 
					function createLink(uuid, id){
 | 
				
			||||||
    var link =  host + '/api/mock/r/'+uuid+'/'+id;
 | 
					    var link =  host + '/api/mock/r/'+uuid+'/'+id;
 | 
				
			||||||
    return link;
 | 
					    return link;
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user