You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
			
				
					27 lines
				
				918 B
			
		
		
			
		
	
	
					27 lines
				
				918 B
			| 
											2 months ago
										 | <script>
 | ||
|  |   let Data = new GetJson("/api/admin/table/{{ .Table }}/{{ .Id }}");
 | ||
|  | </script>
 | ||
|  | 
 | ||
|  | <h1><a href="/admin/table/{{ .Table }}/">«</a>Admin {{ .Table }}</h1>
 | ||
|  | 
 | ||
|  | <block x-data="Data">
 | ||
|  |   <form method="POST" action="/api/admin/table/{{ .Table }}/{{ .Id }}">
 | ||
|  |     <card>
 | ||
|  |     <top><h1>{{ .Table }} : {{ .Id }}</h1></top>
 | ||
|  |     <middle>
 | ||
|  |       <template x-for="(value, key) in item">
 | ||
|  |         <div>
 | ||
|  |           <label x-text="key" x-bind:for="key"></label>
 | ||
|  |           <input x-bind:name="key" x-text="value" x-model="item[key]" x-bind:id="key" />
 | ||
|  |         </div>
 | ||
|  |       </template>
 | ||
|  |     </middle>
 | ||
|  |     <bottom>
 | ||
|  |       <button type="button"><a href="/admin/table/{{ .Table }}/">Back</a></button>
 | ||
|  |       <button class="hover:btn-alert" type="button" @click.prevent="ConfirmDelete('{{ .Table }}', item.id)">Delete</button>
 | ||
|  |       <button class="hover:btn-hover" type="submit">Update</button>
 | ||
|  |     </bottom>
 | ||
|  |     </card>
 | ||
|  |   </form>
 | ||
|  | </block>
 |