text:
import F from '../fragments'

export const user = `
  query user($login: String!, $userHasLogin: Boolean!) {
    user(login: $login) {
      ${F.author}
      views
      sex
      location
      social {
        ${F.userSocial}
      }
      meta {
        isMaker
        publishedPostsCount
        publishedJobsCount
        publishedBlogsCount
        publishedWorksCount
        publishedRadarsCount
        publishedMeetupsCount
      }
      followersCount
      followingsCount
      viewerHasFollowed @include(if: $userHasLogin)
      achievement {
        ${F.achievement}
      }
      fromGithub
      githubProfile {
        htmlUrl
        login
      }
      contributes {
        records {
          count
          date
        }
        startDate
        endDate
        totalCount
      }

      subscribedCommunitiesCount

      insertedAt
    }
  }
`

export const sessionState = `
  query {
    sessionState {
      isValid
      user {
        ${F.author}
        geoCity
        bio
        fromGithub
        location
        social {
          ${F.userSocial}
        }
        sex
        cmsPassport
        subscribedCommunitiesCount
        customization {
          ${F.c11n}
        }
        githubProfile {
          htmlUrl
          login
        }
        achievement {
          ${F.achievement}
        }
      }
    }
  }
`

redpajama_set_name: RedPajamaGithub


text:
/**
 * Created by konzuk on 12/18/2015.
 */

(function () {
    "use strict";

    var app = angular.module("app");

    var controllerId = "addEditDepositDialogCon";
    app.controller(controllerId,
        ["$scope","$uibModalInstance","data","type","depositModel", deposit]);

    function deposit ($scope, $uibModalInstance,data,type,depositModel) {

        var controller = "deposit";

        if(depositModel)
        {
            $scope.isEdit = true;
            $scope.model = depositModel;
        }
        else
        {
            data.get(controller, "initialize_deposit",type).then(function(obj){
                if(obj.data)
                {
                    $scope.model = obj.data;
                }
                else
                {

                }
            });
        }

        $scope.save = function () {
            if(!$scope.isEdit) {
                data.post(controller, "add_deposit", $scope.model).then(function (obj) {
                    if (obj.data) {
                        $uibModalInstance.close(true);
                    }
                    else {

                    }
                });
            }
            else {
                data.post(controller, "update_deposit", $scope.model).then(function (obj) {
                    if (obj.data) {
                        $uibModalInstance.close(true);
                    }
                    else {

                    }
                });
            }

        };

        $scope.cancel = function () {
            $uibModalInstance.dismiss('cancel');
        };
    };
})();


text:
package com.micmiu.common.util;

import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import net.sf.cglib.beans.BeanMap;

import java.util.List;
import java.util.Map;

/**
 * javabean  和 Map 互相转换工具
 * User: micmiu
 * Date: 8/1/2017
 * Time: 00:03
 */
public class BeanMapMapper {

	/**
	 * 将对象装换为map
	 *
	 * @param bean
	 * @return
	 */
	public static <T> Map<String, Object> beanToMap(T bean) {
		Map<String, Object> map = Maps.newHashMap();
		if (bean != null) {
			BeanMap beanMap = BeanMap.create(bean);
			for (Object key : beanMap.keySet()) {
				map.put(key + "", beanMap.get(key));
			}
		}
		return map;
	}

	/**
	 * 将map装换为javabean对象
	 *
	 * @param map
	 * @param bean
	 * @return
	 */
	public static <T> T mapToBean(Map<String, Object> map, T bean) {
		BeanMap beanMap = BeanMap.create(bean);
		beanMap.putAll(map);
		return bean;
	}

	/**
	 * 将List<T>转换为List<Map<String, Object>>
	 *
	 * @param objList
	 * @return
	 */
	public static <T> List<Map<String, Object>> objectsToMaps(List<T> objList) {
		List<Map<String, Object>> list = Lists.newArrayList();
		if (objList != null && objList.size() > 0) {
			Map<String, Object> map = null;
			T bean = null;
			for (int i = 0, size = objList.size(); i < size; i++) {
				bean = objList.get(i);
				map = beanToMap(bean);
				list.add(map);
			}
		}
		return list;
	}

	/**
	 * 将List<Map<String,Object>>转换为List<T>
	 *
	 * @param maps
	 * @param clazz
	 * @return
	 * @throws InstantiationException
	 * @throws IllegalAccessException
	 */
	public static <T> List<T> mapsToObjects(List<Map<String, Object>> maps, Class<T> clazz) throws InstantiationException, IllegalAccessException {
		List<T> list = Lists.newArrayList();
		if (maps != null && maps.size() > 0) {
			Map<String, Object> map = null;
			T bean = null;
			for (int i = 0, size = maps.size(); i < size; i++) {
				map = maps.get(i);
				bean = clazz.newInstance();
				mapToBean(map, bean);
				list.add(bean);
			}
		}
		return list;
	}
}