code: Сделан экран администратора XML
This commit is contained in:
parent
a62ba9da82
commit
92c2753592
@ -21,8 +21,7 @@
|
|||||||
tools:targetApi="31">
|
tools:targetApi="31">
|
||||||
<activity
|
<activity
|
||||||
android:name=".ui.RootActivity"
|
android:name=".ui.RootActivity"
|
||||||
android:exported="true"
|
android:exported="true" >
|
||||||
android:theme="@style/Theme.MaterialComponents.DayNight.NoActionBar">
|
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="android.intent.action.MAIN" />
|
<action android:name="android.intent.action.MAIN" />
|
||||||
|
|
||||||
|
@ -0,0 +1,64 @@
|
|||||||
|
package ru.myitschool.work;
|
||||||
|
|
||||||
|
import android.os.Bundle;
|
||||||
|
|
||||||
|
import androidx.fragment.app.Fragment;
|
||||||
|
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A simple {@link Fragment} subclass.
|
||||||
|
* Use the {@link administrator_screen#newInstance} factory method to
|
||||||
|
* create an instance of this fragment.
|
||||||
|
*/
|
||||||
|
public class administrator_screen extends Fragment {
|
||||||
|
|
||||||
|
// TODO: Rename parameter arguments, choose names that match
|
||||||
|
// the fragment initialization parameters, e.g. ARG_ITEM_NUMBER
|
||||||
|
private static final String ARG_PARAM1 = "param1";
|
||||||
|
private static final String ARG_PARAM2 = "param2";
|
||||||
|
|
||||||
|
// TODO: Rename and change types of parameters
|
||||||
|
private String mParam1;
|
||||||
|
private String mParam2;
|
||||||
|
|
||||||
|
public administrator_screen() {
|
||||||
|
// Required empty public constructor
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Use this factory method to create a new instance of
|
||||||
|
* this fragment using the provided parameters.
|
||||||
|
*
|
||||||
|
* @param param1 Parameter 1.
|
||||||
|
* @param param2 Parameter 2.
|
||||||
|
* @return A new instance of fragment administrator_screen.
|
||||||
|
*/
|
||||||
|
// TODO: Rename and change types and number of parameters
|
||||||
|
public static administrator_screen newInstance(String param1, String param2) {
|
||||||
|
administrator_screen fragment = new administrator_screen();
|
||||||
|
Bundle args = new Bundle();
|
||||||
|
args.putString(ARG_PARAM1, param1);
|
||||||
|
args.putString(ARG_PARAM2, param2);
|
||||||
|
fragment.setArguments(args);
|
||||||
|
return fragment;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
if (getArguments() != null) {
|
||||||
|
mParam1 = getArguments().getString(ARG_PARAM1);
|
||||||
|
mParam2 = getArguments().getString(ARG_PARAM2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||||
|
Bundle savedInstanceState) {
|
||||||
|
// Inflate the layout for this fragment
|
||||||
|
return inflater.inflate(R.layout.fragment_administrator_screen, container, false);
|
||||||
|
}
|
||||||
|
}
|
9
app/src/main/res/drawable/ic_back.xml
Normal file
9
app/src/main/res/drawable/ic_back.xml
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:width="512dp"
|
||||||
|
android:height="512dp"
|
||||||
|
android:viewportWidth="512"
|
||||||
|
android:viewportHeight="512">
|
||||||
|
<path
|
||||||
|
android:fillColor="#FF000000"
|
||||||
|
android:pathData="M353,450a15,15 0,0 1,-10.61 -4.39L157.5,260.71a15,15 0,0 1,0 -21.21L342.39,54.6a15,15 0,1 1,21.22 21.21L189.32,250.1 363.61,424.39A15,15 0,0 1,353 450Z"/>
|
||||||
|
</vector>
|
12
app/src/main/res/drawable/ic_block.xml
Normal file
12
app/src/main/res/drawable/ic_block.xml
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:width="128dp"
|
||||||
|
android:height="128dp"
|
||||||
|
android:viewportWidth="128"
|
||||||
|
android:viewportHeight="128">
|
||||||
|
<path
|
||||||
|
android:fillColor="#FF000000"
|
||||||
|
android:pathData="M64,1C47.5,1 34,14.5 34,31v26H15v70h99V57H94V31C94,14.5 80.5,1 64,1zM42,31c0,-12.1 9.9,-22 22,-22s22,9.9 22,22v26H42V31zM106,65v54H23V65H106z"/>
|
||||||
|
<path
|
||||||
|
android:fillColor="#FF000000"
|
||||||
|
android:pathData="M60,81h8v22h-8z"/>
|
||||||
|
</vector>
|
@ -112,18 +112,18 @@
|
|||||||
android:layout_height="35dp"
|
android:layout_height="35dp"
|
||||||
android:background="@drawable/button_grestroke_whiteback"
|
android:background="@drawable/button_grestroke_whiteback"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/photo_field"
|
app:layout_constraintBottom_toBottomOf="@+id/photo_field"
|
||||||
app:layout_constraintEnd_toEndOf="@+id/position_field"
|
app:layout_constraintEnd_toEndOf="@+id/username_field" />
|
||||||
app:layout_constraintTop_toBottomOf="@+id/position_field" />
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/lastEntry"
|
android:id="@+id/lastEntry"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="18dp"
|
||||||
|
android:layout_marginStart="12dp"
|
||||||
android:text="@string/lastLoginText"
|
android:text="@string/lastLoginText"
|
||||||
android:textColor="@color/black"
|
android:textColor="@color/black"
|
||||||
android:textSize="13sp"
|
android:textSize="13sp"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/lastEntry_field"
|
app:layout_constraintBottom_toBottomOf="@+id/lastEntry_field"
|
||||||
app:layout_constraintEnd_toEndOf="@+id/lastEntry_field"
|
|
||||||
app:layout_constraintStart_toStartOf="@+id/lastEntry_field"
|
app:layout_constraintStart_toStartOf="@+id/lastEntry_field"
|
||||||
app:layout_constraintTop_toTopOf="@+id/lastEntry_field" />
|
app:layout_constraintTop_toTopOf="@+id/lastEntry_field" />
|
||||||
|
|
||||||
|
@ -31,4 +31,6 @@
|
|||||||
<string name="text_input_login">Введите логин сотрудника</string>
|
<string name="text_input_login">Введите логин сотрудника</string>
|
||||||
<string name="text_for">чтобы посмотреть информацию о нем</string>
|
<string name="text_for">чтобы посмотреть информацию о нем</string>
|
||||||
<string name="error">error</string>
|
<string name="error">error</string>
|
||||||
|
<string name="block_user">Заблокировать</string>
|
||||||
|
<string name="text_access">доступ</string>
|
||||||
</resources>
|
</resources>
|
Loading…
x
Reference in New Issue
Block a user