parsav  Diff

Differences From Artifact [06727d1481]:

To Artifact [e47888d2bc]:


   193    193   	if relationship.rel.block() then
   194    194   		comments:lpush('<li style="--co:80">blocked</li>')
   195    195   	end
   196    196   
   197    197   	if relationship.recip.follow() then
   198    198   		comments:lpush('<li style="--co:30">follows you</li>')
   199    199   	end
          200  +
          201  +	var circpanel = co:stra(128)
          202  +	var allcircs = co.srv:circle_search(&co.srv.pool, co.who.id, 0)
          203  +	if allcircs:ref() then
          204  +		var mycircs = co.srv:circle_memberships_uid(&co.srv.pool, co.who.id, actor.id)
          205  +		for i=0, allcircs.ct do
          206  +			circpanel:lpush '<label><input type="checkbox" name="circle" value="'
          207  +			         :shpush(allcircs(i).cid)
          208  +					 :lpush '"> '
          209  +					 :ppush(allcircs(i).name)
          210  +					 :lpush '</label>'
          211  +		end
          212  +	end
   200    213   
   201    214   	var profile = data.view.profile {
   202    215   		nym = fullname;
   203    216   		bio = bio;
   204    217   		xid = cs(actor.xid);
   205    218   		avatar = cs(actor.avatar);
   206    219   
................................................................................
   208    221   		nfollowers = sn_followers, nmutuals = sn_mutuals;
   209    222   		tweetday = cs(timestr);
   210    223   		timephrase = lib.trn(actor.origin == 0, pstr 'joined', pstr 'known since');
   211    224   
   212    225   		remarks = '';
   213    226   
   214    227   		auxbtn = auxp;
          228  +		circles = circpanel:finalize();
   215    229   		relations = relbtns:finalize();
   216    230   		sanctions = sancbtns:finalize();
   217    231   	}
   218    232   	if comments.sz > 0 then profile.remarks = comments:finalize() end
   219    233   
   220    234   	var ret = profile:poolstr(&co.srv.pool)
   221    235   	-- auxp:free() 
   222    236   	--if actor.bio ~= nil then bio:free() end
   223    237   	--if comments.sz > 0 then profile.remarks:free() end
   224    238   	return ret
   225    239   end
   226    240   
   227    241   return render_profile